AT vs API (What, Why, How)

AT

What

  • AT mode is synonymous with "Transparent" mode.
  • In AT mode, any data sent to the XBee module is immediately sent to the remote module identified by the Destination Address in memory.
  • If the XBee that the data is sent to is the Coordinator it will broadcast on the PanID.
  • No packet formation is necessary, but rather simple send Serial data to the tx of one Xbee and it will be received by the rx of the destination XBee
  • Because no packets are created the destination address and type (only-data) are both fixed.

Why

  • If you are new to XBees this is the fastest way to start transmitting
  • If you only communication between two XBees
  • If you can implement an external protocol (Every XBee will have an associated mbed)

How

API

What

  • API mode is "Application Programming Interface"
  • Data must be formatted in frames with Destination information and payload
  • The API is an alternative to the default transparent mode.

Why

  • If you are new to XBees this is the fastest way to start transmitting
  • For larger networks that involve nodes talking to multiple targets
  • If XBees are gathering data without a mbed attached and thus can not format their own data before sending
  • If power is a big concern and you would like End Devices to 'sleep' until data is requested.
  • Need to change parameters without entering command mode (XBee only)
  • Want to view RSSI and source address on a packet by packet basis
  • Would like to receive packet delivery confirmation on every transmitted packet

How

  • More to come...


2 comments on AT vs API (What, Why, How):

25 Dec 2016

How to configure Xbee in API mode to send packet of information to multiple Xbees at a time

12 Apr 2018

Cannot send API commands from Serial interface in Vbasic. Only AT commands and transparent works. Is there a command to switch from "transparent" to "API" command ? +++ works fine to switch to AT commands. Now all API commands are just echoed back! Please help. Using a few different Xbee devices. All works fine in XCTU.

Please log in to post comments.