码迷,mamicode.com
首页 > 其他好文 > 详细

sama5d36 can0 can1 测试

时间:2015-03-18 13:50:14      阅读:136      评论:0      收藏:0      [点我收藏+]

标签:

1 删除/bin/ip

       保留/sbin/ip

 

2 ip link set can0 type can bitrate 125000

       ip link set can1 type can bitrate  125000

 

3    ifconfig can0 up

      ifconfig can1 up

 

4   ip link show

 

$2: can0: <NOARP,UP,LOWER_UP,ECHO> mtu 16 qdisc pfifo_fast state UNKNOWN mode DEFAULT group default qlen 10
link/can
$3: can1: <NOARP,UP,LOWER_UP,ECHO> mtu 16 qdisc pfifo_fast state UNKNOWN mode DEFAULT group default qlen 10
link/can

 

 

5 can0-----can1 loop测试

e.g. 5A1#11.2233.44556677.88 / 123#DEADBEEF / 5AA# / 123##1 / 213##311
1F334455#1122334455667788 / 123#R for remote transmission request.

# cansend can1 5A1#11.2233.44556677.88
# cansend can1 5A1#11.2233.44556677.88
# cansend can1 5A1#11.2233.44556677.88
# cansend can1 5A1#11.2233.44556677.88
# cansend can1 5A1#11.2233.44556677.88
# cansend can1 5A1#11.2233.44556677.88
# cansend can1 5A1#11.2233.44556677.88
# cansend can1 5A1#11.2233.44556677.88
# cansend can1 5A1#11.2233.44556677.88
# cansend can1 5A1#11.2233.44556677.88

 

 

# candump can0
can0 5A1 [8] 11 22 33 44 55 66 77 88
can0 5A1 [8] 11 22 33 44 55 66 77 88
can0 5A1 [8] 11 22 33 44 55 66 77 88
can0 5A1 [8] 11 22 33 44 55 66 77 88
can0 5A1 [8] 11 22 33 44 55 66 77 88
can0 5A1 [8] 11 22 33 44 55 66 77 88
can0 5A1 [8] 11 22 33 44 55 66 77 88
can0 5A1 [8] 11 22 33 44 55 66 77 88
can0 5A1 [8] 11 22 33 44 55 66 77 88
can0 5A1 [8] 11 22 33 44 55 66 77 88

sama5d36 can0 can1 测试

标签:

原文地址:http://www.cnblogs.com/zym0805/p/4346938.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!