ASCII Problem

I was having some problems getting the microcontroller I’m using for bluetooth development to recognize certain characters being sent to it via serial. What was baffling me was the fact that certain keys worked, but other did not. For example, characters such as @, #, $, etc were working fine, but letters were not. I’m using Hyperterminal to send the characters to the development board, which is in turn taking the ASCII value and performing an action based on that value. For my testing I was having specific LED’s turn on when a particular character was sent to the board. After being stumped for a few hours, it turns out that a little Counter Strike was exactly what I needed. Some annoying youngster was having fun yelling into the microphone and typing IN ALL CAPS in the chat. Thats when it hit me: the code in the microcontroller was expecting a CAPITAL letter when I was only sending it lower case letters.  I blame this on the fact that the ASCII chart I had was missing the 2nd page that had the lower case letters.  No matter, now that I’ve gotten that annoyance out of the way, I can expand the functionality of the program to accept more complex inputs.

Leave a Reply

Your email address will not be published.