what a night mare to get something simple to work. ditch Linux use barebones
Sent from Yahoo Mail on Android From:"Mark Irwin" <[email protected]> Date:Wed, Apr 8, 2015 at 9:21 PM Subject:[beagleboard] Re: BBB- DCAN1 problems using latest debian image Hi Rui, I have reverted the changes to uEmv to comment out the #dtb line I then modified am335x-boneblack.dts to uncomment so that it looks like the following: /*can0: P9.19, P9.20: disable: i2c2: cape eeprom */ /* can0: peripheral */ #include "am335x-can0.dtsi" /* can0: pinmux */ #include "am335x-bone-can0.dtsi" /* can1: P9_24, P9_26 */ #include "am335x-can1.dtsi" #include "am335x-bone-can1.dtsi" I built the dtb using dtb-rebuilder and copied the new am335x-boneblack.dtb to /boot/dtbs/3.14.35-ti-rt-r56/ and rebooted the system. Now when i look in the /sys/kernel/debug/pinctrl/44e10800.pinmux/pinmux-pins pin 94 (44e10978.0): P9_20_pinmux.47 (GPIO UNCLAIMED) function pinmux_P9_20_i2c_pin group pinmux_P9_20_i2c_pin pin 95 (44e1097c.0): P9_19_pinmux.46 (GPIO UNCLAIMED) function pinmux_P9_19_i2c_pin group pinmux_P9_19_i2c_pin pin 96 (44e10980.0): P9_26_pinmux.53 (GPIO UNCLAIMED) function pinmux_P9_26_can_pin group pinmux_P$ pin 97 (44e10984.0): P9_24_pinmux.51 (GPIO UNCLAIMED) function pinmux_P9_24_can_pin group pinmux_P$ It seems that the DCAN0 is still associated with i2c and not can0. However I can now use ip link set can1 type can bitrate 125000 triple-sampling on loopback on ip link set can0 type can bitrate 125000 triple-sampling on loopback on and bring up both can devices. If i do candump can0 and cangen can0 i do see loopback messages however when connected with two transceivers one connected to can0 and other can1 and then running cangen can0 and candump can1 i dont get any transmitted bits. I tried using a scope on CANTX P9_26 to ground and find that nothing is coming out of this pin. I also found that running cangen can0 after a few seconds i am getting this error. cangen can0 write: No buffer space available could you give me a step by step from boot up to get the canbus running to see if there is something I am missing? Thanks Mark On Thursday, 9 April 2015 05:30:55 UTC+10, RFA wrote: Hi Mark, I would rebuild the device tree to make sure can0 is included. Revert the changes to uEnv.download Robert Nelson's dtb-rebuilder (https://github.com/ RobertCNelson/dtb-rebuilder) and checkout 3.14-ti.edit am335x-boneblack.dts to include can0.make am335x-boneblack.dtb and replace the original file in /boot/dtbs/3.14.35-ti-r56/reboot. Regards Rui On Wednesday, April 8, 2015 at 2:20:29 PM UTC+1, Mark Irwin wrote: Hi, I have been trying to build a proof of concept system using two beaglebone black units with there DCAN1 (pins P9_24 and P9_26) and two can transcievers TI SN65HVD251P. The can transceivers are powered from the same 5V bench supply as both of the beaglebone blacks. the canh and canl pins are terminated at both ends by 120R resistors to ensure the 60R bus impedence. I was following the instructions in other posts about updating to the latest debian version and then upgrading the kernel to 3.14. This i have done. uname -a Linux beaglebone 3.14.35-ti-rt-r56 #1 SMP PREEMPT Sun Mar 29 01:13:05 UTC 2015 armv7l GNU/Linux I added dtb=am335x-boneblack-can1.dtb to the uEnv.txt I have also installed the canbus tools within the image so i can attempt a cangen can0 and candump can0. On system boot i am doing the following: modprobe can modprobe can-dev modprobe can-raw ip link set can0 type can bitrate 125000 triple-sampling on ifconfig can0 up however if i use candump can0 and cangen can0 within two seperate putty sessions i dont see anything. If I create a vcan bus i do see the messages in loopback. sudo modprobe vcan sudo ip link add dev vcan0 type vcan sudo ifconfig vcan0 up Previously I was using an older debian image and found that when i ran cangen can0 that the buffer would give me an error that it was full. however now with the latest image i am not getting the bufer full message but still not seeing anything on the candump. What should i expect to see here? Can anyone see where I have gone wrong or a step i am missing? Thanks in advance. Mark -- For more options, visit http://beagleboard.org/discuss --- You received this message because you are subscribed to the Google Groups "BeagleBoard" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout. -- For more options, visit http://beagleboard.org/discuss --- You received this message because you are subscribed to the Google Groups "BeagleBoard" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
