Here is an album of the requirements for the lab as well as my code: http://imgur.com/a/eFPVd
Here is some example input and what it looks like in the serial monitor: http://imgur.com/QmJlSSn
For the most part I have the lab working. But I still have a few questions as I’d like to get the extra credit portion as well:
In my serial monitor you’ll notice at first it says "Enter a character: " twice. It also doesn’t say "Enter a character: " again until I’ve already entered a character and hit enter. I’d like it to Show up at first only once in the beginning. And then before I enter a character every time after that-- so after the input is displayed. How should I go about fixing this?
Does my coding only accept ASCII values in the visible range? I know inputting space receives the correct error message, but are there ASCII values of multiple characters like CR, NL (as mentioned in the instructions in hint 3) that will not output the correct error message? Or do those multiple letters stand for something else? Sorry if this is poorly worded but TL;DR - Do I have #3 under 2.2 correctly coded in my program?
Extra Credit Questions
- When it says “Make a new function.” Should I just add another void loop() or could I integrate this into the existing void loop()? Where should I start in either case?
And any general hints about how to go about doing this portion would be much appreciated. Just trying to understand it is a bit confusing for me.
Thanks so much to anyone who can help, I definitely appreciate it!