Skip to content

jameskabbes/HackIllinois2024

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

39 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

John Deere | HackIllinois

John Deere Logo


Table of Contents


Prompt

Autonomous Vehicles

John Deere innovates on behalf of humanity.

It doesn’t matter if you’ve never driven a tractor, mowed a lawn, or operated a dozer. With our role in helping produce food, fiber, fuel, and infrastructure, we work for every single person on the planet.

"We don’t create tech for tech’s sake. There’s purpose behind everything we do, so that our customers have the tools they need to tackle some of the world’s greatest challenges."

John May
Chairman and CEO | John Deere

Along our journey of creating exceptional tools for our customers, we have become pioneers in the autonomous vehicle industry:

  • StarFire™: Track your equipment's location down to the inch
  • AutoTrac™: Achieve automated, hands-free guidance for your field operations, increasing efficiency and reducing operator fatigue
  • See & Spray™ Ultimate: Detect weeds from plants in real time using computer vision-enabled sprayers
  • John Deere Operations Center™: Setup, manager, and monitor critical jobs on your farm from anywhere in the world
  • Machine Sync: Connected machines working simultaneously for maximum productivity in the field
  • Autonomous 8R Tractor: Designed to autonomously perform various agricultural tasks while maintaining precision and productivity

Now, let's see what you can build.

Build your own autonomous vehicle


For your HackIllinois 2024 John Deere prompt, you are tasked with building your own autonomous vehicle, a vehicle that solves any problem that you define.

It is up to each team to determine what problem your vehicle solves. Does it drive down the road? Deliver food? Solve a maze? Plant a corn field? It could be something useful, something fun, or anything you can imagine. The only stipulation is that your vehicle:

  • Solves the problem autonomously, that is, makes decisions on its own
  • Uses data from sensor(s) in its decisions

Each team is supplied with a hardware kit. Teams are welcome to add to the vehicle and kit as needed. Teams are not required to use all items in the kit.

Like many problems at John Deere, this prompt requires more than just a software solution, it requires a solution at the intersection of mechanical systems, electrical systems, sensors, data, automation, programming, and of course, creativity.

Good luck!

Submission Criteria

We expect to see the following as part of submissions:

  • Devpost writeup
    • Codebase
    • Problem description
    • Solution explanation
  • Video of the vehicle working

Scoring Criteria

Submissions will be assessed by the following criteria:

  • Problem Complexity: how complex is your problem?
  • Solution Creativity: how creative is your solution?
  • Functionality: how successfully does your vehicle solve your defined problem autonomously?

Integrity

You are encouraged to use any open source and AI tools you wish. Be sure to mention sources of inspiration in your project write-up.

We have parterned with the Jackson Innovation Studio on campus to give you access to any tools you might need. The studio provides access to 3D printers, multimeters, screwdrivers, tape, and anything else you might need.

Private Office Hours

We have reserved the Jackson Innovation Studio for participants in the John Deere track. The space will be available to participants at the following times:

  • Friday, February 23 8:30pm - 11:00pm
  • Saturday, February 24 12:00pm - 6:00pm

The Jackson Innovation Studio is located in the basement of the Sidney Lu Mechanical Engineering Building at 1206 W Green St, Urbana, IL 61801, Room 0100


Materials

John Deere Kit

John Deere provides the following items:

  • Vehicle Chassis

    • 2 Rubber wheels
    • 2 Speed encoders
    • Swivel wheel and connectors
    • Acryllic frame
    • 3D Printed battery frame
  • Raspberry Pi

  • Power

    • 10,000mAh Rechargeable Battery
    • USB-C to USB-C: for powering Raspberry Pi / recharing battery
    • USB-A to Micro USB: for powering Raspberry Pi HAT / motors
  • Electronics

Bring your Own

We assume your team can supply the following items:

  • A laptop with a USB-C port
  • A USB-C charging brick

Raspberry Pi

A tiny computer in the palm of your hand. raspberrypi.com

Setup Instructions

Follow along for the recommended setup instructions

  • power on your raspberry pi
  • connect raspberry pi to your computer via ethernet cable
  • ssh into raspberry pi on your computer
  • If you want graphical access (to see a screen) follow along below
    • get raspberry pi onto the same internet network as your computer
    • find IP address of raspberry pi
    • establish a VNC connection to raspberry pi

Connecting to your Raspberry Pi

There are few ways to access your raspberry pi:

  1. Keyboard, Mouse, Monitor
  2. SSH (from another computer)
  3. VNC (from another computer)

Keyboard, Mouse, Monitor

You can use a raspberry pi like any other computer. Connect a keyboard and mouse via usb (or bluetooth) and connect a monitor to the Mini HDMI port.

SSH (Command Line Access)

You can establish an ssh connection for access to the raspberry pi terminal.

1a. With direct ethernet connection

  • ssh <username>@<hostname>.local
  • ssh pi@hackilpi1.local

1b. While on same network

  • ssh <username>@<ip_address>
  • ssh pi@10.0.0.35

2. Enter your password

VNC (Graphical Access)

You can establish a VNC connection for graphical access to the raspberry pi.

1. Download a VNC Viewer

Something like RealVNC Viewer

RealVNC Viewer Website Download Image

2. Connect to Network

Ensure your raspberry pi and computer are connected to the same internet network. See connecting to wifi below.

3. Establish Connection

Enter your raspberry pi's ip address and establish a connection

VNC Viewer Connection

4. Enter your password

note: you may need to enable VNC access on your raspberry pi

5. Control the Raspberry Pi

