Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
michael_liao
Level 2
Level 2
First like received 5 replies posted 5 sign-ins

 

This is the official project "D2GL".

The DAC feature is implemented by using the "DAC_LUT" App.

It seems to me that "CCU4_DAC_TRIGGER" is triggered by the "CCU4_PRT_TRIGGER" st event, then "CCU4_DAC_TRIGGER" output the values in the LUT periodically.

The connections as below.

 

michael_liao_0-1676863555776.png

 

However, the matter in fact is the DAC does not output without calling the "DAC_LUT_Start".

 

michael_liao_2-1676863610591.png

 

"XMC_DMA_CH_Enable" is called in "DAC_LUT_Start", and it takes a few microseconds.

michael_liao_3-1676863620467.png

 

"XMC_DMA_CH_Disable" is called in "scfmcw_stop" after every LUT cycle, and it takes a few microseconds, too.

 

michael_liao_4-1676863631820.png

 

(1) Could I enable DMA without disable it anymore?

(2) Could "XMC_DAC_CH_SetMode", "DAC_LUT_ResetIndex" and "DAC_LUT_SetRepetition" are called without disable DMA?

michael_liao_5-1676863842513.png

 

 



0 Likes
1 Solution
LinglingG_46
Moderator
Moderator
Moderator
500 solutions authored 1000 replies posted 10 questions asked

1: The first question:

However, the matter in fact is the DAC does not output without calling the "DAC_LUT_Start".

Because when you call the API:

XMC_DAC_CH_SetMode(HandlePtr->module_ptr, HandlePtr->ch, XMC_DAC_CH_MODE_IDLE);

It means the DAC module has been disable. So it calls the "DAC_LUT_Start(p_inst->mDAC_LUT);", it enables the DAC module.

2:The second question:

"XMC_DMA_CH_Enable" is called in "DAC_LUT_Start", and it takes a few microseconds.

The DAC_LUT_Start()  enables the DAC channel. It takes the code running time. 

3: From the code comments, I think we should ensure to reset everything before the new frame. So I think we should design the code depending on the code example.

More about the Timing flow implementation in firmware:

LinglingG_46_0-1676896948025.png

4: More about radar sensor firmware, please refer to the linker:

https://www.infineon.com/dgdl/Infineon-Distance2GoL_Software_User_Manual-UserManual-v01_01-EN.pdf?fi...

View solution in original post

0 Likes
1 Reply
LinglingG_46
Moderator
Moderator
Moderator
500 solutions authored 1000 replies posted 10 questions asked

1: The first question:

However, the matter in fact is the DAC does not output without calling the "DAC_LUT_Start".

Because when you call the API:

XMC_DAC_CH_SetMode(HandlePtr->module_ptr, HandlePtr->ch, XMC_DAC_CH_MODE_IDLE);

It means the DAC module has been disable. So it calls the "DAC_LUT_Start(p_inst->mDAC_LUT);", it enables the DAC module.

2:The second question:

"XMC_DMA_CH_Enable" is called in "DAC_LUT_Start", and it takes a few microseconds.

The DAC_LUT_Start()  enables the DAC channel. It takes the code running time. 

3: From the code comments, I think we should ensure to reset everything before the new frame. So I think we should design the code depending on the code example.

More about the Timing flow implementation in firmware:

LinglingG_46_0-1676896948025.png

4: More about radar sensor firmware, please refer to the linker:

https://www.infineon.com/dgdl/Infineon-Distance2GoL_Software_User_Manual-UserManual-v01_01-EN.pdf?fi...

0 Likes