Page 1 of 1
Basic GPIO example doesn't work on Pico Ultra W
Posted: 2024-12-17 10:40
by Spock
Hi,
I'm testing GPIO functionality using basic example from Wiki.
Input seems work ok - but output does not.
Input works:
Code: Select all
[root@luckfox gpio]# echo 54 >export
[root@luckfox gpio]# cd gpio54/
[root@luckfox gpio54]# cat value
0
## connect 3.3V to GPIO1_C6. Multimeter shows 3.3V
[root@luckfox gpio54]# cat value
1
However output is not working:
Code: Select all
[root@luckfox gpio54]# echo out >direction
[root@luckfox gpio54]# echo 1 > value
[root@luckfox gpio54]# cat value
0
[root@luckfox gpio54]#
## Multimeter shows 0 (22 mV to be exact).
Is it me doint something wrong ?
Thanks!
Re: Basic GPIO example doesn't work on Pico Ultra W
Posted: 2024-12-20 9:21
by Spock
If that helps I'm using Pico Ultra W - maybe there is some HW bug with GPIO 54/55 I'm now aware.
According to Wiki those two are configured as GPIO by default.
Re: Basic GPIO example doesn't work on Pico Ultra W
Posted: 2024-12-23 1:40
by Crocodile
Hello 54 55 GPIO corresponds to GPIO1_C6 GPIO1_C7, the default is set to LCD data pin, please use luckfox-config to set RGB to disabled and then use iomux command to view multiplexing
If "mux get (GPIO1-22) = 0" is returned, the GPIO54 is successfully set to GPIO, and then the level is pulled high and low.
The default GPIO pins for the Luckfox Pico Ultra are GPIO32 (GPIO1_A0_d), GPIO33 (GPIO1_A1_d), GPIO40 (GPIO1_B0_d), and GPIO41 (GPIO1_B1_d).
The Luckfox Ultra W test I have in my hand is normal, and it is possible that the hardware is damaged
Re: Basic GPIO example doesn't work on Pico Ultra W
Posted: 2024-12-23 13:05
by Spock
Crocodile wrote: ↑2024-12-23 1:40
Hello 54 55 GPIO corresponds to GPIO1_C6 GPIO1_C7, the default is set to LCD data pin, please use luckfox-config to set RGB to disabled and then use iomux command to view multiplexing
If "mux get (GPIO1-22) = 0" is returned, the GPIO54 is successfully set to GPIO, and then the level is pulled high and low.
The default GPIO pins for the Luckfox Pico Ultra are GPIO32 (GPIO1_A0_d), GPIO33 (GPIO1_A1_d), GPIO40 (GPIO1_B0_d), and GPIO41 (GPIO1_B1_d).
The Luckfox Ultra W test I have in my hand is normal, and it is possible that the hardware is damaged
Thanks - you were right. After disabling RGB all started to work !
Thanks - I can buy more boards if my PoC will work
Re: Basic GPIO example doesn't work on Pico Ultra W
Posted: 2025-01-15 1:37
by Martin_Mortensen
how do you come up with iomux 1 22 from goio1_c7_d?
Re: Basic GPIO example doesn't work on Pico Ultra W
Posted: 2025-01-20 2:04
by Ryand
The command to obtain the iomux pin configuration is as follows:
iomux [bank index] [pin index]
Among them, The name gpio1_c7-d is GPIO {bank}_ {group}{X}, So the bank index is 1, and the pin index is group * 8+X=22, group=2 (A=0, B=1, C=2, D=3),X=7