patchAVR Downloader/UploaDEr - Patches: patch #9254, Adds support for selecting USB...

 
 

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

patch #9254: Adds support for selecting USB devices to USBasp

Submitter:  Jon Thacker <jthacker>
Submitted:  Thu 09 Feb 2017 04:49:47 PM UTC
   
 
Category:  None Priority:  5 - Normal
Status:  Need Info Privacy:  Public
Assigned to:  None Open/Closed:  Open

Thu 18 Jan 2018 10:53:09 PM UTC, comment #1: 

Somehow, it doesn't seem to work for me.

The USBasp can be found (no target connected, thus fails):


./avrdude -C avrdude.conf -p m16 -c usbasp -P usb

avrdude: error: usbasp_transmit: Unknown error
avrdude: error: usbasp_transmit: Unknown error
avrdude: warning: cannot set sck period. please check for usbasp firmware update.
avrdude: error: usbasp_transmit: Unknown error
avrdude: error: program enable: target doesn't answer. 1
avrdude: initialization failed, rc=-1
         Double check connections and try again, or use -F to override
         this check.


avrdude done.  Thank you.


However, when passing -P usb:xxx as suggested, I do not get
a list of devices but just:


./avrdude -C avrdude.conf -p m16 -c usbasp -P usb:xxx
avrdude: Error: Invalid -P value: 'usb:xxx'
         Use -P usb:bus:device

avrdude done.  Thank you.


Nonsensical :bus:dev values are not rejected but cause a
stupid error message:


./avrdude -C avrdude.conf -p m16 -c usbasp -P usb:foo:bar
avrdude: error: could not find USB device with vid=0x16c0 pid=0x5dc vendor='www.fischl.de' product='USBasp'

avrdude done.  Thank you.


If there is no USBasp connected, it dumps core:


Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 802806400 (LWP 100762/avrdude)]
0x0000000801acc7a0 in strcasecmp_l () from /lib/libc.so.7
(gdb) up
#1  0x0000000000419bcd in usbasp_open (pgm=0x80286d000, port=<value optimized out>) at usbasp.c:604
604           if(strcasecmp(port, "nibobee") == 0) {
Current language:  auto; currently minimal


Joerg Wunsch <joerg_wunsch>
Group administrator
Thu 09 Feb 2017 04:49:47 PM UTC, original submission:  

The documentation for USBasp indicates that it supports -p usb:bus:dev
style USB device selection, however this is not actually supported. This
commit adds support for this in the same style as USBTiny.
If a dev is not included (e.g. -p usb:xxx), then it will print all the
devices that match one of the vendor and product IDs supported by the
USBasp protocol.

Jon Thacker <jthacker>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attached Files
file #39719:  0001-Adds-support-for-selecting-USB-devices-to-USBasp.patch added by jthacker (9KiB - application/octet-stream - Updating patch to handle empty bus-id and dev-id under libusb 1.0)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by joerg_wunsch (Posted a comment)
  • -email is unavailable- added by jthacker (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

     

    Follow 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2018-01-18 joerg_wunsch StatusNone Need Info
    2017-02-10 jthacker Attached File- Added 0001-Adds-support-for-selecting-USB-devices-to-USBasp.patch, #39719
    2017-02-09 jthacker Attached File- Added 0001-Adds-support-for-selecting-USB-devices-to-USBasp.patch, #39712

    Back to the top

    Powered by Savane 3.13-4448.
    Corresponding source code