Personal tools

Log in

Changes

From IGEP - ISEE Wiki

Jump to: navigation, search

What can I do with IGEPv2 EXPANSION

1,303 bytes added, 17:47, 10 September 2012
m
How to use CAN bus
== How to use CAN bus ==
 
[[Image:Igepv2expcanconnector.PNG|right|200px]]IGEPv2 Expansion integrates a CAN peripheral. Connect any CAN bus device or network to the CAN bus connector (J703).
 
You have to connect the two boards like this:<br>
 
IGEPv2 1 IGEPv2 2
.--- .---
| 1 |-X X-| 1 | VDD_CAN: Supply Voltage (+5V DC)
| 2 |------------------| 2 | CANL: CAN Low-Level Voltage I/O
| 3 |------------------| 3 | GND : Ground
| 4 |------------------| 4 | CANH : CAN High-Level Voltage I/O
.--- .---
 
If this is your first time accessing CAN bus, check J702 jumper is not connected before follow this tutorial. If you don't have this jumper, don't worry because its function is only for testing.
 
Now you can set up the interface (on all boards when using multiple IGEPv2 EXPANSION <span lang="en" id="result_box" class="short_text"><span title="Click for alternate translations" class="hps">connected to a CAN network simultaneously)</span></span>:<br>
 
/bin/ip link set can0 up type can bitrate 125000
 
If you want to receive CAN data, use:
 
candump can0
 
If you want to send CAN data, use:
 
cansend can0 -i 0x123 0xaa 0xbb 0xcc 0xdd
 
On the receiver side, you must see the following messages:
 
can0 123 [4] aa bb cc dd
 
Switch roles and try it again.
 
{{#lst:How to use CAN bus|IGEPv2 EXPANSION}}
''From [[How to use CAN bus]]''
4,199
edits