Project tutorial
The Fishing Bot

The Fishing Bot

A joystick controlled robot for playing the famous fishing game.

  • 2,242 views
  • 0 comments
  • 4 respects

Components and supplies

Necessary tools and machines

Apps and online services

About this project

It was about the classic fishing game. This game is found in almost all toy stores.

People use to challenge themselves by trying to catch the highest possible number of fish. The idea was trying to shift this toy to the automated side.

Code

Fishing bot codeArduino
Binary file (n
#include <SoftwareSerial.h>
#include<Servo.h> // include server library

Servo ser1;  
Servo ser2;
int potpin1 = A0;  // analog pin used to connect the potentiometer
int potpin2 = A1;
int val;    // variable to read the value from the analog pin

void setup() {
  ser1.attach(9);
  ser2.attach(8);// attaches the servo on pin 9 to the servo object
}

void loop() {
  val = analogRead(float(potpin2));            // reads the value of the potentiometer (value between 0 and 1023)
  val = map(val, 0, 1023, 0, 60);     // scale it to use it with the servo (value between 0 and 180)
  ser1.write(val);                  // sets the servo position according to the scaled value
  delay(100); // waits for the servo to get there

  val = analogRead(float(potpin1));            // reads the value of the potentiometer (value between 0 and 1023)
  val = map(val, 0, 1023, 0, 40);     // scale it to use it with the servo (value between 0 and 180)
  ser2.write(val);                  // sets the servo position according to the scaled value
  delay(100);

}o preview)

Comments

Similar projects you might like

Telegram Bot with ESP8266

Project tutorial by Shebin Jose Jacob

  • 25,382 views
  • 41 comments
  • 66 respects

Remote Control Gripper Bot

Project tutorial by Scott Beasley

  • 4,767 views
  • 8 comments
  • 15 respects

GO-4 Smart Home Arduino Bot

Project in progress by AhmedAzouz

  • 5,675 views
  • 0 comments
  • 34 respects

Remote Controlled Pet Feeder

Project tutorial by Amal Mathew

  • 4,327 views
  • 1 comment
  • 28 respects

Turn Walabot into a "Why-Not?" Bot for the Disabled/Elderly

Project in progress by Eric Olson

  • 2,090 views
  • 1 comment
  • 13 respects
Add projectSign up / Login