Re: timeouts on USB ISP programmer

From: Tomek CEDRO <tomek_at_cedro.info>
Date: Mon, 11 Apr 2022 15:51:02 UTC
On Mon, Apr 11, 2022 at 7:35 AM Axel Rau <Axel.Rau@chaos1.de> wrote:
> root@home2l:~ # cat ~/.avrduderc
> default_programmer = "diamex-avr-usb";
> programmer
>  id    = "diamex-avr-usb";
>  desc  = "Diamex AVR USB Programmer";
>  type  =  "stk500v2";
>  connection_type = usb;
>  usbvid     = 0x16c0;
>  usbpid     = 0x2a9b;
> ;
>
> root@home2l:~ # avrdude -p t85 -vvv -t
>
> avrdude: Version 6.4
>          Copyright (c) Brian Dean, http://www.bdmicro.com/
>          Copyright (c) Joerg Wunsch
>
>          System wide configuration file is "/usr/local/etc/avrdude.conf"
>          User configuration file is "/root/.avrduderc"
>
>          Using Port                    : usb
>          Using Programmer              : diamex-avr-usb
> avrdude: usbdev_open(): did not find any USB device "usb" (0x03eb:0x2104)

Wow, this is strange, the programmer is clearly defined with different
VID:PID than avrdude expects :-(

Maybe try full call:

avrdude -c diamex-avr-usb -P usb:/dev/cuaU0 -p t85 -vvv -t

or

avrdude -c stk500v2 -P usb:/dev/cuaU0 -p t85 -vvv -t

or

avrdude -c avrispmkII -P usb:/dev/cuaU0 -p t85 -vvv -t


If that does not work I am out of ideas, sorry, maybe opening an Issue
on the project github repo could help?

Are you sure that diamex-avr-usb is not defined anywhere else (for
instance in /usr/local/etc/avrdude.conf)? We are missing some small
important detail here :-P

What I did at some point was building avrdude port WITH_DEBUG=1 flag
to make, then it is possible to debug it, setting breakpoint at
`usbdev_open` helped me understand -P handling.. maybe that would also
help finding the issue here :-)

-- 
CeDeROM, SQ7MHZ, http://www.tomek.cedro.info