GSM Tricker for AirCon

Hi again

well i have the GSM board and my Uno wired up and it works but i need to find a way to talk to the AirCon unit what kind of data it is using..

well it is a project there is on the run so more will be posted here..

here is the code:


#include "SIM900.h"
#include <SoftwareSerial.h>
#include <LiquidCrystal.h>

//If not used, is better to exclude the HTTP library,
//for RAM saving.
//If your sketch reboots itself proprably you have finished,
//your memory available.
//#include "inetGSM.h"

//If you want to use the Arduino functions to manage SMS, uncomment the lines below.
#include "sms.h"
SMSGSM sms;

LiquidCrystal lcd(8, 9, 4, 5, 6, 7);
int backLight = 13;    // pin 13 will control the backlight
int ledpin = 11;
char msg[160];
int numdata;
boolean started=false;
char smsbuffer[160];
char n[12];
int lcd_key = 0;
int adc_key_in = 0;


void setup()
{
      //LCD Setup
      pinMode(backLight, OUTPUT);
      digitalWrite(backLight, HIGH); // turn backlight on. Replace 'HIGH' with 'LOW' to turn it off.
      lcd.begin(16,2); // columns, rows.  use 16,2 for a 16x2 LCD, etc.
      lcd.print("Starting up");  // start with a "blank screen"
      // Tricker setup
      pinMode(ledpin,   OUTPUT);
      
     //Serial connection.
     Serial.begin(9600);
     Serial.println("GSM Shield testing.");
     //Start configuration of shield with baudrate.
     //For http uses is raccomanded to use 4800 or slower.
     if (gsm.begin(9600)) {
          lcd.setCursor(0,0);           // set cursor to column 0, row 0 (the first row)
          lcd.print("READY");
          Serial.println("\nstatus=READY");
          started=true;
     } else Serial.println("\nstatus=IDLE");
            lcd.setCursor(0,0);           // set cursor to column 0, row 0 (the first row)
            lcd.print("READY");

     if(started) {
          //Enable this two lines if you want to send an SMS.
          //if (sms.SendSMS("4040xxxx", "Arduino SMS"))
          Serial.println("Ready To Send");
          lcd.setCursor(0,0);           // set cursor to column 0, row 0 (the first row)
          lcd.print("Ready to send");
     }
}

void loop()
{
     //lcd.setCursor(9,1); // place cursor
     //lcd.print(millis()/1000); // display seconds 
     lcd.setCursor(0,1); // move cursor
     lcd_key = analogRead(0); // read the buttons

     if (lcd_key<50){
        if(started) {
          //Enable this two lines if you want to send an SMS.
          if (sms.SendSMS("4040xxxx", "Button Right"))
          Serial.println("\nSMS sent OK");
          lcd.setCursor(0,0);           // set cursor to column 0, row 1 (the first row)
          lcd.print("Ready to send");
          lcd.setCursor(0,1);           // set cursor to column 0, row 1 (the first row)
          lcd.print("SMS sent OK");
      
     }
     } 
     else if (lcd_key<250){
        if(started) {
          //Enable this two lines if you want to send an SMS.
          if (sms.SendSMS("4040xxxx", "Button UP"))
          Serial.println("\nSMS sent OK");
          lcd.setCursor(0,0);           // set cursor to column 0, row 0 (the first row)
          lcd.print("Ready to send");
          lcd.setCursor(0,1);           // set cursor to column 0, row 1 (the first row)
          lcd.print("SMS sent OK");
      
     }
     } 
     else if (lcd_key<450)
     {
     
               lcd.setCursor(0,0);           // set cursor to column 0, row 1 (the first row)
               lcd.print("Ready to send");
               lcd.setCursor(0,1);           // set cursor to column 0, row 1 (the first row)
               lcd.print("                ");         
     }
     else if (lcd_key>550)
     {
     if(started) {
          //Read if there are messages on SIM card and print them.
          if(gsm.readSMS(smsbuffer,160,n,12)) {
               Serial.println(n);
               Serial.println(smsbuffer);
               lcd.setCursor(0,0);           // set cursor to column 0, row 1 (the first row)
               lcd.print("                 ");
               lcd.setCursor(0,0);           // set cursor to column 0, row 1 (the first row)
               lcd.print(n);
               lcd.setCursor(0,1);           // set cursor to column 0, row 1 (the first row)
               lcd.print(smsbuffer);
               
              
          }
           if(gsm.readSMS(smsbuffer,160,n,12) == 'On, +454040xxxx')
            {
              Serial.println("led on");
              analogWrite(ledpin, 255);  
            }
            }        
          delay(1000);
            }
     }

GPS Build with LCD

My First try to make a GPS logger and hopefully make a RC Car reproduce the steps (some day)

Items in the build:

Arduino UNO SparkFun
GPS Shield 1.1  itead
LCD Shield SparkFun

the code i got from : David Houlding

I changed it a bit to make it work with my build

my LCD Shield runs on pin 8, 9, 4, 5, 6, 7
my GPS Shield runs on TX Pin 2 and RX Pin 3

GPS_Build

2nd build

My 2nd Build is a box with batteries charger , inputs from 220v , solar , and a generator(12v)

it got 5 USB 1w , 4 12v plugs

what is inside….

well

2 x 12v 30AH
1 x Velleman PLUGC4F (12v plugs)
1 x Arduino with LCD Shield and 4 relay board
6 x print to make 12v stabel
5 x 7805 to make 12v to 5v
5 x Heatsinks for 7805
1 x 120mm FAN to cool it all when it  hits 30degrees
1 x solar converter

if you wish to see the arduino build got to my first build.

image1 image2 image3

1st Build

My First Build is a temp controlled fans

i needed temp controlled fans for another project so i grabbed my arduino and found some code…..

what i used :
Arduino UNO
LCDshield
SainSmart 5v Relay Board
Temperatursensor – LM35DZ 0 til 110°C TO-92
The Code : (i found my setup here : arduino-temperature-controlled-relay)

i changed it a bit, when it hit 30-29 it flip flops , but with the new code it is steady.
1. fan starts at 30c

#include <LiquidCrystal.h>
int reading = 0;
int sensorPin = A1;
int relay = 3;
int relay2 = 1;
//int celsius;
// initialize the library with the numbers of the interface pins
LiquidCrystal lcd(8, 9, 4, 5, 6, 7);

void setup() {
// set up the LCD’s number of columns and rows:
lcd.begin(16, 2);

pinMode(relay,OUTPUT);
pinMode(relay2,OUTPUT);
}

void loop() {
reading = analogRead(sensorPin);
int celsius = reading/2;
lcd.setCursor(0, 0);
lcd.print(“Temperature:”);
lcd.print(celsius, DEC);
lcd.print((char)223);
lcd.print(“C”);

if (celsius >29)
{
digitalWrite(3,HIGH);
lcd.setCursor(0,1);
lcd.print(” IM COOLING OFF”);
}

else if (celsius <26)

{
digitalWrite(3,LOW);
lcd.setCursor(0,1);
lcd.print(” IM COOL”);
}
else
{
lcd.setCursor(0,1);
lcd.print(” GOD SOMMERLEJR”);
}
delay(1000);
lcd.clear();

}