' set up the code for the input through MSComm1.... str = MSComm1.Input ' get the string str = Left(str,1) ' chops off the first char and puts it back in str Debug.Print ">" str "<" ' now you can see what is coming through in the immediate window of VB Select Case (str) ' set a "beak point " here in VB to stop the processing so you can step through the case Case "A" Call LEDOn(vbRed) Case "B" Call LEDOn(vbGreen) Case "C" Call LEDOn(vbBlue) Case "D" Call LEDOn(vbYellow) Case Else Call LEDOff End Select ' on the Arduino side just send out Serial.println("A")'why send out a whole line of text if you don't need it
.great PaulS you got the idea of mine, this is what i wanted to be..but i just want to clarify that pin 7 is our buzzer, whenever something is pressed it will buzz accordingly to it's precise times...so, our output pin will start on pin 9..therefore the switch connected to pin 2 has an output LED on pin 9.thanks you so much guys for helping me. RPCoyle, i try the code you posted but still nothing sends to the vb.. to PaulS:QuoteWhile not running the VB app, open the Serial Monitor. You should see R5 in the serial monitor window, on a new line, and the LED on pin 7 should flash every time you press the switch connected to pin 2. Do both of those things happen?.yes precisely both of them happens.. QuotePresuming that they do, close the Serial Monitor, and run the VB application.i was thinking why everytime i used to run the vb application then afterwards when i am going to press the switch connected to pin 2 the LED 9 didn't flash anymore..maybe that was the problem why there is nothing sends to vb...what do you think..?.another thing, some of my friends told me that maybe i should use < dll > or any software for this..is it true.?.if so, i don't know about dll or those particular software for this..
While not running the VB app, open the Serial Monitor. You should see R5 in the serial monitor window, on a new line, and the LED on pin 7 should flash every time you press the switch connected to pin 2. Do both of those things happen?
Presuming that they do, close the Serial Monitor, and run the VB application.