Page 1 of 3 123 LastLast
Results 1 to 10 of 23

Thread: Autonomous Helicopter

  1. #1
    Join Date
    Sep 2008
    Location
    Nelson, New Zealand
    Posts
    278
    Images
    9
    Rep Power
    39

    Arrow Autonomous Helicopter

    Okay.... so i have started this project.... Yip...


    Just to prove that the picaxe is good enough for these things, i am making an autonomous (ex R/C) helicopter.
    this will will be controlled by two 08ms and a 28x2.


    https://www.sparkfun.com/commerce/product_info.php?products_id=252


    I have an accelerometer arriving any day now from the US of A....

    i have parts ordered off another place for making a voltage regulator;

    i bought two 8gram digital servos yesterday... those have replaced the "other" servos that were once inside my helo.


    i am thinking of placing a PING ultrasonic range sensor on the bottom of the helo to act as an altimeter.

    so far that is what has happened. i'll post some code i have written up awaiting some of the parts, later.

    cheers,
    Last edited by elios; 07-05-2009 at 02:55 AM.
    Hey Hamlet: 2b or not 2b = $FF

  2. #2
    Join Date
    Apr 2009
    Location
    Brisbane, Australia
    Posts
    48
    Rep Power
    34

    Re: Autonomous Helicopter

    Yay. Looking forward to how you go with accelerometers and Picaxe.

  3. #3
    Join Date
    Sep 2008
    Location
    Nelson, New Zealand
    Posts
    278
    Images
    9
    Rep Power
    39

    Re: Autonomous Helicopter

    lol my current plan is to readadc..... idk what if that fails.... hahahaha.. i have to ask my mate
    Hey Hamlet: 2b or not 2b = $FF

  4. #4
    Join Date
    Sep 2008
    Location
    Nelson, New Zealand
    Posts
    278
    Images
    9
    Rep Power
    39

    Re: Autonomous Helicopter

    Okay, the bit of code for the Servo controller 08m. called S08m ~ so far. THIS IS STILL VERY MUCH A WORK IN PROGRESS

    init: 'initial program, does not loop back
    symbol x = b0 'defining x axis
    symbol y = b1 'defining y axis
    symbol z = b2 'defining z axis
    symbol servox = b3 'defining servo on x axis
    symbol servoy = b4 'defining servo on y axis
    symbol motorz = b5 'defining servo on z axis
    servo 1, servoy 'move servo located pin 1, to position defined by servoy. This bit of code initiates the servo
    servo 2, servox 'move servo located pin 2, to position defined by servox. This bit of code initiates the servo

    loopa: 'loop A
    gosub loopd
    if y < 70 then gosub loopc
    if x < 70 then gosub loopb
    debug 'open debug window
    goto loopa 'goto loop A

    loopb: 'loop B
    servopos 2, servox 'move servo, located pin 2, to position that the variable servox is stating
    pause 200 'pause 20 milliseconds,
    return 'return to original place in loop A

    loopc: 'loop C
    servopos 1, servoy 'move servo, located pin 1, to position that the variable servoy is stating
    pause 200 'pause 20 milliseconds
    return 'return to original place in loop A

    loopd:
    serin 4, N2400_4, (":Q"),b3,b4,b5 'serial data in pin 3, baudmode Inverted 2400 on 4Mhz frequency, with the data being inputted to these variables.
    return 'return to original place in programming

    EDIT: x, y, z isnt being used as i moved the accelerometer decoding to the main processing unit ~ the 28x2
    Last edited by elios; 07-05-2009 at 03:24 AM.
    Hey Hamlet: 2b or not 2b = $FF

  5. #5

    Re: Autonomous Helicopter

    Keep me posted! I was given a Blade CX2 I want to do this with in the future! Awesome project!

  6. #6
    Join Date
    Sep 2008
    Location
    Nelson, New Zealand
    Posts
    278
    Images
    9
    Rep Power
    39

    Re: Autonomous Helicopter

    i got servo movements working with the digital servo, the pitch servo.

    init:
    servo 1, 80
    loopa:
    servopos 1, 122
    pause 222
    servopos 1, 80
    pause 222
    debug
    goto loopa

    this program makes it centralise, then go up and centralise again, on a continuous loop

    [edit] i have figured out, from trial and error, that the max movement ranges are:

    centre: b1=135
    up: b1=185
    down: b1=105

    you can subs the values after the pin, i.e servopos, 1, [b1], for b1.

    this is for the pitch servo
    Last edited by elios; 07-05-2009 at 06:29 PM.
    Hey Hamlet: 2b or not 2b = $FF

  7. #7
    Join Date
    Sep 2008
    Location
    Nelson, New Zealand
    Posts
    278
    Images
    9
    Rep Power
    39

    Re: Autonomous Helicopter

    some more code: this is the code currently in the 08m for controlling the x & y servos:

    init:
    servo 1, 135
    servo 2, 149
    pause 5000

    loopa:
    serin 4, n2400, (":Q"), b1, b2
    gosub servox
    gosub servoy
    sertxd ("servo position now: ",9,"x",#b1,44,9,"y",#b2,13,10)
    pause 200
    goto loopa

    servox:
    servopos 1,b1
    pause 175
    low 1
    return

    servoy:
    servopos 2,b2
    pause 175
    low 2
    return
    Hey Hamlet: 2b or not 2b = $FF

  8. #8
    Join Date
    May 2008
    Location
    WNC
    Posts
    413
    Images
    68
    Rep Power
    54

    Re: Autonomous Helicopter

    Cool project Elios. Very, aggressive ... I like that
    I trust you will keep sharing the progress!
    I reject your reality and inject my own.
    www.Trampbot.org

  9. #9
    Join Date
    Sep 2008
    Location
    Nelson, New Zealand
    Posts
    278
    Images
    9
    Rep Power
    39

    Re: Autonomous Helicopter

    lol, thanks Ooops. I spent most of yesterday trying to figure out eagle CAD. I think i have most of it down-pat, except for when it comes to printing the finished PCB, i cant get the track sizes and the vias correct. so ill continue to play with this today
    Last edited by elios; 07-07-2009 at 05:25 PM.
    Hey Hamlet: 2b or not 2b = $FF

  10. #10
    Join Date
    Jul 2008
    Location
    Belgium
    Posts
    633
    Images
    2
    Rep Power
    59

    Re: Autonomous Helicopter

    word of advice: print out your layout 1:1 when you're done and arrange your components on it to see if everything came out the way it should. Wouldn't be the first time the paper slid just the tiniest amount during printing causing a slight offset, but given a large enough board that might mean not being able to place that one vital component.

    Are you etching yourself? or making use of something like batchpcb?

    Might want to try gerber files for 1:1 output, although I've never had an issue with Eagle (been some time since I've used it though)
    Artificial Intelligence is no match for Natural Stupidity

    "For a list of all the ways technology has failed to improve life, press three" - Alice Kahn

    Resistance is futile! (if < 1)

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Interesting Sparkfun autonomous vehicle competition
    By jes1510 in forum Robotics General Discussion
    Replies: 0
    Last Post: 04-16-2009, 09:38 AM
  2. Contest Entry K-9 Autonomous Robot Pet
    By djsures in forum Project Showcase
    Replies: 31
    Last Post: 03-24-2009, 08:33 PM
  3. Contest Entry My Autonomous Cookie Monster (LOL)
    By djsures in forum Project Showcase
    Replies: 10
    Last Post: 11-26-2008, 08:45 PM
  4. Ideas for Autonomous Kondo Robots
    By Atom in forum Humanoids, Walkers & Crawlers
    Replies: 8
    Last Post: 08-23-2008, 07:45 PM
  5. Interesting Portable Autonomous Sentry demonstration
    By Matt in forum Robotics General Discussion
    Replies: 8
    Last Post: 07-08-2008, 02:02 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •