switch() case

This is a beautiful example of Simon’s first daring steps to create his own codes with Arduino. He wanted to make the computer (the serial monitor) say “Yes” once the dimmer was on, then say “No” and then “A Chance”. He tried using switch() case statements instead of if() else statements, but didn’t know about the word “switch”, so he wrote an if() case statement which didn’t work. I googled it for him and corrected the code to my best knowledge (the “Yes” worked within the switch() case statement and the “A Chance” as default, but we didn’t get the “No”to work). Simon was happy to see most of the project work but still seemed to be more interested in the process of writing it than in actually seeing it function.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s