Showing posts with label ArrBot Syllabus. Show all posts
Showing posts with label ArrBot Syllabus. Show all posts

Thursday, August 21, 2014

Hooking up the ArrMote

Here's how to set up the Arrmote.  Pictures forthcoming!  This page a Work in Progress!

Parts

Base

  • Arduino Pro Mini 3.3
  • Battery, 3.3V - 12V
The Pro Mini should have pins A4 and A5 on the top.
The Pro Mini should have a splitter on VCC, or a "long pin" on VCC.
The Pro Mini can optionally have a "long pin" on GND for ease of connection.

If you have two "long pins" it tidies up the assembly since the Nunchuck can be wired from the top and the nRF24L01+ can be wired from the bottom.

Nunchuck
  • Nunchuck
  • Nunchuck Adapter with header pins
  • 4 wire F-F cable
Radio
  • nRF24L01+
  • 100nF ceramic capacitor
  • 7 wire F-F cable
(tentative) solder the capacitor across GND and 3.3V on the nRF board.

Software Setup


You can start by testing your Nunchuck and Radio as described (here and here, coming).
  • Edit the sketch (name)
  • Modify the radio channel assignment.  If you are in the robotics class, your robot kit has a number.  Use use channel 3*RobotNumber (e.g. robot 1 = channel 3, robot 2 = channel 6, etc).
  • Upload this sketch AND DISCONNECT YOUR FTDI CABLE.

Connections

