Control Arduino With Visual Studio Via Bluetooth
Intro: Control Arduino With Visual Studio Via Bluetooth
hi everyone ,
here we will control one led via bluetooth using your pc by a progam wirtten with visual studio
what you need is :
1)Arduino (any one)
2) Bluetooth Module (hc05 or hc 06)
3) led
4) 2 resistors (10ko and 15ko)
and u can do it ;)
all codes will be available :)
11 Comments
bruserker 2 years ago
I've tried to test your C# code that was provided here, however whenever I load the .sln project file to my Visual Studio and click twice on the Form1.cs project file, VS generates the following error message:
Cannot find the file
'C:\Users\bruno\Desktop\v.b+arduino\vi\Form1.cs'. It may have been moved or deleted.
Do you have any idea about what could be the possible problem here or if I am actually doing something wrong?
Thanks in advance,
Bruno.
abedo74 3 years ago
YeahM2 5 years ago
Hi.Everything works.But the receive text box is not showing the sentences Like"Ok,OFF"....Can you help me with that ?
VedaV1 6 years ago
bro unable to give wireless input from the c#.net application
and unable to find COM11 port
YongB1 7 years ago
Am i able to use a wifi shield instead?
alain19 7 years ago
Bonjour et merci pour ce super tuto !
Je n'arrive pas ou ouvrir le code sur visual studio est-il possible d'avoir votre code utilisé ?
J'aimerai faire la même chose mais en vb.net en m'inspirant de votre test.
Vous remerciant par avance,
Très cordialement,
JardaP 8 years ago
Why i can't open arduino code? :/
Ahm3d 8 years ago
int ledPin= 13;
char c ;
void setup()
{
Serial.begin(9600); // initialisation de la connexion série (avec le module bluetooth)
pinMode(ledPin, OUTPUT); // fixe la pin "ledpin" en sortie
}
void loop() {
char c = Serial.read();
switch (c) {
case '1': // si arduino reçois le chiffre 1 alors
digitalWrite(ledPin, HIGH); // allume sur la broche "ledpin"
Serial.println("ok,on");
break;
case '2': // si arduino reçois le chiffre 2 alors
Serial.println("ok,off");
digitalWrite(ledPin, LOW); // eteins la led sur la broche "ledpin"
break;
case '3': // si arduino reçois le chiffre 3 alors clignote
Serial.println("ok,clig");
while(c=='3'){
digitalWrite(ledPin, HIGH);
delay(500);
digitalWrite(ledPin,LOW);
delay(500);}
case '4' :
Serial.println("ok,timer");
digitalWrite(ledPin, HIGH);
delay(5000);
digitalWrite(ledPin,LOW);
}
}
JardaP 8 years ago
Thank You :)
MsSweetSatisfaction 9 years ago
Awesome gadget! Welcome to instructables!
Ahm3d 9 years ago