Skip to content

kstruempf/DRV2605MidiC

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

99 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Haptic Midi Controller

Controls multiple DRV2605 Haptic Drivers via I²C protocol using midi files.

Mapping

Midi notes read from a midi file are mapped to 8 DR2605 drivers using a TCA9548A switch. The midi notes velocity is used as the drivers amplitude.

Mapping Table

Midi Note Note velocity Driver Amplitude
0 1 -> 0x01 1
1 10 -> 0x02 10
3 100 -> 0x03 100
... ... -> ... ...

Hardware Setup

Connecting the Multiplexer to the Raspberry Pi via GPIO (Vin/Ground/SDA/SCL). On the multiplexer use SDA/SCA 0-7 to connect up to 8 DRV2605L. You need one DRV2605 for each motor, since they all have the same adress 0x5A. 5V or 3.3V (both can be used, but has impact on Motor Strength) Connection and Ground from the Raspberry Pi can be in serial and soldered together.

ERM Motor is cheap but less precise. To accomplish good haptic Effects you need LRAs. Mode for each, LRA and ERM, is planned to be adjustable in the software.

How to use (Instructions)

A Makefile for basic usage is available (Maven Wrapper is included).

Install dependencies with

make build

Start the program with. Lets you select a midi file from the midi_test_files folder.

make start-midi

Start the program without any I²C devices connected (only reads and logs the selected midi file).

start-log

Prints help to the console.

make help

About

Vibration Motor controlled via Midi

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published