Error: ENOENT, no such file or directory 'undefined/AIN5'

Am I the only one that gets this when trying to do Analog IO on a board that supposedly combines the best features of the Arduino (like Analog IO) with the Raspberry Pi? Is it something specific with my particular version of hardware? How do I get this fixed? I am trying to evaluate this hardware for a client assignment and it is really hard when I have to go back five flashers to find one that works! Just downloaded the latest and still get the error from the subject when running the Analog2 example script.

Help desired and appreciated!
Will

It has nothing to do with the revision of the hardware. You can see all of the changes made by each revision of the hardware on the support page.

Gerald

What Analog2 example script?

Pretty much all the hardware I/O stuff moved around with the switch
from the 3.2 kernel to 3.8, so you have to make sure whatever tools /
instructions you are using are for the right version.

To read an analog input pin with the latest 3.8 release, just:

# Load the device tree overlay to enable analog inputs
sudo su -c "echo cape-bone-iio > /sys/devices/bone_capemgr.*/slots"

# Read an analog value
cat /sys/devices/ocp.*/helper.*/AIN0

...that's all there is to it.

- --
Charles Steinkuehler
charles@steinkuehler.net

Charles et all:

As Gerald states…it is the bonescript library that is busted rendering the Cloud9 IDE inoperable for analog I/O (when using bonescript). Given that this IDE is highlighted by the BBB distribution it seems like it needs a fix! I will mess around with reading via the device…will be interesting to see what sample rate I get versus bonescript (running on a pre-kernel-update) version of the system.

Thanks for the input and if you know anyone that takes on responsibility for bonescript…

Cheers,
Will

Charles et all:

As Gerald states...it is the bonescript library that is busted rendering
the Cloud9 IDE inoperable for analog I/O (when using bonescript). Given
that this IDE is highlighted by the BBB distribution it seems like it needs
a fix! I will mess around with reading via the device...will be
interesting to see what sample rate I get versus bonescript (running on a
pre-kernel-update) version of the system.

Thanks for the input and if you know anyone that takes on responsibility
for bonescript...........

I have responsibility for BoneScript. Koen has responsibility for the
overall image, including the kernel, and the location for the analog inputs
has been changing between revisions and I wasn't aware. I've created a
test page[1], to test the basic bonescript functions. I'm in the process of
testing that page against the latest build such that I can recommend an
image for which BoneScript works (it worked in the original 4.13 image).
Once I've verified, I'll push my BoneScript updates for Koen to pull into
the latest image and require that all newly released images are run against
this test case.

[1] http://beagleboard.org/support/BoneScript/wired_basic_test/

Jason:

Great news. If you want someone to test the patch I can flash and patch on any of the recent distributions as I have been downloading them every time one comes out!

Will

Supposedly this issue has been corrected but an image with the correction is yet to appear. Hopefully some time this week? The problem has been marked as closed so it would be helpful if it were actually working in the current image. Just sayin.

Cheers,
Will