blob: 2784bb922c233eeffb6cfc219e2993bfd27b6153 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
|
Xytronic LF-1600 Open Source Firmware
=====================================
Copyright (c) 2015-2017 Michael Buesch <m@bues.ch>
Licensed under the terms of the GNU General Public License version 2 or (at your option) any later version.
Selecting the correct firmware hex image:
-----------------------------------------
The `hex` subdirectory of this package contains various pre-built configurations of the firmware.
* There are hex images available for legacy (through-hole) boards and newer SMD boards.
* Images for controller types AtMega-88 (the original controller on legacy through-hole board) or AtMega-88p (the original controller on SMD board) or AtMega-328p (upgrade controller) are available.
* Images with or without debug support (debug vs. release) are available.
If you don't know which one pick, take either `hex/board_legacy/atmega88/release` or `hex/board_smd/atmega88p/release` depending on your board type.
Installing the firmware:
------------------------
1. Erase the chip:
If you use avrdude, a command similar to the following can be used:
`avrdude -B 200 -p m88 -c avrisp2 -P usb -e`
or
`avrdude -B 200 -p m88p -c avrisp2 -P usb -e`
or
`avrdude -B 200 -p m328p -c avrisp2 -P usb -e`
1. Set the fuse bits of the AtMega88 to:
`LFUSE = %%M88_LFUSE%%`
`HFUSE = %%M88_HFUSE%%`
`EFUSE = %%M88_EFUSE%%`
Set the fuse bits of the AtMega88p to:
`LFUSE = %%M88P_LFUSE%%`
`HFUSE = %%M88P_HFUSE%%`
`EFUSE = %%M88P_EFUSE%%`
Set the fuse bits of the AtMega328p to:
`LFUSE = %%M328P_LFUSE%%`
`HFUSE = %%M328P_HFUSE%%`
`EFUSE = %%M328P_EFUSE%%`
Note that the original firmware uses different fuses. So this step must not be omitted.
If you use avrdude, a command similar to the following can be used:
`avrdude -B 200 -p m88 -c avrisp2 -P usb -U lfuse:w:%%M88_LFUSE%%:m -U hfuse:w:%%M88_HFUSE%%:m -U efuse:w:%%M88_EFUSE%%:m`
or
`avrdude -B 200 -p m88p -c avrisp2 -P usb -U lfuse:w:%%M88P_LFUSE%%:m -U hfuse:w:%%M88P_HFUSE%%:m -U efuse:w:%%M88P_EFUSE%%:m`
or
`avrdude -B 200 -p m328p -c avrisp2 -P usb -U lfuse:w:%%M328P_LFUSE%%:m -U hfuse:w:%%M328P_HFUSE%%:m -U efuse:w:%%M328P_EFUSE%%:m`
2. Flash the firmware image file xytronic-lf.hex to the program memory of the AtMega88.
If you use avrdude, a command similar to the following can be used:
`avrdude -B 1 -p m88 -c avrisp2 -P usb -U flash:w:xytronic-lf.hex`
or
`avrdude -B 1 -p m88p -c avrisp2 -P usb -U flash:w:xytronic-lf.hex`
or
`avrdude -B 1 -p m328p -c avrisp2 -P usb -U flash:w:xytronic-lf.hex`
3. Write the EEPROM image file xytronic-lf.eep.hex to the EEPROM memory of the AtMega88.
If you use avrdude, a command similar to the following can be used:
`avrdude -B 1 -p m88 -c avrisp2 -P usb -U eeprom:w:xytronic-lf.eep.hex`
or
`avrdude -B 1 -p m88p -c avrisp2 -P usb -U eeprom:w:xytronic-lf.eep.hex`
or
`avrdude -B 1 -p m328p -c avrisp2 -P usb -U eeprom:w:xytronic-lf.eep.hex`
|