Code Monkey home page Code Monkey logo

rov-lb's People

Contributors

a-ridley avatar jdvalera avatar pwoosam avatar

Watchers

 avatar  avatar  avatar

rov-lb's Issues

Documentation is lacking

We need documentation to describe how to use the custom classes in our code and how to use them. We also need documentation to describe how messages are passed from Pi to Arduino and vice-versa over I2C.

Add additional Thrusters to arduino/i2c-slave/i2c-slave.ino

I have only implemented the elevator thruster (The one that goes up and down). We still need the left and right thrusters to be implemented so that we can send messages to them from the Pi and get them moving. Implementation of the left and right thrusters should be almost identical to my implementation of the elevator thruster.

Here are some examples of messages to the Arduino that move the elevator thruster. The left and right thrusters should be similar.

from i2c_master import Arduino

ard = Arduino()
ard.send('255', register=0x10)   # Move the elevator thruster up at full speed
ard.send('10', register=0x10)    # Move the elevator thruster up at a slow speed
ard.send('0', register=0x10)     # Turns off the elevator thruster
ard.send('-255', register=0x10)  # Move the elevator thruster down at full speed

I would like to be able to move the left and right thrusters in a similar fashion.
For example:

ard.send('255', register=0x11)   # Move the left thruster forward at full speed
ard.send('-255', register=0x12)  # Move the right thruster backward at full speed

README.md is empty

We need someone to write the readme for this project.

The README.md should contain:

  • A description of what the software is used for and maybe some pictures of the ROV
  • Some information about the rov competition. Like objectives that must be met by the participants and what we are trying to achieve with our ROV
  • Dependencies for the Python scripts
  • Instructions for installing and running the software on the Pi and Arduino
  • Instructions for wiring the Arduino to the Pi and other peripherals, possibly using a diagram
  • Anything else you think would be appropriate. Suggestions?

Need to Control Thrusters with Buttons

Reading issue #3 will assist you in moving the thrusters. Although the left and right thrusters have not been implemented yet (not until issue #3 is resolved), you could probably figure out which messages and registers control which thrusters if you read issue #3.

We need to implement the following:

Button number Function (while held down) Motor movement
1 Switch from slow to fast movement none, just switches speed to high while depressed
2 Pivot left left thruster reverse, right thruster forward
3 Pivot right left thruster forward, right thruster reverse
4 Move forward left thruster forward, right thruster forward
5 Move reverse left thruster reverse, right thruster reverse
6 Descend elevator thruster down
7 Ascend elevator thruster up

Since we already have Arduino to Pi communications down, we can write a Python script that reads buttons from the Pi's GPIO inputs.

See the documentation here for details on how to use the RPi.GPIO library for reading GPIO inputs on the Pi.

I would recommend using some code like this:
GPIO.add_event_detect(channel, GPIO.FALLING, callback=my_callback, bouncetime=200)
where channel is the GPIO pin the button is connected and my_callback is a function that checks if the button is still pressed. While the button is still pressed, the pi sends a message telling the arduino to do something. If the button is no longer pressed, then have the pi send a message telling the arduino to stop doing that thing.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.