Atmega32u4 Breakout Board Leonardo Driver Issues

Breakout boards, sensors, Drawdio, Game of Life, other Adafruit kits, etc.

Moderators: adafruit_support_bill, adafruit

Re: Atmega32u4 Breakout Board Leonardo Driver Issues

Postby vtluu » Wed Nov 23, 2011 1:18 pm

Thanks adafruit, turns out bigmessowires is just up the street (well highway) from me so we may meet up and update my board. In any case I ordered an ISP today since I figured it would inevitably come in handy.
Viet-Tam Luu (a.k.a. "Tam")
vtluu
 
Posts: 6
Joined: Thu Nov 10, 2011 11:48 am
Location: San Jose, CA, USA

Re: Atmega32u4 Breakout Board Leonardo Driver Issues

Postby dam54 » Fri Nov 25, 2011 9:54 pm

Hello - I just received (11/25/2011 shipped on 11/19/2011) a new Atmega32u4 Breakout Board with the Leonardo bootloader and I'm still experiencing the issues noted here. I had understood through the various posts that the issue was resolved in all boards sent out after 10/28/2011. Is that correct? If so, why might I still be having a problem. I'm using Windows 7 64 bit. I can force the driver to install as suggested in one of the posts, but then I get the "The device cannot start. (Code 10) error. If I try to upload a sketch, I get the "not in sync" message. Also, the only serial port that shows up under Tools/Serial Port is COM1, though in Control Panel, it shows Arduino Leonardo (COM6) under Ports (COM & LPT). Any help would be much appreciated. Thanks!
dam54
 
Posts: 18
Joined: Fri Nov 25, 2011 9:39 pm


Re: Atmega32u4 Breakout Board Leonardo Driver Issues

Postby dam54 » Sat Nov 26, 2011 8:58 pm

Hi, thanks for responding. The device manager showed a new COM port called Arduino Leonardo on port 6, it had an exclamation point. I'm not able to post a screen shot because I have since used my Mac to upload the example blink sketch, which worked fine. But, now when I plug it into the Windows PC, I get a BSOD with a "BAD_POOL_CALLER " error. I'm now unable to plug it into the PC without getting that error. What can I do? Thanks, Dave
dam54
 
Posts: 18
Joined: Fri Nov 25, 2011 9:39 pm

Re: Atmega32u4 Breakout Board Leonardo Driver Issues

Postby bigmessowires » Sat Nov 26, 2011 9:22 pm

I had the exact same problem after uploading Blink from a Mac, and then coming back to the PC. I was able to get around it using the trick from the second to last post on page 1 of this thread, and then resetting it with an avr ISP mkII and erasing the flash before the USB insert was recognized by Windows.
bigmessowires
 
Posts: 59
Joined: Sun Jun 05, 2011 6:34 pm
Location: San Francisco

Re: Atmega32u4 Breakout Board Leonardo Driver Issues

Postby royco » Sun Nov 27, 2011 4:32 am

or try using a different USB port, thats what I did to get the BSODs to stop.
royco
 
Posts: 8
Joined: Thu May 05, 2011 1:35 pm

Re: Atmega32u4 Breakout Board Leonardo Driver Issues

Postby dam54 » Sun Nov 27, 2011 1:03 pm

