How the olympus mr100/500 remote works
Remote Connector Pinout
|| Wire Color (visible inside remote)
|| Direction (from device's perspective)
|| Audio ground (connects directly to ground of headphone jack)
|| Reset signal (active high, note that the device only resets after RESET has been held high for about 1 second)
| 3, 4
|| Bright pink, Red
|| Audio signals (stereo, connect directly to corresponding pins in headphone jack)
|| Data ground
|| UART Receive (from device's perspective, i.e. data sent from remote to device), works at roughly 19200 baud, 0 to +3.3V
|| UART Transmit (from device's perspective, i.e. data sent from device to remote), works at roughly 19200 baud, 0 to +3.3V
|| Supply for remote (roughly +3.3V)
There is a hardware key combination (on the remote) that asserts RESET regardless of its state (especially useful when it's crashed or not running stock firmware):
Hold Heart + Mode + Play for about 2 seconds to reset the device.
Remote Control Protocol
The remote control of the m:robe provides user input to the device through a series of buttons (Mode, Play, Next, etc.) and displays information about the state of the device through an LCD screen (graphic area for various uses, battery status, etc.). This page describes the serial protocol between the remote control and the device.
At the physical level, the protocol is asynchronous and serial (UART) operating at +3.3V and 19200 baud.
The LCD has both a graphic area (79x16 pixels) and custom masks (for the play mode and battery status).
Immediately after being powered, the remote is in sleep mode. The remote does not accept commands in sleep mode. To wake it up:
* Send something (anything; it can even be a single byte or a complete command).
* Wait about 10 ms for the remote to power up.
* The remote is now ready to accept commands. If you sent a command to wake it up, your command will not be replied.
Typically, a 30h frame is sent periodically to wake up a hotplugged remote as well as poll key state.
In both directions, data is encapsulated in frames composed of an opcode byte, the payload and two checksum fields:
|| 1 byte
|| see below
| XOR checksum
|| 1 byte
|| XOR of the opcode and all payload bytes
| Additive checksum
|| 1 byte
|| 8-bit sum of the opcode and all payload bytes
Remote to Mrobe
The only information reported by the remote to the m:robe is key presses. There is only one opcode for this; its payload indicates the current state of the keys. This opcode is send as a reply to every m:robe to remote command.
Opcode 0xF0 - key status
xx is a bit field representing the currently pressed keys
yy is a bit field representing the currently pressed keys
Mrobe to remote
The m:robe can control the remote in many ways, including turning the LCD on/off, turning the backlight on/off, drawing on the graphic area of the LCD and turning the masks (mode, battery status, etc.) on/off. All these opcodes are replied by the 0xF0 opcode. In other words, all these commands return the current key state.
|| Sent roughly ever 50 ms during normal operation. This seems to be a no-op used to poll the key state.
|| ff gg
|| LCD Control
|| En/Disable the LCD, backlight and sets LCD contrast
|| Mask Control
|| En/Disable the custom masks
|| ff ll x1 y1 x2 y2 d1 ... dn
|| Graphic Draw
|| Draws on the graphic area of the LCD
|| Puts the remote back into very low power sleep mode
Opcode 0x31 - LCD Control
ff is a bitfield representing various LCD control functions
|| LCD on/off
|| Backlight on/off
gg is an integer between 0 and 15 (inclusive) that sets the LCD contrast
Opcode 0x41 - LCD Masks
xx is a bitfield for the LCD masks
|| Batt Bar 1
|| Batt Bar 2
|| Batt Bar 3
|| Batt Case
|| Arrow (around the "1")
Opcode 0x51 - Graphic Draw
ff is a bitfield representing flags that control the draw operation
|| Immediate Update
If the Immediate update
bit is set, the draw occurs directly on the LCD. Otherwise, the data is stored in an off-screen buffer and displayed the next time a draw operation is executed with this flag set.
ll is the number of data bytes ("dd" bytes). This opcode may carry at most 79 bytes (one half-screen worth of data).
x1, y1 is the upper-left corner where the given data is to be drawn. x2, y2 is the lower-left corner. The x coordinates are in pixels, with 0 being at the far left of the screen. The y coordinates must be 0, 8 or 16, which represent the top of the screen, halfway down and the bottom edge of the screen, respectively.
d1 .. dn are data bytes representing the pixels to be drawn on the screen. The first byte represents the leftmost column of 8 pixels in the rectangle given by (x1, y1) - (x2, y2). The second byte represents the second column, etc.
This opcode requires at least 20 ms to complete its operation. Do not send this opcode more often than that.
Opcode 0x71 - Sleep
This opcode puts the remote back to sleep, like it was immediately at power-up. It draws very little current in this mode (30μa at 5V) but does not respond to any commands, so key status cannot be polled. See Power Up for information on waking the remote up from sleep mode.
Copyright © by the contributing authors.