Entiendo que cuando uno comienza hay muchas cosas para aprender pero se comienza por cosas mas simples y no por algo tan complejo como un módulo A6 por citar este caso.
Aprende a buscar en Google de este modo : Arduino A6 code y mira lo que aparece.
Entre las opciones salió este link
que tiene este código
#include <SoftwareSerial.h>
//Create software serial object to communicate with A6
SoftwareSerial mySerial(3, 2); //A6 Tx & Rx is connected to Arduino #3 & #2
void setup()
{
//Begin serial communication with Arduino and Arduino IDE (Serial Monitor)
Serial.begin(9600);
//Begin serial communication with Arduino and A6
mySerial.begin(9600);
Serial.println("Initializing...");
delay(1000);
mySerial.println("AT"); //Once the handshake test is successful, it will back to OK
updateSerial();
mySerial.println("AT+CSQ"); //Signal quality test, value range is 0-31 , 31 is the best
updateSerial();
mySerial.println("AT+CCID"); //Read SIM information to confirm whether the SIM is plugged
updateSerial();
mySerial.println("AT+CREG?"); //Check whether it has registered in the network
updateSerial();
}
void loop()
Es para otra cosa, enviar y recibir códigos SMS pero lo puedes usar para tu problema.
Ya tienes cómo se hace ahora adáptalo a tu necesidad.