ATtiny45 and USB

General discussions about V-USB, our firmware-only implementation of a low speed USB device on Atmel's AVR microcontrollers
Post Reply
IvanBIV
Posts: 2
Joined: Wed Aug 24, 2011 4:29 pm

ATtiny45 and USB

Post by IvanBIV » Wed Aug 24, 2011 4:52 pm

Please help.
Gathered on the USB device ATtiny45, but it is not even defined in the system.
(1) The foundation took the material: http://habrahabr.ru/blogs/DIY/85892/
Using the following scheme: http://i51.photobucket.com/albums/f382/ ... dstrip.png
except that I take food with USB, and in place of transistors - the LEDs.
The device is not working, the operating system (Win7) just keeps quiet and I was advised to use a zener, so I picked up a scheme to supply here: http://www.obdev.at/products/vusb/easylogger.html

Stitch code on the site, the device is generally not determined on a laptop with Win7 and a PC with WinXP writes: device not recognized.
Prior to these experiments, I ask that the MC for the simple blinking LED through a cycle, it turned out.
I use Programmer STK200 (wires with resistors).

The only thing I change in resources, this makefile, type of programmer for stk200.

When the device is connected to a PC via USB, then the voltage on D + 0, well, at D-- pulsing from 0 to 1.2V, approximately.
When disconnected from the IC legs 5 and 7, then D +: 0in; D-: 2.92v

Do you have any ideas?

IvanBIV
Posts: 2
Joined: Wed Aug 24, 2011 4:29 pm

Re: ATtiny45 and USB

Post by IvanBIV » Wed Aug 24, 2011 6:07 pm

Flashed with MCU material published http://www.ruinelli.ch/how-to-use-v-usb-on-an-attiny85, now the device shows up as "Unknown Device", which VID and PID are zero, put my screenshot:
Image
What is it? I will be useful for any ideas.

CaCO3
Posts: 13
Joined: Thu Jun 30, 2011 12:52 am

Re: ATtiny45 and USB

Post by CaCO3 » Fri Aug 26, 2011 11:34 am

I tested my code example (HID-Mouse) under windows XP, there it works. I dont know about Win 7. Officially it should work there as well, but I wouldnt be surprised if Microsoft added some new bugs to break the compatibility.
Could you test it on a linux system?
If you dont have one at hand, download a live-cd of Ubuntu or so.
Linux is very handy for debugging. Windows AFAIK doesnt give you access to those logs easily.

kadim
Posts: 1
Joined: Thu Dec 01, 2011 9:43 pm

Re: ATtiny45 and USB

Post by kadim » Thu Dec 01, 2011 9:52 pm

Hello,
I have same problem and i don't know how to solve it...
I try to connect my device to winxp and to ubuntu 11.04.
In winxp - i get the same result as you, in ubuntu i get:

Code: Select all

Nov  9 15:40:02 dimak-Joybook-S31V kernel: [62881.448107] usb 5-2: new low speed USB device using uhci_hcd and address 44
Nov  9 15:40:02 dimak-Joybook-S31V kernel: [62881.860155] usb 5-2: device not accepting address 44, error -71
Nov  9 15:40:02 dimak-Joybook-S31V kernel: [62881.860195] hub 5-0:1.0: unable to enumerate USB device on port 2


Does anyone have any thoughts on this subject?

Peter Chaffe
Rank 1
Rank 1
Posts: 20
Joined: Fri Dec 02, 2011 12:25 pm

Re: ATtiny45 and USB

Post by Peter Chaffe » Sat Dec 03, 2011 11:27 am

All I can see that might be causing problems from your diagram is the supply voltage of 3v3 in conjunction with a high internal clock freq of (presumably) 16500000 c/s.

• Speed Grade
– ATtiny25V/45V/85V: 0 – 4 MHz @ 1.8 - 5.5V, 0 - 10 MHz @ 2.7 - 5.5V
– ATtiny25/45/85: 0 – 10 MHz @ 2.7 - 5.5V, 0 - 20 MHz @ 4.5 - 5.5V

Could be approaching unstable in operation...

I've used the ATTiny 45 reliably at 5v on windows7, but XP sp3 seems a bit more picky, device detected but failed install...

Peter Chaffe
Rank 1
Rank 1
Posts: 20
Joined: Fri Dec 02, 2011 12:25 pm

Re: ATtiny45 and USB

Post by Peter Chaffe » Sun Dec 04, 2011 11:17 am

Have used the code available in post #1 (ie t45 rar) to built the circuit similar to that suggested in post #3

Host code: Works only on xp sp3 here! crashing on W7.
led circuit not being recognized on xp or w7.

Still playing around with it, has anyone had any success with this code?

xiao
Posts: 7
Joined: Tue Dec 09, 2008 5:26 am
Contact:

Re: ATtiny45 and USB

Post by xiao » Tue Apr 03, 2012 4:56 am

Peter Chaffe wrote:Have used the code available in post #1 (ie t45 rar) to built the circuit similar to that suggested in post #3

Host code: Works only on xp sp3 here! crashing on W7.
led circuit not being recognized on xp or w7.

Still playing around with it, has anyone had any success with this code?



XP or Windows7 has "bug" about USB ack. & some descriptor response, it might be Microsoft did this trick intentionally. unless you have USB protocol analyser to catch that bytes & sequency because there is no simple way to fix this issue. We had seen this problem before, but now just could not find the record.

Post Reply