[chbot] Chchrobotics Digest, Vol 22, Issue 14

Gary T grogyan at woosh.co.nz
Thu Jul 9 19:16:46 BST 2009


>
>Date: Thu, 9 Jul 2009 11:05:28 +1200
>From: Charles Manning <manningc2 at actrix.gen.nz>
>Subject: [chbot] ATMEL ICSP in-circuit programming ,    prop plug
>         programming redux
>To: Christchurch Robotics <chchrobotics at lists.linuxnut.co.nz>
>Message-ID: <200907091105.28761.manningc2 at actrix.gen.nz>
>Content-Type: text/plain;  charset="iso-8859-1"
>
>
>There are two ways to program the AVR (discounting the debug interfaces for
>now):
>
>* UART style as is done with Arduino. This needs a "bootloader" preprogrammed
>onto the AVR. This is just RS232-like and  will work with an unmodified
>prop-plug so  long as you get the pin outs right. It will also work with a
>regular RS232 serial port translation chip like a MAX232.
>
>* ISP mode. This works with a raw micro and does not need a boot loader.
>However this needs an extra control pin...
>
>UART style (Arduino) programming only need ground, RX, TX and a reset. ie 3
>signal pins
>
>ISP mode requires ground, reset, MOSI, MISO, Clock. ie 4 signal pins.
>
>ISP mode programming is easily achieved with the avrdude software which
>supports numerous different hardware configuration including:
>* parallel port:
>* serial port:
>* ftdi chip: (could probably modify a prop plug to do this).
>* USBTinyISP etc.
>and Google will find you more.
>
>I have used parallel programmers in the past and found them sometimes
>unreliable.
>
>I used simplified version of the  ponyser
>(http://core.st/projects/Serial_programmer/index.html) for a bit. That's fast
>enough on directly wired serial port but is far too slow for proper use on a
>USB to serial adapter.
>
>I now use a USBTinyISP V2 (we now have two in the family). This is a USB
>programmer that runs the USB protocol on an AVR chip and is very fast. I
>bought the kit from http://www.ladyada.net/make/usbtinyisp/ for around $US30
>including shipping but it is easy enough to make your own for around $20NZ.
>All the schematics and firmware is published and free to use.
>
>There are two versions of the USBTinyISP:
>* Version 1: http://www.ladyada.net/images/usbtinyisp/usbtinyisp.png 
>Handles a
>reduced voltage range, but simpler. You don't need all those connectors at
>the top of the schematic.
>* Version2: 
>http://www.ladyada.net/images/usbtinyisp/usbtinyisp2sch.png has an
>extra buffer chip to handle a wider voltage range.
>
>Hope that helps...
>
>Charles

Thanks for that Charles,
I'll double check the clock today at work, as I have access to a good 
oscilloscope here.  I can though see the debug LED flash when I 
depress the reset button, which makes me thing that there is a clock 
signal already there.

I programmed the bootloader ok, using the USBTiny, and my prop plug 
still is unable to program the 644p.

On the Sanguino board, the CTS line is shorted to ground, where as on 
the prop plug its left open and floating, would that be the cause of 
it not programming?
The prop plug uses the FT232RQ, just like hte USB to TTL cable, but 
just has less pins out.

I'll talk with the guys tonight at RoboNz to see if they can come up 
with any ideas.

Cheers



Gary T 




More information about the Chchrobotics mailing list