Use the window on your computer to access your Raspberry Pi's OS.

Secure Copy

Secure Copy, scp, allows you to transfer files between two locations, using the SSH protocol. Check out copy_repo_to_pi.sh for an example.

Find IP Address

To find the IP address of your raspberry pi, run

ifconfig

Look for inet.

Other Tips

Connecting to Wifi

You may wish to connect to your raspberry pi without a direct ethernet connection. Follow along for instructions on connecting to a network.

1. Edit the wpa_supplicant.conf file

sudo nano /etc/wpa_supplicant/wpa_supplicant.conf

2. Add your network

Add the following lines to the file, substituing your network's SSID and password

network={
    ssid="your_SSID"
    psk="your_password"
}

3. Restart the networking service

sudo systemctl restart networking


Connecting to IllinoisNet_Guest

1. Go to https://go.illinois.edu/illinoisnetguest and log in, click on "Register a New Device"

2. On your pi type in ifconfig and under wlan0 copy the number next to ether, that is the mac address for the device registration

Assembly - Chassis

Assembly - Chassis

3. On the raspberry pi type in sudo nmtui -> activate a new connection -> connect to IllinoisNet_Guest

Now the Pi is connected to the internet.

4. on the pi enter the command ifconfig again and under wlan0 find the number next to inet

5. ssh pi@<inet> from any device connected to IllinoisNet

Just like that you've done it. Multiple people can ssh in at once.

Assembly

Assemble Car Chassis

Follow the provided instructions to assemble the car chassis. The following items from the chassis kit are not used:

  • AA Battery Pack
  • Speed Encoders
  • Switch

Assembly - Chassis

Attach Battery Holder

Attach the provided 3D print to the chassis. Use the remaining screws and nuts to fasten to the arcyllic frame.

Assembly - Chassis and Frame

Check Battery Fit

Ensure the battery fits properly into the frame.

Assembly - Chassis, Frame, and Battery


Follow along with the wiring schematic for instructions on how to wire your vehicle.

Assembled Vehicle

A fully wired vehicle

Raspberry Pi Pin Layout

To power on the Raspberry Pi, attach the USB-C cable.

Ultrasonic Sensor

Raspberry Pi HAT

To simplify the wiring process, a Raspberry Pi HAT is provided for you. The HAT is placed directly on top of the Raspberry Pi. In the schematic, square pins designate Pin 1. To power on the circuit board, attach the micro USB cable.

Raspberry Pi HAT Schematic Raspberry Pi HAT

H-Bridge

Ensure proper H-Bridge orientation by checking that the notch on the H-Bridge matches the notch on the board.

Each side (motor) of the H-Bridge takes in three inputs sent by the raspberry pi:

  • speed (pwm signal)
  • control 1 (binary signal)
  • control 2 (binary signal)

The direction of the motor is controlled by sending high (3.3V) or low (0V) voltage to controls 1 and 2.

Control 1 Control 2 Motor Direction
HIGH HIGH n/a
HIGH LOW Forward
LOW HIGH Backward
LOW LOW n/a

The speed of the given motor is determined by the duty cycle of the PWM signal. A duty cycle of 100% turns the motor at 100% speed, a duty cycle of 50% turns the motor at 50% speed. Read the source code for examples.

Slide Switch - Motor Power Circuit

A slide switch is already assembled for you. Located next to the micro USB port, this switch controls the motor power circuit.

It has two states:

  • on: slid away from the micro USB port - current flows to motors
  • off: slid toward to the micro USB port - current does not flow to motors

Button Switches

Labeled Switch 1 and Switch 2 on the board, these button switches signal to the Raspberry Pi whether they are currently being pressed. The state of the switch can be tracked with software.

LEDs

Two LEDs are provided for you on the board. They are controlled by the Raspberry Pi.

Other Components

You are required to wire the following components to your vehicle. To insert wires into the green terminal blocks, push down on the top, insert the wire, and release. Test your connecting by gently pulling on the connected wire.

Follow along with this video to install your camera.

Other helpful camera resources:

Connect the pins of each ultrasonic distance sensor in their appropriate appropriate locations. You will need to remove the plastic caps from the jumper wires before inserting into the green terminal blocks.

Connect each motor's positive and negative terminals at the assigned pins. If your motor turns in the opposite direction you expect, swap the polarity by switching the wires.

Motor not turning?

Make sure your motor power slide switch is on.

Still not turning?

You may have blown a fuse in the motor circuit. Reach out for help.

This repository contains CAD files for various aspects of the assembled vehicle in the cad_files directory. These files are provided for your benefit. They may come in handy for additional components you design. Additionally, an Onshape workspace is provided.

CAD Model


This repository contains basic starter code for you in Python in the code directory. The Raspberry Pi comes installed with Python 3.11.2. Documentation is hosted on the repo's GitHub Pages.

Testing

After wiring each system, test its functionality with the appropriate test_<system>.py script.


Computer Vision Models

Teams utilizing the camera for their autonomous vehicle might find it helpful to use open-source computer vision models. It is recommended to look up Raspberry Pi-specific install instructions for your chosen library.

Popular Libraries

  • OpenCV
    • Raspberry Pi installation: sudo apt-get install python3-opencv
  • TensorFLow
  • PyTorch
  • Keras

Need Project Inspiration?

John Deere hosts dozens of publically available APIs and demo data. Create a MyJohnDeere account and get started! Read more at developer.deere.com.

Author Notes

I hope you enjoy your HackIllinois experience! I really enjoyed designing this prompt for you all. Best of luck!

James Kabbes | John Deere