1 |
i2c-tiny-usb - (c) 2006 by Till Harbaum |
1 |
i2c-tiny-usb - (c) 2006 by Till Harbaum |
2 |
--------------------------------------- |
2 |
--------------------------------------- |
3 |
http://www.harbaum.org/till/i2c_tiny_usb |
3 |
http://www.harbaum.org/till/i2c_tiny_usb |
4 |
|
4 |
|
5 |
The firmware code itself is distributed under the GPL, but |
5 |
The firmware code itself is distributed under the GPL, but |
6 |
one of the usb codes comes under a separate license. Plase see |
6 |
one of the usb codes comes under a separate license. Plase see |
7 |
the .txt files in usbdrv for details. |
7 |
the .txt files in usbdrv for details. |
8 |
|
8 |
|
9 |
The default configuration is for a attiny45. The Makefile.mega8 |
9 |
The default configuration is for a attiny45. The Makefile.mega8 |
10 |
allows to compile the device for the Atmega8 cpu. This includes |
10 |
allows to compile the device for the Atmega8 cpu. This includes |
11 |
the possibility to use the atmega8 rs232 for debugging. |
11 |
the possibility to use the atmega8 rs232 for debugging. |
12 |
|
12 |
|
13 |
The attiny45 has to be programmed in high voltage serial |
13 |
The attiny45 has to be programmed in high voltage serial |
14 |
programming (hsvp) mode since this application needs the |
14 |
programming (hsvp) mode since this application needs the |
15 |
reset pin to be reconfigured for other use. |
15 |
reset pin to be reconfigured for other use. |
16 |
|
16 |
|
17 |
This project supports two usb implementations: the avrusb and |
17 |
This project supports two usb implementations: the avrusb and |
18 |
usbtiny. Due to this four Makefiles exist: |
18 |
usbtiny. Due to this four Makefiles exist: |
19 |
|
19 |
|
20 |
Makefile-avrusb.tiny45 - build with avrusb for Attiny45 |
20 |
Makefile-avrusb.tiny45 - build with avrusb for Attiny45 |
21 |
Makefile-avrusb.mega8 - build with avrusb for Atmega8 |
21 |
Makefile-avrusb.mega8 - build with avrusb for Atmega8 |
22 |
Makefile-usbtiny.tiny45 - build with usbtiny for Attiny45 |
22 |
Makefile-usbtiny.tiny45 - build with usbtiny for Attiny45 |
23 |
Makefile-usbtiny.mega8 - build with usbtiny for Atmega8 |
23 |
Makefile-usbtiny.mega8 - build with usbtiny for Atmega8 |
24 |
|
24 |
|
25 |
Just type |
25 |
Just type |
26 |
make -f Makefile-avrusb.xxx program |
26 |
make -f Makefile-avrusb.xxx program |
27 |
or |
27 |
or |
28 |
make -f Makefile-usbtiny.xxx flash |
28 |
make -f Makefile-usbtiny.xxx flash |
29 |
|
29 |
|
30 |
to compile and upload the file. Please adjust e.g. programmer |
30 |
to compile and upload the file. Please adjust e.g. programmer |
31 |
settings in the Makefile. |
31 |
settings in the Makefile. |
32 |
|
32 |
|
33 |
If you don't want to recompile the firmware yourself you might |
33 |
If you don't want to recompile the firmware yourself you might |
34 |
use the included firmware.hex which is a prebuilt binary for the |
34 |
use the included firmware.hex which is a prebuilt binary for the |
35 |
attiny45. Plase make sure you adjust the fuses accordingly. |
35 |
attiny45. Plase make sure you adjust the fuses accordingly. |
36 |
They need to be set to "external crystal > 8Mhz" and the RESET |
36 |
They need to be set to "external crystal > 8Mhz" and the RESET |
37 |
pin has to be disabled in order to be re-used for application |
37 |
pin has to be disabled in order to be re-used for application |
38 |
specific purposes. See Makefile-avrusb.tiny45 for more details. |
38 |
specific purposes. See Makefile-avrusb.tiny45 for more details. |