BeagleBone specific API

Are the BeagleBone-specific APIs documented anywhere. things like
toggling pins and that kind of stuff? I'm interested in the C interface.

Thanks,
John

Hi John,

There isn't really a beaglebone specific API per se, however it does run Linux which has a largely generic API for managing toggling pins and things like that.

I would start at [1] and then either search for a C sysfs implementation of which I'm sure there are, or it should be fairly trivial to write your own.

Best Regards,
Jack

[1] http://www.nathandumont.com/node/250

Thanks, Jack.

I thought that I'd said something off-limits, given the silence...

I'm a long time Unix/Linux developer but not the BeagleBone specific
drivers. I could swear that when I was first looking around that I
found a wiki that documented things like addressing pins but I can't
find it again.

My needs are simple - a few digital pins, a few A/D pins and the SPI
bus, the later of which is giving me fits. Separate post for that.

Anyway, thanks for the pointer.

John

Thanks, Jack.

I thought that I'd said something off-limits, given the silence...

I'm a long time Unix/Linux developer but not the BeagleBone specific
drivers.

If you're feeling adventurous I would give the 3.8 circuitco kernel a go; available at [1]. It uses the newer device tree setup but in my opinion it is significantly less frustrating than the 3.2.x PSP variant. It's a bit less of a magic box of tricks.

I use the SPI and GPIO sucessfully with this kernel, but I can't speak for AD converters.

I could swear that when I was first looking around that I
found a wiki that documented things like addressing pins but I can't
find it again.

My needs are simple - a few digital pins, a few A/D pins and the SPI
bus, the later of which is giving me fits. Separate post for that.

Again, I know SPI works with 3.8 and I also had it going with 3.2 so it works on both ends. If your needs are simple and your requirements aren't latency sensitive then again I would suggest using sysfs, otherwise I would recommend delving into some kernel module writing.

Regards,
Jack.

[1] https://github.com/beagleboard/kernel/tree/3.8

Thanks, Jack.

I thought that I'd said something off-limits, given the silence...

I'm a long time Unix/Linux developer but not the BeagleBone specific
drivers.

If you're feeling adventurous I would give the 3.8 circuitco kernel a
go; available at [1]. It uses the newer device tree setup but in my
opinion it is significantly less frustrating than the 3.2.x PSP variant.
It's a bit less of a magic box of tricks.

Thanks for the reply, Jack.

I don't feel at all adventurous! We're embedding the BB in our next
product (an induction heater) so I just wanna get things running and got
on with the other aspects of the design.

I use the SPI and GPIO sucessfully with this kernel, but I can't speak
for AD converters.

I finally got mine working for communicating with an AD9835 DDS
oscillator. It requires that the chip select go false after each word
to signify end of message. Figuring out how to do that was a mess. The
compiler header file is wrong which cost me a lot of unnecessary time lost.

For others trying to use SPI, there is a test program in
KERNEL/Documentation/spi called spidev_test.c that shows how to actually
use the interface.

After I gather all my thoughts and get them organized, I'll write a post
about using SPI.

Again, I know SPI works with 3.8 and I also had it going with 3.2 so it
works on both ends. If your needs are simple and your requirements
aren't latency sensitive then again I would suggest using sysfs,
otherwise I would recommend delving into some kernel module writing.

I think that what I have now will work fine for my application. My
other large stepping stone is the outboard A/D converter. It needs to
run at 1 megasample a second which is set by the SPI clock frequency.
I'll find out later today if it can run that fast.

One thing I forgot to mention that I need is the PWM facility. Do you
or anyone else have any pointers to working PWM code? It will be
driving the transistor of a buck converter at about 40kHz.

Thanks again,
John