> For the complete documentation index, see [llms.txt](https://docs.eseye.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.eseye.com/smartconnect/at-command-reference/management-at-commands/etmstate-check-current-state.md).

# ETMSTATE – check current state

Checks the current state of the LTE IoT 2 click.

| Type  | Syntax                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                | Response                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| ----- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Test  | AT+ETMSTATE=?                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         | +ETMSTATE: 0: Idle 1: Awaiting keys 2: Network connecting 3: Establishing TLS 5: Establishing data-link 6: Connected 7: Subscribed 8: UDP active 9: Error OK where the modem: 0 – is ready to receive commands. 1 – has registered to the network and is waiting for certificate delivery to complete on the SIM. 2 – is waiting to establish a network connection. 3 – is establishing end-to-end security of data, using the Transport Layer Security protocol. 4 – this state is currently unused. 5 – is establishing a connection to AWS in order to transfer data. 6 – has connected to the MQTT broker. 7 – is subscribed to MQTT topics. 8 – User Datagram Protocol is ready for use. 9 – the device or connections have failed. |
| Read  | AT+ETMSTATE?                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          | +ETMSTATE: OK or ERROR                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| Write | AT+ETMSTATE= where is the command, either: 0 – disable state change URC 1 – enable state change URC "powerdown" – turn off modem when it is not in the busy state For information about the busy state, see ETMINFO – displays AnyNet SMARTconnect™ and device information. "powerdownnow" – turn off modem immediately without waiting for pending actions to complete "startlwm2m" – start the LwM2M protocol "startmqtt" – start AnyNet Secure MQTT application "startudp" – start UDP telemetry application "stop" – stop AnyNet Secure MQTT, LwM2M, or UDP telemetry application. Use this to cleanly shutdown before power off. | OK After AT+ETMSTATE="stop", AnyNet SMARTconnect™ returns to idle and the following response occurs: +ETM: IDLE or +ERROR:                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |

#### Example

```
AT+ETMSTATE?
+ETMSTATE: 0
OK
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.eseye.com/smartconnect/at-command-reference/management-at-commands/etmstate-check-current-state.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
