From c2a003047377b7356c156afb2fecbf2715a0e012 Mon Sep 17 00:00:00 2001 From: Paul Brook Date: Mon, 2 Sep 2013 18:58:28 +0100 Subject: USB serial baud arg type Make USB Serial_::begin() function take an unsigned long argument for consistency with HardwareSerial. Signed-off-by: Paul Brook --- cores/arduino/CDC.cpp | 2 +- cores/arduino/USBAPI.h | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cores/arduino/CDC.cpp b/cores/arduino/CDC.cpp index 701e483..53f86f8 100644 --- a/cores/arduino/CDC.cpp +++ b/cores/arduino/CDC.cpp @@ -130,7 +130,7 @@ bool WEAK CDC_Setup(Setup& setup) int _serialPeek = -1; -void Serial_::begin(uint16_t baud_count) +void Serial_::begin(unsigned long baud_count) { } diff --git a/cores/arduino/USBAPI.h b/cores/arduino/USBAPI.h index eb2e593..d138a0e 100644 --- a/cores/arduino/USBAPI.h +++ b/cores/arduino/USBAPI.h @@ -30,7 +30,7 @@ class Serial_ : public Stream private: ring_buffer *_cdc_rx_buffer; public: - void begin(uint16_t baud_count); + void begin(unsigned long); void end(void); virtual int available(void); @@ -193,4 +193,4 @@ void USB_Flush(uint8_t ep); #endif -#endif /* if defined(USBCON) */ \ No newline at end of file +#endif /* if defined(USBCON) */ -- cgit v1.2.3-18-g5258 From 0ade989a2d6b8408483902533270435d3cb155a4 Mon Sep 17 00:00:00 2001 From: Paul Brook Date: Mon, 2 Sep 2013 19:15:12 +0100 Subject: USB CDC two argument begin() Add two argument form of Serial_::begin Signed-off-by: Paul Brook --- cores/arduino/CDC.cpp | 4 ++++ cores/arduino/USBAPI.h | 1 + 2 files changed, 5 insertions(+) diff --git a/cores/arduino/CDC.cpp b/cores/arduino/CDC.cpp index 53f86f8..e1e859d 100644 --- a/cores/arduino/CDC.cpp +++ b/cores/arduino/CDC.cpp @@ -134,6 +134,10 @@ void Serial_::begin(unsigned long baud_count) { } +void Serial_::begin(unsigned long baud_count, byte config) +{ +} + void Serial_::end(void) { } diff --git a/cores/arduino/USBAPI.h b/cores/arduino/USBAPI.h index d138a0e..7a14285 100644 --- a/cores/arduino/USBAPI.h +++ b/cores/arduino/USBAPI.h @@ -31,6 +31,7 @@ private: ring_buffer *_cdc_rx_buffer; public: void begin(unsigned long); + void begin(unsigned long, uint8_t); void end(void); virtual int available(void); -- cgit v1.2.3-18-g5258 From 452387a184a9f2697cef46df66d8bea882b43f14 Mon Sep 17 00:00:00 2001 From: Cristian Maglie Date: Fri, 13 Sep 2013 20:05:38 +0200 Subject: Fix wrong 'maximum_data_size' key in boards.txt --- boards.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/boards.txt b/boards.txt index ee4818f..393710b 100644 --- a/boards.txt +++ b/boards.txt @@ -649,7 +649,7 @@ robotControl.name=Arduino Robot Control robotControl.upload.tool=avrdude robotControl.upload.protocol=avr109 robotControl.upload.maximum_size=28672 -robotControl.upload.data_size=2560 +robotControl.upload.maximum_data_size=2560 robotControl.upload.speed=57600 robotControl.upload.disable_flushing=true robotControl.upload.use_1200bps_touch=true @@ -679,7 +679,7 @@ robotMotor.name=Arduino Robot Motor robotMotor.upload.tool=avrdude robotMotor.upload.protocol=avr109 robotMotor.upload.maximum_size=28672 -robotMotor.upload.data_size=2560 +robotMotor.upload.maximum_data_size=2560 robotMotor.upload.speed=57600 robotMotor.upload.disable_flushing=true robotMotor.upload.use_1200bps_touch=true -- cgit v1.2.3-18-g5258 From b018e810efbfd5973a0cfba08284248ba1521367 Mon Sep 17 00:00:00 2001 From: Federico Fissore Date: Wed, 25 Sep 2013 17:25:31 +0200 Subject: boards.txt: fixed wrong extended fuses when using external programmer with a yun --- boards.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/boards.txt b/boards.txt index 393710b..9c8f558 100644 --- a/boards.txt +++ b/boards.txt @@ -23,7 +23,7 @@ yun.upload.wait_for_upload_port=true yun.bootloader.tool=avrdude yun.bootloader.low_fuses=0xff yun.bootloader.high_fuses=0xd8 -yun.bootloader.extended_fuses=0xcb +yun.bootloader.extended_fuses=0xfb yun.bootloader.file=caterina/Caterina-Yun.hex yun.bootloader.unlock_bits=0x3F yun.bootloader.lock_bits=0x2F -- cgit v1.2.3-18-g5258 From 7aea84e42f40d1aabbc56f6e1f5f9c525e07e002 Mon Sep 17 00:00:00 2001 From: Federico Fissore Date: Fri, 27 Sep 2013 18:18:51 +0200 Subject: Removed wrong executable flag on many files --- bootloaders/caterina-LilyPadUSB/Caterina-LilyPadUSB.hex | 0 1 file changed, 0 insertions(+), 0 deletions(-) mode change 100755 => 100644 bootloaders/caterina-LilyPadUSB/Caterina-LilyPadUSB.hex diff --git a/bootloaders/caterina-LilyPadUSB/Caterina-LilyPadUSB.hex b/bootloaders/caterina-LilyPadUSB/Caterina-LilyPadUSB.hex old mode 100755 new mode 100644 -- cgit v1.2.3-18-g5258 From acc20676276dd3a59c2f71da87cc8029b9f2a241 Mon Sep 17 00:00:00 2001 From: Federico Fissore Date: Mon, 30 Sep 2013 10:07:03 +0200 Subject: Added yun variant with LED_BUILTIN definition. Closes #1585 --- boards.txt | 2 +- variants/yun/pins_arduino.h | 27 +++++++++++++++++++++++++++ 2 files changed, 28 insertions(+), 1 deletion(-) create mode 100644 variants/yun/pins_arduino.h diff --git a/boards.txt b/boards.txt index 9c8f558..2181292 100644 --- a/boards.txt +++ b/boards.txt @@ -35,7 +35,7 @@ yun.build.pid=0x8041 yun.build.usb_product="Arduino Yun" yun.build.board=AVR_YUN yun.build.core=arduino -yun.build.variant=leonardo +yun.build.variant=yun yun.build.extra_flags={build.usb_flags} ############################################################## diff --git a/variants/yun/pins_arduino.h b/variants/yun/pins_arduino.h new file mode 100644 index 0000000..43912e7 --- /dev/null +++ b/variants/yun/pins_arduino.h @@ -0,0 +1,27 @@ +/* + pins_arduino.h - Pin definition functions for Arduino + Part of Arduino - http://www.arduino.cc/ + + Copyright (c) 2013 Arduino LLC + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General + Public License along with this library; if not, write to the + Free Software Foundation, Inc., 59 Temple Place, Suite 330, + Boston, MA 02111-1307 USA + + $Id: wiring.h 249 2007-02-03 16:52:51Z mellis $ +*/ + +#include "../leonardo/pins_arduino.h" + +#define LED_BUILTIN 13 -- cgit v1.2.3-18-g5258 From df7828d082fa7925be5de4c0d6828c61b7905575 Mon Sep 17 00:00:00 2001 From: Kristian Sloth Lauszus Date: Thu, 3 Oct 2013 20:32:28 +0200 Subject: Split Arduino ADK into separate board --- boards.txt | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/boards.txt b/boards.txt index 2181292..7324849 100644 --- a/boards.txt +++ b/boards.txt @@ -210,6 +210,35 @@ mega.build.variant=mega ############################################################## +megaADK.name=Arduino Mega ADK + +megaADK.vid.0=0x2341 +megaADK.pid.0=0x003f +megaADK.vid.1=0x2341 +megaADK.pid.1=0x0044 + +megaADK.upload.tool=avrdude +megaADK.upload.protocol=wiring +megaADK.upload.maximum_size=258048 +megaADK.upload.maximum_data_size=8192 +megaADK.upload.speed=115200 + +megaADK.bootloader.tool=avrdude +megaADK.bootloader.low_fuses=0xFF +megaADK.bootloader.high_fuses=0xD8 +megaADK.bootloader.extended_fuses=0xFD +megaADK.bootloader.file=stk500v2/stk500boot_v2_mega2560.hex +megaADK.bootloader.unlock_bits=0x3F +megaADK.bootloader.lock_bits=0x0F + +megaADK.build.mcu=atmega2560 +megaADK.build.f_cpu=16000000L +megaADK.build.board=AVR_ADK +megaADK.build.core=arduino +megaADK.build.variant=mega + +############################################################## + leonardo.name=Arduino Leonardo leonardo.vid.0=0x2341 leonardo.pid.0=0x0036 -- cgit v1.2.3-18-g5258 From 3f7d86a77933428f20004ed01780c317d5984e67 Mon Sep 17 00:00:00 2001 From: Kristian Sloth Lauszus Date: Thu, 3 Oct 2013 20:36:25 +0200 Subject: Combine Mega and Mega 2560 --- boards.txt | 75 ++++++++++++++++++++++++++++++-------------------------------- 1 file changed, 36 insertions(+), 39 deletions(-) diff --git a/boards.txt b/boards.txt index 7324849..6c4e517 100644 --- a/boards.txt +++ b/boards.txt @@ -156,58 +156,55 @@ nano.menu.cpu.atmega168.build.mcu=atmega168 ############################################################## -mega2560.name=Arduino Mega 2560 or Mega ADK -mega2560.vid.0=0x2341 -mega2560.pid.0=0x0044 -mega2560.vid.1=0x2341 -mega2560.pid.1=0x003f -mega2560.cpu=2560 or ADK - -mega2560.upload.tool=avrdude -mega2560.upload.protocol=wiring -mega2560.upload.maximum_size=258048 -mega2560.upload.maximum_data_size=8192 -mega2560.upload.speed=115200 - -mega2560.bootloader.tool=avrdude -mega2560.bootloader.low_fuses=0xFF -mega2560.bootloader.high_fuses=0xD8 -mega2560.bootloader.extended_fuses=0xFD -mega2560.bootloader.file=stk500v2/stk500boot_v2_mega2560.hex -mega2560.bootloader.unlock_bits=0x3F -mega2560.bootloader.lock_bits=0x0F - -mega2560.build.mcu=atmega2560 -mega2560.build.f_cpu=16000000L -mega2560.build.board=AVR_MEGA2560 -mega2560.build.core=arduino -mega2560.build.variant=mega - -############################################################## - -mega.name=Arduino Mega (ATmega1280) -mega.cpu=ATmega1280 +mega.name=Arduino Mega mega.upload.tool=avrdude -mega.upload.protocol=arduino -mega.upload.maximum_size=126976 mega.upload.maximum_data_size=8192 -mega.upload.speed=57600 mega.bootloader.tool=avrdude mega.bootloader.low_fuses=0xFF -mega.bootloader.high_fuses=0xDA -mega.bootloader.extended_fuses=0xF5 -mega.bootloader.file=atmega/ATmegaBOOT_168_atmega1280.hex mega.bootloader.unlock_bits=0x3F mega.bootloader.lock_bits=0x0F -mega.build.mcu=atmega1280 mega.build.f_cpu=16000000L -mega.build.board=AVR_MEGA mega.build.core=arduino mega.build.variant=mega +## Arduino Mega w/ ATmega2560 +## ------------------------- +mega.menu.cpu.atmega2560=ATmega2560 (Mega 2560) + +mega.menu.cpu.atmega2560.vid.0=0x2341 +mega.menu.cpu.atmega2560.pid.0=0x0010 +mega.menu.cpu.atmega2560.vid.1=0x2341 +mega.menu.cpu.atmega2560.pid.1=0x0042 + +mega.menu.cpu.atmega2560.upload.protocol=wiring +mega.menu.cpu.atmega2560.upload.maximum_size=258048 +mega.menu.cpu.atmega2560.upload.speed=115200 + +mega.menu.cpu.atmega2560.bootloader.high_fuses=0xD8 +mega.menu.cpu.atmega2560.bootloader.extended_fuses=0xFD +mega.menu.cpu.atmega2560.bootloader.file=stk500v2/stk500boot_v2_mega2560.hex + +mega.menu.cpu.atmega2560.build.mcu=atmega2560 +mega.menu.cpu.atmega2560.build.board=AVR_MEGA2560 + +## Arduino Mega w/ ATmega1280 +## ------------------------- +mega.menu.cpu.atmega1280=ATmega1280 + +mega.menu.cpu.atmega1280.upload.protocol=arduino +mega.menu.cpu.atmega1280.upload.maximum_size=126976 +mega.menu.cpu.atmega1280.upload.speed=57600 + +mega.menu.cpu.atmega1280.bootloader.high_fuses=0xDA +mega.menu.cpu.atmega1280.bootloader.extended_fuses=0xF5 +mega.menu.cpu.atmega1280.bootloader.file=atmega/ATmegaBOOT_168_atmega1280.hex + +mega.menu.cpu.atmega1280.build.mcu=atmega1280 +mega.menu.cpu.atmega1280.build.board=AVR_MEGA + ############################################################## megaADK.name=Arduino Mega ADK -- cgit v1.2.3-18-g5258 From d27087455d338fcffe0719c14d87f18268a085db Mon Sep 17 00:00:00 2001 From: Cristian Maglie Date: Wed, 9 Oct 2013 16:55:47 +0200 Subject: Small fixes to avr/boards.txt: - adjusted Mega board name - moved pid/vid to the proper place - defined default build.board prop (so the IDE stops warning about that) See #1605 --- boards.txt | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/boards.txt b/boards.txt index 6c4e517..bd6c3ae 100644 --- a/boards.txt +++ b/boards.txt @@ -156,7 +156,12 @@ nano.menu.cpu.atmega168.build.mcu=atmega168 ############################################################## -mega.name=Arduino Mega +mega.name=Arduino Mega or Mega 2560 + +mega.vid.0=0x2341 +mega.pid.0=0x0010 +mega.vid.1=0x2341 +mega.pid.1=0x0042 mega.upload.tool=avrdude mega.upload.maximum_data_size=8192 @@ -169,16 +174,13 @@ mega.bootloader.lock_bits=0x0F mega.build.f_cpu=16000000L mega.build.core=arduino mega.build.variant=mega +# default board may be overridden by the cpu menu +mega.build.board=AVR_MEGA2560 ## Arduino Mega w/ ATmega2560 ## ------------------------- mega.menu.cpu.atmega2560=ATmega2560 (Mega 2560) -mega.menu.cpu.atmega2560.vid.0=0x2341 -mega.menu.cpu.atmega2560.pid.0=0x0010 -mega.menu.cpu.atmega2560.vid.1=0x2341 -mega.menu.cpu.atmega2560.pid.1=0x0042 - mega.menu.cpu.atmega2560.upload.protocol=wiring mega.menu.cpu.atmega2560.upload.maximum_size=258048 mega.menu.cpu.atmega2560.upload.speed=115200 -- cgit v1.2.3-18-g5258