cbcGirard / LINXx

Extensions to the LINX toolkit
BSD 2-Clause "Simplified" License
1 stars 0 forks source link

Firmware / Teensy 4.1 #1

Open alexruiz95 opened 4 weeks ago

alexruiz95 commented 4 weeks ago

Hello,

I have a teensy 4.1 and I followed the steps in the readme to install the Linxx package. I installed the Arduino libs and they are present but when I go to install the firmware using the maker hub tool it still shows the old stuff. Is there a way to install the firmware via the arduino ide? And is the 4.1 supported?

Really cool package!

Best Regards, Alex

cbcGirard commented 3 weeks ago

tl;dr: firmware installs thru Arduino IDE, 4.1 probably doable with a bit of effort.

Yes, you'll upload the firmware with the Arduino IDE, not the usual MakerHub menu in Labview. In the Arduino IDE, the firmware sketches are all available under the Examples menu, which you can then upload to the board like any other sketch. Looks like I didn't write a 4.0 firmware (oops), but it'll be basically identical to the 3.0 or 3.1 firmware.

I only have the library files for the 4.0, (and no physical 4.1 to test) but you could probably can run the 4.0's firmware on the 4.1 if you only use pins common to both.

To make a proper 4.1 variant, you'd need the following:

All those files are pretty similar among Teensy 3.x and 4.x variants, so it should only be a matter of changing a few constants, e.g. number of analog input channels. If you want to control the 4.1 over Ethernet instead of the USB serial connection, that would require changes to the listener code (more involved to implement).

alexruiz95 commented 3 weeks ago

Hello,

Thanks for the response! Yeah I played around with all the files in the repo and the LINX files. I could not find the sketches to write the firmware for the teensy 4.1.

I tried modifying the PJRC_Teensy31_Serial.ino by changing:

include To

include

But after a few hours of playing around with it still couldn’t get it to work with labview. I read up on the firmware and like you said changing the number of channels and definitions to possibly write my own. Seems all pretty straightforward, I'll maybe try again. It's for my experiment I am running which currently uses an arduino but it max's out at 50hz with two servos and I thought I could quickly switch over to the teensy:/