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

cross mob
Not applicable
When using default configuration of the app the following while loop in the POW001_Init never evaluates to true

while(!(SCU_INTERRUPT->SRRAW & SCU_INTERRUPT_SRRAW_HDCR_Msk))
{}
0 Likes
9 Replies
Not applicable
I have gotten this statement to evaluate by updating the startup_XMC4500.c
However, the POW001 does not enter hibernate by executing POW001_EnterHibernate()
0 Likes
eugene
Employee
Employee
Hi Doug,

Are you running the code using the XMC4500 Hexagon CPU board or it's your own board ?

Best regards,
Eugene
0 Likes
Not applicable
Eugene,

This is my own board.
I have a hexagon board, but since a different micro variant is being used I did not try the board.
Also, since all apps are tested on the hexagon board it didn't seam necessary to retest it.
The test project consisted only of the POW001 app, and executing the POW001_EnterHibernate() command.
The expected response when debugging is to lose debug sync, and when not debugging is to have a lower current draw.

Regards,
Doug
0 Likes
eugene
Employee
Employee
Hi Doug,

To support the lowest possible current consumption, XMC4500 only support externally controlled hibernate mode. Please consider using the XMC4400, XMC4200 or XMC4100 if you need an internally controlled hibernate mode.

In externally controlled hibernate mode, the external voltage controller supplying MCU VDDP requires a "shutdown", "enable" or "inhibit" functionality. This allows the XMC4500 to control the external voltage regulator using any of the hibernate pins (HIB_IO_0 and HIB_IO_1). When user application calls POW001_EnterHibernate() command, the MCU is actually switching off the external voltage regulator. You can refer to Figure 11-12 in XMC4500 RM for more details.

By default the DAVE POW001 app retains the reset settings of the Hibernate pins. Thus HIB_IO_0 is an input pin and HIB_IO_1 is an open drain output pin.

Please note that if you're using the XMC4500 Hexagon board, it's quite easy to "kill" your board if the Hibernate mode is wrongly configured i.e. device enter permanent hibernate mode. You can recover the board by removing the battery or removing the resistor(R414) connecting HIB_IO_1 to the voltage regulator EN pin

Best regards,
Eugene
0 Likes
Not applicable
Eugene,

Thanks for the info. I could not find a sample application for the POW001 app.
Would you please provide the configuration for the POW001 app on the hexagon board that ensures proper operation?

Thanks,
Doug
0 Likes
Not applicable
Eugene,

Would you also provide some insight in how to configure DAVE to use an ADC boundary flag as the external event that wakes the micro-controller out of sleep or deep sleep?
0 Likes
lock attach
Attachments are accessible only for community members.
eugene
Employee
Employee
Hi Doug,

The DAVE 3 Project Manager should have an example on POW001 for XMC4500 but I can't find it. I'll inform the team about it. Anyway I've attached the POW001 example project for your reference. Let me know if you have any problem.

Also please ensure that your XMC4500 Hexagon battery is not empty before running the example. I had the misfortune of debugging this example with an empty battery yesterday 😞

Best regards,
Eugene
0 Likes
Not applicable
Thanks Eugene.
This answers the initial hibernate question, and was very helpful.
Would you provide some insight into my second question of using an ADC channel boundary flag as an external event to wake up the micro-controller out of deep sleep.
My expectation would be that the ADCH001 boundary flag for result register X signal can be connected to the NVIC_SCU001 which would connect to the POW001 app.
However this functionality is not available.
Is this functionality available by other means, or is this a feature request?
0 Likes
eugene
Employee
Employee
Hi Doug,

In general, to wake up from deep sleep you'll need an interrupt event. Do ensure that the clock to the peripheral that is generating the event is not turned off when you enter deep sleep.

I'm afraid I'm not too familiar with the ADC app itself but I did a quick read of the ADC chapter in the XMC4500 Reference Manual. I assume you want to wake up the device if the signal connected to the ADC exceed a certain threshold thus triggering the boundary flag. One possible method is to generate an ADC channel event(GxCHCTRy.CHEVMODE) and connect the event to an interrupt node (NVIC002).

If you want to use the boundary flag directly; it does not seems to be connected to any interrupt node directly. Looking at the interconnection section, one way is to connect the boundary flag to the ERU to generate an ERU interrupt. However this is only available for Boundary Flag 3 of output group 0 and 1.

I'll try to ask a colleague and get back to you on this matter.

Best regards,
Eugene
0 Likes