Introduction: How to Build a Warzone Defence Game

We are ZipZap, a freshman team from Joint Institute(JI), Shanghai Jiao Tong University. The course Vg100, intro to engineering, which we’re in, is a compulsory course in JI to teach students basic engineering knowledge and technical communication skills.UM-SJTU JI is a joint institute founded by SJTU and University of Michigan. JI trains engineers and has two majors, ECE and ME. It takes an advanced new teaching pattern combining the advantages of both universities. It is committing to developing students’ creativity, team-cooperation spirit, leadership and critical thinking. Now the teaching pattern is widely approved and recognized as a model of other joint institutes. (For further information about JI, visit JI official website, http://umji.sjtu.edu.cn/cn/ ).

OUR TEAM

Name: Zhang Zixiao
Responsible for: communicating with professors and TAs; writing the project manual; setting up working schedule; writing Arduino code of the bug and tower; purchasing materials; Assembly.

Name: Wan Kaining

Responsible for: helping to writing the manual; helping to design the structure of the tower and to build the paper tower.

Name: Huang Kun

Responsible for: assembling the bug; building the paper tower; helping to write the code of the steering engine. Name: Fang Jiayi

Responsible for: writing the code of steering gears; building the paper tower; writing peer evaluation.

Name: Zhao Youchen Responsible for: communicating with TAs; purchasing materials; helping to write the manual; building the paper tower.

About the Warzone Defense Game

There are 20 groups in the competition. Each group should build a bug and a paper tower with laser on the top, so there are 20 bugs in all. For each team’s tower, three bugs are picked randomly from 20 bugs to run on three tracks with white lines from three different directions. The tower should find out where are the bugs in the dark and control the laser to ‘kill’ them one by one. The faster you stop all three bugs, the less paper used to build the tower, the better your bug behave, the higher score you get. Some more specific requirements are listed below.

Requirements for the BUG:

Go straight along the white line (which means a line-tracking bug is required)

Speed: 0.2-0.3 m/s

Stop immediately if shot by the laser.

Has a photosensor : 1) on the central axis of the vertical board

2) 5cm above ground

Wait for 2-4s at the white line lying across the board near the midpoint;

Restart after waiting;

Being immortal if the speed is higher than 0.4m/s (prevent laser’s strafing);

Stop in front of the tower;

Requirements for the tower:

Higher than 60cm;

Use only paper (A4 80g) and white glue;

Place electronic components on the top;

No stacking paper (fewer than 3 sheets);

Step 1: Drawing Concept Diagrams According to Functions Required

Functions of the bug:

  • Four infrared line-tracking sensors in the front (workable in the dark).
  • ---two for tracking the center white line to run straight.
  • ---two for locating where to wait and stop.
  • Two spheral casters in the front enable the car to adjust directions faster.
  • A vertical board to place the photosensor.
  • The photosensor in the very front should be parallel to the ground to make sure that the car can be detected.
  • Arduino uno R3 runs the code and gives orders to the sensors and the motor driving board to operate the whole system.
  • The motor driving board L298N controls two DC motors to run the car.
  • Functions of the tower:
  • Four range sensors at the bottom of the tower detect how far are the bugs
  • Another Arduino on the tower receives data from the range sensors and calculate which bug should be killed first and the angle and direction of the laser to kill it
  • Steering engines on top of the tower adjust the direction of the laser in order to kill the bug

Step 2: Drawing Circuit Diagrams

Step 3: Drilling Holes on the Arcrylic Board

  • Measure and decide where to drill holes.
  • (Be careful in this step because any mistake might lead to failure in assembly)
  • Make marks at the points you want to drill holes.
  • ---You can either use the AutoCAD software if you want a better shaped bug or simply mark by hands in this step since this is not a complicated work.
  • ---Make sure the sizes of your hole suit with the sizes of your screws.
  • l Use either a laser cutting machine to finish this step (you only need to upload your CAD file to the cutting machine, then it will automatically finish the cutting for you) or simply use an electro drill just like what we did
  • (Be careful when using a drill. Wear safety glasses to protect your eyes)

Step 4: Assembling the Main Structure of the Bug

  • Assemble the front casters
  • Use an “L” structure to connect the vertical board and the base
  • Assemble the motors to the board using brackets
  • Connect motors with couplers
  • Plug the hexagon side of the couplers into the wheels

Step 5: Assembling the Circuit on the Bug

  • Assemble Arduino UNO
  • ---Make sure the data port [Figure 4.1]is facing outward to make it easier for code uploading
  • Assemble the motor driving board and the breadboard
  • Weld two Dupont wires to each motor [Figure 4.2]
  • Plug the welded wires to an OUT port on the driving board
  • Assemble the photosensor and four tracking sensors using 3M tapes
  • Connect all the components together according to the circuit diagram given in STEP 1[ Figure 4.3]
  • ---Must be very careful, otherwise, it may take a long time for troubleshooting since there are so many wires
  • ---Don’t connect with 11.1v battery while assembling

Step 6: Preparing Paper Pillars

  • Four long pillars as the main structure of the tower
  • --- 60 cm long
  • --- 2 medium length pillars sticking together
  • --- strongest pillars
  • --- as straight as possible
  • Eight short pillars with holes
  • --- ten cm long
  • --- the size of the holes should suit long pillars well
  • Two medium pillars with holes
  • --- 14 cm long
  • --- bonding the long pillars to make the tower stable
  • A cross at the top
  • --- a platform to place electronic components

Step 7: Building Up the Tower

(1) Make two long pillars go through the holes of two short pillars

(2) Repeat the step to the other two long pillars

(3) Make two diagonal long pillars go through the holes of the medium pillars

(4) Repeat the step to the other diagonal long pillars

(5) Make the four long pillars go through the other four short pillars to make the tower structure more stable

(6) Stick the cross to the end of four long pillars

Step 8: Assembling the Circuit on the Tower

Assemble three steering engines to the platform

Stick the steering engines at the center of the cross

Stick the breadboard and the Arduino board at two corners of the cross

Place a battery case at the middle of the tower

Stick the laser to the steering engine

Connect a battery case to the laser

Place range sensors at the bottom of the tower

Step 9: Final View

Step 10: Material List

See file :material list. xlsx

Step 11: Troubleshooting

1. Whenever there is a problem, check the connection of the wires and
your code first

2. the steering engine can’t turn

--the voltage of your battery may be too low

--check whether you follow the circuit diagram strictly

3. line tracking sensors don’t work

--make sure they are parallel to the ground

Step 12: Gameday!

Step 13: Critical Tools Required

  • Wielding iron
  • Electrical drill
  • Sharp-nose pliers
  • Screwdriver
  • Scissors
  • Ruler
  • A little brush

Comments

author
Swansong (author)2016-10-28

Thanks for sharing :)

About This Instructable

99views

1favorite

License:

More by freiqzzx:How to Build a Warzone Defence Game
Add instructable to: