LucidVR / lucidgloves

Arduino/ESP32 based DIY VR Haptic gloves. Compatible with SteamVR via OpenGloves.
MIT License
2.02k stars 259 forks source link

Allow Driving FFB Servo's through PCA9685 #98

Open Roastlawyer opened 1 year ago

Roastlawyer commented 1 year ago

Allows connecting and driving your FFB servo's through a PCA9685 I2C board instead of needing them directly connected to the ESP/Arduino, allowing you to control all your servo's using only two pins.

I setup the PCA code to follow the input format of the ESP32Servo and Servo.h libraries, allowing the servo commands to be passed to the PCA without changes.

Roastlawyer commented 1 year ago

Well, I moved the I2C struct into its own file as a normal function. Doing so fixed the compile error by indirectly #including AdvancedConfig.h in haptics.ino (and also wire.h which I had missed before) Either way. It now compiles and from what I can tell fully works again.

Roastlawyer commented 1 year ago

Alright, I think that's everything from your original comments done.