autti / veloz

Speed sign classifier
Other
5 stars 1 forks source link

Configure kvaser to use socketcan on linux and create dump files #7

Open ingenieroariel opened 7 years ago

ingenieroariel commented 7 years ago
{"bus": 1, "data": "0x0000f690001ff7ff", "id": 125, "timestamp": 1484685556.    242227}

should be

(1367859965.330495) can0 440#4001800000000000
ingenieroariel commented 7 years ago

Done, let's add pictures of the adapter we had to make, where we connected on the car and what commands we need to run in order to enable it. After that we can close the ticket.

eldarial commented 7 years ago

This is the connector for the Kvaser interface

image

According to Kvaser guide http://www.kvaser.com/software/7330130980146/V1_2_189/kvaser_leaf_light_v2_usersguide.pdf the pins in the db9 pins are

2 CAN LOW 3 GROUND 7 CAN HIGH

There is a 120 resistor between CAN HIGH and CAN LOW

These are the commands to setup the Kvaser interface with can-utils:

 sudo modprobe can
 sudo modprobe can-raw
 sudo modprobe can-dev
 sudo modprobe kvaser_usb
 sudo ip link set can0 type can bitrate 500000
 sudo ifconfig can0 up