Problems with abcminiuser's XPLAINBridge...

Go To Last Post
37 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi all,

So I just tried installing the XPLAINBridge mentioned https://www.avrfreaks.net/index.php?name=PNphpBB2&file=viewtopic&t=87393 and http://fourwalledcubicle.com/blog/archives/508

It compiled fine and I used a JTAG-MKII to program the flash with the hex file:

avrdude -p usb1287 -c jtag2 -P usb -e -U \ flash:w:XPLAINBridge.hex

And this step went fine. I disconnected the MKII and cycled the XPLAIN power. lsusb shows this (regardless if TCK is shorted to ground or not):

Bus 002 Device 036: ID 03eb:204b Atmel Corp.

In windows it shows up as the "Dean Camera LUDA XPLAIN Bridge" so I think the flash worked correctly? But it never shows up as an ISP-MKII clone like the blog mentions it should. It seems like I half working version.

The worst part is... JTAG no longer works so I can't even flash over the backup I made.

Any ideas as what I should try next?

Thanks,
Sam

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Shoot... I was shorting out the wrong pin. Still, is there a way to get JTAG back?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

As part of the initialization code, the XPLAINBridge firmware locks out JTAG so that the pin on the header can be read to see if the mode pin is currently high or low.

You can however override this by holding the /RESET line of the header low when entering JTAG mode, which will prevent the firmware from disabling the interface. I haven't got a clue how to achieve that with avrdude, but AVRStudio will prompt automatically once the first attempt to enter JTAG mode fails.

I'll alter the code to re-enable the JTAG interface once the pin's value has been read, since it could be useful for my own debugging.

- Dean :twisted:

Make Atmel Studio better with my free extensions. Open source and feedback welcome!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi Dean,

I'm also use ure LUFA XPlainBridge.
The XPlain Board is connected as AVR ispmkII.

But if I use avrdude with the following command line:
avrdude -p atxmega128a1 -P usb -c avrispv2 -U flash:w:ATxmega128A1.hex

I'll get the following error message:
avrdude: stk500v2_recv_mk2: error in USB receive

My OS is Windows XP Home, SP3
and avrdude:
avrdude: Version 5.6, compiled on Mar 5 2009 at 09:59:30
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/

System wide configuration file is "C:\WinAVR-20090313\bin\avrdude.conf"

Do you have any idea, what I did wrong?

Thank you and best regards,
sebastian

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Try upgrading your AVRDude version, since that one is quite old. AVRDude had some show-stopper bugs in its PDI programming implementation until the most recent version, which prevented proper programming.

- Dean :twisted:

Make Atmel Studio better with my free extensions. Open source and feedback welcome!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thanks Dean,

Very useful.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:

I'm also use ure LUFA XPlainBridge.
The XPlain Board is connected as AVR ispmkII.

But if I use avrdude with the following command line:
avrdude -p atxmega128a1 -P usb -c avrispv2 -U flash:w:ATxmega128A1.hex

I'll get the following error message:
avrdude: stk500v2_recv_mk2: error in USB receive

I have the same the problem,
My OS is Windows XP Pro, SP3
WinAVR-20100110 (final version)
avrdude: Version 5.10

EDIT:
The original AVRISPmkII (Atmel) works fine with AVRDUDE 5.10 (PDI)

Any ideas as what I should try next?

Thanks
Martin

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Martin,

Would love to help, but I can't get avrdude to work on my Windows installations - XP or Win7. No matter what I do, it always indicates that 'usbdev_open(): did not find any USB device "usb"'. Did you do anything special to get avrdude to connect to your USB tools under Windows?

For what it's worth, it works find under AVRStudio (Windows) and avrdude 9.10 (Linux) on my test machines. Are you using the latest XPLAINBridge firmware?

- Dean :twisted:

Make Atmel Studio better with my free extensions. Open source and feedback welcome!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi Dean,
thank you very much for your excellent project and for your help.

abcminiuser wrote:

Would love to help, but I can't get avrdude to work on my Windows installations - XP or Win7. No matter what I do, it always indicates that 'usbdev_open(): did not find any USB device "usb"'. Did you do anything special to get avrdude to connect to your USB tools under Windows?

I use WinAVR + Notepad + AVRDUDE, I not use AVRStudio.

If I want to install the original AVRISPmkII in Windows to work with WinAVR (without AVRStudio) then I install the driver that is included in WinaAVR.
...\WinAVR-20100110\utils\libusb\bin --> avrisp2.inf

If I have AVRStudio and WinAVR and I want to use the AVRISPmkII in AVRStudio AND in WinAVR then:

I install the driver that inlcudes in AVRStudio (Jungo-driver) and then you must install the LibUsb-win32 filter
(you must be careful in Win7, you must install the LibUsb-win32 filter in compatibility with WinXP SP2)
and then you can use the AVRISPmkII from AVRDUDE.

