Arduino Zero and Adafruit FONA

Hi,

because Arduino Zero is new and also a bit expensive, I would be very grateful if you could tell me if it is already working with the FONA from Adafruit.

Kind regards

Hi,

You can control the FONA by serial communication, and Serial1 works on the Zero (pin 0 and 1). If you want to use the Adafruit FONA library, it should be OK, since there is only Serial communication and String parsing things I guess. You should try to compile the Fona library using the Zero as target board in the IDE, you'll see if there are any error.

Hi,

thank you very much for your answer! I tried to compile the FONAtest example for the Zero but it immediately stops after pressing the compile button. SoftwareSerial.h was missing

After removing all Includes with SoftwareSerial.h in the library it compiles. Will it work that way?

I’ve looked quickly to the library. You could keep everything about SoftwareSerial, but replace in .h and .cpp each
occurance of

#ifndef __SAM3X8E__

by

#if !defined(__SAM3X8E__) && !defined(__SAMD21G18A__)

it will then still be compatible with other board like the Due, the Uno etc

In fact, the Zero and Due are not compatible with the SoftwareSerial, but both have HardwareSerial Serial1. The defined statement just look for each board you compile : if it is an AVR, it use SofwareSerial, and if not it use Stream class Serial (Hardware). You have the same kind of things at the beginning of the FONAtest example :

#ifdef __AVR__
#include <SoftwareSerial.h>    //for AVR board
SoftwareSerial fonaSS = SoftwareSerial(FONA_TX, FONA_RX);
SoftwareSerial *fonaSerial = &fonaSS;
#else
HardwareSerial *fonaSerial = &Serial1; //for Due and Zero
#endif