Npm1300 + nrf5340 reset configuration

Hello,

i'm developing a board based on nrf5340 and i want to use npm1300 as the pmic. My board is very constrained in terms of space so i'm trying to trade-off the flexibility in terms of testability (extra buttons, test-points, leds, etc.) with this. I read a lot the documentation of both nrf5340 and npm1300 and i would like to confirm that i understood well about the reset options.

Short recap of the valuable infos:

- npm1300 resets using 1 button connected to the SHPHLD pin or using 2 buttons (one on SHPHLD, the other on GPIO0). In both cases, button(s) needs to be pressed for t>tresetbut. The mode (1 or 2 buttons) needs to be set using proper register configuration.

- nrf5340 resets using 1 button on the RESET pin.

- the reference design at Fig.49 of npm1300 Product specifications v.1.1 shows a 2 button configuration with 1 button on SHPHLD and the other button connected to both GPIO0 of npm1300 and RESET of nrf5340.

Being space constrained, i would like to add just 1 button to the board. The idea is to use it for the reset of both npm1300 and nrf5340 so, respect to the reference design, i would connect the button with both SHPHLD and RESET pin of nrf5340.

Is this a legit configuration considering that i need to program nrf5340 over and over for tests using the SWD port of a Segger J-link?

My question arises from the fact that in the boards i developed until now, the MCU (and all the stuff used for programming such as memory, etc.) was always supplied with VDD while reset pin was triggered. In this case, due to the fact that the reset of npm1300 causes a power cycle on the nrf5340, i wonder if this could cause trouble to the programming phase. In your reference design this is not an issue because if the nrf53x reset is triggered the npm1300 is still active because of the 2-buttons configuration.

Any clarification on this matter is appreciated!

Thank you,

Francesco

Parents
  • Hi,

    - npm1300 resets using 1 button connected to the SHPHLD pin or using 2 buttons (one on SHPHLD, the other on GPIO0). In both cases, button(s) needs to be pressed for t>tresetbut. The mode (1 or 2 buttons) needs to be set using proper register configuration.

    Yes. See LPRESETCONFIG. See default values (0x00) here to see the default mode for this. As I read it, single button long press enabled is the default.

    - nrf5340 resets using 1 button on the RESET pin.

    Yep. See nRF5340 Pin Reset.

    - the reference design at Fig.49 of npm1300 Product specifications v.1.1 shows a 2 button configuration with 1 button on SHPHLD and the other button connected to both GPIO0 of npm1300 and RESET of nrf5340.

    That makes sense yes.
    I think this has two possible functions:

    You can enable two-button reset.

    Or you can use the GPIO on the nPM1300 to reset the nRF5340 if if you get nPM1300 errors, for example using PO.RESET, seeOutput under nPM1300 GPIO Pin Configuration.

    Is this a legit configuration considering that i need to program nrf5340 over and over for tests using the SWD port of a Segger J-link?

    You do not need the RESET pin to program the nRF5340. Ref  Programming Custom nRF5340 Board Using nRF5340 Development Kit .

    So I do not believe this will become an issue.

    Regards,
    Sigurd Hellesvik

  • Hi Sigurd,

    thank you for the very detailed feedback, but i feel like there are two ways to read your answer:

    1) The configuration i propose (1 button for both nPM1300 reset and nrf5340 reset) is legit;

    2) The configuration i propose is NOT legit, but not needing the reset on the nrf5340 to program it i can just drop this connection (1 button for the nPM1300 reset and Vdd on the nrf5340 reset) and continue using only one button in total

    Which one? :D

    Frax

  • Heh, good that you ask.

    The configuration you propose is legit when it comes to a programming perspective.
    Because you will not trigger the nPM1300 reset during programming if you never connect anything to the reset pin at during programming. Aka it will not matte rif the pins are connected or not.

    I cannot see anything that would be bad with connecting these pins right now.
    However, I will ask a colleguea to be sure I have not missed anything.

  • My doubt for programming is the following: let's assume i connected the button to both nPM1300 and nrf5340 and the reset line is driven by the programming interface. When i run the "program!" button the programmer pull down the reset line to be sure that the device is in a known state. Because of the electrical connections the nrf5340 is reset but also subject to a power-cycle due to the nPM1300 been reset as well. After the reset it could happen that the device is still "off" and the programming fails? Or does it wait for the mcu to boot and everything goes fine?

    It's probably me overthinking too much, but concurrencies and race conditions make me tripping Smiley

    Thank you for the patience

    Frax

  • frax84 said:
    When i run the "program!" button the programmer pull down the reset line to be sure that the device is in a known state.

    If you do not connect the reset line to the programmer (only SWDIO, SWCLK, GND and VDD), the programmer will use Soft Reset instead of pin reset to enter a known state.

    frax84 said:
    due to the nPM1300 been reset as well.

    No reset pin to programmer => During programming the nPM1300 reset line is not changing* => nPM1300 will not be reset.

    *Unless you press the reset button by mistake during programming ofc.

    frax84 said:

    It's probably me overthinking too much, but concurrencies and race conditions make me tripping Smiley

    Thank you for the patience

    It is good that you ask, no worries! Keep the questions coming until you are content with your understanding.

    So, I am sure that this won't be an issue with programming. I am still checking to see if it is a problem for anything else.

  • Oh, and by the way:
    Do you have an nRF5340DK and an nPM1300 EK?

Reply Children
No Data
Related