Monday, November 13, 2023

Mediapipe Hand Solution on Raspberry Pi to OSC to Modular CV / Gate


  1. Set up a Raspberry Pi 4 with a clean install of Raspberry Pi OS: 
  2. Install Mediapipe as per the instructions here:
  3. Install Python OSC on the Raspberry Pi: 
  4. Add ( to mediapipe/examples/hand_landmarker/rasperry_pi
  5. If using my Tele-o module ( replace ip in with the address of the ESP32 in the module. 
  6. If using a different OSC endpoint, replace ip in with the appropriate address. 
  7. It may be beneficial to change the port variable in - the default is 3000
  8. Pressing together or releasing the thumb and index finger sends a 1 or 0 on OSC path /gate/0
  9. The distance between the thumb and index finger sends a float 0 - 1 on OSC path /cv/0
  10. The X and Y co-ordinates of the index finger are sent as floats of 0 -1 on OSC paths /cv/1 and /cv/2
  11. These OSC paths can be changed with the variables near the top of