AtomicRobot
Member
Hello all,
Looking for some advice on a project I am about to begin. I have not really programmed much since college, and decided to just jump right back in with this project. I figured if I break it in to chunks, it will be more manageable + it will be easier to relearn along the way.
I am going to be creating an open-source simple (at least hardware-wise) gyro peripheral that consists of a Teensy LC and an ST ISM330DHCX 9DoF IMU (breakoutboard from Adafruit: https://www.adafruit.com/product/4502) communicating via I2C.
While that part shouldn't be too difficult, I also aim to have the raw gyroscope and accelerometer data transferred to a PC. I am aiming to have the device show up as an HID compliant device, but I am not sure which type, or if I can configure it as an HID Gamepad and still transmit raw gyro/accel data. Does anyone have any advice on how to go about this?
My current project programming plan:
1) Get IMU communicating via I2C with the Teensy -verify with serial outputs
2) Trim down code to just output raw gyro/accel data
3) Create HID - specific code (i.e. HID report descriptor, rename Teensy, VID/PID, etc) ---> I anticipate this taking the most time, since this involves concepts I am not familiar with.
I have found these pages describing USB HID, and some using Teensy as guidance:
https://eleccelerator.com/tutorial-about-usb-hid-report-descriptors/
https://blog.hamaluik.ca/posts/making-a-custom-teensy3-hid-joystick/
On a different note, Adafruit has libraries for that IMU, and they are linked with their own I2C library. Would it be better to this route, or should I modify code to get the IMU library to work with the Teensy I2C library, since it apparently is more efficient/faster?
If anyone has any advice/feedback/information they could, that would be greatly appreciated!
Looking for some advice on a project I am about to begin. I have not really programmed much since college, and decided to just jump right back in with this project. I figured if I break it in to chunks, it will be more manageable + it will be easier to relearn along the way.
I am going to be creating an open-source simple (at least hardware-wise) gyro peripheral that consists of a Teensy LC and an ST ISM330DHCX 9DoF IMU (breakoutboard from Adafruit: https://www.adafruit.com/product/4502) communicating via I2C.
While that part shouldn't be too difficult, I also aim to have the raw gyroscope and accelerometer data transferred to a PC. I am aiming to have the device show up as an HID compliant device, but I am not sure which type, or if I can configure it as an HID Gamepad and still transmit raw gyro/accel data. Does anyone have any advice on how to go about this?
My current project programming plan:
1) Get IMU communicating via I2C with the Teensy -verify with serial outputs
2) Trim down code to just output raw gyro/accel data
3) Create HID - specific code (i.e. HID report descriptor, rename Teensy, VID/PID, etc) ---> I anticipate this taking the most time, since this involves concepts I am not familiar with.
I have found these pages describing USB HID, and some using Teensy as guidance:
https://eleccelerator.com/tutorial-about-usb-hid-report-descriptors/
https://blog.hamaluik.ca/posts/making-a-custom-teensy3-hid-joystick/
On a different note, Adafruit has libraries for that IMU, and they are linked with their own I2C library. Would it be better to this route, or should I modify code to get the IMU library to work with the Teensy I2C library, since it apparently is more efficient/faster?
If anyone has any advice/feedback/information they could, that would be greatly appreciated!