How to config a port pin as Hi-Z in S32DS

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

How to config a port pin as Hi-Z in S32DS

ソリューションへジャンプ
2,539件の閲覧回数
jetty_1012
Contributor II

Hello,

How can I configure a port pin as Hi-Z state in S32DS?

I'd appreciate it if you could show me an example.

jetty_1012_0-1695040360720.png

Thanks.

0 件の賞賛
返信
1 解決策
2,425件の閲覧回数
danielmartynek
NXP TechSupport
NXP TechSupport

Hi Jetty,

The Configuration tool does not allow to dissable the buffers.

Even the No init sets the buffers as per the initial direction configured there.

danielmartynek_0-1695198108836.png

But the pins can be configured for SIUL2 (which is the default muxing) and set them to inputs since the GPIO inputs have high impedance.

After the initialization, the pins can be set to Hi-Z using the Siul2_Port_Ip_SetPinDirection() if you want to have the input buffer disabled too.

danielmartynek_1-1695198370183.png

danielmartynek_2-1695198404525.png

Let me open a discussion with the RTD team to add this option to the Configuration tool.

 

Best regards,

Daniel

 

元の投稿で解決策を見る

3 返答(返信)
2,526件の閲覧回数
danielmartynek
NXP TechSupport
NXP TechSupport

Hi @jetty_1012,

You didn't specify the MCU series, I assume it is S32K3xx.

The default state of the pins out of reset is Hi-Z, there is no need to initialize those pins.

Refer to the IOMUX.xlsx attached to the RM.

There is the reset state of the MSCR registers, MSCR[MUX = OBE = IBE = PUE = 0] which disables the output buffer, input buffer, and pull device.

danielmartynek_0-1695044877172.png

danielmartynek_1-1695045330610.png

 

Regards,

Daniel

 

0 件の賞賛
返信
2,513件の閲覧回数
jetty_1012
Contributor II

Hi @danielmartynek 

Thanks for you reply. And yes, I'm using S32K312.

My problem is that I need some pins to stay Hi-Z, and other pins to be initialized as output/input before my task starts running (I'm using FreeRTOS).

And after my task starts running, I want to set directions for the pins staying Hi-Z state just now by using this API Siul2_Port_Ip_SetPinDirection. If I do not initialize them, then I cannot use the API to set their directions later. 

In other word, I do not want those pins to always keep Hi-Z. I only want them to keep Hi-Z at the beginning and I need to configure them as GPO at sometime when my code is running. Any suggestions about it?

 

Best regards,

Jetty

 

0 件の賞賛
返信
2,426件の閲覧回数
danielmartynek
NXP TechSupport
NXP TechSupport

Hi Jetty,

The Configuration tool does not allow to dissable the buffers.

Even the No init sets the buffers as per the initial direction configured there.

danielmartynek_0-1695198108836.png

But the pins can be configured for SIUL2 (which is the default muxing) and set them to inputs since the GPIO inputs have high impedance.

After the initialization, the pins can be set to Hi-Z using the Siul2_Port_Ip_SetPinDirection() if you want to have the input buffer disabled too.

danielmartynek_1-1695198370183.png

danielmartynek_2-1695198404525.png

Let me open a discussion with the RTD team to add this option to the Configuration tool.

 

Best regards,

Daniel