Introduction: Putting Stroke Trainer

This machine is for training the putting stroke, especially for the backswing- to be wider and not be so short, which would harm the tempo for the entire stroke.

How does it work: When I swing the backstroke of my putter, if it reaches the length it is supposed to be, then the ultrasonic sensor will detect it and two lightbulbs will light up. If it is too short, then it won't reach the sensor and the lightbulb won't light up. So, the goal every time is to get the lightbulb to light up.

Supplies

  1. Styrofoam board
  2. 8 wires
  3. 1 ultrasonic sensor
  4. Arduino board
  5. 2 LED lightbulbs
  6. 2 resistors
  7. wire the connects the computer

Step 1: Coding

This is another code for the training machine:

int ardublockUltrasonicSensorCodeAutoGeneratedReturnCM(int trigPin, int echoPin)
{ long duration;

pinMode(trigPin, OUTPUT);

pinMode(echoPin, INPUT);

digitalWrite(trigPin, LOW);

delayMicroseconds(2);

digitalWrite(trigPin, HIGH);

delayMicroseconds(20);

digitalWrite(trigPin, LOW);

duration = pulseIn(echoPin, HIGH);

duration = duration / 59;

if ((duration < 2) || (duration > 300)) return false; return duration; }

void setup()

{

digitalWrite( 12 , LOW );

pinMode( 8 , OUTPUT);

pinMode( 7 , OUTPUT);

}

void loop()

{

if (( ( ( ardublockUltrasonicSensorCodeAutoGeneratedReturnCM( 12 , 13 ) ) < ( 10.0 ) ) && ( ( ardublockUltrasonicSensorCodeAutoGeneratedReturnCM( 12 , 13 ) ) > ( 0.0 ) ) ))

{ digitalWrite( 8 , HIGH );

delay( 1000.0 );

digitalWrite( 8 , LOW );

delay( 1000.0 );

digitalWrite( 7 , HIGH );

delay( 1000.0 );

digitalWrite( 7 , LOW );

delay( 1000.0 );

}

}

Step 2: Wiring of the Machine

This is the wiring of this machine, this wiring is designed specifically for the code which will work together and do its duty when plugged in. Making it may take up to 10 or 15 minutes.

Step 3: Decoration

Use any kind of box to cover over the board, you need to cut some parts of the box to show the sensor and the LED lights, enabling them to perform its function. The other main parts are for covering and hiding the ugly chords and wires.

Step 4: Plug the Board to the Computer

When you are done with both the coding and the wiring, it is time for you to connect them up and start practicing with you putter!

Step 5: Video of How the Machine Works(finished)

The first time when I swing the putter, the light bulbs didn't light up since I was swinging the club too short to the standard length of about 20 cm. So the second time, I swing longer to trigger the ultrasonic sensor to light up the lightbulb.

After that, you will be able to use this machine to practice your putting length and ultimately improve your putting stroke!