Page 1 of 1

USB recognition problem (3.3v Regulator + 12Mhz Oscillator)

Posted: Tue Apr 03, 2012 8:47 am
by dlf23456
First of all, please kindly understand my broken English. It's not my first language.

I used ATmega32A for MCU.

I built a PCB using a 3.3v Regulator (LM1117s3.3) and an 12Mhz OSC (SCO-103).
No diodes. (At least, I think there wiil be no reason to use diodes).

The oscillator is connected to XTAL1.
XTAL 2 is not connected.

68Ohm to D- and D+ for impedance matching.
D- is pulled up by 1k5 resistor.

10uF(Tantal) and 100nF(Ceramic) capacitors are coupled for stablizing power source. (Both 5v and 3.3v)

Fuse bit I used : H-0xD0 L-0xCF and I also tried H-0xC9 L-0x9F.

I don't understand why it works occationlly.
Even if the connection was established, it fails after few second or minute.
It works properly while it's connected.

The symptoms are vary.
One of them repeats connected and disconnected.
One of them cannot be connected at all.
One of them can be connected. but cannot hold the connection for a long time.

I even tried connecting zenor diodes D-and D+ to GND. but, the same.

Has anyone experienced this situation before?

Please give me some advice.

Thank you in advance.

Re: USB recognition problem (3.3v Regulator + 12Mhz Oscillator)

Posted: Tue Apr 03, 2012 2:06 pm
by Micha
The only obvious thing I can see is that your controller runs out of spec. 12MHz @ 3.3V without violating the spec is only possible with devices that run with 20MHz @ 5V, NOT with those running with 16MHz @ 5V as yours does.

Re: USB recognition problem (3.3v Regulator + 12Mhz Oscillator)

Posted: Wed Apr 04, 2012 12:12 am
by xiangrui
Are you sure it is right to connect oscillator to only XTAL1?

Re: USB recognition problem (3.3v Regulator + 12Mhz Oscillator)

Posted: Wed Apr 04, 2012 2:54 am
by dlf23456
Micha wrote:The only obvious thing I can see is that your controller runs out of spec. 12MHz @ 3.3V without violating the spec is only possible with devices that run with 20MHz @ 5V, NOT with those running with 16MHz @ 5V as yours does.


Thx Micha.
As far as I know, That specification applies ATmega32(L) package or ATmega128A package. I can't find that on the ATmega32A datasheet about that.

It only says that it operates from 2.7v to 5.5v, from 0 to 16Mhz.

Re: USB recognition problem (3.3v Regulator + 12Mhz Oscillator)

Posted: Wed Apr 04, 2012 3:00 am
by dlf23456
xiangrui wrote:Are you sure it is right to connect oscillator to only XTAL1?


Thx xiangrui.
I applied as the figure 8.4 on the datasheet.
I thought SCO-103 is not just a crystal, I assume that is a kind of clock generator.
(it has many pins such as Vcc, GND and Output)

Furthermore, I needed the clock shared.

Re: USB recognition problem (3.3v Regulator + 12Mhz Oscillator)

Posted: Sat Apr 07, 2012 11:43 pm
by Micha
dlf23456 wrote:
Micha wrote:The only obvious thing I can see is that your controller runs out of spec. 12MHz @ 3.3V without violating the spec is only possible with devices that run with 20MHz @ 5V, NOT with those running with 16MHz @ 5V as yours does.


Thx Micha.
As far as I know, That specification applies ATmega32(L) package or ATmega128A package. I can't find that on the ATmega32A datasheet about that.

It only says that it operates from 2.7v to 5.5v, from 0 to 16Mhz.

Have a look on page 299 in the datasheet (doc8155). Between 8MHz/2.7V and 16MHz/4.5V the graph is linear. You can create the formula according to the figure and you'll see that you're out of spec. I remember old datasheets where the formula was already given underneath that figure.

Maybe that's not causing your problems but nevertheless it's a fact.

Re: USB recognition problem (3.3v Regulator + 12Mhz Oscillator)

Posted: Mon Apr 09, 2012 2:31 am
by dlf23456
Micha wrote:
dlf23456 wrote:
Micha wrote:The only obvious thing I can see is that your controller runs out of spec. 12MHz @ 3.3V without violating the spec is only possible with devices that run with 20MHz @ 5V, NOT with those running with 16MHz @ 5V as yours does.


Thx Micha.
As far as I know, That specification applies ATmega32(L) package or ATmega128A package. I can't find that on the ATmega32A datasheet about that.

It only says that it operates from 2.7v to 5.5v, from 0 to 16Mhz.

Have a look on page 299 in the datasheet (doc8155). Between 8MHz/2.7V and 16MHz/4.5V the graph is linear. You can create the formula according to the figure and you'll see that you're out of spec. I remember old datasheets where the formula was already given underneath that figure.

Maybe that's not causing your problems but nevertheless it's a fact.


Thank you. Micha.

I found the graph you told me. I think the reason why it wasn't stable is because of what you told me.
And I also found some reasons that causes the problems.

1. Fuse bit : I changed the fuse bit. as CB,E0. and it works pretty well so far.
2. Hub Controller : I implemented a hub controller togather. I think it doesn't work if the clock is shared.

solution : I got rid of the hub controller (Probably, I have to make the schematic again. for individual clock source). And I also changed the fuse bit.
For stabilized operation, I think VCC must be over 4.5V. I think operating at 3.3V doesn't garantee the stable operation. My device shows unstable little bit.

Problem solved.