I am using an apalis imx8qm module mounted on an Ixora board version 1.2.
right now when starting the ixora board the gpio pins (1-8) goes high for ~1.3 seconds then set to “low” as set up in pinmux.c , also the pins are connected to ground with a pull down resistor, my question is, is there any way to prevent this behavior and keep the pins grounded during startup ?
Thank you for following up, unfortunately I didn’t have time to test this issue, but I will test it early next week and let you know to close the thread, sorry for the delay.
but just to make sure, setting the pin levels in the device tree won’t conflict with controlling the pins from the firmware later?
The title of the topic is misleading, it’s not about setting the pin levels in the device tree but setting them at boot time, in the U-Boot configuration.
Please check the proposed solution, it might solve your issue.
For example, I am looking at GPIO 0 13, which is by default HIGH in U-Boot, I perform gpio clear to set the pin to LOW and I want to keep this as the default value during u-boot until the kernel takes over. However, I cannot set it as a default, and rebooting just overwrites the old value which is HIGH.
From the linked page, actually, it was not clear to me how this can be implemented. Can you please let me know how I can implement such behavior?
I tried what Alex suggested on the other thread. The suggestion works, but it is not exactly what me and Ahmed were expecting to achieve. I wanted to reply to this thread since it is more relevant to this topic.
Please check the below image which is a signal reading from IMX8 booting up:
The suggested environmental variable to clear the GPIO13 (setting it to LOW) was created and implemented here. I put the GPIO 9 to distinguish what we achieve by doing this. So, GPIO 9 was not part of this change, but rather it is set to LOW when the Kernel takes over.
So, this approach does not set the GPIO LOW during the start, but rather 1.27seconds later. We want GPIOs to stay LOW during boot-up without the 1.27 seconds of being HIGH.
Can you help with the correct implementation?
Please let me know if I can clarify further.
Thank you and best regards,
Samir
Are you using Toradex built OS image? If so - could you provide its full name and output of the tdx-info command.
Could you please specify which pin on the module’s X1 connector corresponds to GPIO 9 and GPIO 13 that you’re referencing?