patchAVR Downloader/UploaDEr - Patches: patch #7729, Updated support for FTDI-232H

 
 

You are not allowed to post comments on this tracker with your current authentification level.

patch #7729: Updated support for FTDI-232H

Submitted by:  Jason Hecker <roklobster>
Submitted on:  Fri 24 Feb 2012 02:13:17 PM UTC  
 
Category: NonePriority: 5 - Normal
Status: NonePrivacy: Public
Assigned to: Hannes Weisbach <hweisbach>Open/Closed: Open

Wed 25 Sep 2013 11:10:43 AM UTC, comment #3:

So, I've looked over the patch in detail (finally, sorry for the delay).
I'm not convinced on the merits of the patch. As you've stated, the increased speed does not matter much for AVRs. On the finer frequency resolution I would argue, that
a) you still have only 0xffff distinct frequencies to choose from
b) this was (in my opinion) never a problem in the first place.
Let me elaborate: If I program an AVR part, I choose my SPI frequency fairly arbitrarily and rather conservatively, Let's say 100kHz. Whether I can choose 101.6949kHz (12MHz) or 100.3344kHz (for the 60MHz version) does not matter to me at all (the question is, if this applies to all/the majority of AVRdude users).
In contrast to that feature is the increased code complexity and maintenance (Think a new FTDI device). Essentially, it would be necessary (more or less) to copy the switch-statement from avrftdi_open() (handling the different device types) into set_frequency(). I think that is a bad idea. I could live with having set_frequency() called after the switch and the maximum frequency be passed in as a parameter, determined within said switch-statement. This still leaves the command to switch off the divisior - I'm not sure how to handle this in a "good" way, although one could always hope that FTDI builds new devices backwards-compatible (as they already did).

Other opinions/comments/suggestions/arguments?

Programmer declarations for UM232H and C232H are included in r1248.

Hannes Weisbach <hweisbach>
Project MemberIn charge of this item.
Sat 25 Feb 2012 01:21:33 PM UTC, comment #2:

You are right. I used pin 5 for some reason. I have corrected this and changed it all to pin 4 and tested it. New patch below.

(file #25162)

Jason Hecker <roklobster>
Fri 24 Feb 2012 08:40:32 PM UTC, comment #1:

Hi,

I had a quick look and it looks fine to me. I have just one question. You changed:
if (pgm->pinno[PIN_AVR_RESET] < 4 || pgm->pinno[PIN_AVR_RESET] == 0) {
to:
if (pgm->pinno[PIN_AVR_RESET] < 5 || pgm->pinno[PIN_AVR_RESET] == 0) {
and I don't understand why. Using pin 4 (TMS/CS) as reset-pin is a valid choice and indeed the default. Four lines below pgm->pinno[PIN_AVR_RESET] actually gets set to 4.

Cheers,
Hannes

Hannes Weisbach <hweisbach>
Project MemberIn charge of this item.
Fri 24 Feb 2012 02:13:17 PM UTC, original submission:

I was having some problems with certain .hex files not being verified correctly in my old 5.11-patch7610 of AVRDUDE.

I have since checked out SVN1068 and applied patch #7610 making the necessary changes so that it compiled.

The new binary now verifies the problematic hex files correctly.

This patch adds support for the FTDI-232H part which will be properly available in the upcoming libftdi-0.20. In addition it enables the 30MHz clock in the FTDI chip for all H suffix components. This will obviously allow SPI rates up to 30MHz (as opposed to the default 6MHz) - not that any AVR can do that. It effectively adds some finer frequency granularity for use with the AVR.

I have built the binary using MinGW and the headers and libs from http://code.google.com/p/picusb/downloads/detail?name=libftdi_0.19git_devkit_mingw32_27August2011.zip

It's only been tested on Win7-64 bit with libusb-win32 1.2.5.0.

I have also added a new definition for the C232HM MPSSE cable from FTDI though it's just a copy of the UM232H.

I'll update my site helix.air.net.au with the new Windows binary too.

Jason Hecker <roklobster>

 

Attached Files
file #25155:  avrdude-fdi232h.patch added by roklobster (9kB - text/x-patch)

 

Depends on the following items: None found

Digest:
   patch dependencies.

 

Carbon-Copy List
  • -unavailable- added by joerg_wunsch (Updated the item)
  • -unavailable- added by hweisbach (Posted a comment)
  • -unavailable- added by roklobster (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 4 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Fri 13 Sep 2013 02:45:58 PM UTCjoerg_wunschAssigned toNone=>hweisbach
    Thu 01 Nov 2012 08:52:39 AM UTCrliebscherDependencies-=>patch #7610 is dependent
    Sat 25 Feb 2012 01:21:33 PM UTCroklobsterAttached File-=>Added avrdude-fdi232h_1.patch, #25162
    Fri 24 Feb 2012 02:13:17 PM UTCroklobsterAttached File-=>Added avrdude-fdi232h.patch, #25155

    Back to the top


    Powered by Savane 3.1-cleanup