Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GPIO not working on the BeagleBoneAI64 with firmware versions after April 2023 #7

Open
kevinacahalan opened this issue Oct 20, 2023 · 1 comment

Comments

@kevinacahalan
Copy link

beagleboard/Latest-Images#109

GPIO does not work on the BeagleBoneAI64 with firmware versions after April 2023. It neither works from Linux, or from an R5 core

With some no not so thorough testing, I have found that with the images before bbai64-emmc-flasher-debian-11.6-minimal-arm64-2023-04-06-4gb.img.xz , I am still able to control GPIO. With the images after bbai64-emmc-flasher-debian-11.6-minimal-arm64-2023-04-06-4gb.img.xz I can not control GPIO.

I initially hit this bug after I updated my BBAI64 and ran the eMMC firmware update scripts. With later testing I found that a simple apt dist-upgrade would stop GPIO from working.

Take a look at the #beaglebone-ai-64 channel in Discord to see discussion.

ALEX_PARK on the BeagleBone forum found that the problem is a device tree issue.
Solution: https://forum.beagleboard.org/t/bb-ai64-gpio-basics/36032/7?u=alex_park

@orgua
Copy link

orgua commented Dec 3, 2023

Just for completion I add steps for current debian / ubuntu images with kernel 5.10 ti - as this is still broken.

Check you are running 5.10 ti

uname -r

as there are images with kernel 6.1 or newer.

Now refresh devicetree-files & reboot

arm64/src/arm64/k3-j721e-beagleboneai64-bone-buses.dtsi
git clone https://github.com/beagleboard/BeagleBoard-DeviceTrees.git
cd BeagleBoard*
git checkout v5.10.x-ti-arm64 
# ... (instead of default v5.10.x-ti-unified)
make all_arm64
sudo make install_arm64

sudo reboot

Testing GPIO (here P8_03) should work now

gpioset 1 20=1
gpioset 1 20=0

sudo echo 320 >  /sys/class/gpio/export
sudo echo out > /sys/class/gpio/gpio320/direction
sudo echo 1 > /sys/class/gpio/gpio320/value

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants