Hi all, *The short story is :*
I manage to use vcan0 but the same tests fails on my real can interface. I am not sure about my HW livelyness but I really don't know where to look at to see if everything is working. *The long one :* As I just found my way in the kernel modules, I'm am trying to send a message on my can bus. to begin smoothly, I loaded a vcan modules and tried cansend et candump with this script : > echo "Inserting can drivers..." > echo "insert can" > modprobe can > echo "insert can_raw" > modprobe can_raw > echo "insert can_bcm" > modprobe can_bcm > echo "insert vcan" > modprobe vcan > > echo "Configuring can ..." > ip link add dev vcan0 type vcan > ip link add dev vcan1 type vcan > ip link set up vcan0 > ip link set up vcan1 > And creates this can.log file : > (0.1) vcan0 5D1#0000 > (0.2) vcan0 271#0100 > (0.3) vcan0 289#72027000 > (0.4) vcan0 401#081100000000 > in one term I send : > ?>canplayer -l i -L can.log > in an other one I receive : > ?>candump vcan0 > (by the way if someone could tell me how to configure vcan speed, if it is meaningfull) Then I tried the same thing with my real hardware using this script : > echo "Inserting can drivers ..." > modprobe can > echo "insert can_raw" > modprobe can_raw > echo "insert can_bcm" > modprobe can_bcm > echo "insert sja1000" > modprobe sja1000 > echo "insert sja1000_isa" > insmod $MODPATH/drivers/net/can/sja1000/sja1000_isa.ko irq=5,7 > mem=0xD0000,0xD0200 > > echo "Configuring can drivers ..." > ip link set can0 type can bitrate 500000 > ip link set can1 type can bitrate 500000 > ip link set can0 type can restart-ms 10000 > ip link set can1 type can restart-ms 10000 > ifconfig can0 up > ifconfig can1 up > and uses the same commands after having changed "vcan0" into "can0" in my can.log file. As a result I have a full buffer error message (killing cansend) : > r...@alpha:/opt/ard# ../canplayer -l i -I can.log > sendto: No buffer space available > Here, I am totally lost, I don't know what to look at, I don't event know if my can hw is running. Could someone ligth up my path ? I tried different configuration like : _ no cabling _ cabling can0 into can1 _ cabling on open can0 I am not sure about my 120 Ohm resistors, I will check this on Monday, but as I am just trying to send is the real bus needed ? Here is some information I find relevant for analysis, I don't know what you need to look into my problem. /** HW INFORMATION **/ Then here is my config : _ http://www.ableway.com.cn/wp-content/uploads/2009/12/pcm-3362.pdf (there is a bus cartography) _ http://www.ixxat.com/pc_i_04_104_en.html /** CAN STATS **/ > r...@alpha:/opt/ard# cat /proc/net/can/stats > > 11 transmitted frames (TXF) > 0 received frames (RXF) > 0 matched frames (RXMF) > > 0 % total match ratio (RXMR) > 0 frames/s total tx rate (TXR) > 0 frames/s total rx rate (RXR) > > 0 % current match ratio (CRXMR) > 0 frames/s current tx rate (CTXR) > 0 frames/s current rx rate (CRXR) > > 0 % max match ratio (MRXMR) > 11 frames/s max tx rate (MTXR) > 0 frames/s max rx rate (MRXR) > > 0 current receive list entries (CRCV) > 0 maximum receive list entries (MRCV) > /** IFCONFIG **/ > r...@alpha:/opt/ard# ifconfig > can0 Link encap:UNSPEC HWaddr > 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00 > UP RUNNING NOARP MTU:16 Metric:1 > RX packets:0 errors:0 dropped:0 overruns:0 frame:0 > TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 > collisions:0 lg file transmission:10 > RX bytes:0 (0.0 B) TX bytes:0 (0.0 B) > Interruption:5 > > can1 Link encap:UNSPEC HWaddr > 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00 > UP RUNNING NOARP MTU:16 Metric:1 > RX packets:0 errors:0 dropped:0 overruns:0 frame:0 > TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 > collisions:0 lg file transmission:10 > RX bytes:0 (0.0 B) TX bytes:0 (0.0 B) > Interruption:7 Adresse de base:0x200 > > eth0 Link encap:Ethernet HWaddr 00:0b:ab:30:2f:c2 > inet adr:192.168.1.29 Bcast:192.168.1.255 Masque:255.255.255.0 > adr inet6: fe80::20b:abff:fe30:2fc2/64 Scope:Lien > UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 > RX packets:189493 errors:0 dropped:0 overruns:0 frame:0 > TX packets:51344 errors:0 dropped:0 overruns:0 carrier:0 > collisions:0 lg file transmission:100 > RX bytes:271627363 (259.0 MiB) TX bytes:4765941 (4.5 MiB) > Mémoire:febc0000-febe0000 > > lo Link encap:Boucle locale > inet adr:127.0.0.1 Masque:255.0.0.0 > adr inet6: ::1/128 Scope:Hôte > UP LOOPBACK RUNNING MTU:16436 Metric:1 > RX packets:0 errors:0 dropped:0 overruns:0 frame:0 > TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 > collisions:0 lg file transmission:0 > RX bytes:0 (0.0 B) TX bytes:0 (0.0 B) >
_______________________________________________ Socketcan-users mailing list [email protected] https://lists.berlios.de/mailman/listinfo/socketcan-users
