Enabling input hysteresis with IMXRT1062

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Enabling input hysteresis with IMXRT1062

Jump to solution
1,765 Views
robert-hh
Contributor II

Hello all, I need some advice. I try to enable the hysteresis function on GPIO pin of  IMXRT1062 or IMXRT1021 MCUs. I have set the bit in the IOMUX register according to the spec, If I read back the register, the bit is set. All other settings for that register work as expected. Only there is no hysteresis. If I apply a ramp signal to an input and echo the reading in a loop, it clearly shows no hysteresis. What is the secret for setting it.

transient_jitter_read_DR.png

Tags (1)
0 Kudos
Reply
1 Solution
1,738 Views
robert-hh
Contributor II

Hello Victor,

thank you for your reply. I used indeed an input for testing. I supplied a 10Hz, 3Vpp ramp signal and used a small program loop to display the value read at the input. You can see both the input and the output in the Oscilloscope screen shot.

But the problem is solved. The culprit was the local FM radio station, injecting more than 250mV interference into the wires from the signal generator, even if the open part of wires were short (~10cm) and the output impedance of the generator is low, Adding a 1 kHz RC lowpass immediately at the input pins solved the problem, and I have a clean signal now with hysteresis.

Kind Regards, Robert

View solution in original post

0 Kudos
Reply
3 Replies
1,743 Views
victorjimenez
NXP TechSupport
NXP TechSupport

Hello, 

Could you please clarify how are you testing this? Hysteresis works only for input pins, please see the following figure: 

victorjimenez_0-1622506302007.png

Are you using the Hysteresis on an input pin? 

Regards,
Victor 

0 Kudos
Reply
1,739 Views
robert-hh
Contributor II

Hello Victor,

thank you for your reply. I used indeed an input for testing. I supplied a 10Hz, 3Vpp ramp signal and used a small program loop to display the value read at the input. You can see both the input and the output in the Oscilloscope screen shot.

But the problem is solved. The culprit was the local FM radio station, injecting more than 250mV interference into the wires from the signal generator, even if the open part of wires were short (~10cm) and the output impedance of the generator is low, Adding a 1 kHz RC lowpass immediately at the input pins solved the problem, and I have a clean signal now with hysteresis.

Kind Regards, Robert

0 Kudos
Reply
1,724 Views
victorjimenez
NXP TechSupport
NXP TechSupport

Hi Robert, 

Thanks for sharing your findings! It's pretty interesting. 

Regards,
Victor 

0 Kudos
Reply