Discover

Topics

Arduino 4 Relay Bluetooth

Arduino 4 Relay Bluetooth APK

Arduino 4 Relay Bluetooth APK

1.0 FreeJan Erik Andresen / Andronesen-flyfoto.com ⇣ Download APK (2.39 MB)

What's Arduino 4 Relay Bluetooth APK?

Arduino 4 Relay Bluetooth is a app for Android, It's developed by Jan Erik Andresen / Andronesen-flyfoto.com author.
First released on google play in 7 years ago and latest version released in 7 years ago.
This app has 0 download times on Google play
This product is an app in Education category. More infomartion of Arduino 4 Relay Bluetooth on google play
CODE:

/*
Relay IN1 connected to PinOut 2 Arduino
Relay IN2 connected to PinOut 3 Arduino
Relay IN3 connected to PinOut 4 Arduino
Relay IN4 connected to PinOut 5 Arduino
--->you can connected to relay modul 4 channel

Serial data sending from Arduino 4 Relay.apk
data '1'-'4' to on is Ralay CH 1-4
data 'A'-'D' to off is Ralay CH 1-4
data '9' to on ALL CH 1-4
data 'I' to off ALL CH 1-4
*/

#include
SoftwareSerial mySerial(10, 11); //Pin10 RX , Pin 11 TX connected to--> Bluetooth TX,RX

#define relay1 2
#define relay2 3
#define relay3 4
#define relay4 5

char val;
void setup() {
pinMode(relay1,OUTPUT);
pinMode(relay2,OUTPUT);
pinMode(relay3,OUTPUT);
pinMode(relay4,OUTPUT);
digitalWrite(relay1,LOW);//H
digitalWrite(relay2,LOW);//H
digitalWrite(relay3,LOW);//H
digitalWrite(relay4,LOW);//H
mySerial.begin(9600);
Serial.begin(9600);
}

void loop() {
//chek data serial from bluetooth android App
if( mySerial.available() >0 ) {
val = mySerial.read();
Serial.println(val);
}
//Relay is on
if( val == '1' ) {
digitalWrite(relay1,HIGH); }//L
else if( val == '2' ) {
digitalWrite(relay2,HIGH); }//L
else if( val == '3' ) {
digitalWrite(relay3,HIGH); }//L
else if( val == '4' ) {
digitalWrite(relay4,HIGH); }//L
//relay all on
else if( val == '9' ) {
digitalWrite(relay1,HIGH);//L
digitalWrite(relay2,HIGH);//L
digitalWrite(relay3,HIGH);//L
digitalWrite(relay4,HIGH);//L
}
//relay is off
else if( val == 'A' ) {
digitalWrite(relay1,LOW); }//H
else if( val == 'B' ) {
digitalWrite(relay2,LOW); }//H
else if( val == 'C' ) {
digitalWrite(relay3,LOW); }//H
else if( val == 'D' ) {
digitalWrite(relay4,LOW); }//H
//relay all off
else if( val == 'I' ) {
digitalWrite(relay1,LOW);//H
digitalWrite(relay2,LOW);//H
digitalWrite(relay3,LOW);//H
digitalWrite(relay4,LOW);//H
}

}