--> Do you understand me ?

abcminiuser wrote:

Are you using the latest XPLAINBridge firmware?

Yes, I use the latest firmware LUFA 100219

Grettings from Colombia!
Thank you
Martin

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:

but I can't get avrdude to work on my Windows installations - XP or Win7.

Dean, did you get your WinAVR20100110 between 10th and 20th of January. One of the errors that was later corrected (but without change of version number) is that the avrdude was not compiled against libusb. If you redownload it your avrdude should change from 5.8 to 5.10 and the USB stuff should work.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:

One of the errors that was later corrected (but without change of version number) is that the avrdude was not compiled against libusb.

Yes, but the error message from AVRDUDE was:

avrdude was compiled without usb support.
avrdude.EXE: ser_send(): write error: sorry no info avail

and not:
'usbdev_open(): did not find any USB device "usb"

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Yes, I've got the corrected WinAVR revision, with AVRDude 5.10. My problem is the filter driver (which I forgot to install) under Windows, will give it a go this afternoon.

- Dean :twisted:

Make Atmel Studio better with my free extensions. Open source and feedback welcome!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hmm. I've got the filter driver installed, but avrdude still won't connect.

Can you run "avrdude -P usb -c avrispmkii -p atxmega128a1 -vvvv" for me, and post the resulting output please?

- Dean :twisted:

Make Atmel Studio better with my free extensions. Open source and feedback welcome!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:

Yes, but the error message from AVRDUDE was

Your error might have been but I was talking to Dean which is why I started the post with "Dean,.."

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

so, with -vvvv :

avrdude -p atxmega128a1 -P usb -c avrispv2  -vvv  -U flash:w:../Hexfiles/test1.hex 

avrdude: Version 5.10, compiled on Jan 19 2010 at 10:45:23
         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
         Copyright (c) 2007-2009 Joerg Wunsch

         System wide configuration file is "C:\Program Files\WinAVR-20100110\bin\avrdude.conf"

         Using Port                    : usb
         Using Programmer              : avrispv2
avrdude: usbdev_open(): Found LUFA AVRISP MkII Clone, serno: 0000A00128255
avrdude: usbdev_open(): using read endpoint 0x82
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive
avrdude: usbdev_recv_frame(): usb_bulk_read(): usb_reap: timeout error
avrdude: stk500v2_recv_mk2: error in USB receive

Martin

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

and the Original AVRISPmkII with -vvv here:

avrdude -p atxmega128a1 -P usb -c avrispv2  -vvv  -U flash:w:../Hexfiles/test1.hex 

avrdude: Version 5.10, compiled on Jan 19 2010 at 10:45:23
         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
         Copyright (c) 2007-2009 Joerg Wunsch

         System wide configuration file is "C:\Program Files\WinAVR-20100110\bin\avrdude.conf"

         Using Port                    : usb
         Using Programmer              : avrispv2
avrdude: usbdev_open(): Found AVRISP mkII, serno: 000200021891
avrdude: usbdev_open(): using read endpoint 0x82
avrdude: stk500v2_getsync(): found AVRISP mkII programmer
         AVR Part                      : ATXMEGA128A1
         Chip Erase delay              : 0 us
         PAGEL                         : P00
         BS2                           : P00
         RESET disposition             : dedicated
         RETRY pulse                   : SCK
         serial program mode           : yes
         parallel program mode         : yes
         Timeout                       : 0
         StabDelay                     : 0
         CmdexeDelay                   : 0
         SyncLoops                     : 0
         ByteDelay                     : 0
         PollIndex                     : 0
         PollValue                     : 0x00
         Memory Detail                 :

                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           eeprom         0     0     0    0 no       2048   32      0     0     0 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           application    0     0     0    0 no     131072  256      0     0     0 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           apptable       0     0     0    0 no       8192  256      0     0     0 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           boot           0     0     0    0 no       8192  256      0     0     0 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           flash          0     0     0    0 no     139264  256      0     0     0 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           prodsig        0     0     0    0 no        512  256      0     0     0 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           usersig        0     0     0    0 no        512  256      0     0     0 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           fuse0          0     0     0    0 no          1    0      0     0     0 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           fuse1          0     0     0    0 no          1    0      0     0     0 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           fuse2          0     0     0    0 no          1    0      0     0     0 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           fuse4          0     0     0    0 no          1    0      0     0     0 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           fuse5          0     0     0    0 no          1    0      0     0     0 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           lock           0     0     0    0 no          1    0      0     0     0 0x00 0x00

         Programmer Type : STK500V2
         Description     : Atmel AVR ISP V2
         Programmer Model: AVRISP mkII
         Hardware Version: 1
         Firmware Version Master : 1.13
         Vtarget         : 3.3 V
         SCK period      : 8.00 us

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.01s

