Hi folks!
For some reasons (mainly the kernel support for IEEE 802.11s) I need to use Debian (kernel 3.13 or higher; I’m currently running 3.16.1-bone4) on my BBB. For my project, I will also use the CAN interface of the BBB and some IO pins (mainly for LEDs and switches...).
This is my first BBB project so I searched the web for the easiest / best solution for using the GPIO pins of my BBBs.
In many tutorials about BBB GPIO and can-bus the use of the capemgr is suggested. But as you all know there is no capemgr in 3.16.
Now I would
really need your help to find the best way to enable the can-bus (dcan_1) and
also control some other GPIO pins. Can I do this from userspace some how? Or do
I have to reconfigure and rebuild the kernel?
@GPIO pins: I think the easiest solution is to use "echo [GPIO No.] > /sys/class/gpio/export" and then set the value & direction etc. using echo. Am I right here?
Thanks a
lot for your help and hints,
Marco
Hi again!
I spent some more hours on how to enable the d_can interfaces on my BBB.
I found Robert Nelsons "Really Simple Cape Manager" (RSCM) here [1].
This looks very promising at first. There is a folder for 3.13-bone and the
README says that
3.13-rc6-bone2 should be installed.
I'm currently working on 3.16.1-bone4. As far as I understand the idea behind
Robert’s RSCM I would need the original
.dts file of my BBB. Than add the needed lines to enable d_can1 (to enable d_can0
I would have to disable I2C2. Am I right?). The build a dtb file using dtc
(patched by Robert … he is present everywhere on the BBB I think! J) .
Finally I can move this
file to /boot/dtbs/3.16.1-bone4/ on my BBB (replace the existing dtb file(s).
But where can I find the dts file of my BBB? I wasn’t able to locate it on my board. Can I use the dts file from 3.13? Can I (permanently) damage my BBB when playing around here?
Would be great if someone
can help me!!!
[1] https://github.com/RobertCNelson/rscm
--
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 beagleboard...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Hi Jason!
Thanks for your help! The dtb-rebuilder looks like a very promising solution for me. Although, in
Robert's GitHub repo is just a branch for kernel "3.14-ti". So a very
similar question then in my last post: Can I use the scripts and the dts file
also on my 3.16-bone4 kernel?
Do you think that it would be possible to permanently damage my BBB, if I try
to use the scripts on my 3.16 BBB?
If this is possible, then I think (or more hope :) ) it would be really easy to enable
d_can1:
1.) Like suggested in [1] I would take the am335x-boneblack.dtb file.
2.) It looks like that includes can be added easily:
|
/* can1: P9_24, P9_26 */ |
|
#include "am335x-can1.dtsi" (Already there) |
|
#include "am335x-boneblack-can1.dts" (add this line; But I’m not sure if .dts files can be included like .dtsi file?!) |
|
/* #include "am335x-bone-can1.dtsi" */ |
3.) Build dtb file using dtb-rebuilder.
4.) Copy to /boot/dtbs/ dir.
5.) reboot
Would be great if you can help me once more here!
[1] http://elinux.org/Beagleboard:Capes_3.8_to_3.14#Custom_dtb
Yes and No... It'll boot, but not everything will work, ...
git clone -b 3.14-ti https://github.com/RobertCNelson/dtb-rebuilder.git"2.) Uncommented line 53 (/* #include "am335x-bone-can1.dtsi" */) in file dtb-rebuilder/src/arm/am335x-boneblack.dts.
> 4.) copied the am335x-boneblack.dtb file to /boot/dtbs/3.16.1-bone4/
> 5.) Reboot. Without result. After running modprobe can; modprobe can-dev;
> modprobe can-raw there was no CAN interface when typing ifconfig -a
Do you have can enabled?
The can "pinmux" relies on this patchset in my v3.14.x tree:
https://github.com/RobertCNelson/ti-linux-kernel-dev/tree/ti-linux-3.14.y/patches/beaglebone/pinmux-helper
> 6.) So I checked the uEnv file in /boot dir. There was a line "#dtb="
> 7.) Then I uncommented this line and used
> dtb=/boot/dtbs/3.16.1-bone4/am335x-boneblack.dtb
Yuck, don't do that, just the file name.. (i need to add the exact
path to the lookup function in u-boot so user's don't break their boot
via ^^^^that^^^)
--Hi Marco,
About the patch: I think I made a mistake and changed a similar line by hand. I wasn't checking too carefully because I'm not actually using can0 -- I just wanted to tell you that it was going to work so you could stop wasting your time. I reverted the repo to be sure, and now I can't find the line. Probably a "git pull" is all you need to ensure you have the latest and greatest code.Cheers.
You received this message because you are subscribed to a topic in the Google Groups "BeagleBoard" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/beagleboard/r9HSvN4JH4k/unsubscribe.
To unsubscribe from this group and all its topics, send an email to beagleboard...@googlegroups.com.