To toggle an i/o bit on iMx6 I believe i need to:
1: ensure I can write to GPIO block
2: set the pad ctl register to e.g.0x1b0b0
3: set the pad mux register to the correct alt to route the bit there
4: set relevant gpio dir bit to 1
5: write 1 or 0 to the right gpio data register bit
have I missed anything, e.g. clock enable? or anything else?
Thanks
John
Solved! Go to Solution.
Hi John,
In case of imx6 your prediction is almost right.
To write into GPIO you have to
1. Configure IOMUX to select GPIO mode (Via IOMUXC).
2. Set GPIO direction
3. Write value into corresponding data register.
For more information you can read Chapter 28: General purpose Input/output
in IMX6DQRM pdf.
Hi John,
In case of imx6 your prediction is almost right.
To write into GPIO you have to
1. Configure IOMUX to select GPIO mode (Via IOMUXC).
2. Set GPIO direction
3. Write value into corresponding data register.
For more information you can read Chapter 28: General purpose Input/output
in IMX6DQRM pdf.