Hill Climb game hack for iPhone/droid with arduino bot servo and Stylus

I know it’s silly but i figured anyone else that’s addicted to this game would enjoy this simple program using Arduino and servo.

You have to use the tractor (generously modified) and the moon level. Any other vehicle is inconsistent and can get stuck in a ‘no return to menu’ mode where it doesn’t generate much points. with the tractor you can generate 10,000,000 points overnight. Beware, the points spend quick!

Stylus:

stylus work because they are conductive and conduct through your skin. there are not many stylus that work by themselves (eg. ones that work when you have big winter hand gloves on). i used some black ESD electrically conductive foam, inserted a piece of mag wire with some length and it seemed to give it enough capacitance similar to human body (Remember your finger is attached to this huge body of capacitance). i also soldered on an alligator clip, at first i attached it to the negative lead of a 9v it seemed to help emulate some capacitance body but i found out later just the mag wire (2-3 inches) with the alligator clip floating on the end worked consistently. You can also use carrots or some fruits/veggies.

// Sweep
// by BARRAGAN <http://barraganstudio.com>
// This example code is in the public domain.


#include <Servo.h>
 
Servo myservo;  // create servo object to control a servo
                // a maximum of eight servo objects can be created
 
int pos = 0;    // variable to store the servo position
 
void setup()
{
  myservo.attach(9);  // attaches the servo on pin 9 to the servo object
}
 
 
void loop()
{
  // on  250 ms
// off 8000 ms
// on  12000
// off 1200000 ms
// on 250 ms
// off 500 ms
 // 111111111111111111111111111111111111111111111111111
  for(pos = 0; pos < 28; pos += 1)  // goes from 0 degrees to 180 degrees
  {                                  // in steps of 1 degree
    myservo.write(pos);              // tell servo to go to position in variable 'pos'
    delay(10);                       // waits 15ms for the servo to reach the position
  }
      delay(250);  
  for(pos = 28; pos>=1; pos-=1)     // goes from 180 degrees to 0 degrees
  {                                
    myservo.write(pos);              // tell servo to go to position in variable 'pos'
    delay(10);                       // waits 15ms for the servo to reach the position
  }
  delay(8000); 
  // 222222222222222222222222222222222222222222222222222
  
    for(pos = 0; pos < 28; pos += 1)  // goes from 0 degrees to 180 degrees
  {                                  // in steps of 1 degree
    myservo.write(pos);              // tell servo to go to position in variable 'pos'
    delay(10);                       // waits 15ms for the servo to reach the position
  }
      delay(12000);  
  for(pos = 28; pos>=1; pos-=1)     // goes from 180 degrees to 0 degrees
  {                                
    myservo.write(pos);              // tell servo to go to position in variable 'pos'
    delay(10);                       // waits 15ms for the servo to reach the position
  }
  delay(12000); 
  // 333333333333333333333333333333333333333333333333333
  
      for(pos = 0; pos < 28; pos += 1)  // goes from 0 degrees to 180 degrees
  {                                  // in steps of 1 degree
    myservo.write(pos);              // tell servo to go to position in variable 'pos'
    delay(10);                       // waits 15ms for the servo to reach the position
  }
      delay(250);  
  for(pos = 28; pos>=1; pos-=1)     // goes from 180 degrees to 0 degrees
  {                                
    myservo.write(pos);              // tell servo to go to position in variable 'pos'
    delay(10);                       // waits 15ms for the servo to reach the position
  }
  delay(500); 
}

Nice :slight_smile: Any other examples of “arduino touches iPhone” or Android? ^)