BB GPIO unable to unexport gpio

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
smbrandonjr
 
Posts: 27
Joined: Thu Oct 11, 2018 12:44 am

BB GPIO unable to unexport gpio

Post by smbrandonjr »

I want to use gpio0_30 for something in an app I have written. I am unable to unexport the gpio, but can export/unexport others...

I am using a Beaglebone Black, running:

dogtag:[BeagleBoard.org Debian Image 2017-03-19]
bootloader:[/dev/mmcblk0]:[U-Boot 2017.03-00002-gd12b1519b4]
bootloader:[/dev/mmcblk1]:[U-Boot 2018.03-00002-gac9cce7c6a]
kernel:[4.4.54-ti-r93]
nodejs:[v4.9.1]
Attachments
gpio-issue.PNG
gpio-issue.PNG (14.66 KiB) Viewed 645 times

User avatar
drewfustini
 
Posts: 944
Joined: Sat Dec 26, 2015 1:19 pm

Re: BB GPIO unable to unexport gpio

Post by drewfustini »

This version is u-boot bootloader on the eMMC is too old.

Please run this command on your BeagleBone to disable the old version of the u-boot bootloader on the eMMC:
sudo dd if=/dev/zero of=/dev/mmcblk1 bs=1M count=10

This will cause the newer u-boot bootloader on the SD card to be used.

User avatar
smbrandonjr
 
Posts: 27
Joined: Thu Oct 11, 2018 12:44 am

Re: BB GPIO unable to unexport gpio

Post by smbrandonjr »

Hi,

Thank you for this step. I am just now able to get around performing it and it got me where I needed to be. Thank you.

I am new to beaglebone and am curious if I will be able to use gpio0_2, gpio0_3, gpio0_4, and gpio0_5 or will those always be reserved for eMMC?

User avatar
drewfustini
 
Posts: 944
Joined: Sat Dec 26, 2015 1:19 pm

Re: BB GPIO unable to unexport gpio

Post by drewfustini »

if you boot from MicroSD, then you can reuse the eMMC pins.

Here is how to to disable eMMC in the u-boot bootloader:
https://elinux.org/Beagleboard:BeagleBo ... rd_devices

User avatar
smbrandonjr
 
Posts: 27
Joined: Thu Oct 11, 2018 12:44 am

Re: BB GPIO unable to unexport gpio

Post by smbrandonjr »

how can i release these pins so that i may control them?
pins.PNG
pins.PNG (29.55 KiB) Viewed 593 times

User avatar
drewfustini
 
Posts: 944
Joined: Sat Dec 26, 2015 1:19 pm

Re: BB GPIO unable to unexport gpio

Post by drewfustini »

Please paste the content of /boot/uEnv.txt

I should be able to advise which lines that you should change

User avatar
smbrandonjr
 
Posts: 27
Joined: Thu Oct 11, 2018 12:44 am

Re: BB GPIO unable to unexport gpio

Post by smbrandonjr »

uenv.PNG
uenv.PNG (61.64 KiB) Viewed 591 times

User avatar
smbrandonjr
 
Posts: 27
Joined: Thu Oct 11, 2018 12:44 am

Re: BB GPIO unable to unexport gpio

Post by smbrandonjr »

I'd really like to free up as many of the GPIO as possible...I need to be able to use the ethernet adapter and write my OS to the eMMC...other than that, I would like to be able to use it as my own defined input or output if it will be allowed.
gpio-bb.PNG
gpio-bb.PNG (152.74 KiB) Viewed 569 times
Which of these gpio remain available and how do I free them up?

User avatar
drewfustini
 
Posts: 944
Joined: Sat Dec 26, 2015 1:19 pm

Re: BB GPIO unable to unexport gpio

Post by drewfustini »

I think you have disabled as many of the peripherals as you can, per your uEnv.txt screenshot.

Which pins are you trying to use?

User avatar
smbrandonjr
 
Posts: 27
Joined: Thu Oct 11, 2018 12:44 am

Re: BB GPIO unable to unexport gpio

Post by smbrandonjr »

Drew,

Thanks for getting back to me. Until I stumbled across your Twitter, I didn't realize your association to OSHPark. Ironically, the hobby project I'm working on involves a PCB I had OSHPark create for me (very happy with the results). Unfortunately I made some oversights regarding which GPIOs I would have available and need to create a new version of my PCB.

I need to be able to use at least 45 GPIO for my project. I am not married to any specific GPIO except Serial4_RX and Serial4_TX.

Onboard platforms I want to utilize on by BB Black are the eMMC, Ethernet, the Type A USB, and the Mini B USB (my lack of understanding of the BB platform and embedded hardware in general prevents me from understanding whether modifying/utilizing the accessible GPIO with my application would impact any of those onboard devices...well I realize the eMMC platform based on our previous discussions but am unsure on the others)

User avatar
drewfustini
 
Posts: 944
Joined: Sat Dec 26, 2015 1:19 pm

Re: BB GPIO unable to unexport gpio

Post by drewfustini »

smbrandonjr wrote:Drew,
I need to be able to use at least 45 GPIO for my project. I am not married to any specific GPIO except Serial4_RX and Serial4_TX.

Onboard platforms I want to utilize on by BB Black are the eMMC, Ethernet, the Type A USB, and the Mini B USB (my lack of understanding of the BB platform and embedded hardware in general prevents me from understanding whether modifying/utilizing the accessible GPIO with my application would impact any of those onboard devices...well I realize the eMMC platform based on our previous discussions but am unsure on the others)
Hello - I am not certain if it is possible to have 45 GPIOs and eMMC.

I would be a question of the cross section between:
eMMC and HDMI
and
Digital I/O

I would recommend posting on the BeagleBoard.org community mailing list as it has a much wider audience including Jason Kridner (co-creator of the BeagleBone) and Robert Nelson (who creates the Debian images and kernel builds):
http://bbb.io/discuss

Locked
Please be positive and constructive with your questions and comments.

Return to “Beagle Bone & Adafruit Beagle Bone products”