avrdude: Device signature = 0x1e974c
avrdude: NOTE: FLASH memory has been specified, an erase cycle will be performed
         To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: reading input file "../Hexfiles/test1.hex"
avrdude: input file ../Hexfiles/test1.hex auto detected as Intel Hex
avrdude: writing flash (1576 bytes):

Writing | ################################################## | 100% 0.12s

avrdude: 1576 bytes of flash written
avrdude: verifying flash memory against ../Hexfiles/test1.hex:
avrdude: load data flash data from input file ../Hexfiles/test1.hex:
avrdude: input file ../Hexfiles/test1.hex auto detected as Intel Hex
avrdude: input file ../Hexfiles/test1.hex contains 1576 bytes
avrdude: reading on-chip flash data:

Reading | ################################################## | 100% 0.08s

avrdude: verifying ...
avrdude: 1576 bytes of flash verified

avrdude done.  Thank you.

Martin

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Well, unfortunately the extended logs don't tell me anything other than the XPLAIN isn't responding at all -- or at least, libusb under Windows doesn't think it is. I'm not sure what's going on and I can't begin to debug it until I can get everything working under Windows myself.

I've installed the AVRStudio drivers as normal for it, then installed the LibUSB-Win32 driver as well - both show up in device manager but avrdude still doesn't want to play ball. Is there anything else you did to get avrdude to work?

- Dean :twisted:

Make Atmel Studio better with my free extensions. Open source and feedback welcome!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi Dean,

Quote:

both show up in device manager but avrdude still doesn't want to play ball.

this is not ok! in device manager show up only the jungo-treiber! --> see picture.
Sorry but my English is not anything good, so I'll make a video (easier to explain) and I put the link here.

Martin

Attachment(s): 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hello Dean
I hope with the video can you see that with the LibUSB

http://www.youtube.com/watch?v=f...

Regards
Martin

Last Edited: Tue. Mar 30, 2010 - 01:29 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Aha! I had to download the libusb-Win32 filter driver separately, in addition to installing the libusb driver included with WinAVR. Interested, I wasn't aware of that, as I thought the included driver was all I needed.

I now can see the same error you are seeing. Once I've debugged the code I'll post here how to fix it.

Cheers!
- Dean :twisted:

Make Atmel Studio better with my free extensions. Open source and feedback welcome!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hmmm, this could be a problem.

The official AVRISP-MKII uses an external USB AVR IC for the USB bus management, connected via SPI. With my version, I use a USB AVR to implement the USB functionality directly. Unfortunately, the USB AVRs aren't equipped to properly deal with bidirectional endpoints, so I have to fake it with a single endpoint whose direction I alter as needed to send/receive data.

This scheme works only because the driver is always sending OR receiving, but never both. The Atmel Jungo driver is very picky about the device descriptors, so I can't just change over to using two separately addressed endpoints for the communication.

It looks like the libusb-Win32 filter driver does something different to the *nix libUSB counterpart and the Jungo driver with the endpoint handles. If I change over to two separate endpoints it works under the Windows filter driver, but breaks AVRStudio. I've tried other tricks (ensuring the endpoint is idle before changing directions, resetting the data toggles) to no avail.

So it looks like I've got the choice of making it AVRStudio (and *nix avrdude) compatible, or making it *nix/Windows avrdude compatible, unless someone fixes libusb-Win32. That sucks.

- Dean :twisted:

Make Atmel Studio better with my free extensions. Open source and feedback welcome!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hmmm, Mierda!

but I can not understand following:

if you installalled -> ONLY <- WinAVR in your PC you can use the AVRISPmkii with the driver from WinAVR!

martincol wrote:

I use WinAVR + Notepad + AVRDUDE, I not use AVRStudio.

If I want to install the original AVRISPmkII in Windows to work with WinAVR (without AVRStudio) then I install the driver that is included in WinaAVR.
...\WinAVR-20100110\utils\libusb\bin --> avrisp2.inf

I not use AVRStudio! I mean no need the Jungo driver and the AVRISPmkii work perfectly. You can test it too.

Regards,
Martin

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Yes, but something about the filter driver/Jungo interaction and my half-duplex endpoints causes it to fail to work correctly. It works under the following conditions (if I understand you correctly):

1) AVRStudio (Windows, with Jungo driver)
2) avrdude (Linux, libUSB driver)
3) avrdude (Windows, libUSB driver, no filter)

But not under the following conditions:

4) avrdude (Windows, libUSB driver, with filter + Jungo)

