building raspberry pi nodebots

33
Building high performance Raspberry Pi robots @RiaanCornelius

Upload: riaan-cornelius

Post on 14-Aug-2015

47 views

Category:

Technology


2 download

TRANSCRIPT

Building high performance

Raspberry Pi robots@RiaanCornelius

Riaan Cornelius

• 10 Years of dev experience• Mostly Java and Android • I work for Entelect• I try to do cool stuff in my free

time

How many people here are interested in building robots?

Why haven’t you?

• It’s too hard• I don’t know where to start• It costs too much• I don’t have time

You know Javascript

Node + Robotics = Nodebots

You already have most of the skills

Lets build a robot

What is a robot?A robot is a mechanical or virtual artificial agent, usually an electro-mechanical machine that is

guided by a computer program or electronic circuitry. Robots can be autonomous or semi-autonomous and range from humanoids such as Honda's Advanced Step in Innovative

Mobility (ASIMO) and TOSY's TOSY Ping Pong Playing Robot (TOPIO) to industrial robots, collectively programmed swarm robots, and even microscopic nano robots.

- WikipediaBORING

LetsMakeRobots.com

InspirationTutorialsHelpful community

What do you need

Hardware

Electronics

Software

Patience

HardwareChassis with wheels and space to mount stuff.

ElectronicsRaspberry Pi B+

Why?

• Inexpensive

• Lots of GPIO

• More computing power than you need

• Easy to add a camera for computer vision or video streaming

ElectronicsMotor driver

Sensors

ElectronicsSparkfun Pi B+ Wedge

Breadboard jumper wire

Breadboard

What does this cost?Chassis (With motors, wheels, chassis and battery box)

R249.95

Raspberry Pi B+ R504.67

SparkFun Pi Wedge B+ R132.95

Breadboard Jumper Wire (65PCs Pack) R43.78

Motor driver R129.95

Distance sensor R39.95

Breadboard R64.09

Total: R1165.34

Step 1Assemble the hardware

Step 2Wire everything up

Step 3 – Program itThe part I imagine you are more interested in

What are we going to use?

Client• Johnny-five• JS Robotics library

Hardware• Raspio-io• Talks to the Raspberry Pi

Component specific libraries• R-pi-usonic

Installing1. Set up the Pi (Install raspbian, set up SSH, wifi, etc)

2. Install node.js

3. Install Johnny-five (npm install johnny-five)

4. Setup a board (npm install raspi-io)

5. That’s it

Simulation

Initialising Johnny-Five

Making it move

Bonus – Controlling it

Adding sensors

Logic

What next

• Improve the algorithm• Add more sensors• Give it a goal• Give it personality• Make the hardware better (Better chassis, stronger motors, etc)

Riaan Cornelius

@RiaanCornelius

http://[email protected]

https://github.com/riaancornelius/nodebot_steve

What will you build?

References

• Controlling 2 motors with the TB6612FNG + Arduino• Running Johnny-Five on Raspberry Pi• Johnny five website - Lots of examples• Lets make robots – Awesome robot building community

Online retailers I use:• www.netram.co.za

• www.microrobotics.co.za

• www.hobbytronics.co.za

• www.riecktron.co.za