go_away

Author Topic: $50 robot programming question  (Read 2425 times)

0 Members and 1 Guest are viewing this topic.

Offline Elias1001Topic starter

  • Beginner
  • *
  • Posts: 5
  • Helpful? 0
$50 robot programming question
« on: January 10, 2009, 01:48:02 PM »
I'm at the programming stage of the $50 robot. Should I program the robot by uploading the complied photovore hex file first? or should I first upload the hex file for setting the servo to 0 and modify the servo before the photovote file? or does it matter what order it is done in?

Also, how to I download the hex file for setting the servo to 0? I click on the link http://www.societyofrobots.com/downloads/hold_servo.hex and it gives me the hex code, but I don't know how to turn it into a format that AVR studio will understand. Someone asked the same question here http://www.societyofrobots.com/robotforum/index.php?topic=2499.0 but the thread just went extremely off topic and it wasn't really answered satisfactorially.

Edit:
Would I just be able to right click on the hex code here, http://www.societyofrobots.com/downloads/hold_servo.hex and click save page as, then change the file type to all files, and then change it to a hex file by changing the name of the file to hold_servo.hex?
« Last Edit: January 10, 2009, 02:18:03 PM by Elias1001 »

Offline frodo

  • Supreme Robot
  • *****
  • Posts: 329
  • Helpful? 2
  • BOW DOWN TO MY MIGHTY STARE!!
Re: $50 robot programming question
« Reply #1 on: January 10, 2009, 02:08:26 PM »
hi, i don't think it matters what order you download them in but i think you have to set the servos and modify them first before doing the photovore programming. this should work in theory. lol
OMG!!!! I AM SUPREME ROBOT!!!

Check out my Web

Offline Webbot

  • Expert Roboticist
  • Supreme Robot
  • *****
  • Posts: 2,152
  • Helpful? 110
Re: $50 robot programming question
« Reply #2 on: January 10, 2009, 07:02:04 PM »
In AVR studio:
clicon on the black box icon that says 'AVR' to pop up a new dialog
If it asks you to 'Select AVR programmer'  then click AVRispMKII in the left box and USB in the right hand Port box.
In the main download box you should see 3 sections: Flash, EEPROM and ELF.
In the Flash area it says 'Input HEX file' followed by a text box followed by a '...' button.
Click on '...' to browse and select the 'hold-a-servo.hex' file
Then click on Program


Its worth centering your servos first before using photovore. If your servos are centered then the photovore program will do SOMETHING-but not what you might expect.
Webbot Home: http://webbot.org.uk/
WebbotLib online docs: http://webbot.org.uk/WebbotLibDocs
If your in the neighbourhood: http://www.hovinghamspa.co.uk

Offline tristantech

  • Jr. Member
  • **
  • Posts: 34
  • Helpful? 0
Re: $50 robot programming question
« Reply #3 on: January 10, 2009, 10:46:23 PM »
Quote
http://www.societyofrobots.com/downloads/hold_servo.hex and it gives me the hex code, but I don't know how to turn it into a format that AVR studio will understand.


.hex files are compiled programs. They can't be easily turned back in to source code.
Hey! Visit my website @ http://www.tristantech.net

Offline Jdog

  • Robot Overlord
  • ****
  • Posts: 259
  • Helpful? 3
Re: $50 robot programming question
« Reply #4 on: January 11, 2009, 12:14:09 PM »
I recommend uploading the center servo code to the mcu first and modding your servos before you upload the photovore code so that when you do use the photovore code, everything will work right.

If you are using Ponyprog, you can copy and paste all the text in the page he gives you and put it in notepad. Then save the file as center_servo.hex, but make sure when you save the file, right below where you type in the name it says all files, not .txt.

Offline Elias1001Topic starter

  • Beginner
  • *
  • Posts: 5
  • Helpful? 0
Re: $50 robot programming question
« Reply #5 on: January 15, 2009, 02:18:52 PM »
I recommend uploading the center servo code to the mcu first and modding your servos before you upload the photovore code so that when you do use the photovore code, everything will work right.

If you are using Ponyprog, you can copy and paste all the text in the page he gives you and put it in notepad. Then save the file as center_servo.hex, but make sure when you save the file, right below where you type in the name it says all files, not .txt.

Thank you Jdog, that answered my question.

Offline fuzzyt

  • Jr. Member
  • **
  • Posts: 34
  • Helpful? 0
Re: $50 robot programming question
« Reply #6 on: January 15, 2009, 04:54:10 PM »
To download the hex files, simply right click and select "Save Taget as..."

Offline omar

  • Beginner
  • *
  • Posts: 4
  • Helpful? 0
Re: $50 robot programming question
« Reply #7 on: August 30, 2009, 03:09:05 AM »
Hello, i wanna know how can i get a code for a project, i wanna make like the accelerometer which serves the servo motor, i have the sensor which i bought from Dimension Engineering , i have the hardware, but i don't know how to connect them and how to write a code to program the pic microcontroller.
help me please  :-\

Offline Jdog

  • Robot Overlord
  • ****
  • Posts: 259
  • Helpful? 3
Re: $50 robot programming question
« Reply #8 on: September 08, 2009, 03:00:47 PM »
Make a new topic.

 


Get Your Ad Here