go_away

Author Topic: Programming $50 Robot  (Read 1118 times)

0 Members and 1 Guest are viewing this topic.

Offline cclifTopic starter

  • Beginner
  • *
  • Posts: 2
  • Helpful? 0
Programming $50 Robot
« on: November 06, 2011, 12:38:17 PM »
To start off, I've done searches and can't find exactly what I need to answer my question. Maybe I'm just stupid but hey, I tried!

I've built the "brain" of the $50 robot and I am ready to program it. I bought the AVRISP mkII and downloaded studio 5 since it was the newest version and was immediately lost upon starting the program, since it looks nothing like studio 4 (which is what is covered in the tutorial). I then decided to just download studio 4 and go with the tutorial, but it wouldn't connect to the robot. I have the two green lights on the mkII so I tried to search for that solution, and from what I understand, the newer mkII's don't play well with studio 4. THEN I thought id be a sneaky snake and just use ponyprog2000 to circumvent the entire problem, but that doesn't want to connect either.

So now I come to you with a slew of questions, but only one needs to be answered and I don't care which one. Just save my robochild.

Is there a way to apply the source files provided in the tutorial to studio 5? The biggest problem is the lack of a handy dandy sidebar where I can easily import the source and header files, but really the whole program is a mystery to me.

Is there some other way to use studio 4? Meaning, am I overlooking a simple fix to get it to connect to my robot? Again, I have two steady green lights but it will not connect and I can't Adjust the ISP frequency in "disconnected mode".

Or is there some easy way to make ponyprog work for me? I followed the steps for it in the tutorial and got the error message that was predicted but none of the troubleshooting steps that were provided were able to resolve the issue.

Offline cclifTopic starter

  • Beginner
  • *
  • Posts: 2
  • Helpful? 0
Re: Programming $50 Robot
« Reply #1 on: December 06, 2011, 11:09:51 AM »
bumpalumpadump

Offline newInRobotics

  • Supreme Robot
  • *****
  • Posts: 1,015
  • Helpful? 48
  • N.I.R.
Re: Programming $50 Robot
« Reply #2 on: December 06, 2011, 04:36:12 PM »
Hi fella  :)

Hopefully, this will be useful for You.

1. Create New Project in AVR Studio 5 using microcontroller name of Your choice.




2. Go to project location in Your computer.


3. Find includes folder and put all dependency (library) files into it.

4. Copy content of main file (the one that contains main function) to main (nameOfYOurProject.c) file of Your newly created project. It can be found in the same folder as includes and Debug directories.

5. Reload Studio 5 and reopen Your project.

6. Adjust top of the document (includes section) as required - putting all filenames found in includes folder used before.


7. Build Your project and hope for no error messages  ;D


8. Plug Your programmer to the robot and to the computer.

9. Hit AVR Programming button.


10. Select Tool, Device, Interface and hit Apply. Click Read (Device ID) and Read (Target Voltage). If You get Device ID and Voltage - Your setup is OK.


11. Go to Memories and put .hex file location into Flash field.


12. Hit Program.



Anyhow, it works every time. Hope it works for You too  ;)
"Computer games don't affect kids; I mean if Pac-Man affected us as kids, we'd all be running around in darkened rooms, munching magic pills and listening to repetitive electronic music." - Kristian W

 


Get Your Ad Here