2296655_en-US

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

2296655_en-US

2296655_en-US

What is the meaning of FLEXIO_CTRL[DBGE]

The reference manual wording on DBGE is a bit short with only

"Enables the FLEXIO operation in Debug mode"

What happens if it is disabled and you debug code?


Trying to figure out what debug operations are safe when using FLEXIO and debugging FLEXIO drivers.

I guess it is NOT safe to let the debugger read SHIFTBUFn in receive mode or any other hardware register with read sideeffect, not even by accidently howering over it in the debugger.

Re: What is the meaning of FLEXIO_CTRL[DBGE]

Hi @Henrik-Wires 

If the "Enable FLEXIO operation in debug mode" is disabled, the FLEXIO module stops when the debugger stops the CPU. All FIexIO activity is freeze until execution resumes.

This topic has also been discussed in the following thread: Does it means that flexio can't work in debug mode?


BR, VaneB

Re: What is the meaning of FLEXIO_CTRL[DBGE]Does that also mean that it is safe to access the FLEXIO registers using the debugger if DBGE is disabled, or will reading SHIFTBUFn with the debugger disturb the Shift Status Flag SHIFTSTAT[SSF]

Re: What is the meaning of FLEXIO_CTRL[DBGE]

Hi @Henrik-Wires 

As stated in the S32K3 reference manual, the SHIFTBUFn register must be read only when the corresponding SHIFTSTAT[SSF] flag is set.

Re: What is the meaning of FLEXIO_CTRL[DBGE]

Hi @Henrik-Wires 

Could you please clarify what this will be used for or what kind of analysis you are trying to achieve?

Re: What is the meaning of FLEXIO_CTRL[DBGE]Can I somehow block S32DS from attempting to access registers? Only briefly howering over a pointer to SHIFTBUFn makes the debugger access the value which disturbs the FLEXIO state by clearing SHIFTSTAT[SSF]Re: What is the meaning of FLEXIO_CTRL[DBGE]

Hi @Henrik-Wires 

The IDE itself does not block access to registers. That kind of protection can be implemented using the MPU or XRDC; however, I do think that approach aligns with what you are trying to achieve.

Instead, you could monitor when SHIFTSTAT[SSF] is set and then verify whether the corresponding SHIFTBUFn register contains the expected value.

Re: What is the meaning of FLEXIO_CTRL[DBGE]I am exploring, writing and debugging a custom low level FLEXIO driver.
Experienced odd results while debugging which I suspect is due to S32DS fetching SHIFTBUFn register values while stepping thru the driver, disturbing the SHIFTSTAT[SSF] state and resulting in lost events.
Re: What is the meaning of FLEXIO_CTRL[DBGE]The driver obviously monitors SHIFTSTAT and access SHIFTBUFn accordingly.

My issue is that it that stepping over the driver code with S32DS can trigger a debug read of SHIFTSTAT, which seems to disturb the state held in that register. For example when howering with the mouse over a pointer to SHIFTSTAT.

If I carefully avoid touching any such pointers with the debugger then the driver works.

I had hope that disabling DBGE would allow the debugger to access SHIFTSTAT without disturbing the **bleep**FSTAT register state, but from your response this is not the case.
Re: What is the meaning of FLEXIO_CTRL[DBGE]

Hi @Henrik-Wires 

Disabling the DBGE bit does not prevent the debugger from disturbing registers such as SHIFTSTAT, because DBGE does not control debug read behavior. Instead, DBGE controls whether the peripheral keeps running when the core is halted.

タグ(1)
評価なし
バージョン履歴
最終更新日:
‎01-28-2026 04:26 AM
更新者: