Fa2018-es200-3321-proj2-WHACK_A_MOLE
/
HighFiveCode
Code for the High Five Portion of the game
Fork of Guntrigger by
Diff: main.cpp
- Revision:
- 1:a1880f0b0f04
- Parent:
- 0:e65fc2ec46d6
- Child:
- 2:629e8eb2c308
--- a/main.cpp Wed Oct 10 14:40:32 2018 +0000 +++ b/main.cpp Wed Oct 10 14:43:42 2018 +0000 @@ -11,13 +11,14 @@ wait(1); while (1) { c = getchar (); - for (pos =0.0; pos<=10.0; pos=pos+10.0) { - myservo=(pos/10.0); + for (pos =0.0; pos<=50.0; pos=pos+10.0) { + myservo=(pos/50.0); wait (0.07); printf("%f\n",pos); } - for (pos =10.0; pos>=0.0; pos=pos-10.0) { - myservo=(pos/10.0); + wait(2.0); + for (pos =50.0; pos>=0.0; pos=pos-10.0) { + myservo=(pos/50.0); wait (0.07); printf("%f\n",pos); }