We have a led ring on a usb camera for vision tracking. How would I code it in Java to turn on.
Use a digital output.
You’ll want something like this to switch the higher LED current from the roboRIO:
There are a number of devices like this for the Arduino and Raspberry Pi applications space. So long as they can be driven from the 3.3V output of the roboRIO, you’ll be fine.
I’m looking at the roboRIO manual and I don’t quickly see a current rating for the DIO ports but you definitely don’t want to drive your ring right from the roboRIO DIO port.
from what ive heard its supposed to be powered by the PWM ports and controlled in the code.
That’s a good point, you can run it from PWM and then be able to control the brightness.
You control it from the PWM and then handle power through an external switch like the one above.
Past years students have done straight to the PWM on the rio but since my mentor isnt adept at coding he didn’t have anything to do with that half of it.
You can get away with stuff all the up to where you can’t. That power controller I mentioned will work at PWM frequencies no problem.
It all comes down to only blowing up the cheap or less important part - neither of which are the roboRIO I’m afraid so you want insurance.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.