How do I write to GPIO_AD pins on my RT1170?

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

How do I write to GPIO_AD pins on my RT1170?

ソリューションへジャンプ
261件の閲覧回数
violkvas
Contributor I

Hi, I am trying to toggle the state of my J10[8] pin but I can't write to it and it outputs the wrong logic after initialization.

My end goal is to use the LPSPI1 port to connect to my Renesas PTX105R NFC reader but now I am trying to debug the LPSPI port. I have initialized the J10[8] pin to have an initial output logic of 0 and to take the GPIO3 pin 29 as input signal so that I can write to it from software. (see picture)

But after executing BOARD_InitPins the J10[8] pin measures to 3.3V instead of 0V, and it does not change when I try to use GPIO_PinWrite(GPIO3, 29U, 0U). What am I missing?

ラベル(1)
0 件の賞賛
返信
1 解決策
143件の閲覧回数
Habib_MS
NXP Employee
NXP Employee

Hello again @violkvas,
when you click the button called "Update code", appears the next window:

Habib_MS_0-1719529268522.png

This window describes what files will change when you update the code.

 when you click, can you see the next message in Pin_mux.c file?

Habib_MS_1-1719529268523.png

At the same time, this link has many trainings that could help you to learn more about how use config tools, also in the same link you can see the file called "MCUXpresso Config Tools User's Guide (IDE)" that could be helps.

Also, if you experience any issue, do not hesitate to let me know.

BR

Habib

元の投稿で解決策を見る

0 件の賞賛
返信
4 返答(返信)
182件の閲覧回数
Habib_MS
NXP Employee
NXP Employee

Hello @violkvas,

I tested the pins with the configuration that you provided me in RT1170-EVKB. However, I did not see any issue respect the initial state (the value can toggle and initialize in logic 0).

In order to support you better, can you provide me the function generated by config tools called "BOARD_InitPins()"? This is in order to try a pinpoint if the issue is in the configuration of each pin.

Also, if you experience any issue, do not hesitate to let me know.

BR

Habib.

0 件の賞賛
返信
163件の閲覧回数
violkvas
Contributor I

Hi, I did eventually figure it out but good to know that you agree with the settings because I'm very new to all of this.

I found that the pins tool didn't generate the correct code when I pressed 'Update code' with my configuration. I commented out the old setting and set it to the GPIO pin I wanted manually and then everything worked.

IOMUXC_SetPinConfig(
      /*IOMUXC_GPIO_AD_30_LPSPI1_SOUT*/
      IOMUXC_GPIO_AD_30_GPIO_MUX3_IO29,
      0x02U);

 However I do wonder why it is that the pins tool does not alter to or generate up-to-date code?

0 件の賞賛
返信
144件の閲覧回数
Habib_MS
NXP Employee
NXP Employee

Hello again @violkvas,
when you click the button called "Update code", appears the next window:

Habib_MS_0-1719529268522.png

This window describes what files will change when you update the code.

 when you click, can you see the next message in Pin_mux.c file?

Habib_MS_1-1719529268523.png

At the same time, this link has many trainings that could help you to learn more about how use config tools, also in the same link you can see the file called "MCUXpresso Config Tools User's Guide (IDE)" that could be helps.

Also, if you experience any issue, do not hesitate to let me know.

BR

Habib

0 件の賞賛
返信
127件の閲覧回数
violkvas
Contributor I

I see, I thought it updated the files for me. Thanks!

0 件の賞賛
返信