Skip to content

Make Reboot after Factory Reset on an EP optional #11178

Closed
@def1149

Description

@def1149

Related area

Zigbee

Hardware specification

C6, H2

Is your feature request related to a problem?

When an EP executes a factory reset, it also executes a device reboot. When I execute a factory reset, I may want to shut the device down, not reboot. Currently, I need to set a shutdown flag in flash, and upon reboot, if the flag is set, clear it and shut the device down. That works, but it's a workaround.

Describe the solution you'd like

Add a boolean to factoryReset(bool reboot)
If true, reboot.
If false, return to the caller

Describe alternatives you've considered

Flash-based flag to signal shutdown after the reboot from a factoryReset() call.

Additional context

No response

I have checked existing list of Feature requests and the Contribution Guide

  • I confirm I have checked existing list of Feature requests and Contribution Guide.

Activity

self-assigned this
on Mar 26, 2025
Citrus101

Citrus101 commented on Mar 26, 2025

@Citrus101

Hello, can I take up this issue or is anyone else working on this?

P-R-O-C-H-Y

P-R-O-C-H-Y commented on Mar 26, 2025

@P-R-O-C-H-Y
Member

Hi @Citrus101, I have this assigned to me as I am maintainer of Zigbee Library but I did not start yet.
But if you would like to take this, is. a simple change feel free to open a PR with the change and ping me there.

Citrus101

Citrus101 commented on Mar 26, 2025

@Citrus101

Oh okay perfect, will do.

Citrus101

Citrus101 commented on Mar 26, 2025

@Citrus101

@P-R-O-C-H-Y sorry to bother you like this but can you provide me your thought process for the solution you were going to come up with?
I'm struggling since I thought a simple modification to the factoryReset function would suffice but it doesn't seem like it.
I cannot code the described solution since esp_zb_factory_reset is a Core API function and can't avoid the reboot performed by the device.

P-R-O-C-H-Y

P-R-O-C-H-Y commented on Mar 26, 2025

@P-R-O-C-H-Y
Member

@Citrus101 I have some thought but I would need to investigate the options. Maybe it's not that simple as I imagine. So please let me work on this fr. Would be easier for me to do it directly when I would need to also investigate.

Citrus101

Citrus101 commented on Mar 26, 2025

@Citrus101

Yes agreed. I'll sit this one out.

def1149

def1149 commented on Mar 28, 2025

@def1149
Author

Working as requested

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Area: ZigbeeIssues and Feature Request about ZigbeeType: Feature requestFeature request for Arduino ESP32

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

    Participants

    @def1149@P-R-O-C-H-Y@Citrus101

    Issue actions

      Make Reboot after Factory Reset on an EP optional · Issue #11178 · espressif/arduino-esp32