Buff Flow — Motion Capture Setup Guide
This guide covers setting up Sony Mocopi motion capture for Buff Flow sessions. Motion data enables gesture recognition, form feedback, and the computational choreography features in later phases.
Full Public Reader
Buff Flow — Motion Capture Setup Guide
Document ID: BUFF-FLOW-MOCAP-001
Version: 1.0.0
Last Updated: 2026-01-18
---
Overview
This guide covers setting up Sony Mocopi motion capture for Buff Flow sessions. Motion data enables gesture recognition, form feedback, and the computational choreography features in later phases.
---
Equipment
Required
| Item | Model | Purpose | Status |
|---|---|---|---|
| Motion Sensors | Sony Mocopi (6 IMU) | Full-body tracking | To acquire |
| Recording Device | Laptop with cc-mcs | Motion capture server | Available |
| Backup Camera | iPhone/iPad | MediaPipe fallback | Available |
Recommended
| Item | Purpose | Priority |
|---|---|---|
| External SSD (500GB+) | Motion data storage | P1 |
| USB-C hub | Charging + data | P2 |
| Sensor straps (backup) | Replace worn straps | P3 |
---
Sony Mocopi Overview
What It Is
Sony Mocopi is a 6-sensor IMU (Inertial Measurement Unit) system that captures full-body motion without cameras. Each sensor tracks rotation and acceleration, and the system reconstructs a 27-bone skeleton.
Sensors
| Sensor | Placement | Tracks |
|---|---|---|
| Head | Headband/cap | Head orientation |
| Torso | Chest strap | Core rotation, posture |
| Left Wrist | Watch-style band | Left arm movement |
| Right Wrist | Watch-style band | Right arm movement |
| Left Ankle | Ankle strap | Left leg movement |
| Right Ankle | Ankle strap | Right leg movement |
Specifications
- Frame Rate: 60 Hz
- Latency: ~50ms
- Battery Life: ~10 hours per sensor
- Connectivity: Bluetooth LE
- Output: 27-bone skeleton (quaternion + position)
---
Sensor Placement for Buff Flow
Standard Placement
┌───┐
│ H │ ← Head sensor (headband)
└───┘
│
┌─────┼─────┐
│ │ │
LW [T] RW ← Wrists (watch bands), Torso (chest)
│ │
│ │
│ │
LA RA ← Ankles (straps)Placement Tips for Buff Flow
Head:
- Use sport headband, not cap (allows sweating)
- Sensor sits on forehead or side
- Tight enough to not shift during jumps
Torso:
- Center of chest, under apron if wearing
- Strap should be snug but allow breathing
- May need to adjust after warm-up
Wrists:
- Inside wrist preferred (less movement artifact)
- Below wristbone, above hand
- Secure when holding weights
Ankles:
- Above ankle bone, below calf
- Tight enough to not slip during jumps
- Check after warm-up
Weight Considerations
When dancing with weights, wrist sensors may shift:
- Use tighter bands
- Consider wrist wraps over sensors
- Check alignment between songs
---
Software Setup
cc-mcs (Motion Capture Server)
Location: `[home]/Desktop/Comp-Core/backend/cc-mcs/`
Starting the Server:
cd [home]/Desktop/Comp-Core/backend/cc-mcs
cargo run --releaseDefault Ports:
- Mocopi UDP: 12351
- WebSocket: 8765
- HTTP API: 3847
Mocopi App Connection
1. Open Sony Mocopi app on phone
2. Pair all 6 sensors
3. In app settings, enable "External Output"
4. Set destination IP to laptop
5. Set port to 12351 (UDP)
Verifying Connection
# Check if data is flowing
curl http://localhost:3847/status
# Should show:
# {
# "connected": true,
# "sensors": 6,
# "fps": 60,
# "session_id": "..."
# }---
Recording Workflow
Pre-Session Checklist
30 Minutes Before:
- [ ] Charge all 6 Mocopi sensors (check in app)
- [ ] Start laptop, open cc-mcs
- [ ] Create session folder: `YYYY-MM-DD_tier_name`
- [ ] Test Bluetooth connection
10 Minutes Before:
- [ ] Put on sensors
- [ ] Calibrate in Mocopi app (T-pose)
- [ ] Verify all 6 showing in cc-mcs
- [ ] Test range of motion
2 Minutes Before:
- [ ] Start recording in cc-mcs
- [ ] Say "Recording started" (audio marker)
- [ ] Begin session
During Session
Recording Controls:
- Start: `curl -X POST http://localhost:3847/record/start`
- Stop: `curl -X POST http://localhost:3847/record/stop`
- Mark: `curl -X POST http://localhost:3847/mark -d '{"label":"The Barista"}'`
Verbal Markers:
Say move names out loud during transitions:
- "Starting The Barista"
- "Into Coffee Grind"
- "Espresso Shot now"
This helps with labeling later (if also recording audio).
Sensor Issues:
If a sensor disconnects:
1. Continue session if possible
2. Note the time
3. Reconnect during recovery break
4. Re-calibrate if needed
Post-Session
Immediately After:
1. Stop recording
2. Verify file saved
3. Quick playback check
4. Note any issues in session log
Export:
# Export to standard format
cc-mcs export --session SESSION_ID --output /path/to/sessions/
# Creates:
# - session.json (metadata)
# - frames.bin (motion data)
# - markers.json (labeled points)---
Data Organization
Directory Structure
[home]/spine/Buf Barista/data/motion/
├── sessions/
│ ├── 2026-03-15_full-roast_001/
│ │ ├── session.json
│ │ ├── frames.bin
│ │ ├── markers.json
│ │ └── notes.txt
│ ├── 2026-03-17_first-brew_001/
│ └── ...
├── labeled/
│ ├── the-barista/
│ │ ├── sample_001.json
│ │ ├── sample_002.json
│ │ └── ...
│ ├── coffee-grind/
│ └── ...
└── motionphrase/
└── buff_flow_library.jsonSession Naming Convention
YYYY-MM-DD_tier_sequenceExamples:
- `2026-03-15_full-roast_001`
- `2026-03-15_full-roast_002`
- `2026-03-17_first-brew_001`
Session Log Template
Create `notes.txt` for each session:
Session: 2026-03-15_full-roast_001
Date: March 15, 2026
Tier: Full Roast (45 min)
Duration: 47:23
Sensors:
- All 6 connected throughout
- Left wrist strap loosened at 23:00, retightened
Issues:
- Brief dropout at 31:45 (~5 seconds)
- Head sensor shifted during jumps
Moves Performed:
- The Barista: Multiple throughout
- Coffee Grind: 3x in Flow Block 2
- Espresso Shot: 2x, once in each block
Notes:
- Good energy, clear move transitions
- New combo worth labeling: Flow Press → Coffee Grind---
Labeling Moves
Using cc-mcs Playback
# Start playback tool
cc-mcs playback --session 2026-03-15_full-roast_001
# Opens browser interface at localhost:3847/playbackLabeling Interface
1. Play/pause with spacebar
2. Use frame-by-frame arrows
3. Mark start frame (S key)
4. Mark end frame (E key)
5. Enter move name
6. Save label
Move Label Schema
{
"move_name": "the_barista",
"display_name": "The Barista",
"session_id": "2026-03-15_full-roast_001",
"start_frame": 3450,
"end_frame": 3690,
"duration_ms": 4000,
"quality": "good",
"notes": "Clean execution, full range"
}Quality Ratings
| Rating | Meaning | Use For |
|---|---|---|
| `excellent` | Perfect form, clear boundaries | Training primary |
| `good` | Minor issues, usable | Training general |
| `fair` | Form issues, boundaries unclear | Training with caution |
| `poor` | Don't use | Archive only |
---
Building MotionPhrase Library
What Is a MotionPhrase?
A MotionPhrase is a reusable motor program — a labeled segment of motion that can be:
- Retrieved by similarity (RAG++)
- Used for gesture classification training
- Compared for form feedback
Export to MotionPhrase Format
# From labeled moves
cc-mcs build-phrases \
--input /path/to/labeled/ \
--output /path/to/motionphrase/buff_flow_library.json
# Options
--min-quality good # Minimum quality to include
--normalize true # Normalize to standard skeleton
--include-anticipation # Add anticipation signalsLibrary Structure
{
"library_name": "buff_flow_v1",
"created": "2026-06-01",
"moves": {
"the_barista": {
"samples": 15,
"avg_duration_ms": 4000,
"embeddings": [...],
"anticipation_profile": {
"commitment_curve": [...],
"transition_points": [...]
}
},
"coffee_grind": {...},
...
}
}---
Troubleshooting
| Issue | Cause | Solution |
|---|---|---|
| Sensor won't pair | Bluetooth interference | Move away from WiFi router, other devices |
| Skeleton looks wrong | Calibration issue | Re-do T-pose calibration |
| Limbs jittering | Low battery | Charge sensors |
| Connection drops | Range | Stay within 5m of phone |
| Frame drops | CPU overload | Close other apps, reduce export quality |
| Data corrupt | Storage full | Clear space, use external SSD |
Sensor Battery Indicators
| LED | Meaning |
|---|---|
| Green solid | >50 |
| Green blinking | 20-50 |
| Red blinking | <20 |
| No light | Dead or not paired |
---
Backup Camera (MediaPipe)
When to Use
- Mocopi sensors unavailable
- Need hand/face data (not in Mocopi)
- Backup for sensor failures
- Testing without full setup
Setup
1. Position iPhone/iPad on tripod
2. Full body visible in frame
3. Good lighting (avoid backlight)
4. Start MediaPipe capture in cc-mcs
cc-mcs --mediapipe --camera-id 0Limitations vs Mocopi
| Aspect | Mocopi | MediaPipe |
|---|---|---|
| Frame rate | 60 Hz | ~30 Hz |
| Occlusion handling | Good (IMU) | Poor (camera) |
| Setup time | 5 min | 1 min |
| Accuracy | High | Medium |
| Hands/face | No | Yes |
---
Data Privacy
What Gets Recorded
- Skeleton positions/rotations only
- No video or images (unless MediaPipe backup)
- Session metadata (date, duration, tier)
- Move labels
Storage
- Local only (laptop + external SSD)
- No cloud upload unless explicitly enabled
- Backup to encrypted drive recommended
---
Related Documentation
- [COMP_CORE_INTEGRATION.md](COMP_CORE_INTEGRATION.md) — Full integration plan
- [BUFF_FLOW_PROGRAM.md](BUFF_FLOW_PROGRAM.md) — Program overview
- [CHOREOGRAPHY_LIBRARY.md](CHOREOGRAPHY_LIBRARY.md) — Move definitions
- Comp-Core docs: `/Desktop/Comp-Core/core/motion/cc-collection/docs/`
---
Change Log
| Version | Date | Changes |
|---|---|---|
| 1.0.0 | 2026-01-18 | Initial creation — Mocopi setup, recording workflow, labeling |
Promotion Decision
Attach run IDs, datasets, metrics, and reproduction commands.
Source Anchor
spine/Buf Barista/program/MOTION_CAPTURE_SETUP.md
Detected Structure
Evaluation · Code Anchors