1 |
Hello, |
2 |
|
3 |
Your posts are kind of hard to reply to, sorry if I miss something. |
4 |
I'll try to get everything into this message. |
5 |
|
6 |
On Mon, Aug 7, 2017 at 10:41 AM, <tuxic@××××××.de> wrote: |
7 |
> Hi, |
8 |
> |
9 |
> |
10 |
> On 08/06 07:04, R0b0t1 wrote: |
11 |
>> On Sun, Aug 6, 2017 at 11:50 AM, <tuxic@××××××.de> wrote: |
12 |
>> > When I plug in such a little board into my PC, demesg |
13 |
>> > reports: |
14 |
>> > [ 1429.834140] usb 7-4: new low-speed USB device number 15 using ohci-pci |
15 |
>> > [ 1429.965142] usb 7-4: device descriptor read/64, error -62 |
16 |
>> > [ 1430.203151] usb 7-4: device descriptor read/64, error -62 |
17 |
>> > [ 1430.438161] usb 7-4: new low-speed USB device number 16 using ohci-pci |
18 |
>> > [ 1430.569151] usb 7-4: device descriptor read/64, error -62 |
19 |
>> > [ 1430.803174] usb 7-4: device descriptor read/64, error -62 |
20 |
>> > [ 1431.038184] usb 7-4: new low-speed USB device number 17 using ohci-pci |
21 |
>> > [ 1431.456157] usb 7-4: device not accepting address 17, error -62 |
22 |
>> > [ 1431.582204] usb 7-4: new low-speed USB device number 18 using ohci-pci |
23 |
>> > [ 1432.000209] usb 7-4: device not accepting address 18, error -62 |
24 |
>> > [ 1432.000244] usb usb7-port4: unable to enumerate USB device |
25 |
>> > |
26 |
>> |
27 |
>> > |
28 |
>> > My first thought was: The micronucleus bootloaed is missing or |
29 |
>> > is defective... |
30 |
>> > |
31 |
>> > But plugging in the board into my Android tablet (the tablet runs |
32 |
>> > Lollipop and is nothing special at all beside being rooted) via |
33 |
>> > an OTG cable and using lsusb after that, it shows |
34 |
>> > Bus 001 Device 003 ID 16d0:0753 MCS Digistump DigiSpark |
35 |
>> > |
36 |
>> |
37 |
>> What the dmesg output is saying is that your USB hardware has reported |
38 |
>> a communication error to the driver. It is my guess that the ATtiny85 |
39 |
>> is not meeting the timing requirements for USB. |
40 |
> |
41 |
> The above is the only part of the dmesg log regarding this usb |
42 |
> "device"... |
43 |
> |
44 |
> If I plug it into a usb-port, it "works"... (read: will be recognized |
45 |
> according to dmesg, but still the udev rules dont get triggered, so |
46 |
> I still get nothing under /dev/... |
47 |
> |
48 |
|
49 |
You should look more closely at the dmesg output, though admittedly |
50 |
some of this might not be obvious without reading the USB |
51 |
specification. The computer being unable to read a descriptor or the |
52 |
device failing to accept an address are things that will prevent the |
53 |
device from properly registering on the bus. The initial handshake |
54 |
fails to complete. |
55 |
|
56 |
> |
57 |
>> Looking at the board there does not seem to be a crystal oscillator |
58 |
>> which most people would consider necessary for doing USB |
59 |
>> communication. This is an oversight on DigiStump's part and it is very |
60 |
>> likely you will not be able to fix the communication issues. You |
61 |
>> should contact them and tell them that your computer will not |
62 |
>> recognize their device and that you suspect it is because the clock is |
63 |
>> too inaccurate. |
64 |
> |
65 |
> ...the board is a thumbnail thing: |
66 |
> http://digistump.com/products/1 |
67 |
> |
68 |
> No crystal. It is not an original digistum and had cost me less than 1 |
69 |
> EUR...so not such a painful loss... |
70 |
> |
71 |
> |
72 |
>> > |
73 |
>> > What can I do to make this Digispark being correctly recognized? |
74 |
>> > |
75 |
>> > Thank you VERY much for any help in advance! |
76 |
>> > |
77 |
>> |
78 |
>> Three things: |
79 |
>> |
80 |
>> 1) Return the one you bought and get a new one. The ATtiny85's |
81 |
>> internal oscillator might be at the end of the bell curve but within |
82 |
>> manufacturer tolerance, which isn't enough to produce a USB signal |
83 |
>> close enough to the specified frequency. Expect the seller to pay for |
84 |
>> return shipping. |
85 |
> |
86 |
> Returning the board does cost more than the board and I haven't |
87 |
> any hope that this will change anything: I have six of them and none |
88 |
> works. "The design can be improved..." to be friendly. |
89 |
> |
90 |
> |
91 |
>> 2) You can calibrate the oscillator using instructions in this |
92 |
>> application note: |
93 |
>> http://www.atmel.com/Images/Atmel-2555-Internal-RC-Oscillator-Calibration-for-tinyAVR-and-megaAVR-Devices_ApplicationNote_AVR053.pdf. |
94 |
>> This process still might not get you close enough. |
95 |
> |
96 |
> I have no oscilloscope nor a frequency counter. |
97 |
> That is above my financial possibilities... |
98 |
> |
99 |
>> 3) Add a crystal oscillator to the ATtiny85 and change its fuses to |
100 |
>> use the oscillator. You will need to recompile the firmware if the |
101 |
>> crystal is a different frequency from the internal oscillator. |
102 |
> |
103 |
> There is not enough space on the board. |
104 |
> |
105 |
|
106 |
Well, if you can't do any of those and if the board doesn't have level |
107 |
shifters that might be affecting the signal then you probably won't be |
108 |
able to use the board. If you send the hardware developer a message |
109 |
that the board has failed to work with a device you will be doing them |
110 |
a favor. |
111 |
|
112 |
|
113 |
On Mon, Aug 7, 2017 at 10:51 AM, <tuxic@××××××.de> wrote: |
114 |
> I ordered a similiar board yesterday, with a more reasonable setup: |
115 |
> ATmega32u4 and a attached sdcard slot for the flash memory. |
116 |
> The ATmega32u4 has a fully fledged USB 2.0 stack (is it called a "stack"?) |
117 |
> and does not bitbang the whole stuff but "talks USB natively". |
118 |
> I have gathered some hope so far, that this thingy will |
119 |
> a) work with USB < 3.0 |
120 |
> b) is more stable and more versatile |
121 |
|
122 |
The software is the stack, the device itself is said to have a USB |
123 |
interface or peripheral. |
124 |
|
125 |
The ATmega32U4 is a good choice but it can be exceedingly hard to use |
126 |
without the Arduino wrappers. It's a good idea to learn how to use it, |
127 |
but a lot of existing software you will find was personally very hard |
128 |
to read, even after referring to the USB specification and doing a |
129 |
bunch of searching. |
130 |
|
131 |
Typically the suggestion is to avoid tinyAVRs (or microcontrollers of |
132 |
similarly limited capabilities) for development work and only choose |
133 |
them after you know what you are doing. If you have problems with the |
134 |
ATmega32U4 you should get a board with, say, an ATmega328PA and use a |
135 |
serial to USB converter for a while. |
136 |
|
137 |
|
138 |
On another note, you should look up needle probes for multimeters and |
139 |
oscilloscopes. You can also poke into insulated wires with them. |
140 |
Working with SMD components isn't too hard, the solder tends to orient |
141 |
them for you. For a lot of parts a hot air rework station is helpful |
142 |
and is not too much money. If you are going to continue in this |
143 |
direction you should get one as almost all modern parts come only in |
144 |
SMD packages. Buying premade boards can only get you so far (but for |
145 |
most people it's enough). |
146 |
|
147 |
R0b0t1. |