How to Debugin 2 letters and store in microcontroller memory?
Sir, my gsm will be sending +CSQ: 19,0....
I want to store the value 19 in the memory like b0.. I only able to store single value.. please help me on this...
Thank You
Re: How to Debugin 2 letters and store in microcontroller memory?
Hello and Welcome,
The first thing that comes to mind is 19 has binary value %00010011, a hex value $13, a decimal value of 19 and an ascii value of49,57. Which value are you sending and which value are you expecting? If you are sending ascii text then you are sending 2 characters which would prefer an array, probably doable with a word if you are clever.
Re: How to Debugin 2 letters and store in microcontroller memory?
Quote:
Originally Posted by
Joe S.
Hello and Welcome,
The first thing that comes to mind is 19 has binary value %00010011, a hex value $13, a decimal value of 19 and an ascii value of49,57. Which value are you sending and which value are you expecting? If you are sending ascii text then you are sending 2 characters which would prefer an array, probably doable with a word if you are clever.
Sir, actually my code like this:
CC:
DEBUG "AT+CSQ"
PAUSE 10
DEBUG 13
debugin [wait("+")]
debugin [wait("C")]
debugin [wait("S")]
debugin [wait("Q")]
debugin [SKIP 2,DEC1 B0]
DEBUG B0
IF B0= 1 THEN RC
IF B0= 2 OR 3 OR 4 THEN GC
By using this code, i am only able to store one digit in the b0 memory. Please guide me on how to store few incoming data in the memory. I am sending ascii characters and expecting incoming ascii characters also from gsm if i am not mistaken. I am sorry if i am not able to explain clearly, sir . I am just a beginner. Tq
Re: How to Debugin 2 letters and store in microcontroller memory?
Try ...
Code:
debugin [wait("+CSQ:"),DEC B0]