Thanks for the suggestions! Here is what finally worked for me. When I insert the board into the USB port, Windows searches through the preconfigured folders and fails to install the driver. The board will be listed as Arduino Boot Loader under Other Devices. If I right click on that and choose Update Driver Software, and Search automatically for updated driver software, it will successfully install the driver for a USB Composite Device. It will then continue to install Arduino Leanardo on a COM port, and also a USB Input Device. From then on, it will be listed under Ports as Arduino Leonardo (COM#) and be working fine. I can now remove it and plug it back into the same USB port and it works fine. I have been able to do this with any USB port on my computer. Since my board had already had a sketch uploaded with my MAC before I tried this, I'm not sure if this method would have worked without having to do that or not.
dam54
 
Posts: 18
Joined: Fri Nov 25, 2011 9:39 pm

Re: Atmega32u4 Breakout Board Leonardo Driver Issues

Postby toddkrein » Tue Nov 29, 2011 3:26 am

(Now that we're done frying the turkey...)

I'm trying to dump the post-programmed data from my 32u4, using an Atmel DRAGON, to avoid BSoD. I'm not having any luck at all...

I have AVR studio 5.0, which I just downloaded, and I connected the Dragon board. AS5 recognized it, and updated the firmware, so that connection seems OK. I have the ISP connection jumpered across to the 6-pin header on the 32u4 board, but I keep getting the message that the device won't enter programming mode.

Any ideas?

Adafruit - a request: Please put a pin 1 marking on the 6-pin connector in the next spin of the board. I had to go back to the board layout file to determine how to connect it....
toddkrein
 
Posts: 17
Joined: Wed May 05, 2010 2:17 pm
Location: Palo Alto / Loomis

Re: Atmega32u4 Breakout Board Leonardo Driver Issues

Postby toddkrein » Tue Nov 29, 2011 3:34 am

Woops - operator error. Got the programmer working.

*Really* could use the Pin 1 marker, for blind old people like me....
toddkrein
 
Posts: 17
Joined: Wed May 05, 2010 2:17 pm
Location: Palo Alto / Loomis

Re: Atmega32u4 Breakout Board Leonardo Driver Issues

Postby vtluu » Sat Dec 03, 2011 1:06 pm

Okay, received my USBtinyISP today; soldered it together, patched my avrdude.conf, etc. and got it talking to the breakout board.

I've re-flashed the breakout board successfully--I think--multiple times but still get the same "This device cannot start. (Code 10)" error. Here's the AVRDUDE mantra I'm using; the fuse bits are a bit of a guess (got them via http://www.engbedded.com/fusecalc/) so if someone could double-check them... Also I haven't quite figured what to do with the "lock" byte; I've switched it between 0x0f and 0x3f without any apparent effect.

Code: Select all
avrdude -c usbtiny -p m32u4 -B 1 -U flash:w:DiskLoader-Leonardo.hex -U lfuse:w:0xff:m -U hfuse:w:0xd8:m -U efuse:w:0xc1:m
Viet-Tam Luu (a.k.a. "Tam")
vtluu
 
Posts: 6
Joined: Thu Nov 10, 2011 11:48 am
Location: San Jose, CA, USA

Re: Atmega32u4 Breakout Board Leonardo Driver Issues

Postby vtluu » Sat Dec 03, 2011 1:08 pm

I'm going to try connecting to a different host (Linux or WinXP VM), will update you on how that goes...
Viet-Tam Luu (a.k.a. "Tam")
vtluu
 
Posts: 6
Joined: Thu Nov 10, 2011 11:48 am
Location: San Jose, CA, USA

Re: Atmega32u4 Breakout Board Leonardo Driver Issues

Postby bigmessowires » Sat Dec 03, 2011 7:20 pm

I have half a feeling that the updated Leonardo bootloader actually has nothing to do with the "This device cannot start. (Code 10)" error or BSOD. In my case it did start working after I updated the bootloader, but not immediately after-- I actually reburned the new bootloader twice, and reset it a bunch of times, and uninstalled and reinstalled the drivers again, then suddenly it started working. The updated bootloader seems like the most likely explanation, but since it wasn't an obvious new bootloader -> immediate success experience, maybe it was just a coincidence?
bigmessowires
 
Posts: 59
Joined: Sun Jun 05, 2011 6:34 pm
Location: San Francisco

Re: Atmega32u4 Breakout Board Leonardo Driver Issues

Postby Seannerd » Mon Dec 05, 2011 8:54 pm

Wohoo! It works!

Well - I hope this will for others (provided you have an ISP programmer). Here is what I did, after reading all of your efforts, and contacting support@adafruit - who told me to try a 32 bit OS.

Since I got it working, I believe this is a 64bit windows OS issue . I used my win7 64 bit machine with Adafruit's USBTinyISP programmer to re-flash the chip's bootloader with the Leonardo from Arduino 1.0. The Bootloader hex is in arduino-1.0\hardware\arduino\bootloaders\diskloader To do this, I ran jumpers from the USBTiny's 6 pin programmer cable to my bread board to the appropriate atMega32u4 pins. The command from WinAvr is:
Code: Select all
avrdude -p atmega32u4 -c usbtiny -U flash:w:DiskLoader-Leonardo.hex

Image

Next, I dug out my crappy laptop from the closet (win XP) and installed all the supporting software (Arduino 1.0, all the "belt" libraries from adafruit, uncommented the leonardo from the hardware\arduino\boards.txt file). I plugged the breakout board into the USB port and it couldn't find a driver - so I had to edit the .inf file to match the hardware UID/PID, and poof - it worked - mostly. There was a new COM port (Yay!), but there was a "not working" HID device.

(If you want it, the .inf file I edited is attached.)

"So what if it isn't perfect!", I said - I'll keep going. So - I ran Arduino 1.0 from the XP laptop, and uploaded the Belt sketch. After it finished, the operating system indicated two USB disconnects "bee-doop ... bee-doop" and then two connects "boo-deep ... boo-deep". It then proceeded to re-install the COM port and (this time) a successfully working HID device. Cool!

I wired up the board to the LED belt, and it worked perfectly. So - then I experimented a little. I plugged the board into my Win 7 64 bit laptop, and it recognized properly! I uploaded the advanced belt sketch (after adding the timer library). Win 7 did the same double disconnect and reconnect (a little weird), but the result was a working atMega32u4.

So - I think the solution is to program the thing on a 32bit OS first and then try 64bit.

Hope this helps. Good luck - and thanks to all who posted such great information.

- Sean
Attachments
Arduino Leonardo.zip
Edited inf file for Leonardo Bootloader
(1.17 KiB) Downloaded 102 times
Seannerd
 
Posts: 4
Joined: Thu Dec 02, 2010 6:17 pm

Re: Atmega32u4 Breakout Board Leonardo Driver Issues

Postby adafruit » Tue Dec 06, 2011 10:18 am

thats interesting and somewhat helpful but still terribly confusing - nothing in programming it with a new sketch should change the ability of 64 bit windows identifying it :/

can anyone else verify this oddness?
User avatar
adafruit
 
Posts: 10546
Joined: Thu Apr 06, 2006 3:21 pm
Location: nyc

Re: Atmega32u4 Breakout Board Leonardo Driver Issues

Postby bigmessowires » Tue Dec 06, 2011 12:21 pm

adafruit wrote:thats interesting and somewhat helpful but still terribly confusing - nothing in programming it with a new sketch should change the ability of 64 bit windows identifying it :/

can anyone else verify this oddness?


That does sound odd. I don't have a 32-bit OS to test that theory with, but my guess is that what made the difference here is which sketch (if any) was programmed to the ATMEGA32u4. We saw earlier that several people got BSOD after programming the Blink sketch, for example. Maybe the ATMEGA is switching from bootloader to sketch mode too quickly, while the PC is still trying to enumerate USB, and depending on what sketch gets run you get random results?
bigmessowires
 
Posts: 59
Joined: Sun Jun 05, 2011 6:34 pm
Location: San Francisco

PreviousNext

Return to Other Adafruit products

Who is online

Users browsing this forum: ArekKindAcere and 6 guests

Stuff to buy from the Adafruit store and links to product documentation!


New Products [114]

Raspberry Pi[82]
 
FLORA[24]
 
Bunnie Studios[9]
 
FPGA[1]
 
mbed[12]
Arduino[60]
 
NETduino[14]
 
BeagleBone[23]
 
Android[6]
 
XBee[10]
More Dev Boards[30]


 
BoArduino[8]
 
SpokePOV[4]
 
TV-B-Gone[4]
 
MiniPOV[3]
 
SIM reader[3]
 
Microtouch[5]
 
Clocks & Watches[18]
 
Drawdio[4]
 
Brain Machine[1]
 
Game of Life[2]
 
MintyBoost[2]
More DIY Kits[16]


 
MaKey MaKey[3]
 
Tweet-a-Watt[5]
 
Young Engineers[39]
 
Discover Electronics[2]
 
Snap Circuits[4]
 
littleBits[3]
 
Project packs[9]


 
Breakout Boards[35]
LCDs & Displays[49]
Components & Parts[70]
Batteries & Power[54]
EL Wire/Tape/Panel[52]
LEDs[112]
 
Wireless[16]
Cables[66]
 
Lasers[6]
Sensors/Parts[147]
 
Enclosures/Cases[11]
 
Solar[11]
 
RFID / NFC[13]
Prototyping[70]
 
iDevices[13]
Tools[71]
 
Wearables[41]
 
CNC[37]
 
Robotics[29]
 
3D printing[1]
 
Materials[25]


 
Stickers[41]
 
Skill badges[55]
 
Books[26]
 
Circuit Playground[7]
 
Gift Certificates[4]