Attach the Nunchuck to the Pro Mini using the 4 wire cable and Nunchuck Adapter. (details here)
  • "+" : VCC
  • "-"  : GND
  • "d"  : A4 (top, farthest from header)
  • "c"  : A5 (top, closest to header)

    Attach the nRF24L01+ to the Pro Mini  (details here)
    • 1 : GND
    • 2 : VCC
    • 3 : pin 9
    • 4 : pin 10
    • 5 : pin 13
    • 6 : pin 11
    • 7 : pin 12
    • 8 : UNUSED
    Attach the battery to the Pro Mini
    • "+" : RAW
    • "-" : GND
    One the power is attached, your unit should be operational.  (test program tba)

    blogodex = {"toc" : ["ArrBot", "ArrBot Syllabus"], "idx" : ["nRF24L01+", "Nunchuck"]};

    Saturday, August 9, 2014

    Arrbot: Assembling the Body

    Now that we've got the body printed and servos modified, it's time for some relatively easy assembly work.  Rewarding too... finally we'll start to have something that looks like a  robot!  In addition to the body and servos, we'll need two treads, two servo arm kits, two front wheels, and two drive (back) wheels.  The drive wheels have two pieces.

    Read on to see the step by step instructions.


    Thursday, August 7, 2014

    ArrBot: Class 3 Notes

    Today's class will be a bit more entertaining than the last two classes.  Now that we have the components, we're going to assemble the robots!

    (pictures forthcoming!!)

    You should have prepared for class:
    • Robot body and wheels
    • Two CR servos
    Bring to class:
    • Robotics kit, including the above
    • Soldering stuff
    • Small (but not tiny) phillips screwdriver.  Look at the screws in the servo kit.
    • Sandpaper, medium and fine grit.
    • Hot glue gun, if you have it.  I'll bring some extra hot glue sticks if you don't mind sharing your hot glue gun.
    Building the Robot

    tl;dr: put all the 3D printed parts together and put the battery and breadboard on top.

    Front Wheels

    Fit the front wheels onto the axles.  Most likely they won't fit, and will need to be sanded down.  Even if they do fit, you will want to sand them to make the axle and the interior bearing surface of the wheel as smooth as possible.

    When each front wheel turns smoothly on its axle, use one of the "large" servo screws to attach the wheel to the axle.  You might have to open up the hole in the wheel a bit so that the wheel will turn freely.  Heating the screw a bit will allow it to screw smoothly into the axle.  Tighten the screws so that the wheels don't wobble, but not so tightly that they bind against the wheel.

    Put some dry silicone/teflon lubricant between the axle and the wheel.  Not too much, it gets a bit messy if you use too much.

    Drive Wheels

    The drive wheels come in two pieces.  Take the long servo arm and fit it into the slot.  Press the outside part of the wheel tight so that the servo arm is held firmly in place.  Trim any excess plastic off the servo arm.  Add a bit of hot glue to hold everything together.  The teeth should be centered on the wheel.  Attach the servo arm to the servo with the small screw in the servo package.

    Note that there's a wrong way to put the drive wheels together.  The gears should end up in the middle.  If the gears are touching the side, you've done it wrong.

    Mounting Servos

    You can do this in either of two ways.  If you have some extra screws, you can screw the servo onto the body.  There's a flat surface that will accept the screws.

    You can also just hot glue the servo to the body.  This seems to work fine as well.  Use a thin layer of hot glue, and press it tight with your fingers to ensure a square, tight fit.

    Battery Pack

    Solder or crimp a servo lead onto the battery pack.  Put "+" in the center and "-" on one side.  This will allow you to attach the battery to the breadboard on pins inserted into RAW and GND.

    Make sure your battery pack fits within the ArrBot treads.  If not, hot glue a bit of cardboard or other material the bottom of the breadboard (remove the paper backing covering the adhesive first) so that it clears the treads.

    The Stack

    Pull the paper off of the adhesive on the breadboard.  Put some Dual Lock on the top of robot body, top and bottom of the battery holder, and bottom of the breadboard.  Stack all this up and lock it tight.

    If you don't have Dual Lock, use some Velcro or any other stuff that looks like it might hold everything together.

    The Treads

    Finally, put the treads on the wheels.  Note that there's an indentation on one side of the tread, that should be on the inside and line up with the gear teeth.

    blogodex = {"toc" : ["ArrBot", "ArrBot Syllabus"]};

    Sunday, August 3, 2014

    ArrBot: Dual Servo Calibration

    Here's the process we'll use to calibrate the servos.  In phase 1, we'll do this the simplest way possible. There's two reasons for this:
    • Practically, we're coding the first iteration in a limited amount of time.  Tending towards simplicity is a good thing at this time.
    • For teaching purposes, it's good to have a couple of small single-purpose programs.  Later we'll combine everything into one program and put a cross-platform GUI.
    Measure the Left Servo

    Load the  Basic ArrBot Servo Tester.  There's a couple of values we're trying to find.
    • Find the midpoint where the servo is stopped.  Write down this value as MID.
    • Increase the value until the servo is at its maximum speed. Write down this value as HI.
    • Decrease the value until the servo is at its maximum speed in the other direction.  Write down this value as LO.
    • Calculate SPAN as HI - MID.
    • Hopefully, SPAN = MID - LO as well.  If not, choose the lower balue.

    Measure the Right Servo

    Get MID and SPAN for the right servo as above.

    Write the Calibration Data to the Arduino
    • Grab the Basic Servo Calibrator.
    • Fill in MID and SPAN for the left and right servos.
    • Don't worry about REVERSE.  You may need to set that later.
    • Run the program and the calibration data will be written to the EEPROM.
    • Watch the serial monitor and it will confirm.
    Now we're going to switch things up a bit.  First, we want to start thinking of motor speed in terms of percentage.
    • -100% = maximum speed reverse
    • 0% = full stop
    • 100% = maximum speed forward
    And we want to see if  if the two servos are working well together, i.e. if -100%,0%,100% produces the same speed on both motors.  We'll modify our servo test in two ways:
    • Add a second servo control.  Now we can test the left and right servos at the same time.
    • Change the control values to percentages.

    Assemble the Enhanced Servo Tester

    Start with the ArrBot Servo Tester. Duplicate the connections, so you have this configuration:
    • left servo: RAW, GND, Pin 9
    • right servo: RAW, GND, Pin 10
    This will be the basic ArrBot configuration.

    Test the Two Servos Together

    Run the ArrBot Dual Servo Tester (coming!)  It has the following controls.
    • v -- variable sweep from -100% to 100%
    • c -- set 0%
    • j, k -- subtract, add 1%
    • r -- cycle through channel reversal combinations

    blogodex = {"toc" : ["ArrBot", "ArrBot Syllabus"], "idx" = "Servo Calibration"};

    Thursday, July 31, 2014

    ArrBot: Assembling the Arduinos

    Assemble The Arduino Micro

    Solder the male pins down each long row.
    • Put the pins in the breadboard.
    • Long end of pins go into the breadboard.
    • Line up the Arduino Micro so that it sits on the pins.
    • CPU goes on top.
    Assemble The Arduino Mini

    Solder the male pins down each row.  Same as for the Micro.

    Solder the end pins.
    • Those are the 90 degree pins.
    • They go into the 6 through holes on the short end.
    • Use the helping hands.
    • Flip the board over, the CPU should be on the bottom.
    • The short end of the 90 degree pins should come through the holes.

    ArrBot Parts List

    Here's a cut and paste.  Sorry it's so ugly... I'll clean it up, but I wanted to get the parts available for people following along on the web.


    ArrBot Class 2 Notes

    Today's class will consist of of setting up your Arduino environment, testing the Arduinos we made last time, and making "continous rotation" servos.

    Syllabus: http://eastbay-rc.blogspot.com/2014/07/arrbot-syllabus.html

    Bring:
    • Soldering stuff
    • Laptop computer, if you have it
    • USB "Micro B" cable to fit your Arduino
    • Tiny #000 Phillips screwdriver (fits tiny servo screws), if you have one.
    • Small tweezers, if you have them.
    • Bring extra tools if you have them and don't mind sharing.

    Thursday, July 17, 2014

    ArrBot Syllabus

    (note)
    The first ArrBot session has been scheduled.  It will tentatively run for 5 2-hour sessions, meeting once per week.  This first session is highly experimental.  If we're crunched for time, we may add an extra class at the end.

    The ArrBoteers and I are working on the first pass of the software, and there's a couple of "known unknowns" along with (I'm sure) a ton of other things we'll discover along the way.  It will be a journey for all of us!

    I'll be revising this as we go along... when we've finished the first session, it should be a somewhat reliable guide as to what can be accomplished by a class in this timeframe.
    (end note)

    Prerequisites
    • Basic Electronic Soldering.  Should be able to solder wires and through-hole.
    • Not required, but familiarity with Arduino is a plus.
    Student Tools
    • Soldering iron
    • #000 screwdriver for servos
    • small screwdriver for wheels
    • side cutters
    • laptop w/ micro USB cable
    Scheduling

    Time is tight, since we have a hard out after two hours.  I will start talking at the top of the hour.  Don't be late!