Author Topic: Can anyone deploy Axon code via USB from a Mac?  (Read 847 times)

0 Members and 1 Guest are viewing this topic.

Offline E.MkTopic starter

  • Jr. Member
  • **
  • Posts: 15
  • Helpful? 0
Can anyone deploy Axon code via USB from a Mac?
« on: November 26, 2010, 02:21:56 PM »
Hey all,

This is a more of an open question.  I have been able to write code, compile, and download to the Axon on Windows(32 bit XPmode) and linux(32 bit Ubuntu) successfully but not much luck on the Mac OS X.

I've scoured the internet as well as the forum and the set up tutorials and I really have one question;

Anyone doing any development for the Axon software on a Mac, how do you download the code onto the Axon?  Do you use an external programmer (ISP MKII is one I read the Admin mentioned on one of the tutorial pages) or via the USB (CP2102 chip)?

If you can get it download the code via USB, how were you able to get it set up?

I personally get stuck with the  tty.SiLab_USBtoUART driver stuck on 9600 baud and can't seem to change the baud rate, preventing me from a successful download.

Thanks in advance!

Offline Crunchy Theory

  • Full Member
  • ***
  • Posts: 80
  • Helpful? 0
  • "Well great is ok, but amazing would be great."
Re: Can anyone deploy Axon code via USB from a Mac?
« Reply #1 on: December 01, 2010, 12:49:45 PM »
This thread might be helpful: http://www.societyofrobots.com/robotforum/index.php?topic=8714.0
Particularly this link within: http://tinkerlog.com/2007/09/29/programming-avr-with-a-macbook/

I have been using the USBtinyISP programmer from ladyada.net and avrdude in Terminal to load the programs onto my $50 robot. Since the Axon and the $50 robot both use Atmel AVR chips, I would think you can do it the same way but you might be overwriting the bootloader that's already on the Axon by default.

Right now I'm trying to add in UART and the bootloader to my $50 robot, so I will have to switch to the SILabs chip and USB to program directly. But as I am running into problems myself, this is also of interest to me :)
The only way to top an upright screen, keyboard, and mouse is to eliminate the need for humans to touch a PC at all. Oh, hello there Mr. Robot... what would I like you to do, you ask?

Offline E.MkTopic starter

  • Jr. Member
  • **
  • Posts: 15
  • Helpful? 0
Re: Can anyone deploy Axon code via USB from a Mac?
« Reply #2 on: December 01, 2010, 01:51:01 PM »
This thread might be helpful: http://www.societyofrobots.com/robotforum/index.php?topic=8714.0
Particularly this link within: http://tinkerlog.com/2007/09/29/programming-avr-with-a-macbook/

I have been using the USBtinyISP programmer from ladyada.net and avrdude in Terminal to load the programs onto my $50 robot. Since the Axon and the $50 robot both use Atmel AVR chips, I would think you can do it the same way but you might be overwriting the bootloader that's already on the Axon by default.

Right now I'm trying to add in UART and the bootloader to my $50 robot, so I will have to switch to the SILabs chip and USB to program directly. But as I am running into problems myself, this is also of interest to me :)



I've read about LadyAda and the USBtinyISP programmer.  I was a little confused(first Mac user) - on my windows/linux machines, I can just set the baud rate, connect the Axon to the USB port and use the bootloader to download the code.  On the Mac, it seems closed.  I've installed Ubuntu under virtual box and I'm able to use the linux method(stty) to set the baud rate but that command seems to not do anything in Mac.

I figured maybe there's a trick with the Mac OS that I'm not familiar with.

Based on your experience, how are you finding the USBtinyISP?  Is it worth it to have when your main(only) device is the Axon?

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,660
  • Helpful? 169
    • Society of Robots
Re: Can anyone deploy Axon code via USB from a Mac?
« Reply #3 on: December 01, 2010, 02:04:29 PM »
Using an ISP programmer will overwrite the bootloader, but its not a big deal as an ISP programmer can program the bootloader back onto the Axon.

The Axon bootloader has an auto-baud feature, so it'll generally work no matter the baud you send the .hex at.

Offline Crunchy Theory

  • Full Member
  • ***
  • Posts: 80
  • Helpful? 0
  • "Well great is ok, but amazing would be great."
Re: Can anyone deploy Axon code via USB from a Mac?
« Reply #4 on: December 01, 2010, 02:30:52 PM »
This thread might be helpful: http://www.societyofrobots.com/robotforum/index.php?topic=8714.0
Particularly this link within: http://tinkerlog.com/2007/09/29/programming-avr-with-a-macbook/

I have been using the USBtinyISP programmer from ladyada.net and avrdude in Terminal to load the programs onto my $50 robot. Since the Axon and the $50 robot both use Atmel AVR chips, I would think you can do it the same way but you might be overwriting the bootloader that's already on the Axon by default.

