paper: Reading the FTC Battery Voltage

Thread created automatically to discuss a document in CD-Media.

Reading the FTC Battery Voltage
by: PhilBot

Forgetting to turn on an FTC robot’s battery, or accidentally letting the battery voltage get too low is a huge fear of mine. So I created a LabVIEW VI that can be used to read the battery voltage.

Forgetting to turn on an FTC robot’s battery, or accidentally letting the battery voltage get too low is a huge fear of mine. So I created a VI that can be used to read the battery voltage.

ReadBatteryVoltage.vi talks to any HiTechnic Motor Controller and reads the battery level in milli-Volts (mV). There are 1000 mV in one Volt.

A side benefit of this control is that if the power to the HiTechnic controller is NOT ON, then ReadBatteryVoltage.vi returns an error status. So this one control can be used to ensure that the power is turned on, and there is plenty of voltage.

Reading the FTC Battery Voltage.pdf (66 KB)
ReadBatteryVoltage.zip (26.7 KB)

Philbot, ive been racking my brain for the past few hours trying to figure out about the NXT items you have in the battery display, where can i find those items, all i have is question marks, please write back ASAP

OK, I’m going to assume you are working with FTC (not FRC), and if so, you should have downloaded a bunch of “FTC” vi’s to augment your copy of LabVIEW.

These are in addition to what you got when you did the initial FTC LabVIEW install.

Most of these VI’s are used to access the Motor Control Encoders (or encoder related functions). They are part of the “FTC Toolkit”.

The update is referenced on the FIRST FTC page:

http://www.usfirst.org/community/ftc/content.aspx?id=6650

Go to this page in the NI site to see the available updates:

http://zone.ni.com/devzone/cda/tut/p/id/7956

In particular is this update page:

http://joule.ni.com/nidu/cds/view/p/lang/en/id/1129

You want the update file called:
lv_ftc_motors_nov1708.zip

After downloading, you must follow the direction at the bottom of the page to install them. It requires you to unzip the files and copy them to a folder contained in the LabVIEW program folder.

c:\program files\LabVIEW 8.5\vi.lib\addons\FTC Toolkit

This should now give you a new sub-pallette called “FTC Motor Encoder Functions”

That’s where all the controls are that I use as part of my control.

Phil.

ok, well im actually in FRC, do you know if theres any compatibility there

None.

To read voltage in FRC you just need to read the analog voltage on chan 8 slot1 and convert to volts (scale by 1.68)

See how they do it to send to driver station.

http://www.gearsinc.org/images/getvoltage.jpg