4 months agoPosted by Chilipp 50 points 2 replies
I'm experiencing some strange/different behaviors for the freertos_retarget sample application while my custom board is supplied via VBUS vs. VBAT.
When powered via VBUS, the application sends the # character on UART for approx. 8 s (due to the settlement of XTAL32K which is used for lp_clock). Afterwards, there is no more UART communication until a debugger is attached and activated (e.g. via J-Link Comander "connect"). The system awakes when the debugger connects (as it is supposed to) and the # character is sent again via UART. As soon as the debugger closes the connection, the target stops sending the # character.
When powered via VBAT, the application continues forever sending the # character on UART, i.e. even after the 8 s for settling the XTAL32K are passed (I assume that the application is going to sleep and is waking up for sending the # character, as this is AFAIK the intended behavior according to "DA1469x Starting a Project => Running The Demonstration Example => Verifying with SmartSnippets Toolbox").
When target is first powered via VBUS and then - after already sleeping - additionally via VBAT, the target remains in sleeping state.
When target ist first powered via VBUS and then - when not already sleeping, i.e. before 8 s have passed - additionally via VBAT, the target continues sending # characters via UART but stops immediately when VBAT is detached. Afterwards, the same behavior as when first powered via VBUS and then (while sleeping) VBAT occures, i.e. the target remains in sleeping state.
Re-attaching VBUS does not wake the target in this case (even though I have read that somehow there is a VBUS-sense IRQ ... maybe it is not enabled in the example).
So my question is, how / where is this different sleep behavior for VBUS vs. VBAT specified or set in the SDK? Is it a common fact resulting of the datasheet or is it made by the SDK? I searched almost all day long through the SDK and the DA1469X datasheet, but I have not found something.
Another observation I made today is that if I connect VBUS but VBAT is also present, the board does not consume current through VBUS even though I measure 5.1V at the VBUS TP on the board.
However, the datasheet tells: "Finally, when the system is connected to a USB charger, pin VBUS is the source of the power instead of pin VBAT1/VBAT2".
Another tiny question in this context: Is LDO_USB equal to LDO_VBUS or are these two different LDOs?