I can make it work with #4, but that will break #1. I could possibly add it to the release firmware as a compile time option, but at the moment I don't see any way of getting it to work with all four at the same time.

If you really don't care about AVRStudio I can send you the modified firmware which works under avrdude (all configurations) but won't work with AVRStudio.

- Dean :twisted:

Make Atmel Studio better with my free extensions. Open source and feedback welcome!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:

It works under the following conditions (if I understand you correctly):
1), 2), 3)

yes, that's right!

Quote:

I can make it work with #4, but that will break #1. I could possibly add it to the release firmware as a compile time option

that would be very good
Quote:

If you really don't care about AVRStudio I can send you the modified firmware which works under avrdude (all configurations) but won't work with AVRStudio.

makes me happy, that's wonderful! :D
but, it pleased so many people, I know that many people unter Windows no use AVRStudio!

Martin

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Odd - if they don't use AVRStudio, why don't they just uninstall the Jungo driver, and just use the straight libUSB driver without the problematic filter driver? The workaround here would break AVRStudio compatibility anyway.

Nevertheless, I've attached the patched build for the XPLAIN, which will work with everything but AVRStudio.

- Dean :twisted:

Attachment(s): 

Make Atmel Studio better with my free extensions. Open source and feedback welcome!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Dean,
I am sorry! but my English is so bad that I think du you have not understand me :-(

Quote:
Odd - if they don't use AVRStudio, why don't they just uninstall the Jungo driver, and just use the straight libUSB driver without the problematic filter driver?

1) I don't use AVRStudio
2) I don't use Jungo driver
3) I don't use FILTER driver

--> 4) I USE libUSB driver

BUT So it looks under Windows and WinAVR (no AVRStudio installed, no jungo driver):

1) The Original AVRISPmkII from Atmel -->> the works well with LibUSB driver
2) The Xplain Board with LUFA Firmware -->> it doesn't work well with LibUSB driver

--> and for this (2) I asked you

The "FILTER DRIVER" is alone if somebody use both AVRSTUDIO + AVRDUDE.

Martin

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Aha, so it's libUSB itself then that's interacting badly, rather than the filter driver. I'll make the fix a compile time option in the code, so that people can choose between AVRStudio and avrdude on Windows.

- Dean :twisted:

Make Atmel Studio better with my free extensions. Open source and feedback welcome!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Silly question but if using Windows what does avrdude.exe offer that stk500.exe doesn't? (and hence (1) above)

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

abcminiuser wrote:
Aha, so it's libUSB itself then that's interacting badly, rather than the filter driver.

possibly yes.

clawson wrote:
Silly question but if using Windows what does avrdude.exe offer that stk500.exe doesn't? (and hence (1) above)

I don't know!
I have no idea whether avrdude.exe is better than stk500.exe. But The fact is I find AVRDUDE better (that's my opinion), I have never worked with stk500.exe and I need not now change. From the beginning I have worked with AVRDUDE (Unix ...), I find the combination WinAVR + Notepad (Editor) and AVRDUDE is perfect! :lol:

Regards
Martin

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi Dean,

Thank you for the firmware! Now I can flash the target with AVRDude without any problems.
I think the reset register holding the target in indefinite reset because the target is not running unless I make power-cycle the board, BUT that is no problem!

Thanks again,
Martin

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:

I think the reset register holding the target in indefinite reset because the target is not running unless I make power-cycle the board, BUT that is no problem!

I've had read trouble with this; I personally think it's a silicon problem since on my board, I have to clear the XMEGA's PDI Reset register twice for it to take affect. Can you try the attached build to see if it fixes the problem?

- Dean :twisted:

Attachment(s): 

Make Atmel Studio better with my free extensions. Open source and feedback welcome!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:
Can you try the attached build to see if it fixes the problem?

It does not work.

error message:
avrdude: stk500v2_recv_mk2: error in USB receive

Martin

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Ooops, I forgot to compile with the new mode setting token :oops:. Try this version.

- Dean :twisted:

Attachment(s): 

Make Atmel Studio better with my free extensions. Open source and feedback welcome!

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Jup, PERFECT!

Thanks again,
Martin

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi dude
what if I don't have AVR Studio
abedinionline.com

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Quote:

what if I don't have AVR Studio

Did you read Dean's most recent post (2 days ago) about this here?

https://www.avrfreaks.net/index.p...

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Yes, AVRDude compatible versions are now also available pre-built on my site:

http://www.fourwalledcubicle.com...

These work with AVRDude under all platforms (the AVRStudio one does not work with avrdude under Windows due to differences in the Atmel and libUSB drivers). Either version of the firmware works the same from the user's perspective - just treat it like a real AVRISP-MKII when using your programming software.

- Dean :twisted:

Make Atmel Studio better with my free extensions. Open source and feedback welcome!