@@ -67,31 +67,31 @@ var boardUno = &Board{
6767var boardMega = & Board {
6868 BoardID : "mega" ,
6969 Properties : properties .NewFromHashmap (map [string ]string {
70- "name" : "Arduino/Genuino Mega or Mega 2560" ,
71- "vid.0" : "0x2341" ,
72- "pid.0" : "0x0010" ,
73- "vid.1" : "0x2341" ,
74- "pid.1" : "0x0042" ,
75- "vid.2" : "0x2A03" ,
76- "pid.2" : "0x0010" ,
77- "vid.3" : "0x2A03" ,
78- "pid.3" : "0x0042" ,
79- "vid.4" : "0x2341" ,
80- "pid.4" : "0x0210" ,
81- "vid.5" : "0x2341" ,
82- "pid.5" : "0x0242" ,
83- "upload.tool" : "avrdude" ,
84- "upload.maximum_data_size" : "8192" ,
85- "bootloader.tool" : "avrdude" ,
86- "bootloader.low_fuses" : "0xFF" ,
87- "bootloader.unlock_bits" : "0x3F" ,
88- "bootloader.lock_bits" : "0x0F" ,
89- "build.f_cpu" : "16000000L" ,
90- "build.core" : "arduino" ,
91- "build.variant" : "mega" ,
92- "build.board" : "AVR_MEGA2560" ,
93- "menu.cpu.atmega2560" : "ATmega2560 (Mega 2560)" ,
94- "menu.cpu.atmega2560.upload.protocol" : "wiring" ,
70+ "name" : "Arduino/Genuino Mega or Mega 2560" ,
71+ "vid.0" : "0x2341" ,
72+ "pid.0" : "0x0010" ,
73+ "vid.1" : "0x2341" ,
74+ "pid.1" : "0x0042" ,
75+ "vid.2" : "0x2A03" ,
76+ "pid.2" : "0x0010" ,
77+ "vid.3" : "0x2A03" ,
78+ "pid.3" : "0x0042" ,
79+ "vid.4" : "0x2341" ,
80+ "pid.4" : "0x0210" ,
81+ "vid.5" : "0x2341" ,
82+ "pid.5" : "0x0242" ,
83+ "upload.tool" : "avrdude" ,
84+ "upload.maximum_data_size" : "8192" ,
85+ "bootloader.tool" : "avrdude" ,
86+ "bootloader.low_fuses" : "0xFF" ,
87+ "bootloader.unlock_bits" : "0x3F" ,
88+ "bootloader.lock_bits" : "0x0F" ,
89+ "build.f_cpu" : "16000000L" ,
90+ "build.core" : "arduino" ,
91+ "build.variant" : "mega" ,
92+ "build.board" : "AVR_MEGA2560" ,
93+ "menu.cpu.atmega2560" : "ATmega2560 (Mega 2560)" ,
94+ "menu.cpu.atmega2560.upload.protocol" : "wiring" ,
9595 "menu.cpu.atmega2560.upload.maximum_size" : "253952" ,
9696 "menu.cpu.atmega2560.upload.speed" : "115200" ,
9797 "menu.cpu.atmega2560.bootloader.high_fuses" : "0xD8" ,
@@ -189,19 +189,19 @@ func TestBoard(t *testing.T) {
189189
190190func TestBoardOptions (t * testing.T ) {
191191 expConf2560 := properties .NewFromHashmap (map [string ]string {
192- "bootloader.extended_fuses" : "0xFD" ,
193- "bootloader.file" : "stk500v2/stk500boot_v2_mega2560.hex" ,
194- "bootloader.high_fuses" : "0xD8" ,
195- "bootloader.lock_bits" : "0x0F" ,
196- "bootloader.low_fuses" : "0xFF" ,
197- "bootloader.tool" : "avrdude" ,
198- "bootloader.unlock_bits" : "0x3F" ,
199- "build.board" : "AVR_MEGA2560" ,
200- "build.core" : "arduino" ,
201- "build.f_cpu" : "16000000L" ,
202- "build.mcu" : "atmega2560" ,
203- "build.variant" : "mega" ,
204- "menu.cpu.atmega1280" : "ATmega1280" ,
192+ "bootloader.extended_fuses" : "0xFD" ,
193+ "bootloader.file" : "stk500v2/stk500boot_v2_mega2560.hex" ,
194+ "bootloader.high_fuses" : "0xD8" ,
195+ "bootloader.lock_bits" : "0x0F" ,
196+ "bootloader.low_fuses" : "0xFF" ,
197+ "bootloader.tool" : "avrdude" ,
198+ "bootloader.unlock_bits" : "0x3F" ,
199+ "build.board" : "AVR_MEGA2560" ,
200+ "build.core" : "arduino" ,
201+ "build.f_cpu" : "16000000L" ,
202+ "build.mcu" : "atmega2560" ,
203+ "build.variant" : "mega" ,
204+ "menu.cpu.atmega1280" : "ATmega1280" ,
205205 "menu.cpu.atmega1280.bootloader.extended_fuses" : "0xF5" ,
206206 "menu.cpu.atmega1280.bootloader.file" : "atmega/ATmegaBOOT_168_atmega1280.hex" ,
207207 "menu.cpu.atmega1280.bootloader.high_fuses" : "0xDA" ,
@@ -219,44 +219,44 @@ func TestBoardOptions(t *testing.T) {
219219 "menu.cpu.atmega2560.upload.maximum_size" : "253952" ,
220220 "menu.cpu.atmega2560.upload.protocol" : "wiring" ,
221221 "menu.cpu.atmega2560.upload.speed" : "115200" ,
222- "name" : "Arduino/Genuino Mega or Mega 2560" ,
223- "pid.0" : "0x0010" ,
224- "pid.1" : "0x0042" ,
225- "pid.2" : "0x0010" ,
226- "pid.3" : "0x0042" ,
227- "pid.4" : "0x0210" ,
228- "pid.5" : "0x0242" ,
229- "upload.maximum_data_size" : "8192" ,
230- "upload.maximum_size" : "253952" ,
231- "upload.protocol" : "wiring" ,
232- "upload.speed" : "115200" ,
233- "upload.tool" : "avrdude" ,
234- "vid.0" : "0x2341" ,
235- "vid.1" : "0x2341" ,
236- "vid.2" : "0x2A03" ,
237- "vid.3" : "0x2A03" ,
238- "vid.4" : "0x2341" ,
239- "vid.5" : "0x2341" ,
222+ "name" : "Arduino/Genuino Mega or Mega 2560" ,
223+ "pid.0" : "0x0010" ,
224+ "pid.1" : "0x0042" ,
225+ "pid.2" : "0x0010" ,
226+ "pid.3" : "0x0042" ,
227+ "pid.4" : "0x0210" ,
228+ "pid.5" : "0x0242" ,
229+ "upload.maximum_data_size" : "8192" ,
230+ "upload.maximum_size" : "253952" ,
231+ "upload.protocol" : "wiring" ,
232+ "upload.speed" : "115200" ,
233+ "upload.tool" : "avrdude" ,
234+ "vid.0" : "0x2341" ,
235+ "vid.1" : "0x2341" ,
236+ "vid.2" : "0x2A03" ,
237+ "vid.3" : "0x2A03" ,
238+ "vid.4" : "0x2341" ,
239+ "vid.5" : "0x2341" ,
240240 })
241241
242242 conf2560 , err := boardMega .GeneratePropertiesForConfiguration ("cpu=atmega2560" )
243243 require .NoError (t , err , "generating cpu=atmega2560 configuration" )
244244 require .EqualValues (t , expConf2560 .AsMap (), conf2560 .AsMap (), "configuration for cpu=atmega2560" )
245245
246246 expConf1280 := properties .NewFromHashmap (map [string ]string {
247- "bootloader.extended_fuses" : "0xF5" ,
248- "bootloader.file" : "atmega/ATmegaBOOT_168_atmega1280.hex" ,
249- "bootloader.high_fuses" : "0xDA" ,
250- "bootloader.lock_bits" : "0x0F" ,
251- "bootloader.low_fuses" : "0xFF" ,
252- "bootloader.tool" : "avrdude" ,
253- "bootloader.unlock_bits" : "0x3F" ,
254- "build.board" : "AVR_MEGA" ,
255- "build.core" : "arduino" ,
256- "build.f_cpu" : "16000000L" ,
257- "build.mcu" : "atmega1280" ,
258- "build.variant" : "mega" ,
259- "menu.cpu.atmega1280" : "ATmega1280" ,
247+ "bootloader.extended_fuses" : "0xF5" ,
248+ "bootloader.file" : "atmega/ATmegaBOOT_168_atmega1280.hex" ,
249+ "bootloader.high_fuses" : "0xDA" ,
250+ "bootloader.lock_bits" : "0x0F" ,
251+ "bootloader.low_fuses" : "0xFF" ,
252+ "bootloader.tool" : "avrdude" ,
253+ "bootloader.unlock_bits" : "0x3F" ,
254+ "build.board" : "AVR_MEGA" ,
255+ "build.core" : "arduino" ,
256+ "build.f_cpu" : "16000000L" ,
257+ "build.mcu" : "atmega1280" ,
258+ "build.variant" : "mega" ,
259+ "menu.cpu.atmega1280" : "ATmega1280" ,
260260 "menu.cpu.atmega1280.bootloader.extended_fuses" : "0xF5" ,
261261 "menu.cpu.atmega1280.bootloader.file" : "atmega/ATmegaBOOT_168_atmega1280.hex" ,
262262 "menu.cpu.atmega1280.bootloader.high_fuses" : "0xDA" ,
@@ -274,24 +274,24 @@ func TestBoardOptions(t *testing.T) {
274274 "menu.cpu.atmega2560.upload.maximum_size" : "253952" ,
275275 "menu.cpu.atmega2560.upload.protocol" : "wiring" ,
276276 "menu.cpu.atmega2560.upload.speed" : "115200" ,
277- "name" : "Arduino/Genuino Mega or Mega 2560" ,
278- "pid.0" : "0x0010" ,
279- "pid.1" : "0x0042" ,
280- "pid.2" : "0x0010" ,
281- "pid.3" : "0x0042" ,
282- "pid.4" : "0x0210" ,
283- "pid.5" : "0x0242" ,
284- "upload.maximum_data_size" : "8192" ,
285- "upload.maximum_size" : "126976" ,
286- "upload.protocol" : "arduino" ,
287- "upload.speed" : "57600" ,
288- "upload.tool" : "avrdude" ,
289- "vid.0" : "0x2341" ,
290- "vid.1" : "0x2341" ,
291- "vid.2" : "0x2A03" ,
292- "vid.3" : "0x2A03" ,
293- "vid.4" : "0x2341" ,
294- "vid.5" : "0x2341" ,
277+ "name" : "Arduino/Genuino Mega or Mega 2560" ,
278+ "pid.0" : "0x0010" ,
279+ "pid.1" : "0x0042" ,
280+ "pid.2" : "0x0010" ,
281+ "pid.3" : "0x0042" ,
282+ "pid.4" : "0x0210" ,
283+ "pid.5" : "0x0242" ,
284+ "upload.maximum_data_size" : "8192" ,
285+ "upload.maximum_size" : "126976" ,
286+ "upload.protocol" : "arduino" ,
287+ "upload.speed" : "57600" ,
288+ "upload.tool" : "avrdude" ,
289+ "vid.0" : "0x2341" ,
290+ "vid.1" : "0x2341" ,
291+ "vid.2" : "0x2A03" ,
292+ "vid.3" : "0x2A03" ,
293+ "vid.4" : "0x2341" ,
294+ "vid.5" : "0x2341" ,
295295 })
296296 conf1280 , err := boardMega .GeneratePropertiesForConfiguration ("cpu=atmega1280" )
297297 require .NoError (t , err , "generating cpu=atmega1280 configuration" )
@@ -331,7 +331,7 @@ func TestBoardOptions(t *testing.T) {
331331 "upload.tool" : "micronucleus" ,
332332 "upload.use_1200bps_touch" : "false" ,
333333 "upload.wait_for_upload_port" : "false" ,
334- "vid.0" : "0x16D0" ,
334+ "vid.0" : "0x16D0" ,
335335 })
336336 confWatterott , err := boardWatterottTiny841 .GeneratePropertiesForConfiguration ("core=spencekonde,info=info" )
337337 require .NoError (t , err , "generating core=spencekonde,info=info configuration" )
0 commit comments