avrdude-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avrdude-dev] Adding support for ATmega32C1 in avrdude.conf


From: Joerg Wunsch
Subject: Re: [avrdude-dev] Adding support for ATmega32C1 in avrdude.conf
Date: Tue, 15 Jan 2013 19:47:28 +0100
User-agent: Mutt/1.5.20 (2009-06-14)

As Stuart Cording wrote:

> I am trying to add support for the ATmgea32C1 in avrdude.conf. My key aim
> is to support this MCU (and some others later) to be programmed using the
> Arduino IDE.

Well, the Arduino still uses the ancient STK500v1 protocol.  The
parametrization in this protocol was primarily handled by a device
code, the "stk500_devcode" in avrdude.conf.

As Atmel switched to the V2 protocol many years ago, these devcodes
have never been extended for newer devices then.  You'd have to ask the
Arduino folks what they'd like to see as the device code for a newer
device.  I've got no idea how these device codes are being evaluated
within their programmer firmware.  The V2 protocol switched to a run-time
parametrization by passing several values down to the programmer as part
of the initialization sequence, which is obviously way more flexible.

I guess your best bet is to re-use a devcode from a similar device,
perhaps the 0x90 from the ATmega32?

> It isn't clear to me how to correctly add a new entry for an MCU that was
> never supported by the STK500 and for which I can't find any "XML" files in
> the Atmel Studio 6 install.

Well, the XML files are there, but they don't list prehistoric
STK500v1 devcodes.  They do list the STK500v2 parameters (which are
also used for other tools, like the AVRISPmkII, or the various JTAG
ICEs in ISP mode) though:

        <property-group name="ISP_INTERFACE">
          <property name="IspEnterProgMode_timeout" value="200"/>
          <property name="IspEnterProgMode_stabDelay" value="100"/>
          <property name="IspEnterProgMode_cmdexeDelay" value="25"/>
          <property name="IspEnterProgMode_synchLoops" value="32"/>
          <property name="IspEnterProgMode_byteDelay" value="0"/>
          <property name="IspEnterProgMode_pollIndex" value="3"/>
          <property name="IspEnterProgMode_pollValue" value="0x53"/>
          <property name="IspLeaveProgMode_preDelay" value="1"/>
          <property name="IspLeaveProgMode_postDelay" value="1"/>
          <property name="IspChipErase_eraseDelay" value="45"/>
          <property name="IspChipErase_pollMethod" value="1"/>
...

It's just we have to write some XSLT stylesheet to extract these data,
and convert them to an avrdude.conf snippet.

> b) Check my new entry in the avrdude.conf to tell me if it is correct?

Well, just post it.  Or, even better, file it into a patch tracker.

-- 
cheers, J"org               .-.-.   --... ...--   -.. .  DL8DTL

http://www.sax.de/~joerg/                        NIC: JW11-RIPE
Never trust an operating system you don't have sources for. ;-)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]