Shape of the Wave · field notes
The Muse 2 is a consumer EEG headband: four dry electrodes, a motion sensor and a pulse sensor. We set one up without the vendor app, wrote a small Rust program that anyone can read and change, and wrote down everything the headset told us along the way.
The headband presses four electrodes against the head: two on the forehead (AF7, AF8) and two behind the ears (TP9, TP10), measured against a reference at the centre of the forehead. It samples each at 256 times a second. It also carries an accelerometer and gyroscope, and a light sensor on the forehead that sees the pulse.
Normally all of this goes to the Muse phone app, which turns it into guided meditation and keeps the raw signal to itself. Our setup skips the app. A program called muse2 talks to the headset directly and gives you the raw numbers, live on screen and as plain CSV files.
What has been checked against the real headset, and what has not.
| Piece | State | Evidence |
|---|---|---|
| USB console: versions, status, commands | Verified | Replies captured from the headset over the cable. |
| Bluetooth discovery and connection | Verified | Found and connected from a Mac; 17 characteristics listed. |
| EEG, four electrodes | Verified | 60-second recording, about 255 samples a second per channel, no packets lost. |
| Accelerometer and gyroscope | Verified | About 52 samples a second, gravity reads 1 g. |
| Pulse sensor (preset p50) | Verified | 30-second recording, three light channels at about 64 samples a second. |
| Battery telemetry | Verified | Battery percent and fuel gauge decode; the last two fields read zero on this unit. |
| Auxiliary EEG input (preset p20) | Not yet tried | Implemented from the published protocol. |
| Linux | Builds, not yet streamed | Compiles and passes tests on Linux; streaming was run on macOS. |
| Open firmware on the headset | Not available | Protocol core written and tested; no flashable image. See Firmware. |
You need a Mac or Linux machine with Bluetooth, the Rust toolchain, and a Muse 2.
curl -LO https://muse.shapeofthewave.com/muse2-open-driver.zip
unzip muse2-open-driver.zip && cd muse2-open-driver/host
cargo build --release
cargo test # the decoders, checked without a headset
Plug the headset in with a micro-USB cable that carries data, then:
./target/release/muse2 info
It prints the name, board, firmware and bootloader versions, and battery. No Bluetooth is involved.
Unplug the cable (the radio is off while charging), hold the power button until the lights sweep, put the band on, and close the Muse phone app if it is running anywhere nearby.
./target/release/muse2 scan # is it visible?
./target/release/muse2 stream # live readout, Ctrl-C to stop
./target/release/muse2 stream --seconds 120 --out rec/sitting-still
./target/release/muse2 stream --preset p50 --out rec/with-pulse
The live readout prints one line a second: for each electrode the signal size in microvolts and its alpha share (how much of the 4 to 30 Hz power sits in the 8 to 13 Hz alpha band), then head tilt, battery, and packets received and lost.
A good fit shows 5 to 30 µV per electrode when you sit still. Hundreds of microvolts means an electrode is not touching skin: move hair, dampen the electrodes slightly, tighten the band.
With --out, each run writes a folder of CSV files. Every row carries time_s, seconds since streaming began.
| File | Columns | Rate |
|---|---|---|
eeg.csv | time_s, channel, seq, microvolts | 256 per second per channel |
accel.csv | time_s, seq, x_g, y_g, z_g | 52 per second |
gyro.csv | time_s, seq, x_dps, y_dps, z_dps | 52 per second |
ppg.csv | time_s, channel, seq, raw | 64 per second per channel, preset p50 only |
telemetry.csv | time_s, seq, battery_percent, fuel_gauge_mv, adc_raw, temperature_c | every few seconds |
control.jsonl | each JSON reply from the headset | |
meta.json | start time, preset, versions, stream list |
The manual describes the micro-USB port as a charging port. On our unit it is also a serial console. Plugged into a computer the headset appears as a USB serial device (USB id 0483:5740, an STMicroelectronics id) and answers the same short text commands the phone app sends over Bluetooth. We have not seen this written up elsewhere.
$ muse2 usb v1
v1 -> {"ap":"headset","sp":"Blackcomb_revB","tp":"consumer","hw":"30.2","bn":1,"fw":"1.0.27","bl":"1.1.0","pv":1,"rc":0}
| Command | What came back |
|---|---|
v1 | versions: board, hardware, firmware, bootloader |
s | status: name, serial, address, processor id, battery, preset |
h d k | halt, start, keep-alive: each acknowledged |
p21 p20 p50 | choose which sensors stream |
a l x z | acknowledged; purpose not yet known |
b | two counters, rd and rt; purpose not yet known |
Two limits. Sensor data does not come out of the USB port, even after the start command. And while the cable is in, the radio is off, so you cannot charge and stream at once. Interaxon's own radio test report says the same.
We wanted open firmware on the headset itself. There is none. The Muse 2 runs Interaxon's closed firmware (1.0.27 on ours) on an STM32 microcontroller, and nobody has published a replacement or a dump. So the work has two layers.
Everything on the computer side is ours and readable: the transport, the packet decoders, the recording, the band-power maths. The headset's firmware is treated as a black box that speaks a documented protocol.
*0, writes 128-byte pages with a w command, sends a checksum with c, and boots back with *1.no_std library: the command parser, the reply framing, and encoders for every packet type, with 18 tests. It builds, and it is not something you can flash.What a real open firmware still needs: a genuine image to study, the chip identities, and a way to recover a headset if a flash goes wrong. Until those exist, flashing anything would risk the device.
Enough to write your own client in any language.
0xfe8d. Characteristics share the base 273e____-4c4d-454d-96be-f03bac821358.0001 is control. Write one length byte, the command text, and a newline. Replies come back as notifications: one length byte and a piece of JSON; join pieces until the closing brace.0x01, a length byte, then text.p21, then d, then k every couple of seconds.| Id | Stream | Packet after the 2-byte counter |
|---|---|---|
0003 to 0006 | EEG TP9, AF7, AF8, TP10 | twelve 12-bit samples; µV = 0.48828125 × (raw − 2048) |
0007 | EEG auxiliary input | same, preset p20 |
0009 | gyroscope | three (x, y, z) of signed 16-bit; × 0.0074768 degrees per second |
000a | accelerometer | three (x, y, z) of signed 16-bit; × 0.0000610352 g |
000b | telemetry | battery ÷ 512 percent, fuel gauge × 2.2 mV, ADC, temperature |
000f to 0011 | pulse sensor: ambient, infrared, red | six 24-bit samples, preset p50 |
The packet layouts come from the long-standing community projects muse-lsl and muse-js.
| Symptom | Cause and fix |
|---|---|
| "No Muse seen" | The cable is still plugged in, the headset is off, or the phone app has the connection. Unplug, power on, close the app. |
| Bluetooth "not authorized" on a Mac | macOS grants Bluetooth per application. Run from a terminal app that has it under System Settings, Privacy and Security, Bluetooth. A plain SSH login is refused; a tmux session started from an allowed terminal works. |
| Connects, then the headset switches off | The headset often drops the first connection after power-on within two seconds; the next one holds, and muse2 retries by itself. Left unconnected, the headset switches itself off: press the power button again. |
| Signal in the hundreds of microvolts | An electrode is off the skin. Adjust the fit and wait a few seconds for it to settle. |
muse2 info finds no port | The cable is charge-only. Use one that carries data. |
| Stream stops after ten seconds in your own client | Send the keep-alive command k every couple of seconds. |
One archive holds the host driver, the firmware protocol library, and the protocol notes. MIT licence.