Atmel's response has been unsatisfactory - first they asked for more information, then they asked for more information again, and now they've stopped replying. Shame on them; two thumbs down for customer support. Therefore I don't know if the ATTiny85 is defective by design, or if I got some bad parts. I also don't know if the attiny25 and attiny45 are similarly afflicted. I plan to order a few of each from a different vendor (thus hopefully a different manufacturing batch) and test them, and I'll update this entry when I do.
Since this defect the part almost completely useless for any application which involves both analog input and output, which is probably the majority of applications, it seems impossible to me that all of them could have this problem, or many large customers would have complained by now. I therefore favor the explanation that I got some from a bad batch.
Update, June 30 2011: I have tested several more parts, and the results are grim. Every single one has the same problem. Atmel's support representative did get back to me, and after several rounds of trying to understand each other's setup, we're still trying to figure out why he isn't seeing the same magnitude of problem that I am.
Part | Datecode | Result |
---|---|---|
ATTINY85-20PU | 1039 | FAIL |
ATTINY85-20PU | 1111 | FAIL |
ATTINY85V-10PU | 1111 | FAIL |
ATTINY45V-10PU | 1013 | FAIL |
Update, July 17, 2011: The problem is much more significant when sinking current than when sourcing it, and can be partially mitigated by bringing the reference out at PB0 and connecting it to ground via a capacitor, if that is feasible for your design. The table below shows the results of my tests:
Current per pin | Direction | Aref Cap | ADC Difference |
---|---|---|---|
15 mA | Sourcing | No | 2 counts |
15 mA | Sourcing | 100nF | 1 count |
15 mA | Sinking | No | 16 counts |
15 mA | Sinking | 100nF | 6 counts |
5 mA | Sourcing | No | 0 counts |
5 mA | Sourcing | 100nF | 0 counts |
5 mA | Sinking | No | 6 counts |
5 mA | Sinking | 100nF | 1 count |
Conclusion: Sourcing=OK, sinking=big problem for ADC. I still assert that this is a defect in the part. Sinking 5 mA on two pins is clearly within spec (they're specified to 10 mA), and 6 counts of variation clearly do NOT meet the specified 2 LSB absolute accuracy for the ADC.