Pages: 1 [2]   Go Down
Author Topic: Working with Case & Switches  (Read 1042 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 13
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Well I changed the orginal loop to a function and then created a new loop and added the switches and case numbers to it.  Everything complies just find with no errors.  But when I upload load, the arduino gets to the end of the void setup and then stops.  It doesn't seem to get into the void loop.

I even tried adding a "default" thinking it might would use that, but it doesn't.

Any suggestions?

Chipper

I have attached the new code.

* inverse with stages.txt (11.35 KB - downloaded 12 times.)
Logged

Offline Offline
Faraday Member
**
Karma: 61
Posts: 2879
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Your program looks ridiculously complicated.

How do you actually "know"  that it never makes it into the loop() function ?
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 13
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Your program looks ridiculously complicated.

How do you actually "know"  that it never makes it into the loop() function ?

Well, it would get to a certin point and then stop.  I knew exactly where it was stopping at. 

I later discovered that I had a "void" in the case section and that was what was making it stop.  After removing the void, it worked great!!

Now on to do the rest of the code.
Logged

Pages: 1 [2]   Go Up
Jump to: