XBee DIO Output State After Power Cycle – Unexpected Latching

Hi all,

In my irrigation control system, a coordinator sets DIO1 on a remote router (XBee S2C, API mode) to HIGH using ATD1=5. The router drives a relay that controls a pump.

Observation:
If I power down the router while DIO1 is HIGH, and then power it back up with no coordinator present, DIO1 remains latched HIGH — the pump stays on indefinitely.

Expected behavior:
I was hoping DIO1 would reset to LOW (OFF) on boot — or at least require a fresh command from the coordinator.

I know PR affects only digital inputs, and D1=4 (LOW) should set the default state. But it seems that once ATD1=5 is sent remotely, the pin remembers that state across power cycles.

:wrench: Module Details:
Model: XB24C (XBee Series 2C)

Function Set: Zigbee TH Reg

Firmware Version: 4061

Hardware Version: 2E4E

Mode: API, Router

:red_question_mark: My questions:
Is this expected behavior for DIOs remotely configured?

Is there a way to force DIO1 to reset LOW on power-up, unless commanded otherwise?

Could a different firmware version avoid this latched state?

Any suggested workarounds (e.g. firmware, watchdog, fallback logic)?

Any tips or similar experiences would be greatly appreciated — especially from those doing reliable actuator control over ZigBee.

Thanks in advance!

If you are using the write function in your API frame, then yes, it is expected behavior.

Yes, do not use the write function in your remote AT API frame (Option bit).

Thank you for your reply. Now I understand what has to be done: D1 command has a parameter (0x05 and 0x04 to set output on and off), and API frame has an option to write it to flash memory or not (0x02 means write to flash and 0x01 applies it temporarily - does not persist through reboot)

Byte(s) Name Value / Meaning
0x17 Frame Type Remote AT Command Request

| 0x01 | Frame ID | Any non-zero value |
| xx xx xx xx xx xx xx xx | 64-bit Dest. Addr | Your router’s address (e.g., 0x0013A20041XXXXXX) |
| FF FE | 16-bit Network Addr | 0xFFFE (unknown / ignored) |
| 02 | Remote Options | This is the important byte (see below) |
| 44 31 | AT Command | ASCII for D1 |
| 05 | Command Parameter | Set pin mode to Digital Output, HIGH |