Saturday, February 20, 2016

The ATN Pin on New Arduino 101 and Arduino Zero

If you look at the pictures of the new Arduino (.cc) Arduino/Genuino 101 and Arduino/Genuino Zero, next to the IOREF pin you will see a new pin.  Formerly undefined on AVR (ala Uno) style Arduinos, the pin is now labelled ATN.


Currently there is not much information on use for this pin except one forum.arduino.cc thread. There, Cristian Maglie of the Arduino team explains:

The ATN pin is an experimental feature we're introducing with the Arduino Zero.
Many shields and expansion modules use an SPI communication protocol and this always requires electing a pin to act as  "chip select" effectively making one extra pin unavailable. On processors that have more than 28 pins there are usually extra unallocated pins that can be used. We decided to experiment and allocate a pin to act as the default chip select for the first shield/module on the bus.
We're going to issue a more formal "application note" to explain some of the new features provided by this pin. For now just treat it as one extra pin available for you to use.
In the Arduino IDE, it is defined as ATN when you select a board that supports it.

Use


SPI use on Arduino is discussed in this reference.  TO use SPI, you connect to the SPI bus, often on the ICSP connector.
The only pin that is needed but not on this header is the Select line to select a particular SPI device on the bus (often called a Slave Select or SS pin).  For this purpose on most boards, you can use any digital or even an analog pin.  But this will take away a pin that could be otherwise useful in your project.

As modern processors have alot of digital pins, more than are used on the standard Arduino shield pinout, a extra pin has been provided for your use, ATN, ostensibly to help you use that as the SS pin function freeing the digital pin you might have had to use for other uses.

More will be posted when use of this pin is more widely published.