- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
I am trying to write to SCU_PMSWCR0 register in a AURIX 265 TFT Kit with Safety Endinit set and clear. I am specifically writing to TRISTEN and TRISTREQ bits, but I am not able to do so. Am I missing some steps here?
I am trying to set the default state of the GPIOs to be Tristate instead of weak pull up on reset(warm).
Code:
/* Clear safety EndInit protection */
IfxScuWdt_clearSafetyEndinitInline(IfxScuWdt_getSafetyWatchdogPasswordInline());
SCU_PMSWSTATCLR.U = 0x000300FC;
//SCU_PMSWCR0.B.TRISTEN = 1;
SCU_PMSWCR0.U = 0x2102D0;
//while(SCU_PMSWSTAT.B.TRIST == 0)SCU_PMSWCR0.B.TRISTEN = 1;
SCU_PMSWCR0.U = 0x4102D0;
//SCU_PMSWCR0.B.TRISTREQ = 1;
//while(SCU_PMSWSTAT.B.TRIST == 0)SCU_PMSWCR0.B.TRISTREQ = 1;
//SCU_PMSWCR0.B.TRISTEN = 0;
/* Set safety EndInit protection */
IfxScuWdt_setSafetyEndinitInline(IfxScuWdt_getSafetyWatchdogPasswordInline());
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You must set TRISTEN and TRISTREQ in the same write access.
Clear bit TRISTREQ: SCU_PMSWCR0.U = 0x2102D0; // TRISTEN=1 and TRISTREQ=0
Set bit TRISTREQ: SCU_PMSWCR0.U = 0x6102D0; // TRISTEN=1 and TRISTREQ=1
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You must set TRISTEN and TRISTREQ in the same write access.
Clear bit TRISTREQ: SCU_PMSWCR0.U = 0x2102D0; // TRISTEN=1 and TRISTREQ=0
Set bit TRISTREQ: SCU_PMSWCR0.U = 0x6102D0; // TRISTEN=1 and TRISTREQ=1
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks for clarifying. I was doing it over separate instructions.