Giter Site home page Giter Site logo

sea-me-project-1's Introduction

SEA:ME Pi Racer

Table of Contents


Assemble Pi Racer

Important Point

  1. When connect motor & servo, attention to the connection
  2. Connect right direction the Camera

Write Image on Raspberry Pi

Install Raspberry Pi imager for set up Raspberry Pi

  • Click this link
    image

Write downloaded Image on SD card

image

  • Operating System -> Downloaded image
  • SD Card -> Your own SD card for Raspberry Pi

Enable SSH & Setting WIFI

image

  • Check Enable SSH
  • Check Set username and password
    • Username is server's name
    • Password is server's password
    • Remember this. It needs when connect Raspberry Pi server & PC

image

  • Check Configure wireless LAN

    • Enter the Wi-Fi or LAN information you are using on the PC you are connecting to
  • Setting done. Write the Image

Enable SSH

  • Write finish and Move to /boot directory
  • Enter the command touch ssh or touch /Volume/boot/ssh
    • Second one only work in Linux or Mac

Find & Connect Raspberry Pi

1st. Use monitor

  1. Connect monitor with Raspberry Pi
  2. Command ifconfig & check IP_ADDRESS
  3. Command ssh -Y {SERVER_NAME}@{IP_ADDRESS}

2nd. Use nmap

  1. nmap -sn {IP_ADDRESS}.0/24
    • ex) nmap -sn 192.168.2.0/24 -> Change last number to 0 or *
  2. Find Raspberry Pi's IP_ADDRESS
  3. Command ssh -Y {SERVER_NAME}@{IP_ADDRESS}

If there are many devices connected to the router, check the Raspberry Pie by turning it off and on

3rd. Make a wild guess

  • Raspberry Pie IP is caught similar to a PC

But I don't recommend it. It's not like a programmer.

Install & Set up Environment


Create donkeycar from template

  • Create a set of files to control your Donkey with this command
    • donkey createcar --path ~/mycar
    • You can also change your path something else instead of "mycar"

Configure I2C PCA9685

  • It's only for Raspberry Pi

  • sudo apt-get install -y i2c-tools -> install i2c-tools

  • sudo i2cdetect -y 1 -> check your car

    image
    • If you can't see 40
      1. On Pi, ensure I2C is enable in menu of sudo raspi-config
        • It suggest reboot
      2. Check your hardwear
        • Maybe your cable or Something wrong

Control with Web Controller & Gamepad

  • In terminal, follow commands
    pi@raspberrypi:~$ source ~/env/bin/activate
    (env) pi@raspberrypi:~$ cd mycar/
    (env) pi@raspberrypi:~/mycar$ python manage.py drive
    
  • Open Chrome in host pc. Go to http://{RASPBERRY_PI_IP_ADDRESS}:8887
  • Reference Link
  • Connect the USB adapter of Gamepad to Raspberry Pi
  • In terminal, follow commands
    pi@raspberrypi:~$ source ~/env/bin/activate
    (env) pi@raspberrypi:~$ cd mycar/
    (env) pi@raspberrypi:~/mycar$ python manage.py drive --js
    

Way to use Gamepad

  1. Use --js option
    • Run donkeycar with this command
      python manage.py drive --js
  2. Modify myconfig.py file
    • Find USE_JOYSTICK_AS_DEFAULT
    • Modify False to True
      USE_JOYSTICK_AS_DEFAULT = True

Display OLED pannel

Enable display in myconfig.py

  • Find line USE_SSD1306_128_32 removing #
  • Find line SSD1306_RESOLUTION removing #
  • example
    image

Tips

When you need to re-install Raspberry Pi

  • It should be occur this message Image
  • follow this code to reset ssh-key
    • ssh-keygen -R {IP_ADDRESS}
    • IP_ADDRESS => Raspberry Pi's IP address

Errors

  • Gamepad work different way

image

  • 7 & 8 is changed
  • Left and Right -> Left is forward and Right is backward
  • Front and Rear -> Front is right and Read is Left

sea-me-project-1's People

Contributors

pprajapa-42 avatar skamo3 avatar

Watchers

 avatar

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.