Right now I'm trying to add in UART and the bootloader to my $50 robot, so I will have to switch to the SILabs chip and USB to program directly. But as I am running into problems myself, this is also of interest to me :)



I've read about LadyAda and the USBtinyISP programmer.  I was a little confused(first Mac user) - on my windows/linux machines, I can just set the baud rate, connect the Axon to the USB port and use the bootloader to download the code.  On the Mac, it seems closed.  I've installed Ubuntu under virtual box and I'm able to use the linux method(stty) to set the baud rate but that command seems to not do anything in Mac.

I figured maybe there's a trick with the Mac OS that I'm not familiar with.

Based on your experience, how are you finding the USBtinyISP?  Is it worth it to have when your main(only) device is the Axon?


The USBtinyISP works fine. Pretty quick, though the $50 robot program is relatively small I think. A bootloader is nice to have if you didn't feel like spending the money on a programmer. But I had to get one for the $50 robot in order to actually put a bootloader on it. You might want to just get the programmer anyway so that you have a backup in case there is a problem with the bootloader.

It's pretty obvious on the site, but I though I should mention that the programmer is a kit that you have to build yourself. The fact that they explicitly state that it works for OS X is what sold me, though. Didn't have any problems putting it together and getting it to work, but I guess it would have sucked if I had run into problems with that part of it.

You would still have to sort out your UART issues if you want to receive information from the robot on your PC. But from what Admin said, it sounds like it'll work even at the 9600 baudrate. Might be kind of slow though...
« Last Edit: December 01, 2010, 02:34:16 PM by Crunchy Theory »
The only way to top an upright screen, keyboard, and mouse is to eliminate the need for humans to touch a PC at all. Oh, hello there Mr. Robot... what would I like you to do, you ask?

Offline E.MkTopic starter

  • Jr. Member
  • **
  • Posts: 15
  • Helpful? 0
Re: Can anyone deploy Axon code via USB from a Mac?
« Reply #5 on: December 01, 2010, 02:40:43 PM »
Using an ISP programmer will overwrite the bootloader, but its not a big deal as an ISP programmer can program the bootloader back onto the Axon.

The Axon bootloader has an auto-baud feature, so it'll generally work no matter the baud you send the .hex at.

... you know, I read that in the pages under Axon... but I disregarded it.  In linux, it seemed like I had to set it to 115200.  When I used the Mac bootloader, I get an error message that read something like,  did not get complete signal from device or something(sorry, I don't have the Axon on me right now to get the exact message).

Assumed this was a baud mismatch issue.

Offline Crunchy Theory

  • Full Member
  • ***
  • Posts: 80
  • Helpful? 0
  • "Well great is ok, but amazing would be great."
Re: Can anyone deploy Axon code via USB from a Mac?
« Reply #6 on: December 01, 2010, 03:49:39 PM »
I realized a little while ago that I wasn't sure if I could use Terminal to talk to the board. So I did some digging and found ZTerm: http://homepage.mac.com/dalverson/zterm/

I'll have to give it a try when I get my UART-to-USB breakout board. But since you already have an Axon, you might look into this if you don't already have a way to talk to it.

Or let me know if Terminal works, that would be cool too!
The only way to top an upright screen, keyboard, and mouse is to eliminate the need for humans to touch a PC at all. Oh, hello there Mr. Robot... what would I like you to do, you ask?

Offline E.MkTopic starter

  • Jr. Member
  • **
  • Posts: 15
  • Helpful? 0
Re: Can anyone deploy Axon code via USB from a Mac?
« Reply #7 on: December 01, 2010, 04:06:44 PM »
I realized a little while ago that I wasn't sure if I could use Terminal to talk to the board. So I did some digging and found ZTerm: http://homepage.mac.com/dalverson/zterm/

I'll have to give it a try when I get my UART-to-USB breakout board. But since you already have an Axon, you might look into this if you don't already have a way to talk to it.

Or let me know if Terminal works, that would be cool too!


I had downloaded(and removed) ZTerm.  Not that it wasn't good, it was just that I couldn't get the bootloader to successfully send the .hex file to the Axon via USB on Mac OS X.

In linux(Ubunutu), I used minicom as the terminal app to connect to Axon and it worked enough.  There is a build of minicom for the Mac OS X available, so I used that and it worked fine.

At this rate, because I don't have an ISP programmer, I load up Ubuntu in VirtualBox in my Mac and do all my Axon-related development there.  And since in Ubuntu, I can use stty + Mac bootloader to push .hex file to the Axon, I'm doing that.  Although, if there was a Mac OS X native way to do this, it'd be great...

 


Get Your Ad Here

data_list