[NBLUG/talk] Beaglebone SPI linux device - Jezra this is for you

John Morio Sakaguchi morio.earth at gmail.com
Wed Aug 14 19:33:56 PDT 2013


Looked up that Python library wrapper for the SPI interface. Here is the c
file that does all the work.

https://github.com/adafruit/adafruit-beaglebone-io-python/blob/master/source/spimodule.c

Line 710 sets the variable path
if (snprintf(path, MAXPATH, "/dev/spidev%d.%d", bus+1, device) >= MAXPATH) {
Line 715 opens device for read/write
if ((self->fd = open(path, O_RDWR, 0)) == -1) {

So from what I gather,
/dev/spidev2.3
2 would be which spi interface you are using ( guessing there is only one,
so it should probably be 1 ).
3 would be the device would would like to fiddle with (e.g. my LCD or LED
character display also would probably be 1).

After that I don't know but here is a good place to start.
https://www.kernel.org/doc/Documentation/spi/spidev

-Morio
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://nblug.org/pipermail/talk/attachments/20130814/1417cc64/attachment.html>


More information about the talk mailing list