Download - Programming CAN
![Page 1: Programming CAN](https://reader036.vdocuments.net/reader036/viewer/2022062720/56813370550346895d9a845b/html5/thumbnails/1.jpg)
Programming CAN
![Page 2: Programming CAN](https://reader036.vdocuments.net/reader036/viewer/2022062720/56813370550346895d9a845b/html5/thumbnails/2.jpg)
Jaguar ID
Each Jaguar has its own ID number. The factory default is 1, but for CAN to work each Jaguar must have its own unique ID.
To change the ID, you must first connect the Jaguars to the computer using the DB9 adapter. After this, you must run the BDC-COMM application that will come with LabView.
![Page 3: Programming CAN](https://reader036.vdocuments.net/reader036/viewer/2022062720/56813370550346895d9a845b/html5/thumbnails/3.jpg)
Jaguar ID (cont.)
Go to the System tab. Enter a new ID (2 to 63) and press Assign. You will then have 5 seconds to press the User button on the Jaguar being set. The light on the Jaguar should then blink a number of times equal to its ID.
![Page 4: Programming CAN](https://reader036.vdocuments.net/reader036/viewer/2022062720/56813370550346895d9a845b/html5/thumbnails/4.jpg)
![Page 5: Programming CAN](https://reader036.vdocuments.net/reader036/viewer/2022062720/56813370550346895d9a845b/html5/thumbnails/5.jpg)
Updating Firmware
After setting the IDs, you will need to update the firmware. While running the BDC-COMM application, select the ID of the Jaguar to be updated, then go to File>Update Firmware. Browse for the appropriate file, then click Update. This needs to be done for each Jaguar individually, and Black and Tan Jaguars each have their own version of firmware.
![Page 6: Programming CAN](https://reader036.vdocuments.net/reader036/viewer/2022062720/56813370550346895d9a845b/html5/thumbnails/6.jpg)
Re-image the CRio
Before the CAN system can be used with the CRio, the CRio has to be re-imaged. When it is re-imaged, you must select ‘Black Jaguar Serial Bridge’ from the CAN Driver Plug-in drop-down menu.
![Page 7: Programming CAN](https://reader036.vdocuments.net/reader036/viewer/2022062720/56813370550346895d9a845b/html5/thumbnails/7.jpg)
![Page 8: Programming CAN](https://reader036.vdocuments.net/reader036/viewer/2022062720/56813370550346895d9a845b/html5/thumbnails/8.jpg)
Opening the Motors
Opening CAN motors is just like opening a normal Jaguar or Victor. Just select ‘CAN Jaguar’ from the drop-down menu beneath the Open sub-vi.
![Page 9: Programming CAN](https://reader036.vdocuments.net/reader036/viewer/2022062720/56813370550346895d9a845b/html5/thumbnails/9.jpg)
The numeric value is the ID of the Jaguar being referenced, and the blue drop-down menu selects how the Jaguar will control what is hooked up to it.
Opening the Motors
![Page 10: Programming CAN](https://reader036.vdocuments.net/reader036/viewer/2022062720/56813370550346895d9a845b/html5/thumbnails/10.jpg)
Types of Control
The Jaguars can control in 4 different ways:• Percent Vbus – this is just like normal motor
control. (-1 to 1)• Voltage – Similar to Vbus, except it is in units of
voltage. (0-12)• Speed – Can control speed in RPM if an encoder
is connected to the Jaguar.• Position – Can control motor position if an
encoder or potentiometer is connected to the Jaguar.
![Page 11: Programming CAN](https://reader036.vdocuments.net/reader036/viewer/2022062720/56813370550346895d9a845b/html5/thumbnails/11.jpg)
Controlling the Motors
After the motors are opened, they function just as any other motor would, except the output values may need to be different depending on the type of control selected in Begin.
![Page 12: Programming CAN](https://reader036.vdocuments.net/reader036/viewer/2022062720/56813370550346895d9a845b/html5/thumbnails/12.jpg)
Sync Groups
The blue colored input on the Motor Set Output sub-vi syncs the updating of motor outputs for the Jaguars, so that all motors will change at the same time.
![Page 13: Programming CAN](https://reader036.vdocuments.net/reader036/viewer/2022062720/56813370550346895d9a845b/html5/thumbnails/13.jpg)
Jaguar Specific VI’s
![Page 14: Programming CAN](https://reader036.vdocuments.net/reader036/viewer/2022062720/56813370550346895d9a845b/html5/thumbnails/14.jpg)
![Page 15: Programming CAN](https://reader036.vdocuments.net/reader036/viewer/2022062720/56813370550346895d9a845b/html5/thumbnails/15.jpg)
![Page 16: Programming CAN](https://reader036.vdocuments.net/reader036/viewer/2022062720/56813370550346895d9a845b/html5/thumbnails/16.jpg)
![Page 17: Programming CAN](https://reader036.vdocuments.net/reader036/viewer/2022062720/56813370550346895d9a845b/html5/thumbnails/17.jpg)
Jaguar Status
![Page 18: Programming CAN](https://reader036.vdocuments.net/reader036/viewer/2022062720/56813370550346895d9a845b/html5/thumbnails/18.jpg)
Front Panel Indicator
![Page 19: Programming CAN](https://reader036.vdocuments.net/reader036/viewer/2022062720/56813370550346895d9a845b/html5/thumbnails/19.jpg)
Questions?