Toggle i/o bit on iMx6 .. ??

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Toggle i/o bit on iMx6 .. ??

ソリューションへジャンプ
1,584件の閲覧回数
johnballance
Contributor III

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

ラベル(4)
0 件の賞賛
返信
1 解決策
1,041件の閲覧回数
Raybiztech
Contributor V

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.

元の投稿で解決策を見る

0 件の賞賛
返信
1 返信
1,042件の閲覧回数
Raybiztech
Contributor V

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.

0 件の賞賛
返信