From 89acc339e0d413d882be6efbeb62aada89043586 Mon Sep 17 00:00:00 2001 From: Khoi Hoang <57012152+khoih-prog@users.noreply.github.com> Date: Wed, 9 Nov 2022 23:44:57 -0500 Subject: [PATCH] Update `Packages' Patches` --- .../hardware/samd/1.8.0/boards.txt | 1730 ++++++++++++++++ .../hardware/samd/1.9.0/boards.txt | 1751 +++++++++++++++++ .../k210/0.3.10/cores/arduino/Stream.h | 226 +-- .../k210/0.3.11/cores/arduino/Stream.h | 226 +-- .../1.9.0/variants/NUCLEO_F767ZI/variant.h | 40 +- .../1.9.0/variants/NUCLEO_L053R8/variant.h | 40 +- .../variant_NUCLEO_F767ZI.h | 68 +- .../L052R(6-8)H_L053R(6-8)H/variant_generic.h | 80 +- .../variant_NUCLEO_F767ZI.h | 68 +- .../variant_generic.h | 80 +- .../variant_NUCLEO_F767ZI.h | 68 +- .../variant_generic.h | 80 +- .../variant_NUCLEO_F767ZI.h | 68 +- .../variant_generic.h | 80 +- .../variant_NUCLEO_F767ZI.h | 68 +- .../variant_generic.h | 80 +- .../hardware/nrf52/1.0.0/cores/nRF5/Print.cpp | 458 ++--- .../hardware/nrf52/1.0.0/cores/nRF5/Print.h | 174 +- .../hardware/nrf52/1.0.0/cores/nRF5/Udp.h | 107 +- .../variants/Seeed_XIAO_RP2040/pins_arduino.h | 2 +- .../Seeeduino/hardware/samd/1.7.0/boards.txt | 1730 ++++++++++++++++ .../samd/1.7.7/cores/arduino/Arduino.h | 40 +- .../samd/1.7.7/cores/arduino/Print.cpp | 458 ++--- .../hardware/samd/1.7.7/cores/arduino/Print.h | 175 +- .../samd/1.7.8/cores/arduino/Arduino.h | 40 +- .../samd/1.7.8/cores/arduino/Print.cpp | 458 ++--- .../hardware/samd/1.7.8/cores/arduino/Print.h | 175 +- .../samd/1.7.9/cores/arduino/Arduino.h | 40 +- .../samd/1.7.9/cores/arduino/Print.cpp | 458 ++--- .../hardware/samd/1.7.9/cores/arduino/Print.h | 175 +- .../samd/1.8.1/cores/arduino/Arduino.h | 40 +- .../samd/1.8.1/cores/arduino/Print.cpp | 458 ++--- .../hardware/samd/1.8.1/cores/arduino/Print.h | 174 +- .../samd/1.8.2/cores/arduino/Arduino.h | 40 +- .../samd/1.8.2/cores/arduino/Print.cpp | 458 ++--- .../hardware/samd/1.8.2/cores/arduino/Print.h | 174 +- .../samd/1.8.3/cores/arduino/Arduino.h | 40 +- .../samd/1.8.3/cores/arduino/Print.cpp | 458 ++--- .../hardware/samd/1.8.3/cores/arduino/Print.h | 174 +- .../samd/1.8.3/cores/arduino/Print.cpp | 458 ++--- .../hardware/samd/1.8.3/cores/arduino/Print.h | 174 +- .../samd/1.8.3/cores/arduino51/Print.cpp | 458 ++--- .../samd/1.8.3/cores/arduino51/Print.h | 174 +- .../teensy/avr/cores/teensy/Stream.cpp | 482 ++--- .../hardware/teensy/avr/cores/teensy/Stream.h | 232 +-- .../teensy/avr/cores/teensy3/Stream.cpp | 482 ++--- .../teensy/avr/cores/teensy3/Stream.h | 232 +-- .../teensy/avr/cores/teensy4/Stream.cpp | 482 ++--- .../teensy/avr/cores/teensy4/Stream.h | 232 +-- .../avr/1.1.36/cores/industrialshields/Udp.h | 93 +- .../avr/1.1.37/cores/industrialshields/Udp.h | 93 +- .../rp2040/1.3.1/cores/rp2040/Arduino.h | 2 +- .../rp2040/1.4.0/cores/rp2040/Arduino.h | 2 +- 53 files changed, 10035 insertions(+), 4820 deletions(-) create mode 100644 Packages_Patches/Fab_SAM_Arduino/hardware/samd/1.8.0/boards.txt create mode 100644 Packages_Patches/Fab_SAM_Arduino/hardware/samd/1.9.0/boards.txt create mode 100644 Packages_Patches/Seeeduino/hardware/samd/1.7.0/boards.txt diff --git a/Packages_Patches/Fab_SAM_Arduino/hardware/samd/1.8.0/boards.txt b/Packages_Patches/Fab_SAM_Arduino/hardware/samd/1.8.0/boards.txt new file mode 100644 index 00000000..ec3f9ff3 --- /dev/null +++ b/Packages_Patches/Fab_SAM_Arduino/hardware/samd/1.8.0/boards.txt @@ -0,0 +1,1730 @@ +# Copyright (c) 2014-2017 Arduino LLC. All right reserved. +# +# 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + +menu.cpu=Microcontroller +menu.clock=Clock Source +menu.usb=USB Config +menu.serial=Serial Config +menu.bootloader=Bootloader Size +menu.timer=Timer PWM Frequency +menu.float=Floating Point +menu.config=Build Options + +# Generic D11C14A +d11c14a.name=Generic D11C14A +d11c14a.vid.0=0x16D0 +d11c14a.pid.0=0x1557 +d11c14a.vid.1=0x16D0 +d11c14a.pid.1=0x1856 +d11c14a.vid.2=0x16D0 +d11c14a.pid.2=0x1B41 +d11c14a.vid.3=0x16D0 +d11c14a.pid.3=0x1B40 +d11c14a.vid.4=0x16D0 +d11c14a.pid.4=0x1A0C +d11c14a.vid.5=0x16D0 +d11c14a.pid.5=0x1856 +d11c14a.build.mcu=cortex-m0plus +d11c14a.build.mathlib=arm_cortexM0l_math +d11c14a.build.f_cpu=48000000L +d11c14a.build.usb_product="D11C14A" +d11c14a.build.usb_manufacturer="Fab Foundation" +d11c14a.build.board=SAMD_ZERO +d11c14a.build.core=arduino +d11c14a.build.variant=Generic_D11C14A +d11c14a.build.variant_system_lib= +d11c14a.build.vid=0x16D0 +d11c14a.upload.protocol=sam-ba +d11c14a.bootloader.tool=openocd +d11c14a.menu.float.default=Print & String use auto-promoted doubles only +d11c14a.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +d11c14a.menu.float.print=Print uses separate singles and doubles +d11c14a.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +d11c14a.menu.float.string=String uses separate singles and doubles +d11c14a.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +d11c14a.menu.float.both=Print & String use separate singles and doubles +d11c14a.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +d11c14a.menu.config.disabled=config.h disabled +d11c14a.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +d11c14a.menu.config.enabled=config.h enabled (mostly code size reductions) +d11c14a.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +d11c14a.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +d11c14a.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +d11c14a.menu.clock.internal=INTERNAL_OSCILLATOR +d11c14a.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +d11c14a.menu.clock.crystal_32k=32KHZ_CRYSTAL +d11c14a.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +d11c14a.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +d11c14a.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +d11c14a.menu.timer.timer_732Hz=732.4Hz (16-bit) +d11c14a.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +d11c14a.menu.timer.timer_366Hz=366.2Hz (16-bit) +d11c14a.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +d11c14a.menu.timer.timer_244Hz=244.1Hz (16-bit) +d11c14a.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +d11c14a.menu.timer.timer_183Hz=183.1Hz (16-bit) +d11c14a.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +d11c14a.menu.timer.timer_146Hz=146.5Hz (16-bit) +d11c14a.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +d11c14a.menu.timer.timer_122Hz=122.1Hz (16-bit) +d11c14a.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +d11c14a.menu.timer.timer_105Hz=104.6Hz (16-bit) +d11c14a.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +d11c14a.menu.timer.timer_81Hz=81.38Hz (16-bit) +d11c14a.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +d11c14a.menu.timer.timer_61Hz=61.04Hz (16-bit) +d11c14a.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +d11c14a.menu.timer.timer_31Hz=30.52Hz (16-bit) +d11c14a.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +d11c14a.menu.timer.timer_187500Hz=187500Hz (8-bit) +d11c14a.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +d11c14a.menu.timer.timer_93750Hz=93750Hz (8-bit) +d11c14a.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +d11c14a.menu.timer.timer_62500Hz=62500Hz (8-bit) +d11c14a.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +d11c14a.menu.timer.timer_37500Hz=37500Hz (8-bit) +d11c14a.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +d11c14a.menu.timer.timer_20833Hz=20833Hz (8-bit) +d11c14a.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +d11c14a.menu.timer.timer_12500Hz=12500Hz (8-bit) +d11c14a.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +d11c14a.menu.timer.timer_7500Hz=7500Hz (8-bit) +d11c14a.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +d11c14a.menu.timer.timer_4166Hz=4166Hz (8-bit) +d11c14a.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +d11c14a.menu.timer.timer_2930Hz=2930Hz (8-bit) +d11c14a.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +d11c14a.menu.timer.timer_1465Hz=1465Hz (8-bit) +d11c14a.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +d11c14a.build.extra_flags=-D__SAMD11C14A__ {build.usb_flags} -DARM_MATH_CM0PLUS +d11c14a.build.ldscript=flash_16KB.ld +d11c14a.build.openocdscript=openocd_scripts/SAMD11C14A.cfg +d11c14a.bootloader.file=zero/binaries/sam_ba_SAMD11C14A.bin +d11c14a.menu.bootloader.4kb=4KB_BOOTLOADER +d11c14a.menu.bootloader.4kb.build.bootloader_size=__4KB_BOOTLOADER__ +d11c14a.menu.bootloader.4kb.build.ldscript_path=linker_scripts/gcc/4KB_Bootloader +d11c14a.menu.bootloader.4kb.upload.tool=Fab_SAM_Arduino:bossac +d11c14a.menu.bootloader.4kb.upload.use_1200bps_touch=true +d11c14a.menu.bootloader.4kb.upload.wait_for_upload_port=true +d11c14a.menu.bootloader.4kb.upload.native_usb=true +d11c14a.menu.bootloader.4kb.upload.maximum_size=12288 +d11c14a.menu.bootloader.0kb=NO_BOOTLOADER +d11c14a.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +d11c14a.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +d11c14a.menu.bootloader.0kb.upload.tool=openocd +d11c14a.menu.bootloader.0kb.upload.use_1200bps_touch=false +d11c14a.menu.bootloader.0kb.upload.wait_for_upload_port=false +d11c14a.menu.bootloader.0kb.upload.native_usb=false +d11c14a.menu.bootloader.0kb.upload.maximum_size=16384 +d11c14a.menu.serial.one_uart=ONE_UART_ONE_WIRE_NO_SPI +d11c14a.menu.serial.one_uart.build.serialcom_uart=ONE_UART +d11c14a.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +d11c14a.menu.serial.one_uart.build.serialcom_spi=NO_SPI +d11c14a.menu.serial.two_uart=TWO_UART_NO_WIRE_NO_SPI +d11c14a.menu.serial.two_uart.build.serialcom_uart=TWO_UART +d11c14a.menu.serial.two_uart.build.serialcom_wire=NO_WIRE +d11c14a.menu.serial.two_uart.build.serialcom_spi=NO_SPI +d11c14a.menu.serial.one_uart_no_wire_one_spi=ONE_UART_NO_WIRE_ONE_SPI +d11c14a.menu.serial.one_uart_no_wire_one_spi.build.serialcom_uart=ONE_UART +d11c14a.menu.serial.one_uart_no_wire_one_spi.build.serialcom_wire=NO_WIRE +d11c14a.menu.serial.one_uart_no_wire_one_spi.build.serialcom_spi=ONE_SPI +d11c14a.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +d11c14a.menu.serial.no_uart.build.serialcom_uart=NO_UART +d11c14a.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +d11c14a.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +d11c14a.menu.usb.cdc=CDC_ONLY +d11c14a.menu.usb.cdc.build.usbcom=CDC_ONLY +d11c14a.menu.usb.cdc.build.pid=0x1557 +d11c14a.menu.usb.cdc_hid=CDC_HID +d11c14a.menu.usb.cdc_hid.build.usbcom=CDC_HID +d11c14a.menu.usb.cdc_hid.build.pid=0x1856 +d11c14a.menu.usb.withcdc=WITH_CDC +d11c14a.menu.usb.withcdc.build.usbcom=WITH_CDC +d11c14a.menu.usb.withcdc.build.pid=0x1B41 +d11c14a.menu.usb.hid=HID_ONLY +d11c14a.menu.usb.hid.build.usbcom=HID_ONLY +d11c14a.menu.usb.hid.build.pid=0x1B40 +d11c14a.menu.usb.nocdc=WITHOUT_CDC +d11c14a.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +d11c14a.menu.usb.nocdc.build.pid=0x1A0C +d11c14a.menu.usb.none=USB_DISABLED +d11c14a.menu.usb.none.build.usbcom=USB_DISABLED +d11c14a.menu.usb.none.build.pid=0x1856 + +# Generic D11D14AS +d11d14as.name=Generic D11D14AS +d11d14as.vid.0=0x16D0 +d11d14as.pid.0=0x2557 +d11d14as.vid.1=0x16D0 +d11d14as.pid.1=0x2856 +d11d14as.vid.2=0x16D0 +d11d14as.pid.2=0x2B41 +d11d14as.vid.3=0x16D0 +d11d14as.pid.3=0x2B40 +d11d14as.vid.4=0x16D0 +d11d14as.pid.4=0x2A0C +d11d14as.vid.5=0x16D0 +d11d14as.pid.5=0x2856 +d11d14as.build.mcu=cortex-m0plus +d11d14as.build.mathlib=arm_cortexM0l_math +d11d14as.build.f_cpu=48000000L +d11d14as.build.usb_product="D11D14AS" +d11d14as.build.usb_manufacturer="Fab Foundation" +d11d14as.build.board=SAMD_ZERO +d11d14as.build.core=arduino +d11d14as.build.variant=Generic_D11D14AS +d11d14as.build.variant_system_lib= +d11d14as.build.vid=0x16D0 +d11d14as.upload.protocol=sam-ba +d11d14as.bootloader.tool=openocd +d11d14as.menu.float.default=Print & String use auto-promoted doubles only +d11d14as.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +d11d14as.menu.float.print=Print uses separate singles and doubles +d11d14as.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +d11d14as.menu.float.string=String uses separate singles and doubles +d11d14as.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +d11d14as.menu.float.both=Print & String use separate singles and doubles +d11d14as.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +d11d14as.menu.config.disabled=config.h disabled +d11d14as.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +d11d14as.menu.config.enabled=config.h enabled (mostly code size reductions) +d11d14as.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +d11d14as.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +d11d14as.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +d11d14as.menu.clock.internal=INTERNAL_OSCILLATOR +d11d14as.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +d11d14as.menu.clock.crystal_32k=32KHZ_CRYSTAL +d11d14as.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +d11d14as.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +d11d14as.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +d11d14as.menu.timer.timer_732Hz=732.4Hz (16-bit) +d11d14as.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +d11d14as.menu.timer.timer_366Hz=366.2Hz (16-bit) +d11d14as.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +d11d14as.menu.timer.timer_244Hz=244.1Hz (16-bit) +d11d14as.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +d11d14as.menu.timer.timer_183Hz=183.1Hz (16-bit) +d11d14as.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +d11d14as.menu.timer.timer_146Hz=146.5Hz (16-bit) +d11d14as.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +d11d14as.menu.timer.timer_122Hz=122.1Hz (16-bit) +d11d14as.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +d11d14as.menu.timer.timer_105Hz=104.6Hz (16-bit) +d11d14as.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +d11d14as.menu.timer.timer_81Hz=81.38Hz (16-bit) +d11d14as.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +d11d14as.menu.timer.timer_61Hz=61.04Hz (16-bit) +d11d14as.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +d11d14as.menu.timer.timer_31Hz=30.52Hz (16-bit) +d11d14as.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +d11d14as.menu.timer.timer_187500Hz=187500Hz (8-bit) +d11d14as.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +d11d14as.menu.timer.timer_93750Hz=93750Hz (8-bit) +d11d14as.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +d11d14as.menu.timer.timer_62500Hz=62500Hz (8-bit) +d11d14as.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +d11d14as.menu.timer.timer_37500Hz=37500Hz (8-bit) +d11d14as.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +d11d14as.menu.timer.timer_20833Hz=20833Hz (8-bit) +d11d14as.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +d11d14as.menu.timer.timer_12500Hz=12500Hz (8-bit) +d11d14as.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +d11d14as.menu.timer.timer_7500Hz=7500Hz (8-bit) +d11d14as.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +d11d14as.menu.timer.timer_4166Hz=4166Hz (8-bit) +d11d14as.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +d11d14as.menu.timer.timer_2930Hz=2930Hz (8-bit) +d11d14as.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +d11d14as.menu.timer.timer_1465Hz=1465Hz (8-bit) +d11d14as.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +d11d14as.build.extra_flags=-D__SAMD11D14AS__ {build.usb_flags} -DARM_MATH_CM0PLUS +d11d14as.build.ldscript=flash_16KB.ld +d11d14as.build.openocdscript=openocd_scripts/SAMD11D14AS.cfg +d11d14as.bootloader.file=zero/binaries/sam_ba_SAMD11D14AS.bin +d11d14as.menu.bootloader.4kb=4KB_BOOTLOADER +d11d14as.menu.bootloader.4kb.build.bootloader_size=__4KB_BOOTLOADER__ +d11d14as.menu.bootloader.4kb.build.ldscript_path=linker_scripts/gcc/4KB_Bootloader +d11d14as.menu.bootloader.4kb.upload.tool=Fab_SAM_Arduino:bossac +d11d14as.menu.bootloader.4kb.upload.use_1200bps_touch=true +d11d14as.menu.bootloader.4kb.upload.wait_for_upload_port=true +d11d14as.menu.bootloader.4kb.upload.native_usb=true +d11d14as.menu.bootloader.4kb.upload.maximum_size=12288 +d11d14as.menu.bootloader.0kb=NO_BOOTLOADER +d11d14as.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +d11d14as.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +d11d14as.menu.bootloader.0kb.upload.tool=openocd +d11d14as.menu.bootloader.0kb.upload.use_1200bps_touch=false +d11d14as.menu.bootloader.0kb.upload.wait_for_upload_port=false +d11d14as.menu.bootloader.0kb.upload.native_usb=false +d11d14as.menu.bootloader.0kb.upload.maximum_size=16384 +d11d14as.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +d11d14as.menu.serial.one_uart.build.serialcom_uart=ONE_UART +d11d14as.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +d11d14as.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +d11d14as.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +d11d14as.menu.serial.no_uart.build.serialcom_uart=NO_UART +d11d14as.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +d11d14as.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +d11d14as.menu.serial.two_uart=TWO_UART_ONE_WIRE_NO_SPI +d11d14as.menu.serial.two_uart.build.serialcom_uart=TWO_UART +d11d14as.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +d11d14as.menu.serial.two_uart.build.serialcom_spi=NO_SPI +d11d14as.menu.usb.cdc=CDC_ONLY +d11d14as.menu.usb.cdc.build.usbcom=CDC_ONLY +d11d14as.menu.usb.cdc.build.pid=0x2557 +d11d14as.menu.usb.cdc_hid=CDC_HID +d11d14as.menu.usb.cdc_hid.build.usbcom=CDC_HID +d11d14as.menu.usb.cdc_hid.build.pid=0x2856 +d11d14as.menu.usb.withcdc=WITH_CDC +d11d14as.menu.usb.withcdc.build.usbcom=WITH_CDC +d11d14as.menu.usb.withcdc.build.pid=0x2B41 +d11d14as.menu.usb.hid=HID_ONLY +d11d14as.menu.usb.hid.build.usbcom=HID_ONLY +d11d14as.menu.usb.hid.build.pid=0x2B40 +d11d14as.menu.usb.nocdc=WITHOUT_CDC +d11d14as.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +d11d14as.menu.usb.nocdc.build.pid=0x2A0C +d11d14as.menu.usb.none=USB_DISABLED +d11d14as.menu.usb.none.build.usbcom=USB_DISABLED +d11d14as.menu.usb.none.build.pid=0x2856 + +# Generic D11D14AM +d11d14am.name=Generic D11D14AM +d11d14am.vid.0=0x16D0 +d11d14am.pid.0=0x3557 +d11d14am.vid.1=0x16D0 +d11d14am.pid.1=0x3856 +d11d14am.vid.2=0x16D0 +d11d14am.pid.2=0x3B41 +d11d14am.vid.3=0x16D0 +d11d14am.pid.3=0x3B40 +d11d14am.vid.4=0x16D0 +d11d14am.pid.4=0x3A0C +d11d14am.vid.5=0x16D0 +d11d14am.pid.5=0x3856 +d11d14am.build.mcu=cortex-m0plus +d11d14am.build.mathlib=arm_cortexM0l_math +d11d14am.build.f_cpu=48000000L +d11d14am.build.usb_product="MT-D11" +d11d14am.build.usb_manufacturer="Fab Foundation" +d11d14am.build.board=SAMD_ZERO +d11d14am.build.core=arduino +d11d14am.build.variant=Generic_D11D14AM +d11d14am.build.variant_system_lib= +d11d14am.build.vid=0x16D0 +d11d14am.upload.protocol=sam-ba +d11d14am.bootloader.tool=openocd +d11d14am.menu.float.default=Print & String use auto-promoted doubles only +d11d14am.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +d11d14am.menu.float.print=Print uses separate singles and doubles +d11d14am.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +d11d14am.menu.float.string=String uses separate singles and doubles +d11d14am.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +d11d14am.menu.float.both=Print & String use separate singles and doubles +d11d14am.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +d11d14am.menu.config.disabled=config.h disabled +d11d14am.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +d11d14am.menu.config.enabled=config.h enabled (mostly code size reductions) +d11d14am.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +d11d14am.menu.clock.crystal_32k=32KHZ_CRYSTAL +d11d14am.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +d11d14am.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +d11d14am.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +d11d14am.menu.clock.internal=INTERNAL_OSCILLATOR +d11d14am.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +d11d14am.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +d11d14am.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +d11d14am.menu.timer.timer_732Hz=732.4Hz (16-bit) +d11d14am.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +d11d14am.menu.timer.timer_366Hz=366.2Hz (16-bit) +d11d14am.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +d11d14am.menu.timer.timer_244Hz=244.1Hz (16-bit) +d11d14am.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +d11d14am.menu.timer.timer_183Hz=183.1Hz (16-bit) +d11d14am.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +d11d14am.menu.timer.timer_146Hz=146.5Hz (16-bit) +d11d14am.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +d11d14am.menu.timer.timer_122Hz=122.1Hz (16-bit) +d11d14am.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +d11d14am.menu.timer.timer_105Hz=104.6Hz (16-bit) +d11d14am.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +d11d14am.menu.timer.timer_81Hz=81.38Hz (16-bit) +d11d14am.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +d11d14am.menu.timer.timer_61Hz=61.04Hz (16-bit) +d11d14am.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +d11d14am.menu.timer.timer_31Hz=30.52Hz (16-bit) +d11d14am.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +d11d14am.menu.timer.timer_187500Hz=187500Hz (8-bit) +d11d14am.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +d11d14am.menu.timer.timer_93750Hz=93750Hz (8-bit) +d11d14am.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +d11d14am.menu.timer.timer_62500Hz=62500Hz (8-bit) +d11d14am.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +d11d14am.menu.timer.timer_37500Hz=37500Hz (8-bit) +d11d14am.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +d11d14am.menu.timer.timer_20833Hz=20833Hz (8-bit) +d11d14am.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +d11d14am.menu.timer.timer_12500Hz=12500Hz (8-bit) +d11d14am.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +d11d14am.menu.timer.timer_7500Hz=7500Hz (8-bit) +d11d14am.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +d11d14am.menu.timer.timer_4166Hz=4166Hz (8-bit) +d11d14am.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +d11d14am.menu.timer.timer_2930Hz=2930Hz (8-bit) +d11d14am.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +d11d14am.menu.timer.timer_1465Hz=1465Hz (8-bit) +d11d14am.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +d11d14am.build.extra_flags=-D__SAMD11D14AM__ {build.usb_flags} -DARM_MATH_CM0PLUS +d11d14am.build.ldscript=flash_16KB.ld +d11d14am.build.openocdscript=openocd_scripts/SAMD11D14AM.cfg +d11d14am.bootloader.file=zero/binaries/sam_ba_SAMD11D14AM.bin +d11d14am.menu.bootloader.4kb=4KB_BOOTLOADER +d11d14am.menu.bootloader.4kb.build.bootloader_size=__4KB_BOOTLOADER__ +d11d14am.menu.bootloader.4kb.build.ldscript_path=linker_scripts/gcc/4KB_Bootloader +d11d14am.menu.bootloader.4kb.upload.tool=Fab_SAM_Arduino:bossac +d11d14am.menu.bootloader.4kb.upload.use_1200bps_touch=true +d11d14am.menu.bootloader.4kb.upload.wait_for_upload_port=true +d11d14am.menu.bootloader.4kb.upload.native_usb=true +d11d14am.menu.bootloader.4kb.upload.maximum_size=12288 +d11d14am.menu.bootloader.0kb=NO_BOOTLOADER +d11d14am.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +d11d14am.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +d11d14am.menu.bootloader.0kb.upload.tool=openocd +d11d14am.menu.bootloader.0kb.upload.use_1200bps_touch=false +d11d14am.menu.bootloader.0kb.upload.wait_for_upload_port=false +d11d14am.menu.bootloader.0kb.upload.native_usb=false +d11d14am.menu.bootloader.0kb.upload.maximum_size=16384 +d11d14am.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +d11d14am.menu.serial.one_uart.build.serialcom_uart=ONE_UART +d11d14am.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +d11d14am.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +d11d14am.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +d11d14am.menu.serial.no_uart.build.serialcom_uart=NO_UART +d11d14am.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +d11d14am.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +d11d14am.menu.serial.two_uart=TWO_UART_ONE_WIRE_NO_SPI +d11d14am.menu.serial.two_uart.build.serialcom_uart=TWO_UART +d11d14am.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +d11d14am.menu.serial.two_uart.build.serialcom_spi=NO_SPI +d11d14am.menu.usb.cdc=CDC_ONLY +d11d14am.menu.usb.cdc.build.usbcom=CDC_ONLY +d11d14am.menu.usb.cdc.build.pid=0x3557 +d11d14am.menu.usb.cdc_hid=CDC_HID +d11d14am.menu.usb.cdc_hid.build.usbcom=CDC_HID +d11d14am.menu.usb.cdc_hid.build.pid=0x3856 +d11d14am.menu.usb.withcdc=WITH_CDC +d11d14am.menu.usb.withcdc.build.usbcom=WITH_CDC +d11d14am.menu.usb.withcdc.build.pid=0x3B41 +d11d14am.menu.usb.hid=HID_ONLY +d11d14am.menu.usb.hid.build.usbcom=HID_ONLY +d11d14am.menu.usb.hid.build.pid=0x3B40 +d11d14am.menu.usb.nocdc=WITHOUT_CDC +d11d14am.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +d11d14am.menu.usb.nocdc.build.pid=0x3A0C +d11d14am.menu.usb.none=USB_DISABLED +d11d14am.menu.usb.none.build.usbcom=USB_DISABLED +d11d14am.menu.usb.none.build.pid=0x3856 + +# Generic x21E +x21e.name=Generic x21E +x21e.vid.0=0x16D0 +x21e.pid.0=0x4557 +x21e.vid.1=0x16D0 +x21e.pid.1=0x4856 +x21e.vid.2=0x16D0 +x21e.pid.2=0x4B41 +x21e.vid.3=0x16D0 +x21e.pid.3=0x4B40 +x21e.vid.4=0x16D0 +x21e.pid.4=0x4A0C +x21e.vid.5=0x16D0 +x21e.pid.5=0x4856 +x21e.build.mcu=cortex-m0plus +x21e.build.mathlib=arm_cortexM0l_math +x21e.build.f_cpu=48000000L +x21e.build.usb_product="x21E" +x21e.build.usb_manufacturer="Fab Foundation" +x21e.build.board=SAMD_ZERO +x21e.build.core=arduino +x21e.build.variant=Generic_x21E +x21e.build.variant_system_lib= +x21e.build.vid=0x16D0 +x21e.upload.protocol=sam-ba +x21e.bootloader.tool=openocd +x21e.menu.float.default=Print & String use auto-promoted doubles only +x21e.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +x21e.menu.float.print=Print uses separate singles and doubles +x21e.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +x21e.menu.float.string=String uses separate singles and doubles +x21e.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +x21e.menu.float.both=Print & String use separate singles and doubles +x21e.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +x21e.menu.config.disabled=config.h disabled +x21e.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +x21e.menu.config.enabled=config.h enabled (mostly code size reductions) +x21e.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +x21e.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +x21e.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +x21e.menu.clock.internal=INTERNAL_OSCILLATOR +x21e.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +x21e.menu.clock.crystal_32k=32KHZ_CRYSTAL +x21e.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +x21e.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +x21e.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +x21e.menu.timer.timer_732Hz=732.4Hz (16-bit) +x21e.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +x21e.menu.timer.timer_366Hz=366.2Hz (16-bit) +x21e.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +x21e.menu.timer.timer_244Hz=244.1Hz (16-bit) +x21e.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +x21e.menu.timer.timer_183Hz=183.1Hz (16-bit) +x21e.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +x21e.menu.timer.timer_146Hz=146.5Hz (16-bit) +x21e.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +x21e.menu.timer.timer_122Hz=122.1Hz (16-bit) +x21e.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +x21e.menu.timer.timer_105Hz=104.6Hz (16-bit) +x21e.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +x21e.menu.timer.timer_81Hz=81.38Hz (16-bit) +x21e.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +x21e.menu.timer.timer_61Hz=61.04Hz (16-bit) +x21e.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +x21e.menu.timer.timer_31Hz=30.52Hz (16-bit) +x21e.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +x21e.menu.timer.timer_187500Hz=187500Hz (8-bit) +x21e.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +x21e.menu.timer.timer_93750Hz=93750Hz (8-bit) +x21e.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +x21e.menu.timer.timer_62500Hz=62500Hz (8-bit) +x21e.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +x21e.menu.timer.timer_37500Hz=37500Hz (8-bit) +x21e.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +x21e.menu.timer.timer_20833Hz=20833Hz (8-bit) +x21e.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +x21e.menu.timer.timer_12500Hz=12500Hz (8-bit) +x21e.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +x21e.menu.timer.timer_7500Hz=7500Hz (8-bit) +x21e.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +x21e.menu.timer.timer_4166Hz=4166Hz (8-bit) +x21e.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +x21e.menu.timer.timer_2930Hz=2930Hz (8-bit) +x21e.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +x21e.menu.timer.timer_1465Hz=1465Hz (8-bit) +x21e.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +x21e.menu.cpu.samd21e15a=SAMD21E15A +x21e.menu.cpu.samd21e15a.upload.maximum_size=24576 +x21e.menu.cpu.samd21e15a.build.extra_flags=-D__SAMD21E15A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.samd21e15a.build.ldscript=flash_32KB.ld +x21e.menu.cpu.samd21e15a.build.openocdscript=openocd_scripts/SAMD21E15A.cfg +x21e.menu.cpu.samd21e15a.bootloader.file=zero/binaries/sam_ba_SAMD21E15A.bin +x21e.menu.cpu.samd21e16a=SAMD21E16A +x21e.menu.cpu.samd21e16a.upload.maximum_size=57344 +x21e.menu.cpu.samd21e16a.build.extra_flags=-D__SAMD21E16A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.samd21e16a.build.ldscript=flash_64KB.ld +x21e.menu.cpu.samd21e16a.build.openocdscript=openocd_scripts/SAMD21E16A.cfg +x21e.menu.cpu.samd21e16a.bootloader.file=zero/binaries/sam_ba_SAMD21E16A.bin +x21e.menu.cpu.samd21e17a=SAMD21E17A +x21e.menu.cpu.samd21e17a.upload.maximum_size=122880 +x21e.menu.cpu.samd21e17a.build.extra_flags=-D__SAMD21E17A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.samd21e17a.build.ldscript=flash_128KB.ld +x21e.menu.cpu.samd21e17a.build.openocdscript=openocd_scripts/SAMD21E17A.cfg +x21e.menu.cpu.samd21e17a.bootloader.file=zero/binaries/sam_ba_SAMD21E17A.bin +x21e.menu.cpu.samd21e18a=SAMD21E18A +x21e.menu.cpu.samd21e18a.upload.maximum_size=253952 +x21e.menu.cpu.samd21e18a.build.extra_flags=-D__SAMD21E18A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.samd21e18a.build.ldscript=flash_256KB.ld +x21e.menu.cpu.samd21e18a.build.openocdscript=openocd_scripts/SAMD21E18A.cfg +x21e.menu.cpu.samd21e18a.bootloader.file=zero/binaries/sam_ba_SAMD21E18A.bin +x21e.menu.cpu.saml21e15b=SAML21E15B +x21e.menu.cpu.saml21e15b.upload.maximum_size=24576 +x21e.menu.cpu.saml21e15b.build.extra_flags=-D__SAML21E15B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.saml21e15b.build.ldscript=flash_32KB.ld +x21e.menu.cpu.saml21e15b.build.openocdscript=openocd_scripts/SAML21E15B.cfg +x21e.menu.cpu.saml21e15b.bootloader.file=zero/binaries/sam_ba_SAML21E15B.bin +x21e.menu.cpu.saml21e16b=SAML21E16B +x21e.menu.cpu.saml21e16b.upload.maximum_size=57344 +x21e.menu.cpu.saml21e16b.build.extra_flags=-D__SAML21E16B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.saml21e16b.build.ldscript=flash_64KB.ld +x21e.menu.cpu.saml21e16b.build.openocdscript=openocd_scripts/SAML21E16B.cfg +x21e.menu.cpu.saml21e16b.bootloader.file=zero/binaries/sam_ba_SAML21E16B.bin +x21e.menu.cpu.saml21e17b=SAML21E17B +x21e.menu.cpu.saml21e17b.upload.maximum_size=122880 +x21e.menu.cpu.saml21e17b.build.extra_flags=-D__SAML21E17B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.saml21e17b.build.ldscript=flash_128KB.ld +x21e.menu.cpu.saml21e17b.build.openocdscript=openocd_scripts/SAML21E17B.cfg +x21e.menu.cpu.saml21e17b.bootloader.file=zero/binaries/sam_ba_SAML21E17B.bin +x21e.menu.cpu.saml21e18b=SAML21E18B +x21e.menu.cpu.saml21e18b.upload.maximum_size=253952 +x21e.menu.cpu.saml21e18b.build.extra_flags=-D__SAML21E18B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.saml21e18b.build.ldscript=flash_256KB.ld +x21e.menu.cpu.saml21e18b.build.openocdscript=openocd_scripts/SAML21E18B.cfg +x21e.menu.cpu.saml21e18b.bootloader.file=zero/binaries/sam_ba_SAML21E18B.bin +x21e.menu.cpu.samc21e15a=SAMC21E15A +x21e.menu.cpu.samc21e15a.upload.maximum_size=24576 +x21e.menu.cpu.samc21e15a.build.extra_flags=-D__SAMC21E15A__ -DARM_MATH_CM0PLUS +x21e.menu.cpu.samc21e15a.build.ldscript=flash_32KB.ld +x21e.menu.cpu.samc21e15a.build.openocdscript=openocd_scripts/SAMC21E15A.cfg +x21e.menu.cpu.samc21e15a.bootloader.file=zero/binaries/sam_ba_SAMC21E15A.bin +x21e.menu.cpu.samc21e16a=SAMC21E16A +x21e.menu.cpu.samc21e16a.upload.maximum_size=57344 +x21e.menu.cpu.samc21e16a.build.extra_flags=-D__SAMC21E16A__ -DARM_MATH_CM0PLUS +x21e.menu.cpu.samc21e16a.build.ldscript=flash_64KB.ld +x21e.menu.cpu.samc21e16a.build.openocdscript=openocd_scripts/SAMC21E16A.cfg +x21e.menu.cpu.samc21e16a.bootloader.file=zero/binaries/sam_ba_SAMC21E16A.bin +x21e.menu.cpu.samc21e17a=SAMC21E17A +x21e.menu.cpu.samc21e17a.upload.maximum_size=122880 +x21e.menu.cpu.samc21e17a.build.extra_flags=-D__SAMC21E17A__ -DARM_MATH_CM0PLUS +x21e.menu.cpu.samc21e17a.build.ldscript=flash_128KB.ld +x21e.menu.cpu.samc21e17a.build.openocdscript=openocd_scripts/SAMC21E17A.cfg +x21e.menu.cpu.samc21e17a.bootloader.file=zero/binaries/sam_ba_SAMC21E17A.bin +x21e.menu.cpu.samc21e18a=SAMC21E18A +x21e.menu.cpu.samc21e18a.upload.maximum_size=253952 +x21e.menu.cpu.samc21e18a.build.extra_flags=-D__SAMC21E18A__ -DARM_MATH_CM0PLUS +x21e.menu.cpu.samc21e18a.build.ldscript=flash_256KB.ld +x21e.menu.cpu.samc21e18a.build.openocdscript=openocd_scripts/SAMC21E18A.cfg +x21e.menu.cpu.samc21e18a.bootloader.file=zero/binaries/sam_ba_SAMC21E18A.bin +x21e.menu.bootloader.8kb=8KB_BOOTLOADER +x21e.menu.bootloader.8kb.build.bootloader_size=__8KB_BOOTLOADER__ +x21e.menu.bootloader.8kb.build.ldscript_path=linker_scripts/gcc/8KB_Bootloader +x21e.menu.bootloader.8kb.upload.tool=Fab_SAM_Arduino:bossac +x21e.menu.bootloader.8kb.upload.use_1200bps_touch=true +x21e.menu.bootloader.8kb.upload.wait_for_upload_port=true +x21e.menu.bootloader.8kb.upload.native_usb=true +x21e.menu.bootloader.16kb=16KB_BOOTLOADER +x21e.menu.bootloader.16kb.build.bootloader_size=__16KB_BOOTLOADER__ +x21e.menu.bootloader.16kb.build.ldscript_path=linker_scripts/gcc/16KB_Bootloader +x21e.menu.bootloader.16kb.upload.tool=Fab_SAM_Arduino:bossac +x21e.menu.bootloader.16kb.upload.use_1200bps_touch=true +x21e.menu.bootloader.16kb.upload.wait_for_upload_port=true +x21e.menu.bootloader.16kb.upload.native_usb=true +x21e.menu.bootloader.0kb=NO_BOOTLOADER +x21e.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +x21e.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +x21e.menu.bootloader.0kb.upload.tool=openocd +x21e.menu.bootloader.0kb.upload.use_1200bps_touch=false +x21e.menu.bootloader.0kb.upload.wait_for_upload_port=false +x21e.menu.bootloader.0kb.upload.native_usb=false +x21e.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +x21e.menu.serial.one_uart.build.serialcom_uart=ONE_UART +x21e.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +x21e.menu.serial.one_uart_one_wire_two_spi=ONE_UART_ONE_WIRE_TWO_SPI +x21e.menu.serial.one_uart_one_wire_two_spi.build.serialcom_uart=ONE_UART +x21e.menu.serial.one_uart_one_wire_two_spi.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.one_uart_one_wire_two_spi.build.serialcom_spi=TWO_SPI +x21e.menu.serial.one_uart_two_wire_one_spi=ONE_UART_TWO_WIRE_ONE_SPI +x21e.menu.serial.one_uart_two_wire_one_spi.build.serialcom_uart=ONE_UART +x21e.menu.serial.one_uart_two_wire_one_spi.build.serialcom_wire=TWO_WIRE +x21e.menu.serial.one_uart_two_wire_one_spi.build.serialcom_spi=ONE_SPI +x21e.menu.serial.two_uart=TWO_UART_ONE_WIRE_ONE_SPI +x21e.menu.serial.two_uart.build.serialcom_uart=TWO_UART +x21e.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.two_uart.build.serialcom_spi=ONE_SPI +x21e.menu.serial.three_uart_one_wire_no_spi=THREE_UART_ONE_WIRE_NO_SPI +x21e.menu.serial.three_uart_one_wire_no_spi.build.serialcom_uart=THREE_UART +x21e.menu.serial.three_uart_one_wire_no_spi.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.three_uart_one_wire_no_spi.build.serialcom_spi=NO_SPI +x21e.menu.serial.three_uart_no_wire_one_spi=THREE_UART_NO_WIRE_ONE_SPI +x21e.menu.serial.three_uart_no_wire_one_spi.build.serialcom_uart=THREE_UART +x21e.menu.serial.three_uart_no_wire_one_spi.build.serialcom_wire=NO_WIRE +x21e.menu.serial.three_uart_no_wire_one_spi.build.serialcom_spi=ONE_SPI +x21e.menu.serial.four_uart=FOUR_UART_NO_WIRE_NO_SPI +x21e.menu.serial.four_uart.build.serialcom_uart=FOUR_UART +x21e.menu.serial.four_uart.build.serialcom_wire=NO_WIRE +x21e.menu.serial.four_uart.build.serialcom_spi=NO_SPI +x21e.menu.serial.no_uart_one_wire_two_spi=NO_UART_ONE_WIRE_TWO_SPI +x21e.menu.serial.no_uart_one_wire_two_spi.build.serialcom_uart=NO_UART +x21e.menu.serial.no_uart_one_wire_two_spi.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.no_uart_one_wire_two_spi.build.serialcom_spi=TWO_SPI +x21e.menu.serial.four_uart_one_wire_one_spi=FOUR_UART_ONE_WIRE_ONE_SPI (L21 only) +x21e.menu.serial.four_uart_one_wire_one_spi.build.serialcom_uart=FOUR_UART +x21e.menu.serial.four_uart_one_wire_one_spi.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.four_uart_one_wire_one_spi.build.serialcom_spi=ONE_SPI +x21e.menu.serial.five_uart_no_wire_one_spi=FIVE_UART_NO_WIRE_ONE_SPI (L21 only) +x21e.menu.serial.five_uart_no_wire_one_spi.build.serialcom_uart=FIVE_UART +x21e.menu.serial.five_uart_no_wire_one_spi.build.serialcom_wire=NO_WIRE +x21e.menu.serial.five_uart_no_wire_one_spi.build.serialcom_spi=ONE_SPI +x21e.menu.serial.five_uart_one_wire_no_spi=FIVE_UART_ONE_WIRE_NO_SPI (L21 only) +x21e.menu.serial.five_uart_one_wire_no_spi.build.serialcom_uart=FIVE_UART +x21e.menu.serial.five_uart_one_wire_no_spi.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.five_uart_one_wire_no_spi.build.serialcom_spi=NO_SPI +x21e.menu.serial.six_uart=SIX_UART_NO_WIRE_NO_SPI (L21 only) +x21e.menu.serial.six_uart.build.serialcom_uart=SIX_UART +x21e.menu.serial.six_uart.build.serialcom_wire=NO_WIRE +x21e.menu.serial.six_uart.build.serialcom_spi=NO_SPI +x21e.menu.usb.cdc=CDC_ONLY +x21e.menu.usb.cdc.build.usbcom=CDC_ONLY +x21e.menu.usb.cdc.build.pid=0x4557 +x21e.menu.usb.cdc_hid=CDC_HID +x21e.menu.usb.cdc_hid.build.usbcom=CDC_HID +x21e.menu.usb.cdc_hid.build.pid=0x4856 +x21e.menu.usb.withcdc=WITH_CDC +x21e.menu.usb.withcdc.build.usbcom=WITH_CDC +x21e.menu.usb.withcdc.build.pid=0x4B41 +x21e.menu.usb.hid=HID_ONLY +x21e.menu.usb.hid.build.usbcom=HID_ONLY +x21e.menu.usb.hid.build.pid=0x4B40 +x21e.menu.usb.nocdc=WITHOUT_CDC +x21e.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +x21e.menu.usb.nocdc.build.pid=0x4A0C +x21e.menu.usb.none=USB_DISABLED +x21e.menu.usb.none.build.usbcom=USB_DISABLED +x21e.menu.usb.none.build.pid=0x4856 + +# Generic x21G +x21g.name=Generic x21G +x21g.vid.0=0x16D0 +x21g.pid.0=0x5557 +x21g.vid.1=0x16D0 +x21g.pid.1=0x5856 +x21g.vid.2=0x16D0 +x21g.pid.2=0x5B41 +x21g.vid.3=0x16D0 +x21g.pid.3=0x5B40 +x21g.vid.4=0x16D0 +x21g.pid.4=0x5A0C +x21g.vid.5=0x16D0 +x21g.pid.5=0x5856 +x21g.build.usb_manufacturer="Fab Foundation" +x21g.build.board=SAMD_ZERO +x21g.build.core=arduino +x21g.build.variant=Generic_xx1G +x21g.build.variant_system_lib= +x21g.build.vid=0x16D0 +x21g.upload.protocol=sam-ba +x21g.bootloader.tool=openocd +x21g.menu.float.default=Print & String use auto-promoted doubles only +x21g.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +x21g.menu.float.print=Print uses separate singles and doubles +x21g.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +x21g.menu.float.string=String uses separate singles and doubles +x21g.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +x21g.menu.float.both=Print & String use separate singles and doubles +x21g.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +x21g.menu.config.disabled=config.h disabled +x21g.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +x21g.menu.config.enabled=config.h enabled (mostly code size reductions) +x21g.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +x21g.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +x21g.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +x21g.menu.clock.internal=INTERNAL_OSCILLATOR +x21g.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +x21g.menu.clock.crystal_32k=32KHZ_CRYSTAL +x21g.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +x21g.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +x21g.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +x21g.menu.timer.timer_732Hz=732.4Hz (16-bit) +x21g.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +x21g.menu.timer.timer_366Hz=366.2Hz (16-bit) +x21g.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +x21g.menu.timer.timer_244Hz=244.1Hz (16-bit) +x21g.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +x21g.menu.timer.timer_183Hz=183.1Hz (16-bit) +x21g.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +x21g.menu.timer.timer_146Hz=146.5Hz (16-bit) +x21g.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +x21g.menu.timer.timer_122Hz=122.1Hz (16-bit) +x21g.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +x21g.menu.timer.timer_105Hz=104.6Hz (16-bit) +x21g.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +x21g.menu.timer.timer_81Hz=81.38Hz (16-bit) +x21g.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +x21g.menu.timer.timer_61Hz=61.04Hz (16-bit) +x21g.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +x21g.menu.timer.timer_31Hz=30.52Hz (16-bit) +x21g.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +x21g.menu.timer.timer_187500Hz=187500Hz (8-bit) +x21g.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +x21g.menu.timer.timer_93750Hz=93750Hz (8-bit) +x21g.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +x21g.menu.timer.timer_62500Hz=62500Hz (8-bit) +x21g.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +x21g.menu.timer.timer_37500Hz=37500Hz (8-bit) +x21g.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +x21g.menu.timer.timer_20833Hz=20833Hz (8-bit) +x21g.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +x21g.menu.timer.timer_12500Hz=12500Hz (8-bit) +x21g.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +x21g.menu.timer.timer_7500Hz=7500Hz (8-bit) +x21g.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +x21g.menu.timer.timer_4166Hz=4166Hz (8-bit) +x21g.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +x21g.menu.timer.timer_2930Hz=2930Hz (8-bit) +x21g.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +x21g.menu.timer.timer_1465Hz=1465Hz (8-bit) +x21g.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +x21g.menu.cpu.samd21g17a=SAMD21G17A +x21g.menu.cpu.samd21g17a.upload.maximum_size=122880 +x21g.menu.cpu.samd21g17a.build.mcu=cortex-m0plus +x21g.menu.cpu.samd21g17a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samd21g17a.build.f_cpu=48000000L +x21g.menu.cpu.samd21g17a.build.usb_product="D21" +x21g.menu.cpu.samd21g17a.build.extra_flags=-D__SAMD21G17A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.samd21g17a.build.ldscript=flash_128KB.ld +x21g.menu.cpu.samd21g17a.build.openocdscript=openocd_scripts/SAMD21G17A.cfg +x21g.menu.cpu.samd21g17a.bootloader.file=zero/binaries/sam_ba_SAMD21G17A.bin +x21g.menu.cpu.samd21g18a=SAMD21G18A +x21g.menu.cpu.samd21g18a.upload.maximum_size=253952 +x21g.menu.cpu.samd21g18a.build.mcu=cortex-m0plus +x21g.menu.cpu.samd21g18a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samd21g18a.build.f_cpu=48000000L +x21g.menu.cpu.samd21g18a.build.usb_product="D21" +x21g.menu.cpu.samd21g18a.build.extra_flags=-D__SAMD21G18A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.samd21g18a.build.ldscript=flash_256KB.ld +x21g.menu.cpu.samd21g18a.build.openocdscript=openocd_scripts/SAMD21G18A.cfg +x21g.menu.cpu.samd21g18a.bootloader.file=zero/binaries/sam_ba_SAMD21G18A.bin +x21g.menu.cpu.samd21g15a=SAMD21G15A +x21g.menu.cpu.samd21g15a.upload.maximum_size=24576 +x21g.menu.cpu.samd21g15a.build.mcu=cortex-m0plus +x21g.menu.cpu.samd21g15a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samd21g15a.build.f_cpu=48000000L +x21g.menu.cpu.samd21g15a.build.usb_product="D21" +x21g.menu.cpu.samd21g15a.build.extra_flags=-D__SAMD21G15A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.samd21g15a.build.ldscript=flash_32KB.ld +x21g.menu.cpu.samd21g15a.build.openocdscript=openocd_scripts/SAMD21G15A.cfg +x21g.menu.cpu.samd21g15a.bootloader.file=zero/binaries/sam_ba_SAMD21G15A.bin +x21g.menu.cpu.samd21g16a=SAMD21G16A +x21g.menu.cpu.samd21g16a.upload.maximum_size=57344 +x21g.menu.cpu.samd21g16a.build.mcu=cortex-m0plus +x21g.menu.cpu.samd21g16a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samd21g16a.build.f_cpu=48000000L +x21g.menu.cpu.samd21g16a.build.usb_product="D21" +x21g.menu.cpu.samd21g16a.build.extra_flags=-D__SAMD21G16A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.samd21g16a.build.ldscript=flash_64KB.ld +x21g.menu.cpu.samd21g16a.build.openocdscript=openocd_scripts/SAMD21G16A.cfg +x21g.menu.cpu.samd21g16a.bootloader.file=zero/binaries/sam_ba_SAMD21G16A.bin +x21g.menu.cpu.saml21g17b=SAML21G17B +x21g.menu.cpu.saml21g17b.upload.maximum_size=122880 +x21g.menu.cpu.saml21g17b.build.mcu=cortex-m0plus +x21g.menu.cpu.saml21g17b.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.saml21g17b.build.f_cpu=48000000L +x21g.menu.cpu.saml21g17b.build.usb_product="L21" +x21g.menu.cpu.saml21g17b.build.extra_flags=-D__SAML21G17B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.saml21g17b.build.ldscript=flash_128KB.ld +x21g.menu.cpu.saml21g17b.build.openocdscript=openocd_scripts/SAML21G17B.cfg +x21g.menu.cpu.saml21g17b.bootloader.file=zero/binaries/sam_ba_SAML21G17B.bin +x21g.menu.cpu.saml21g18b=SAML21G18B +x21g.menu.cpu.saml21g18b.upload.maximum_size=253952 +x21g.menu.cpu.saml21g18b.build.mcu=cortex-m0plus +x21g.menu.cpu.saml21g18b.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.saml21g18b.build.f_cpu=48000000L +x21g.menu.cpu.saml21g18b.build.usb_product="L21" +x21g.menu.cpu.saml21g18b.build.extra_flags=-D__SAML21G18B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.saml21g18b.build.ldscript=flash_256KB.ld +x21g.menu.cpu.saml21g18b.build.openocdscript=openocd_scripts/SAML21G18B.cfg +x21g.menu.cpu.saml21g18b.bootloader.file=zero/binaries/sam_ba_SAML21G18B.bin +x21g.menu.cpu.saml21g15b=SAML21G15B +x21g.menu.cpu.saml21g15b.upload.maximum_size=24576 +x21g.menu.cpu.saml21g15b.build.mcu=cortex-m0plus +x21g.menu.cpu.saml21g15b.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.saml21g15b.build.f_cpu=48000000L +x21g.menu.cpu.saml21g15b.build.usb_product="L21" +x21g.menu.cpu.saml21g15b.build.extra_flags=-D__SAML21G15B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.saml21g15b.build.ldscript=flash_32KB.ld +x21g.menu.cpu.saml21g15b.build.openocdscript=openocd_scripts/SAML21G15B.cfg +x21g.menu.cpu.saml21g15b.bootloader.file=zero/binaries/sam_ba_SAML21G15B.bin +x21g.menu.cpu.saml21g16b=SAML21G16B +x21g.menu.cpu.saml21g16b.upload.maximum_size=57344 +x21g.menu.cpu.saml21g16b.build.mcu=cortex-m0plus +x21g.menu.cpu.saml21g16b.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.saml21g16b.build.f_cpu=48000000L +x21g.menu.cpu.saml21g16b.build.usb_product="L21" +x21g.menu.cpu.saml21g16b.build.extra_flags=-D__SAML21G16B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.saml21g16b.build.ldscript=flash_64KB.ld +x21g.menu.cpu.saml21g16b.build.openocdscript=openocd_scripts/SAML21G16B.cfg +x21g.menu.cpu.saml21g16b.bootloader.file=zero/binaries/sam_ba_SAML21G16B.bin +x21g.menu.cpu.samc21g17a=SAMC21G17A +x21g.menu.cpu.samc21g17a.upload.maximum_size=122880 +x21g.menu.cpu.samc21g17a.build.mcu=cortex-m0plus +x21g.menu.cpu.samc21g17a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samc21g17a.build.f_cpu=48000000L +x21g.menu.cpu.samc21g17a.build.usb_product="C21" +x21g.menu.cpu.samc21g17a.build.extra_flags=-D__SAMC21G17A__ -DARM_MATH_CM0PLUS +x21g.menu.cpu.samc21g17a.build.ldscript=flash_128KB.ld +x21g.menu.cpu.samc21g17a.build.openocdscript=openocd_scripts/SAMC21G17A.cfg +x21g.menu.cpu.samc21g17a.bootloader.file=zero/binaries/sam_ba_SAMC21G17A.bin +x21g.menu.cpu.samc21g18a=SAMC21G18A +x21g.menu.cpu.samc21g18a.upload.maximum_size=253952 +x21g.menu.cpu.samc21g18a.build.mcu=cortex-m0plus +x21g.menu.cpu.samc21g18a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samc21g18a.build.f_cpu=48000000L +x21g.menu.cpu.samc21g18a.build.usb_product="C21" +x21g.menu.cpu.samc21g18a.build.extra_flags=-D__SAMC21G18A__ -DARM_MATH_CM0PLUS +x21g.menu.cpu.samc21g18a.build.ldscript=flash_256KB.ld +x21g.menu.cpu.samc21g18a.build.openocdscript=openocd_scripts/SAMC21G18A.cfg +x21g.menu.cpu.samc21g18a.bootloader.file=zero/binaries/sam_ba_SAMC21G18A.bin +x21g.menu.cpu.samc21g15a=SAMC21G15A +x21g.menu.cpu.samc21g15a.upload.maximum_size=24576 +x21g.menu.cpu.samc21g15a.build.mcu=cortex-m0plus +x21g.menu.cpu.samc21g15a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samc21g15a.build.f_cpu=48000000L +x21g.menu.cpu.samc21g15a.build.usb_product="C21" +x21g.menu.cpu.samc21g15a.build.extra_flags=-D__SAMC21G15A__ -DARM_MATH_CM0PLUS +x21g.menu.cpu.samc21g15a.build.ldscript=flash_32KB.ld +x21g.menu.cpu.samc21g15a.build.openocdscript=openocd_scripts/SAMC21G15A.cfg +x21g.menu.cpu.samc21g15a.bootloader.file=zero/binaries/sam_ba_SAMC21G15A.bin +x21g.menu.cpu.samc21g16a=SAMC21G16A +x21g.menu.cpu.samc21g16a.upload.maximum_size=57344 +x21g.menu.cpu.samc21g16a.build.mcu=cortex-m0plus +x21g.menu.cpu.samc21g16a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samc21g16a.build.f_cpu=48000000L +x21g.menu.cpu.samc21g16a.build.usb_product="C21" +x21g.menu.cpu.samc21g16a.build.extra_flags=-D__SAMC21G16A__ -DARM_MATH_CM0PLUS +x21g.menu.cpu.samc21g16a.build.ldscript=flash_64KB.ld +x21g.menu.cpu.samc21g16a.build.openocdscript=openocd_scripts/SAMC21G16A.cfg +x21g.menu.cpu.samc21g16a.bootloader.file=zero/binaries/sam_ba_SAMC21G16A.bin +x21g.menu.bootloader.8kb=8KB_BOOTLOADER +x21g.menu.bootloader.8kb.build.bootloader_size=__8KB_BOOTLOADER__ +x21g.menu.bootloader.8kb.build.ldscript_path=linker_scripts/gcc/8KB_Bootloader +x21g.menu.bootloader.8kb.upload.tool=Fab_SAM_Arduino:bossac +x21g.menu.bootloader.8kb.upload.use_1200bps_touch=true +x21g.menu.bootloader.8kb.upload.wait_for_upload_port=true +x21g.menu.bootloader.8kb.upload.native_usb=true +x21g.menu.bootloader.16kb=16KB_BOOTLOADER +x21g.menu.bootloader.16kb.build.bootloader_size=__16KB_BOOTLOADER__ +x21g.menu.bootloader.16kb.build.ldscript_path=linker_scripts/gcc/16KB_Bootloader +x21g.menu.bootloader.16kb.upload.tool=Fab_SAM_Arduino:bossac +x21g.menu.bootloader.16kb.upload.use_1200bps_touch=true +x21g.menu.bootloader.16kb.upload.wait_for_upload_port=true +x21g.menu.bootloader.16kb.upload.native_usb=true +x21g.menu.bootloader.0kb=NO_BOOTLOADER +x21g.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +x21g.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +x21g.menu.bootloader.0kb.upload.tool=openocd +x21g.menu.bootloader.0kb.upload.use_1200bps_touch=false +x21g.menu.bootloader.0kb.upload.wait_for_upload_port=false +x21g.menu.bootloader.0kb.upload.native_usb=false +x21g.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +x21g.menu.serial.one_uart.build.serialcom_uart=ONE_UART +x21g.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +x21g.menu.serial.one_uart_two_spi=ONE_UART_ONE_WIRE_TWO_SPI +x21g.menu.serial.one_uart_two_spi.build.serialcom_uart=ONE_UART +x21g.menu.serial.one_uart_two_spi.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.one_uart_two_spi.build.serialcom_spi=TWO_SPI +x21g.menu.serial.one_uart_two_wire=ONE_UART_TWO_WIRE_ONE_SPI +x21g.menu.serial.one_uart_two_wire.build.serialcom_uart=ONE_UART +x21g.menu.serial.one_uart_two_wire.build.serialcom_wire=TWO_WIRE +x21g.menu.serial.one_uart_two_wire.build.serialcom_spi=ONE_SPI +x21g.menu.serial.two_uart=TWO_UART_ONE_WIRE_ONE_SPI +x21g.menu.serial.two_uart.build.serialcom_uart=TWO_UART +x21g.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.two_uart.build.serialcom_spi=ONE_SPI +x21g.menu.serial.two_uart_two_spi=TWO_UART_ONE_WIRE_TWO_SPI +x21g.menu.serial.two_uart_two_spi.build.serialcom_uart=TWO_UART +x21g.menu.serial.two_uart_two_spi.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.two_uart_two_spi.build.serialcom_spi=TWO_SPI +x21g.menu.serial.two_uart_two_wire=TWO_UART_TWO_WIRE_ONE_SPI +x21g.menu.serial.two_uart_two_wire.build.serialcom_uart=TWO_UART +x21g.menu.serial.two_uart_two_wire.build.serialcom_wire=TWO_WIRE +x21g.menu.serial.two_uart_two_wire.build.serialcom_spi=ONE_SPI +x21g.menu.serial.three_uart=THREE_UART_ONE_WIRE_ONE_SPI +x21g.menu.serial.three_uart.build.serialcom_uart=THREE_UART +x21g.menu.serial.three_uart.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.three_uart.build.serialcom_spi=ONE_SPI +x21g.menu.serial.three_uart_two_spi=THREE_UART_ONE_WIRE_TWO_SPI +x21g.menu.serial.three_uart_two_spi.build.serialcom_uart=THREE_UART +x21g.menu.serial.three_uart_two_spi.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.three_uart_two_spi.build.serialcom_spi=TWO_SPI +x21g.menu.serial.three_uart_two_wire=THREE_UART_TWO_WIRE_ONE_SPI +x21g.menu.serial.three_uart_two_wire.build.serialcom_uart=THREE_UART +x21g.menu.serial.three_uart_two_wire.build.serialcom_wire=TWO_WIRE +x21g.menu.serial.three_uart_two_wire.build.serialcom_spi=ONE_SPI +x21g.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +x21g.menu.serial.no_uart.build.serialcom_uart=NO_UART +x21g.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +x21g.menu.usb.cdc=CDC_ONLY +x21g.menu.usb.cdc.build.usbcom=CDC_ONLY +x21g.menu.usb.cdc.build.pid=0x5557 +x21g.menu.usb.cdc_hid=CDC_HID +x21g.menu.usb.cdc_hid.build.usbcom=CDC_HID +x21g.menu.usb.cdc_hid.build.pid=0x5856 +x21g.menu.usb.withcdc=WITH_CDC +x21g.menu.usb.withcdc.build.usbcom=WITH_CDC +x21g.menu.usb.withcdc.build.pid=0x5B41 +x21g.menu.usb.hid=HID_ONLY +x21g.menu.usb.hid.build.usbcom=HID_ONLY +x21g.menu.usb.hid.build.pid=0x5B40 +x21g.menu.usb.nocdc=WITHOUT_CDC +x21g.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +x21g.menu.usb.nocdc.build.pid=0x5A0C +x21g.menu.usb.none=USB_DISABLED +x21g.menu.usb.none.build.usbcom=USB_DISABLED +x21g.menu.usb.none.build.pid=0x5856 + +# Generic x21J +x21j.name=Generic x21J +x21j.vid.0=0x16D0 +x21j.pid.0=0x6557 +x21j.vid.1=0x16D0 +x21j.pid.1=0x6856 +x21j.vid.2=0x16D0 +x21j.pid.2=0x6B41 +x21j.vid.3=0x16D0 +x21j.pid.3=0x6B40 +x21j.vid.4=0x16D0 +x21j.pid.4=0x6A0C +x21j.vid.5=0x16D0 +x21j.pid.5=0x6856 +x21j.build.usb_manufacturer="Fab Foundation" +x21j.build.board=SAMD_ZERO +x21j.build.core=arduino +x21j.build.variant=Generic_xx1J +x21j.build.variant_system_lib= +x21j.build.vid=0x16D0 +x21j.upload.protocol=sam-ba +x21j.bootloader.tool=openocd +x21j.menu.float.default=Print & String use auto-promoted doubles only +x21j.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +x21j.menu.float.print=Print uses separate singles and doubles +x21j.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +x21j.menu.float.string=String uses separate singles and doubles +x21j.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +x21j.menu.float.both=Print & String use separate singles and doubles +x21j.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +x21j.menu.config.disabled=config.h disabled +x21j.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +x21j.menu.config.enabled=config.h enabled (mostly code size reductions) +x21j.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +x21j.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +x21j.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +x21j.menu.clock.internal=INTERNAL_OSCILLATOR +x21j.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +x21j.menu.clock.crystal_32k=32KHZ_CRYSTAL +x21j.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +x21j.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +x21j.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +x21j.menu.timer.timer_732Hz=732.4Hz (16-bit) +x21j.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +x21j.menu.timer.timer_366Hz=366.2Hz (16-bit) +x21j.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +x21j.menu.timer.timer_244Hz=244.1Hz (16-bit) +x21j.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +x21j.menu.timer.timer_183Hz=183.1Hz (16-bit) +x21j.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +x21j.menu.timer.timer_146Hz=146.5Hz (16-bit) +x21j.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +x21j.menu.timer.timer_122Hz=122.1Hz (16-bit) +x21j.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +x21j.menu.timer.timer_105Hz=104.6Hz (16-bit) +x21j.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +x21j.menu.timer.timer_81Hz=81.38Hz (16-bit) +x21j.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +x21j.menu.timer.timer_61Hz=61.04Hz (16-bit) +x21j.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +x21j.menu.timer.timer_31Hz=30.52Hz (16-bit) +x21j.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +x21j.menu.timer.timer_187500Hz=187500Hz (8-bit) +x21j.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +x21j.menu.timer.timer_93750Hz=93750Hz (8-bit) +x21j.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +x21j.menu.timer.timer_62500Hz=62500Hz (8-bit) +x21j.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +x21j.menu.timer.timer_37500Hz=37500Hz (8-bit) +x21j.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +x21j.menu.timer.timer_20833Hz=20833Hz (8-bit) +x21j.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +x21j.menu.timer.timer_12500Hz=12500Hz (8-bit) +x21j.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +x21j.menu.timer.timer_7500Hz=7500Hz (8-bit) +x21j.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +x21j.menu.timer.timer_4166Hz=4166Hz (8-bit) +x21j.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +x21j.menu.timer.timer_2930Hz=2930Hz (8-bit) +x21j.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +x21j.menu.timer.timer_1465Hz=1465Hz (8-bit) +x21j.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +x21j.menu.cpu.samd21j17a=SAMD21J17A +x21j.menu.cpu.samd21j17a.upload.maximum_size=122880 +x21j.menu.cpu.samd21j17a.build.mcu=cortex-m0plus +x21j.menu.cpu.samd21j17a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samd21j17a.build.f_cpu=48000000L +x21j.menu.cpu.samd21j17a.build.usb_product="Xeno D21" +x21j.menu.cpu.samd21j17a.build.extra_flags=-D__SAMD21J17A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.samd21j17a.build.ldscript=flash_128KB.ld +x21j.menu.cpu.samd21j17a.build.openocdscript=openocd_scripts/SAMD21J17A.cfg +x21j.menu.cpu.samd21j17a.bootloader.file=zero/binaries/sam_ba_SAMD21J17A.bin +x21j.menu.cpu.samd21j18a=SAMD21J18A +x21j.menu.cpu.samd21j18a.upload.maximum_size=253952 +x21j.menu.cpu.samd21j18a.build.mcu=cortex-m0plus +x21j.menu.cpu.samd21j18a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samd21j18a.build.f_cpu=48000000L +x21j.menu.cpu.samd21j18a.build.usb_product="Xeno D21" +x21j.menu.cpu.samd21j18a.build.extra_flags=-D__SAMD21J18A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.samd21j18a.build.ldscript=flash_256KB.ld +x21j.menu.cpu.samd21j18a.build.openocdscript=openocd_scripts/SAMD21J18A.cfg +x21j.menu.cpu.samd21j18a.bootloader.file=zero/binaries/sam_ba_SAMD21J18A.bin +x21j.menu.cpu.samd21j15a=SAMD21J15A +x21j.menu.cpu.samd21j15a.upload.maximum_size=24576 +x21j.menu.cpu.samd21j15a.build.mcu=cortex-m0plus +x21j.menu.cpu.samd21j15a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samd21j15a.build.f_cpu=48000000L +x21j.menu.cpu.samd21j15a.build.usb_product="Xeno D21" +x21j.menu.cpu.samd21j15a.build.extra_flags=-D__SAMD21J15A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.samd21j15a.build.ldscript=flash_32KB.ld +x21j.menu.cpu.samd21j15a.build.openocdscript=openocd_scripts/SAMD21J15A.cfg +x21j.menu.cpu.samd21j15a.bootloader.file=zero/binaries/sam_ba_SAMD21J15A.bin +x21j.menu.cpu.samd21j16a=SAMD21J16A +x21j.menu.cpu.samd21j16a.upload.maximum_size=57344 +x21j.menu.cpu.samd21j16a.build.mcu=cortex-m0plus +x21j.menu.cpu.samd21j16a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samd21j16a.build.f_cpu=48000000L +x21j.menu.cpu.samd21j16a.build.usb_product="Xeno D21" +x21j.menu.cpu.samd21j16a.build.extra_flags=-D__SAMD21J16A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.samd21j16a.build.ldscript=flash_64KB.ld +x21j.menu.cpu.samd21j16a.build.openocdscript=openocd_scripts/SAMD21J16A.cfg +x21j.menu.cpu.samd21j16a.bootloader.file=zero/binaries/sam_ba_SAMD21J16A.bin +x21j.menu.cpu.saml21j17b=SAML21J17B +x21j.menu.cpu.saml21j17b.upload.maximum_size=122880 +x21j.menu.cpu.saml21j17b.build.mcu=cortex-m0plus +x21j.menu.cpu.saml21j17b.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.saml21j17b.build.f_cpu=48000000L +x21j.menu.cpu.saml21j17b.build.usb_product="Xeno L21" +x21j.menu.cpu.saml21j17b.build.extra_flags=-D__SAML21J17B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.saml21j17b.build.ldscript=flash_128KB.ld +x21j.menu.cpu.saml21j17b.build.openocdscript=openocd_scripts/SAML21J17B.cfg +x21j.menu.cpu.saml21j17b.bootloader.file=zero/binaries/sam_ba_SAML21J17B.bin +x21j.menu.cpu.saml21j18b=SAML21J18B +x21j.menu.cpu.saml21j18b.upload.maximum_size=253952 +x21j.menu.cpu.saml21j18b.build.mcu=cortex-m0plus +x21j.menu.cpu.saml21j18b.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.saml21j18b.build.f_cpu=48000000L +x21j.menu.cpu.saml21j18b.build.usb_product="Xeno L21" +x21j.menu.cpu.saml21j18b.build.extra_flags=-D__SAML21J18B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.saml21j18b.build.ldscript=flash_256KB.ld +x21j.menu.cpu.saml21j18b.build.openocdscript=openocd_scripts/SAML21J18B.cfg +x21j.menu.cpu.saml21j18b.bootloader.file=zero/binaries/sam_ba_SAML21J18B.bin +x21j.menu.cpu.saml21j16b=SAML21J16B +x21j.menu.cpu.saml21j16b.upload.maximum_size=57344 +x21j.menu.cpu.saml21j16b.build.mcu=cortex-m0plus +x21j.menu.cpu.saml21j16b.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.saml21j16b.build.f_cpu=48000000L +x21j.menu.cpu.saml21j16b.build.usb_product="Xeno L21" +x21j.menu.cpu.saml21j16b.build.extra_flags=-D__SAML21J16B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.saml21j16b.build.ldscript=flash_64KB.ld +x21j.menu.cpu.saml21j16b.build.openocdscript=openocd_scripts/SAML21J16B.cfg +x21j.menu.cpu.saml21j16b.bootloader.file=zero/binaries/sam_ba_SAML21J16B.bin +x21j.menu.cpu.samc21j17a=SAMC21J17A +x21j.menu.cpu.samc21j17a.upload.maximum_size=122880 +x21j.menu.cpu.samc21j17a.build.mcu=cortex-m0plus +x21j.menu.cpu.samc21j17a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samc21j17a.build.f_cpu=48000000L +x21j.menu.cpu.samc21j17a.build.usb_product="Xeno C21" +x21j.menu.cpu.samc21j17a.build.extra_flags=-D__SAMC21J17A__ -DARM_MATH_CM0PLUS +x21j.menu.cpu.samc21j17a.build.ldscript=flash_128KB.ld +x21j.menu.cpu.samc21j17a.build.openocdscript=openocd_scripts/SAMC21J17A.cfg +x21j.menu.cpu.samc21j17a.bootloader.file=zero/binaries/sam_ba_SAMC21J17A.bin +x21j.menu.cpu.samc21j18a=SAMC21J18A +x21j.menu.cpu.samc21j18a.upload.maximum_size=253952 +x21j.menu.cpu.samc21j18a.build.mcu=cortex-m0plus +x21j.menu.cpu.samc21j18a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samc21j18a.build.f_cpu=48000000L +x21j.menu.cpu.samc21j18a.build.usb_product="Xeno C21" +x21j.menu.cpu.samc21j18a.build.extra_flags=-D__SAMC21J18A__ -DARM_MATH_CM0PLUS +x21j.menu.cpu.samc21j18a.build.ldscript=flash_256KB.ld +x21j.menu.cpu.samc21j18a.build.openocdscript=openocd_scripts/SAMC21J18A.cfg +x21j.menu.cpu.samc21j18a.bootloader.file=zero/binaries/sam_ba_SAMC21J18A.bin +x21j.menu.cpu.samc21j15a=SAMC21J15A +x21j.menu.cpu.samc21j15a.upload.maximum_size=24576 +x21j.menu.cpu.samc21j15a.build.mcu=cortex-m0plus +x21j.menu.cpu.samc21j15a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samc21j15a.build.f_cpu=48000000L +x21j.menu.cpu.samc21j15a.build.usb_product="Xeno C21" +x21j.menu.cpu.samc21j15a.build.extra_flags=-D__SAMC21J15A__ -DARM_MATH_CM0PLUS +x21j.menu.cpu.samc21j15a.build.ldscript=flash_32KB.ld +x21j.menu.cpu.samc21j15a.build.openocdscript=openocd_scripts/SAMC21J15A.cfg +x21j.menu.cpu.samc21j15a.bootloader.file=zero/binaries/sam_ba_SAMC21J15A.bin +x21j.menu.cpu.samc21j16a=SAMC21J16A +x21j.menu.cpu.samc21j16a.upload.maximum_size=57344 +x21j.menu.cpu.samc21j16a.build.mcu=cortex-m0plus +x21j.menu.cpu.samc21j16a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samc21j16a.build.f_cpu=48000000L +x21j.menu.cpu.samc21j16a.build.usb_product="Xeno C21" +x21j.menu.cpu.samc21j16a.build.extra_flags=-D__SAMC21J16A__ -DARM_MATH_CM0PLUS +x21j.menu.cpu.samc21j16a.build.ldscript=flash_64KB.ld +x21j.menu.cpu.samc21j16a.build.openocdscript=openocd_scripts/SAMC21J16A.cfg +x21j.menu.cpu.samc21j16a.bootloader.file=zero/binaries/sam_ba_SAMC21J16A.bin +x21j.menu.bootloader.8kb=8KB_BOOTLOADER +x21j.menu.bootloader.8kb.build.bootloader_size=__8KB_BOOTLOADER__ +x21j.menu.bootloader.8kb.build.ldscript_path=linker_scripts/gcc/8KB_Bootloader +x21j.menu.bootloader.8kb.upload.tool=Fab_SAM_Arduino:bossac +x21j.menu.bootloader.8kb.upload.use_1200bps_touch=true +x21j.menu.bootloader.8kb.upload.wait_for_upload_port=true +x21j.menu.bootloader.8kb.upload.native_usb=true +x21j.menu.bootloader.16kb=16KB_BOOTLOADER +x21j.menu.bootloader.16kb.build.bootloader_size=__16KB_BOOTLOADER__ +x21j.menu.bootloader.16kb.build.ldscript_path=linker_scripts/gcc/16KB_Bootloader +x21j.menu.bootloader.16kb.upload.tool=Fab_SAM_Arduino:bossac +x21j.menu.bootloader.16kb.upload.use_1200bps_touch=true +x21j.menu.bootloader.16kb.upload.wait_for_upload_port=true +x21j.menu.bootloader.16kb.upload.native_usb=true +x21j.menu.bootloader.0kb=NO_BOOTLOADER +x21j.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +x21j.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +x21j.menu.bootloader.0kb.upload.tool=openocd +x21j.menu.bootloader.0kb.upload.use_1200bps_touch=false +x21j.menu.bootloader.0kb.upload.wait_for_upload_port=false +x21j.menu.bootloader.0kb.upload.native_usb=false +x21j.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +x21j.menu.serial.one_uart.build.serialcom_uart=ONE_UART +x21j.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +x21j.menu.serial.one_uart_two_spi=ONE_UART_ONE_WIRE_TWO_SPI +x21j.menu.serial.one_uart_two_spi.build.serialcom_uart=ONE_UART +x21j.menu.serial.one_uart_two_spi.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.one_uart_two_spi.build.serialcom_spi=TWO_SPI +x21j.menu.serial.one_uart_two_wire=ONE_UART_TWO_WIRE_ONE_SPI +x21j.menu.serial.one_uart_two_wire.build.serialcom_uart=ONE_UART +x21j.menu.serial.one_uart_two_wire.build.serialcom_wire=TWO_WIRE +x21j.menu.serial.one_uart_two_wire.build.serialcom_spi=ONE_SPI +x21j.menu.serial.two_uart=TWO_UART_ONE_WIRE_ONE_SPI +x21j.menu.serial.two_uart.build.serialcom_uart=TWO_UART +x21j.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.two_uart.build.serialcom_spi=ONE_SPI +x21j.menu.serial.two_uart_two_spi=TWO_UART_ONE_WIRE_TWO_SPI +x21j.menu.serial.two_uart_two_spi.build.serialcom_uart=TWO_UART +x21j.menu.serial.two_uart_two_spi.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.two_uart_two_spi.build.serialcom_spi=TWO_SPI +x21j.menu.serial.two_uart_two_wire=TWO_UART_TWO_WIRE_ONE_SPI +x21j.menu.serial.two_uart_two_wire.build.serialcom_uart=TWO_UART +x21j.menu.serial.two_uart_two_wire.build.serialcom_wire=TWO_WIRE +x21j.menu.serial.two_uart_two_wire.build.serialcom_spi=ONE_SPI +x21j.menu.serial.three_uart=THREE_UART_ONE_WIRE_ONE_SPI +x21j.menu.serial.three_uart.build.serialcom_uart=THREE_UART +x21j.menu.serial.three_uart.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.three_uart.build.serialcom_spi=ONE_SPI +x21j.menu.serial.three_uart_two_spi=THREE_UART_ONE_WIRE_TWO_SPI +x21j.menu.serial.three_uart_two_spi.build.serialcom_uart=THREE_UART +x21j.menu.serial.three_uart_two_spi.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.three_uart_two_spi.build.serialcom_spi=TWO_SPI +x21j.menu.serial.three_uart_two_wire=THREE_UART_TWO_WIRE_ONE_SPI +x21j.menu.serial.three_uart_two_wire.build.serialcom_uart=THREE_UART +x21j.menu.serial.three_uart_two_wire.build.serialcom_wire=TWO_WIRE +x21j.menu.serial.three_uart_two_wire.build.serialcom_spi=ONE_SPI +x21j.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +x21j.menu.serial.no_uart.build.serialcom_uart=NO_UART +x21j.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +x21j.menu.usb.cdc=CDC_ONLY +x21j.menu.usb.cdc.build.usbcom=CDC_ONLY +x21j.menu.usb.cdc.build.pid=0x6557 +x21j.menu.usb.cdc_hid=CDC_HID +x21j.menu.usb.cdc_hid.build.usbcom=CDC_HID +x21j.menu.usb.cdc_hid.build.pid=0x6856 +x21j.menu.usb.withcdc=WITH_CDC +x21j.menu.usb.withcdc.build.usbcom=WITH_CDC +x21j.menu.usb.withcdc.build.pid=0x6B41 +x21j.menu.usb.hid=HID_ONLY +x21j.menu.usb.hid.build.usbcom=HID_ONLY +x21j.menu.usb.hid.build.pid=0x6B40 +x21j.menu.usb.nocdc=WITHOUT_CDC +x21j.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +x21j.menu.usb.nocdc.build.pid=0x6A0C +x21j.menu.usb.none=USB_DISABLED +x21j.menu.usb.none.build.usbcom=USB_DISABLED +x21j.menu.usb.none.build.pid=0x6856 + +# Generic D51G +d51g.name=Generic D51G +d51g.vid.0=0x16D0 +d51g.pid.0=0x7557 +d51g.vid.1=0x16D0 +d51g.pid.1=0x7856 +d51g.vid.2=0x16D0 +d51g.pid.2=0x7B41 +d51g.vid.3=0x16D0 +d51g.pid.3=0x7B40 +d51g.vid.4=0x16D0 +d51g.pid.4=0x7A0C +d51g.vid.5=0x16D0 +d51g.pid.5=0x7856 +d51g.build.usb_manufacturer="Fab Foundation" + +# KH mod +#d51g.build.board=SAMD_ZERO +d51g.build.board=__SAMD51__ +###### + +d51g.build.core=arduino + +# KH mod +#d51g.build.variant=Generic_D51G +d51g.build.variant=Generic_xx1G +###### + +d51g.build.variant_system_lib= +d51g.build.vid=0x16D0 +d51g.upload.protocol=sam-ba +d51g.bootloader.tool=openocd +d51g.menu.float.default=Print & String use auto-promoted doubles only +d51g.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +d51g.menu.float.print=Print uses separate singles and doubles +d51g.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +d51g.menu.float.string=String uses separate singles and doubles +d51g.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +d51g.menu.float.both=Print & String use separate singles and doubles +d51g.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +d51g.menu.config.disabled=config.h disabled +d51g.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +d51g.menu.config.enabled=config.h enabled (mostly code size reductions) +d51g.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +d51g.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +d51g.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +d51g.menu.clock.internal=INTERNAL_OSCILLATOR +d51g.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +d51g.menu.clock.crystal_32k=32KHZ_CRYSTAL +d51g.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +d51g.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +d51g.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +d51g.menu.timer.timer_732Hz=732.4Hz (16-bit) +d51g.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +d51g.menu.timer.timer_366Hz=366.2Hz (16-bit) +d51g.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +d51g.menu.timer.timer_244Hz=244.1Hz (16-bit) +d51g.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +d51g.menu.timer.timer_183Hz=183.1Hz (16-bit) +d51g.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +d51g.menu.timer.timer_146Hz=146.5Hz (16-bit) +d51g.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +d51g.menu.timer.timer_122Hz=122.1Hz (16-bit) +d51g.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +d51g.menu.timer.timer_105Hz=104.6Hz (16-bit) +d51g.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +d51g.menu.timer.timer_81Hz=81.38Hz (16-bit) +d51g.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +d51g.menu.timer.timer_61Hz=61.04Hz (16-bit) +d51g.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +d51g.menu.timer.timer_31Hz=30.52Hz (16-bit) +d51g.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +d51g.menu.timer.timer_187500Hz=187500Hz (8-bit) +d51g.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +d51g.menu.timer.timer_93750Hz=93750Hz (8-bit) +d51g.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +d51g.menu.timer.timer_62500Hz=62500Hz (8-bit) +d51g.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +d51g.menu.timer.timer_37500Hz=37500Hz (8-bit) +d51g.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +d51g.menu.timer.timer_20833Hz=20833Hz (8-bit) +d51g.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +d51g.menu.timer.timer_12500Hz=12500Hz (8-bit) +d51g.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +d51g.menu.timer.timer_7500Hz=7500Hz (8-bit) +d51g.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +d51g.menu.timer.timer_4166Hz=4166Hz (8-bit) +d51g.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +d51g.menu.timer.timer_2930Hz=2930Hz (8-bit) +d51g.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +d51g.menu.timer.timer_1465Hz=1465Hz (16-bit) +d51g.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +d51g.menu.cpu.samd51g18a_120=SAMD51G18A_120MHz +d51g.menu.cpu.samd51g18a_120.upload.maximum_size=253952 +d51g.menu.cpu.samd51g18a_120.build.mcu=cortex-m4 +d51g.menu.cpu.samd51g18a_120.build.mathlib=arm_cortexM4lf_math +d51g.menu.cpu.samd51g18a_120.build.f_cpu=120000000L +d51g.menu.cpu.samd51g18a_120.build.usb_product="Xeno Mini D51" + +# KH mod +#d51g.menu.cpu.samd51g18a_120.build.extra_flags=-D__SAMD51G18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +#d51g.menu.cpu.samd51g18a_120.build.extra_flags=-D__SAMD51G18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +d51g.menu.cpu.samd51g18a_120.build.extra_flags=-D__SAMD51G18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + + +d51g.menu.cpu.samd51g18a_120.build.ldscript=flash_m4f_256KB.ld +d51g.menu.cpu.samd51g18a_120.build.openocdscript=openocd_scripts/SAMD51G18A.cfg +d51g.menu.cpu.samd51g18a_120.bootloader.file=zero/binaries/sam_ba_SAMD51G18A.bin +d51g.menu.cpu.samd51g18a_48=SAMD51G18A_48MHz +d51g.menu.cpu.samd51g18a_48.upload.maximum_size=253952 +d51g.menu.cpu.samd51g18a_48.build.mcu=cortex-m4 +d51g.menu.cpu.samd51g18a_48.build.mathlib=arm_cortexM4lf_math +d51g.menu.cpu.samd51g18a_48.build.f_cpu=48000000L +d51g.menu.cpu.samd51g18a_48.build.usb_product="Xeno Mini D51" + +# KH mod +#d51g.menu.cpu.samd51g18a_48.build.extra_flags=-D__SAMD51G18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51g.menu.cpu.samd51g18a_48.build.extra_flags=-D__SAMD51G18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51g.menu.cpu.samd51g18a_48.build.ldscript=flash_m4f_256KB.ld +d51g.menu.cpu.samd51g18a_48.build.openocdscript=openocd_scripts/SAMD51G18A.cfg +d51g.menu.cpu.samd51g18a_48.bootloader.file=zero/binaries/sam_ba_SAMD51G18A.bin +d51g.menu.cpu.samd51g19a_120=SAMD51G19A_120MHz +d51g.menu.cpu.samd51g19a_120.upload.maximum_size=516096 +d51g.menu.cpu.samd51g19a_120.build.mcu=cortex-m4 +d51g.menu.cpu.samd51g19a_120.build.mathlib=arm_cortexM4lf_math +d51g.menu.cpu.samd51g19a_120.build.f_cpu=120000000L +d51g.menu.cpu.samd51g19a_120.build.usb_product="Xeno Mini D51" + +# KH mod +#d51g.menu.cpu.samd51g19a_120.build.extra_flags=-D__SAMD51G19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51g.menu.cpu.samd51g19a_120.build.extra_flags=-D__SAMD51G19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51g.menu.cpu.samd51g19a_120.build.ldscript=flash_m4f_512KB.ld +d51g.menu.cpu.samd51g19a_120.build.openocdscript=openocd_scripts/SAMD51G19A.cfg +d51g.menu.cpu.samd51g19a_120.bootloader.file=zero/binaries/sam_ba_SAMD51G19A.bin +d51g.menu.cpu.samd51g19a_48=SAMD51G19A_48MHz +d51g.menu.cpu.samd51g19a_48.upload.maximum_size=516096 +d51g.menu.cpu.samd51g19a_48.build.mcu=cortex-m4 +d51g.menu.cpu.samd51g19a_48.build.mathlib=arm_cortexM4lf_math +d51g.menu.cpu.samd51g19a_48.build.f_cpu=48000000L +d51g.menu.cpu.samd51g19a_48.build.usb_product="Xeno Mini D51" + +# KH mod +#d51g.menu.cpu.samd51g19a_48.build.extra_flags=-D__SAMD51G19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51g.menu.cpu.samd51g19a_48.build.extra_flags=-D__SAMD51G19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51g.menu.cpu.samd51g19a_48.build.ldscript=flash_m4f_512KB.ld +d51g.menu.cpu.samd51g19a_48.build.openocdscript=openocd_scripts/SAMD51G19A.cfg +d51g.menu.cpu.samd51g19a_48.bootloader.file=zero/binaries/sam_ba_SAMD51G19A.bin +d51g.menu.bootloader.8kb=8KB_BOOTLOADER +d51g.menu.bootloader.8kb.build.bootloader_size=__8KB_BOOTLOADER__ +d51g.menu.bootloader.8kb.build.ldscript_path=linker_scripts/gcc/8KB_Bootloader +d51g.menu.bootloader.8kb.upload.tool=Fab_SAM_Arduino:bossac +d51g.menu.bootloader.8kb.upload.use_1200bps_touch=true +d51g.menu.bootloader.8kb.upload.wait_for_upload_port=true +d51g.menu.bootloader.8kb.upload.native_usb=true +d51g.menu.bootloader.16kb=16KB_BOOTLOADER +d51g.menu.bootloader.16kb.build.bootloader_size=__16KB_BOOTLOADER__ +d51g.menu.bootloader.16kb.build.ldscript_path=linker_scripts/gcc/16KB_Bootloader +d51g.menu.bootloader.16kb.upload.tool=Fab_SAM_Arduino:bossac +d51g.menu.bootloader.16kb.upload.use_1200bps_touch=true +d51g.menu.bootloader.16kb.upload.wait_for_upload_port=true +d51g.menu.bootloader.16kb.upload.native_usb=true +d51g.menu.bootloader.0kb=NO_BOOTLOADER +d51g.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +d51g.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +d51g.menu.bootloader.0kb.upload.tool=openocd +d51g.menu.bootloader.0kb.upload.use_1200bps_touch=false +d51g.menu.bootloader.0kb.upload.wait_for_upload_port=false +d51g.menu.bootloader.0kb.upload.native_usb=false +d51g.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +d51g.menu.serial.one_uart.build.serialcom_uart=ONE_UART +d51g.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +d51g.menu.serial.one_uart_two_spi=ONE_UART_ONE_WIRE_TWO_SPI +d51g.menu.serial.one_uart_two_spi.build.serialcom_uart=ONE_UART +d51g.menu.serial.one_uart_two_spi.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.one_uart_two_spi.build.serialcom_spi=TWO_SPI +d51g.menu.serial.one_uart_two_wire=ONE_UART_TWO_WIRE_ONE_SPI +d51g.menu.serial.one_uart_two_wire.build.serialcom_uart=ONE_UART +d51g.menu.serial.one_uart_two_wire.build.serialcom_wire=TWO_WIRE +d51g.menu.serial.one_uart_two_wire.build.serialcom_spi=ONE_SPI +d51g.menu.serial.two_uart=TWO_UART_ONE_WIRE_ONE_SPI +d51g.menu.serial.two_uart.build.serialcom_uart=TWO_UART +d51g.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.two_uart.build.serialcom_spi=ONE_SPI +d51g.menu.serial.two_uart_two_spi=TWO_UART_ONE_WIRE_TWO_SPI +d51g.menu.serial.two_uart_two_spi.build.serialcom_uart=TWO_UART +d51g.menu.serial.two_uart_two_spi.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.two_uart_two_spi.build.serialcom_spi=TWO_SPI +d51g.menu.serial.two_uart_two_wire=TWO_UART_TWO_WIRE_ONE_SPI +d51g.menu.serial.two_uart_two_wire.build.serialcom_uart=TWO_UART +d51g.menu.serial.two_uart_two_wire.build.serialcom_wire=TWO_WIRE +d51g.menu.serial.two_uart_two_wire.build.serialcom_spi=ONE_SPI +d51g.menu.serial.three_uart=THREE_UART_ONE_WIRE_ONE_SPI +d51g.menu.serial.three_uart.build.serialcom_uart=THREE_UART +d51g.menu.serial.three_uart.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.three_uart.build.serialcom_spi=ONE_SPI +d51g.menu.serial.three_uart_two_spi=THREE_UART_ONE_WIRE_TWO_SPI +d51g.menu.serial.three_uart_two_spi.build.serialcom_uart=THREE_UART +d51g.menu.serial.three_uart_two_spi.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.three_uart_two_spi.build.serialcom_spi=TWO_SPI +d51g.menu.serial.three_uart_two_wire=THREE_UART_TWO_WIRE_ONE_SPI +d51g.menu.serial.three_uart_two_wire.build.serialcom_uart=THREE_UART +d51g.menu.serial.three_uart_two_wire.build.serialcom_wire=TWO_WIRE +d51g.menu.serial.three_uart_two_wire.build.serialcom_spi=ONE_SPI +d51g.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +d51g.menu.serial.no_uart.build.serialcom_uart=NO_UART +d51g.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +d51g.menu.usb.cdc=CDC_ONLY +d51g.menu.usb.cdc.build.usbcom=CDC_ONLY +d51g.menu.usb.cdc.build.pid=0x7557 +d51g.menu.usb.cdc_hid=CDC_HID +d51g.menu.usb.cdc_hid.build.usbcom=CDC_HID +d51g.menu.usb.cdc_hid.build.pid=0x7856 +d51g.menu.usb.withcdc=WITH_CDC +d51g.menu.usb.withcdc.build.usbcom=WITH_CDC +d51g.menu.usb.withcdc.build.pid=0x7B41 +d51g.menu.usb.hid=HID_ONLY +d51g.menu.usb.hid.build.usbcom=HID_ONLY +d51g.menu.usb.hid.build.pid=0x7B40 +d51g.menu.usb.nocdc=WITHOUT_CDC +d51g.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +d51g.menu.usb.nocdc.build.pid=0x7A0C +d51g.menu.usb.none=USB_DISABLED +d51g.menu.usb.none.build.usbcom=USB_DISABLED +d51g.menu.usb.none.build.pid=0x7856 + +# Generic D51J +d51j.name=Generic D51J +d51j.vid.0=0x16D0 +d51j.pid.0=0x8557 +d51j.vid.1=0x16D0 +d51j.pid.1=0x8856 +d51j.vid.2=0x16D0 +d51j.pid.2=0x8B41 +d51j.vid.3=0x16D0 +d51j.pid.3=0x8B40 +d51j.vid.4=0x16D0 +d51j.pid.4=0x8A0C +d51j.vid.5=0x16D0 +d51j.pid.5=0x8856 +d51j.build.usb_manufacturer="Fab Foundation" + +# KH mod +#d51j.build.board=SAMD_ZERO +d51j.build.board=__SAMD51__ +###### + +d51j.build.core=arduino +d51j.build.variant=Generic_xx1J +d51j.build.variant_system_lib= +d51j.build.vid=0x16D0 +d51j.upload.protocol=sam-ba +d51j.bootloader.tool=openocd +d51j.menu.float.default=Print & String use auto-promoted doubles only +d51j.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +d51j.menu.float.print=Print uses separate singles and doubles +d51j.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +d51j.menu.float.string=String uses separate singles and doubles +d51j.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +d51j.menu.float.both=Print & String use separate singles and doubles +d51j.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +d51j.menu.config.disabled=config.h disabled +d51j.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +d51j.menu.config.enabled=config.h enabled (mostly code size reductions) +d51j.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +d51j.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +d51j.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +d51j.menu.clock.internal=INTERNAL_OSCILLATOR +d51j.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +d51j.menu.clock.crystal_32k=32KHZ_CRYSTAL +d51j.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +d51j.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +d51j.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +d51j.menu.timer.timer_732Hz=732.4Hz (16-bit) +d51j.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +d51j.menu.timer.timer_366Hz=366.2Hz (16-bit) +d51j.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +d51j.menu.timer.timer_244Hz=244.1Hz (16-bit) +d51j.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +d51j.menu.timer.timer_183Hz=183.1Hz (16-bit) +d51j.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +d51j.menu.timer.timer_146Hz=146.5Hz (16-bit) +d51j.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +d51j.menu.timer.timer_122Hz=122.1Hz (16-bit) +d51j.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +d51j.menu.timer.timer_105Hz=104.6Hz (16-bit) +d51j.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +d51j.menu.timer.timer_81Hz=81.38Hz (16-bit) +d51j.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +d51j.menu.timer.timer_61Hz=61.04Hz (16-bit) +d51j.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +d51j.menu.timer.timer_31Hz=30.52Hz (16-bit) +d51j.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +d51j.menu.timer.timer_187500Hz=187500Hz (8-bit) +d51j.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +d51j.menu.timer.timer_93750Hz=93750Hz (8-bit) +d51j.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +d51j.menu.timer.timer_62500Hz=62500Hz (8-bit) +d51j.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +d51j.menu.timer.timer_37500Hz=37500Hz (8-bit) +d51j.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +d51j.menu.timer.timer_20833Hz=20833Hz (8-bit) +d51j.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +d51j.menu.timer.timer_12500Hz=12500Hz (8-bit) +d51j.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +d51j.menu.timer.timer_7500Hz=7500Hz (8-bit) +d51j.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +d51j.menu.timer.timer_4166Hz=4166Hz (8-bit) +d51j.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +d51j.menu.timer.timer_2930Hz=2930Hz (8-bit) +d51j.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +d51j.menu.timer.timer_1465Hz=1465Hz (16-bit) +d51j.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +d51j.menu.cpu.samd51j18a_120=SAMD51J18A_120MHz +d51j.menu.cpu.samd51j18a_120.upload.maximum_size=253952 +d51j.menu.cpu.samd51j18a_120.build.mcu=cortex-m4 +d51j.menu.cpu.samd51j18a_120.build.mathlib=arm_cortexM4lf_math +d51j.menu.cpu.samd51j18a_120.build.f_cpu=120000000L +d51j.menu.cpu.samd51j18a_120.build.usb_product="Xeno D51" + +# KH mod +#d51j.menu.cpu.samd51j18a_120.build.extra_flags=-D__SAMD51J18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51j.menu.cpu.samd51j18a_120.build.extra_flags=-D__SAMD51J18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51j.menu.cpu.samd51j18a_120.build.ldscript=flash_m4f_256KB.ld +d51j.menu.cpu.samd51j18a_120.build.openocdscript=openocd_scripts/SAMD51J18A.cfg +d51j.menu.cpu.samd51j18a_120.bootloader.file=zero/binaries/sam_ba_SAMD51J18A.bin +d51j.menu.cpu.samd51j18a_48=SAMD51J18A_48MHz +d51j.menu.cpu.samd51j18a_48.upload.maximum_size=253952 +d51j.menu.cpu.samd51j18a_48.build.mcu=cortex-m4 +d51j.menu.cpu.samd51j18a_48.build.mathlib=arm_cortexM4lf_math +d51j.menu.cpu.samd51j18a_48.build.f_cpu=48000000L +d51j.menu.cpu.samd51j18a_48.build.usb_product="Xeno D51" + +# KH mod +#d51j.menu.cpu.samd51j18a_48.build.extra_flags=-D__SAMD51J18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51j.menu.cpu.samd51j18a_48.build.extra_flags=-D__SAMD51J18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51j.menu.cpu.samd51j18a_48.build.ldscript=flash_m4f_256KB.ld +d51j.menu.cpu.samd51j18a_48.build.openocdscript=openocd_scripts/SAMD51J18A.cfg +d51j.menu.cpu.samd51j18a_48.bootloader.file=zero/binaries/sam_ba_SAMD51J18A.bin +d51j.menu.cpu.samd51j19a_120=SAMD51J19A_120MHz +d51j.menu.cpu.samd51j19a_120.upload.maximum_size=516096 +d51j.menu.cpu.samd51j19a_120.build.mcu=cortex-m4 +d51j.menu.cpu.samd51j19a_120.build.mathlib=arm_cortexM4lf_math +d51j.menu.cpu.samd51j19a_120.build.f_cpu=120000000L +d51j.menu.cpu.samd51j19a_120.build.usb_product="Xeno D51" + +# KH mod +#d51j.menu.cpu.samd51j19a_120.build.extra_flags=-D__SAMD51J19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51j.menu.cpu.samd51j19a_120.build.extra_flags=-D__SAMD51J19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51j.menu.cpu.samd51j19a_120.build.ldscript=flash_m4f_512KB.ld +d51j.menu.cpu.samd51j19a_120.build.openocdscript=openocd_scripts/SAMD51J19A.cfg +d51j.menu.cpu.samd51j19a_120.bootloader.file=zero/binaries/sam_ba_SAMD51J19A.bin +d51j.menu.cpu.samd51j19a_48=SAMD51J19A_48MHz +d51j.menu.cpu.samd51j19a_48.upload.maximum_size=516096 +d51j.menu.cpu.samd51j19a_48.build.mcu=cortex-m4 +d51j.menu.cpu.samd51j19a_48.build.mathlib=arm_cortexM4lf_math +d51j.menu.cpu.samd51j19a_48.build.f_cpu=48000000L +d51j.menu.cpu.samd51j19a_48.build.usb_product="Xeno D51" + +# KH mod +#d51j.menu.cpu.samd51j19a_48.build.extra_flags=-D__SAMD51J19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51j.menu.cpu.samd51j19a_48.build.extra_flags=-D__SAMD51J19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51j.menu.cpu.samd51j19a_48.build.ldscript=flash_m4f_512KB.ld +d51j.menu.cpu.samd51j19a_48.build.openocdscript=openocd_scripts/SAMD51J19A.cfg +d51j.menu.cpu.samd51j19a_48.bootloader.file=zero/binaries/sam_ba_SAMD51J19A.bin +d51j.menu.cpu.samd51j20a_120=SAMD51J20A_120MHz +d51j.menu.cpu.samd51j20a_120.upload.maximum_size=1040384 +d51j.menu.cpu.samd51j20a_120.build.mcu=cortex-m4 +d51j.menu.cpu.samd51j20a_120.build.mathlib=arm_cortexM4lf_math +d51j.menu.cpu.samd51j20a_120.build.f_cpu=120000000L +d51j.menu.cpu.samd51j20a_120.build.usb_product="Xeno D51" + +# KH mod +#d51j.menu.cpu.samd51j20a_120.build.extra_flags=-D__SAMD51J20A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51j.menu.cpu.samd51j20a_120.build.extra_flags=-D__SAMD51J20A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51j.menu.cpu.samd51j20a_120.build.ldscript=flash_m4f_1MB.ld +d51j.menu.cpu.samd51j20a_120.build.openocdscript=openocd_scripts/SAMD51J20A.cfg +d51j.menu.cpu.samd51j20a_120.bootloader.file=zero/binaries/sam_ba_SAMD51J20A.bin +d51j.menu.cpu.samd51j20a_48=SAMD51J20A_48MHz +d51j.menu.cpu.samd51j20a_48.upload.maximum_size=1040384 +d51j.menu.cpu.samd51j20a_48.build.mcu=cortex-m4 +d51j.menu.cpu.samd51j20a_48.build.mathlib=arm_cortexM4lf_math +d51j.menu.cpu.samd51j20a_48.build.f_cpu=48000000L +d51j.menu.cpu.samd51j20a_48.build.usb_product="Xeno D51" + +# KH mod +#d51j.menu.cpu.samd51j20a_48.build.extra_flags=-D__SAMD51J20A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51j.menu.cpu.samd51j20a_48.build.extra_flags=-D__SAMD51J20A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51j.menu.cpu.samd51j20a_48.build.ldscript=flash_m4f_1MB.ld +d51j.menu.cpu.samd51j20a_48.build.openocdscript=openocd_scripts/SAMD51J20A.cfg +d51j.menu.cpu.samd51j20a_48.bootloader.file=zero/binaries/sam_ba_SAMD51J20A.bin +d51j.menu.bootloader.8kb=8KB_BOOTLOADER +d51j.menu.bootloader.8kb.build.bootloader_size=__8KB_BOOTLOADER__ +d51j.menu.bootloader.8kb.build.ldscript_path=linker_scripts/gcc/8KB_Bootloader +d51j.menu.bootloader.8kb.upload.tool=Fab_SAM_Arduino:bossac +d51j.menu.bootloader.8kb.upload.use_1200bps_touch=true +d51j.menu.bootloader.8kb.upload.wait_for_upload_port=true +d51j.menu.bootloader.8kb.upload.native_usb=true +d51j.menu.bootloader.16kb=16KB_BOOTLOADER +d51j.menu.bootloader.16kb.build.bootloader_size=__16KB_BOOTLOADER__ +d51j.menu.bootloader.16kb.build.ldscript_path=linker_scripts/gcc/16KB_Bootloader +d51j.menu.bootloader.16kb.upload.tool=Fab_SAM_Arduino:bossac +d51j.menu.bootloader.16kb.upload.use_1200bps_touch=true +d51j.menu.bootloader.16kb.upload.wait_for_upload_port=true +d51j.menu.bootloader.16kb.upload.native_usb=true +d51j.menu.bootloader.0kb=NO_BOOTLOADER +d51j.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +d51j.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +d51j.menu.bootloader.0kb.upload.tool=openocd +d51j.menu.bootloader.0kb.upload.use_1200bps_touch=false +d51j.menu.bootloader.0kb.upload.wait_for_upload_port=false +d51j.menu.bootloader.0kb.upload.native_usb=false +d51j.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +d51j.menu.serial.one_uart.build.serialcom_uart=ONE_UART +d51j.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +d51j.menu.serial.one_uart_two_spi=ONE_UART_ONE_WIRE_TWO_SPI +d51j.menu.serial.one_uart_two_spi.build.serialcom_uart=ONE_UART +d51j.menu.serial.one_uart_two_spi.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.one_uart_two_spi.build.serialcom_spi=TWO_SPI +d51j.menu.serial.one_uart_two_wire=ONE_UART_TWO_WIRE_ONE_SPI +d51j.menu.serial.one_uart_two_wire.build.serialcom_uart=ONE_UART +d51j.menu.serial.one_uart_two_wire.build.serialcom_wire=TWO_WIRE +d51j.menu.serial.one_uart_two_wire.build.serialcom_spi=ONE_SPI +d51j.menu.serial.two_uart=TWO_UART_ONE_WIRE_ONE_SPI +d51j.menu.serial.two_uart.build.serialcom_uart=TWO_UART +d51j.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.two_uart.build.serialcom_spi=ONE_SPI +d51j.menu.serial.two_uart_two_spi=TWO_UART_ONE_WIRE_TWO_SPI +d51j.menu.serial.two_uart_two_spi.build.serialcom_uart=TWO_UART +d51j.menu.serial.two_uart_two_spi.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.two_uart_two_spi.build.serialcom_spi=TWO_SPI +d51j.menu.serial.two_uart_two_wire=TWO_UART_TWO_WIRE_ONE_SPI +d51j.menu.serial.two_uart_two_wire.build.serialcom_uart=TWO_UART +d51j.menu.serial.two_uart_two_wire.build.serialcom_wire=TWO_WIRE +d51j.menu.serial.two_uart_two_wire.build.serialcom_spi=ONE_SPI +d51j.menu.serial.three_uart=THREE_UART_ONE_WIRE_ONE_SPI +d51j.menu.serial.three_uart.build.serialcom_uart=THREE_UART +d51j.menu.serial.three_uart.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.three_uart.build.serialcom_spi=ONE_SPI +d51j.menu.serial.three_uart_two_spi=THREE_UART_ONE_WIRE_TWO_SPI +d51j.menu.serial.three_uart_two_spi.build.serialcom_uart=THREE_UART +d51j.menu.serial.three_uart_two_spi.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.three_uart_two_spi.build.serialcom_spi=TWO_SPI +d51j.menu.serial.three_uart_two_wire=THREE_UART_TWO_WIRE_ONE_SPI +d51j.menu.serial.three_uart_two_wire.build.serialcom_uart=THREE_UART +d51j.menu.serial.three_uart_two_wire.build.serialcom_wire=TWO_WIRE +d51j.menu.serial.three_uart_two_wire.build.serialcom_spi=ONE_SPI +d51j.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +d51j.menu.serial.no_uart.build.serialcom_uart=NO_UART +d51j.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +d51j.menu.usb.cdc=CDC_ONLY +d51j.menu.usb.cdc.build.usbcom=CDC_ONLY +d51j.menu.usb.cdc.build.pid=0x8557 +d51j.menu.usb.cdc_hid=CDC_HID +d51j.menu.usb.cdc_hid.build.usbcom=CDC_HID +d51j.menu.usb.cdc_hid.build.pid=0x8856 +d51j.menu.usb.withcdc=WITH_CDC +d51j.menu.usb.withcdc.build.usbcom=WITH_CDC +d51j.menu.usb.withcdc.build.pid=0x8B41 +d51j.menu.usb.hid=HID_ONLY +d51j.menu.usb.hid.build.usbcom=HID_ONLY +d51j.menu.usb.hid.build.pid=0x8B40 +d51j.menu.usb.nocdc=WITHOUT_CDC +d51j.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +d51j.menu.usb.nocdc.build.pid=0x8A0C +d51j.menu.usb.none=USB_DISABLED +d51j.menu.usb.none.build.usbcom=USB_DISABLED +d51j.menu.usb.none.build.pid=0x8856 diff --git a/Packages_Patches/Fab_SAM_Arduino/hardware/samd/1.9.0/boards.txt b/Packages_Patches/Fab_SAM_Arduino/hardware/samd/1.9.0/boards.txt new file mode 100644 index 00000000..fef27b73 --- /dev/null +++ b/Packages_Patches/Fab_SAM_Arduino/hardware/samd/1.9.0/boards.txt @@ -0,0 +1,1751 @@ +# Copyright (c) 2014-2017 Arduino LLC. All right reserved. +# +# 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + +menu.cpu=Microcontroller +menu.clock=Clock Source +menu.usb=USB Config +menu.serial=Serial Config +menu.bootloader=Bootloader Size +menu.timer=Timer PWM Frequency +menu.float=Floating Point +menu.config=Build Options + +# Generic D11C14A +d11c14a.name=Generic D11C14A +d11c14a.vid.0=0x16D0 +d11c14a.pid.0=0x1557 +d11c14a.vid.1=0x16D0 +d11c14a.pid.1=0x1856 +d11c14a.vid.2=0x16D0 +d11c14a.pid.2=0x1B41 +d11c14a.vid.3=0x16D0 +d11c14a.pid.3=0x1B40 +d11c14a.vid.4=0x16D0 +d11c14a.pid.4=0x1A0C +d11c14a.vid.5=0x16D0 +d11c14a.pid.5=0x1856 +d11c14a.build.mcu=cortex-m0plus +d11c14a.build.mathlib=arm_cortexM0l_math +d11c14a.build.f_cpu=48000000L +d11c14a.build.usb_product="D11C14A" +d11c14a.build.usb_manufacturer="Fab Foundation" +d11c14a.build.board=SAMD_ZERO +d11c14a.build.core=arduino +d11c14a.build.variant=Generic_D11C14A +d11c14a.build.variant_system_lib= +d11c14a.build.vid=0x16D0 +d11c14a.upload.protocol=sam-ba +d11c14a.bootloader.tool=openocd-withbootsize +d11c14a.menu.float.default=Print & String use auto-promoted doubles only +d11c14a.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +d11c14a.menu.float.print=Print uses separate singles and doubles +d11c14a.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +d11c14a.menu.float.string=String uses separate singles and doubles +d11c14a.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +d11c14a.menu.float.both=Print & String use separate singles and doubles +d11c14a.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +d11c14a.menu.config.disabled=config.h disabled +d11c14a.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +d11c14a.menu.config.enabled=config.h enabled (mostly code size reductions) +d11c14a.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +d11c14a.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +d11c14a.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +d11c14a.menu.clock.internal=INTERNAL_OSCILLATOR +d11c14a.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +d11c14a.menu.clock.crystal_32k=32KHZ_CRYSTAL +d11c14a.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +d11c14a.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +d11c14a.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +d11c14a.menu.timer.timer_732Hz=732.4Hz (16-bit) +d11c14a.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +d11c14a.menu.timer.timer_366Hz=366.2Hz (16-bit) +d11c14a.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +d11c14a.menu.timer.timer_244Hz=244.1Hz (16-bit) +d11c14a.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +d11c14a.menu.timer.timer_183Hz=183.1Hz (16-bit) +d11c14a.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +d11c14a.menu.timer.timer_146Hz=146.5Hz (16-bit) +d11c14a.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +d11c14a.menu.timer.timer_122Hz=122.1Hz (16-bit) +d11c14a.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +d11c14a.menu.timer.timer_105Hz=104.6Hz (16-bit) +d11c14a.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +d11c14a.menu.timer.timer_81Hz=81.38Hz (16-bit) +d11c14a.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +d11c14a.menu.timer.timer_61Hz=61.04Hz (16-bit) +d11c14a.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +d11c14a.menu.timer.timer_31Hz=30.52Hz (16-bit) +d11c14a.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +d11c14a.menu.timer.timer_187500Hz=187500Hz (8-bit) +d11c14a.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +d11c14a.menu.timer.timer_93750Hz=93750Hz (8-bit) +d11c14a.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +d11c14a.menu.timer.timer_62500Hz=62500Hz (8-bit) +d11c14a.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +d11c14a.menu.timer.timer_37500Hz=37500Hz (8-bit) +d11c14a.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +d11c14a.menu.timer.timer_20833Hz=20833Hz (8-bit) +d11c14a.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +d11c14a.menu.timer.timer_12500Hz=12500Hz (8-bit) +d11c14a.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +d11c14a.menu.timer.timer_7500Hz=7500Hz (8-bit) +d11c14a.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +d11c14a.menu.timer.timer_4166Hz=4166Hz (8-bit) +d11c14a.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +d11c14a.menu.timer.timer_2930Hz=2930Hz (8-bit) +d11c14a.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +d11c14a.menu.timer.timer_1465Hz=1465Hz (8-bit) +d11c14a.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +d11c14a.build.extra_flags=-D__SAMD11C14A__ {build.usb_flags} -DARM_MATH_CM0PLUS +d11c14a.build.ldscript=flash_16KB.ld +d11c14a.build.openocdscript=openocd_scripts/SAMD11C14A.cfg +d11c14a.bootloader.file=zero/binaries/sam_ba_SAMD11C14A.bin +d11c14a.menu.bootloader.4kb=4KB_BOOTLOADER +d11c14a.menu.bootloader.4kb.build.bootloader_size=__4KB_BOOTLOADER__ +d11c14a.menu.bootloader.4kb.build.ldscript_path=linker_scripts/gcc/4KB_Bootloader +d11c14a.menu.bootloader.4kb.upload.tool=Fab_SAM_Arduino:bossac +d11c14a.menu.bootloader.4kb.upload.use_1200bps_touch=true +d11c14a.menu.bootloader.4kb.upload.wait_for_upload_port=true +d11c14a.menu.bootloader.4kb.upload.native_usb=true +d11c14a.menu.bootloader.4kb.upload.maximum_size=12288 +d11c14a.menu.bootloader.4kb.upload.offset=0x1000 +d11c14a.menu.bootloader.0kb=NO_BOOTLOADER +d11c14a.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +d11c14a.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +d11c14a.menu.bootloader.0kb.upload.tool=openocd-withbootsize +d11c14a.menu.bootloader.0kb.upload.use_1200bps_touch=false +d11c14a.menu.bootloader.0kb.upload.wait_for_upload_port=false +d11c14a.menu.bootloader.0kb.upload.native_usb=false +d11c14a.menu.bootloader.0kb.upload.maximum_size=16384 +d11c14a.menu.bootloader.0kb.upload.offset=0x0000 +d11c14a.menu.serial.one_uart=ONE_UART_ONE_WIRE_NO_SPI +d11c14a.menu.serial.one_uart.build.serialcom_uart=ONE_UART +d11c14a.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +d11c14a.menu.serial.one_uart.build.serialcom_spi=NO_SPI +d11c14a.menu.serial.two_uart=TWO_UART_NO_WIRE_NO_SPI +d11c14a.menu.serial.two_uart.build.serialcom_uart=TWO_UART +d11c14a.menu.serial.two_uart.build.serialcom_wire=NO_WIRE +d11c14a.menu.serial.two_uart.build.serialcom_spi=NO_SPI +d11c14a.menu.serial.one_uart_no_wire_one_spi=ONE_UART_NO_WIRE_ONE_SPI +d11c14a.menu.serial.one_uart_no_wire_one_spi.build.serialcom_uart=ONE_UART +d11c14a.menu.serial.one_uart_no_wire_one_spi.build.serialcom_wire=NO_WIRE +d11c14a.menu.serial.one_uart_no_wire_one_spi.build.serialcom_spi=ONE_SPI +d11c14a.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +d11c14a.menu.serial.no_uart.build.serialcom_uart=NO_UART +d11c14a.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +d11c14a.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +d11c14a.menu.usb.cdc=CDC_ONLY +d11c14a.menu.usb.cdc.build.usbcom=CDC_ONLY +d11c14a.menu.usb.cdc.build.pid=0x1557 +d11c14a.menu.usb.cdc_hid=CDC_HID +d11c14a.menu.usb.cdc_hid.build.usbcom=CDC_HID +d11c14a.menu.usb.cdc_hid.build.pid=0x1856 +d11c14a.menu.usb.withcdc=WITH_CDC +d11c14a.menu.usb.withcdc.build.usbcom=WITH_CDC +d11c14a.menu.usb.withcdc.build.pid=0x1B41 +d11c14a.menu.usb.hid=HID_ONLY +d11c14a.menu.usb.hid.build.usbcom=HID_ONLY +d11c14a.menu.usb.hid.build.pid=0x1B40 +d11c14a.menu.usb.nocdc=WITHOUT_CDC +d11c14a.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +d11c14a.menu.usb.nocdc.build.pid=0x1A0C +d11c14a.menu.usb.none=USB_DISABLED +d11c14a.menu.usb.none.build.usbcom=USB_DISABLED +d11c14a.menu.usb.none.build.pid=0x1856 + +# Generic D11D14AS +d11d14as.name=Generic D11D14AS +d11d14as.vid.0=0x16D0 +d11d14as.pid.0=0x2557 +d11d14as.vid.1=0x16D0 +d11d14as.pid.1=0x2856 +d11d14as.vid.2=0x16D0 +d11d14as.pid.2=0x2B41 +d11d14as.vid.3=0x16D0 +d11d14as.pid.3=0x2B40 +d11d14as.vid.4=0x16D0 +d11d14as.pid.4=0x2A0C +d11d14as.vid.5=0x16D0 +d11d14as.pid.5=0x2856 +d11d14as.build.mcu=cortex-m0plus +d11d14as.build.mathlib=arm_cortexM0l_math +d11d14as.build.f_cpu=48000000L +d11d14as.build.usb_product="D11D14AS" +d11d14as.build.usb_manufacturer="Fab Foundation" +d11d14as.build.board=SAMD_ZERO +d11d14as.build.core=arduino +d11d14as.build.variant=Generic_D11D14AS +d11d14as.build.variant_system_lib= +d11d14as.build.vid=0x16D0 +d11d14as.upload.protocol=sam-ba +d11d14as.bootloader.tool=openocd-withbootsize +d11d14as.menu.float.default=Print & String use auto-promoted doubles only +d11d14as.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +d11d14as.menu.float.print=Print uses separate singles and doubles +d11d14as.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +d11d14as.menu.float.string=String uses separate singles and doubles +d11d14as.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +d11d14as.menu.float.both=Print & String use separate singles and doubles +d11d14as.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +d11d14as.menu.config.disabled=config.h disabled +d11d14as.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +d11d14as.menu.config.enabled=config.h enabled (mostly code size reductions) +d11d14as.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +d11d14as.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +d11d14as.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +d11d14as.menu.clock.internal=INTERNAL_OSCILLATOR +d11d14as.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +d11d14as.menu.clock.crystal_32k=32KHZ_CRYSTAL +d11d14as.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +d11d14as.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +d11d14as.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +d11d14as.menu.timer.timer_732Hz=732.4Hz (16-bit) +d11d14as.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +d11d14as.menu.timer.timer_366Hz=366.2Hz (16-bit) +d11d14as.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +d11d14as.menu.timer.timer_244Hz=244.1Hz (16-bit) +d11d14as.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +d11d14as.menu.timer.timer_183Hz=183.1Hz (16-bit) +d11d14as.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +d11d14as.menu.timer.timer_146Hz=146.5Hz (16-bit) +d11d14as.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +d11d14as.menu.timer.timer_122Hz=122.1Hz (16-bit) +d11d14as.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +d11d14as.menu.timer.timer_105Hz=104.6Hz (16-bit) +d11d14as.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +d11d14as.menu.timer.timer_81Hz=81.38Hz (16-bit) +d11d14as.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +d11d14as.menu.timer.timer_61Hz=61.04Hz (16-bit) +d11d14as.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +d11d14as.menu.timer.timer_31Hz=30.52Hz (16-bit) +d11d14as.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +d11d14as.menu.timer.timer_187500Hz=187500Hz (8-bit) +d11d14as.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +d11d14as.menu.timer.timer_93750Hz=93750Hz (8-bit) +d11d14as.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +d11d14as.menu.timer.timer_62500Hz=62500Hz (8-bit) +d11d14as.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +d11d14as.menu.timer.timer_37500Hz=37500Hz (8-bit) +d11d14as.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +d11d14as.menu.timer.timer_20833Hz=20833Hz (8-bit) +d11d14as.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +d11d14as.menu.timer.timer_12500Hz=12500Hz (8-bit) +d11d14as.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +d11d14as.menu.timer.timer_7500Hz=7500Hz (8-bit) +d11d14as.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +d11d14as.menu.timer.timer_4166Hz=4166Hz (8-bit) +d11d14as.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +d11d14as.menu.timer.timer_2930Hz=2930Hz (8-bit) +d11d14as.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +d11d14as.menu.timer.timer_1465Hz=1465Hz (8-bit) +d11d14as.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +d11d14as.build.extra_flags=-D__SAMD11D14AS__ {build.usb_flags} -DARM_MATH_CM0PLUS +d11d14as.build.ldscript=flash_16KB.ld +d11d14as.build.openocdscript=openocd_scripts/SAMD11D14AS.cfg +d11d14as.bootloader.file=zero/binaries/sam_ba_SAMD11D14AS.bin +d11d14as.menu.bootloader.4kb=4KB_BOOTLOADER +d11d14as.menu.bootloader.4kb.build.bootloader_size=__4KB_BOOTLOADER__ +d11d14as.menu.bootloader.4kb.build.ldscript_path=linker_scripts/gcc/4KB_Bootloader +d11d14as.menu.bootloader.4kb.upload.tool=Fab_SAM_Arduino:bossac +d11d14as.menu.bootloader.4kb.upload.use_1200bps_touch=true +d11d14as.menu.bootloader.4kb.upload.wait_for_upload_port=true +d11d14as.menu.bootloader.4kb.upload.native_usb=true +d11d14as.menu.bootloader.4kb.upload.maximum_size=12288 +d11d14as.menu.bootloader.4kb.upload.offset=0x1000 +d11d14as.menu.bootloader.0kb=NO_BOOTLOADER +d11d14as.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +d11d14as.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +d11d14as.menu.bootloader.0kb.upload.tool=openocd-withbootsize +d11d14as.menu.bootloader.0kb.upload.use_1200bps_touch=false +d11d14as.menu.bootloader.0kb.upload.wait_for_upload_port=false +d11d14as.menu.bootloader.0kb.upload.native_usb=false +d11d14as.menu.bootloader.0kb.upload.maximum_size=16384 +d11d14as.menu.bootloader.0kb.upload.offset=0x0000 +d11d14as.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +d11d14as.menu.serial.one_uart.build.serialcom_uart=ONE_UART +d11d14as.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +d11d14as.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +d11d14as.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +d11d14as.menu.serial.no_uart.build.serialcom_uart=NO_UART +d11d14as.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +d11d14as.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +d11d14as.menu.serial.two_uart=TWO_UART_ONE_WIRE_NO_SPI +d11d14as.menu.serial.two_uart.build.serialcom_uart=TWO_UART +d11d14as.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +d11d14as.menu.serial.two_uart.build.serialcom_spi=NO_SPI +d11d14as.menu.usb.cdc=CDC_ONLY +d11d14as.menu.usb.cdc.build.usbcom=CDC_ONLY +d11d14as.menu.usb.cdc.build.pid=0x2557 +d11d14as.menu.usb.cdc_hid=CDC_HID +d11d14as.menu.usb.cdc_hid.build.usbcom=CDC_HID +d11d14as.menu.usb.cdc_hid.build.pid=0x2856 +d11d14as.menu.usb.withcdc=WITH_CDC +d11d14as.menu.usb.withcdc.build.usbcom=WITH_CDC +d11d14as.menu.usb.withcdc.build.pid=0x2B41 +d11d14as.menu.usb.hid=HID_ONLY +d11d14as.menu.usb.hid.build.usbcom=HID_ONLY +d11d14as.menu.usb.hid.build.pid=0x2B40 +d11d14as.menu.usb.nocdc=WITHOUT_CDC +d11d14as.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +d11d14as.menu.usb.nocdc.build.pid=0x2A0C +d11d14as.menu.usb.none=USB_DISABLED +d11d14as.menu.usb.none.build.usbcom=USB_DISABLED +d11d14as.menu.usb.none.build.pid=0x2856 + +# Generic D11D14AM +d11d14am.name=Generic D11D14AM +d11d14am.vid.0=0x16D0 +d11d14am.pid.0=0x3557 +d11d14am.vid.1=0x16D0 +d11d14am.pid.1=0x3856 +d11d14am.vid.2=0x16D0 +d11d14am.pid.2=0x3B41 +d11d14am.vid.3=0x16D0 +d11d14am.pid.3=0x3B40 +d11d14am.vid.4=0x16D0 +d11d14am.pid.4=0x3A0C +d11d14am.vid.5=0x16D0 +d11d14am.pid.5=0x3856 +d11d14am.build.mcu=cortex-m0plus +d11d14am.build.mathlib=arm_cortexM0l_math +d11d14am.build.f_cpu=48000000L +d11d14am.build.usb_product="MT-D11" +d11d14am.build.usb_manufacturer="Fab Foundation" +d11d14am.build.board=SAMD_ZERO +d11d14am.build.core=arduino +d11d14am.build.variant=Generic_D11D14AM +d11d14am.build.variant_system_lib= +d11d14am.build.vid=0x16D0 +d11d14am.upload.protocol=sam-ba +d11d14am.bootloader.tool=openocd-withbootsize +d11d14am.menu.float.default=Print & String use auto-promoted doubles only +d11d14am.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +d11d14am.menu.float.print=Print uses separate singles and doubles +d11d14am.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +d11d14am.menu.float.string=String uses separate singles and doubles +d11d14am.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +d11d14am.menu.float.both=Print & String use separate singles and doubles +d11d14am.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +d11d14am.menu.config.disabled=config.h disabled +d11d14am.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +d11d14am.menu.config.enabled=config.h enabled (mostly code size reductions) +d11d14am.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +d11d14am.menu.clock.crystal_32k=32KHZ_CRYSTAL +d11d14am.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +d11d14am.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +d11d14am.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +d11d14am.menu.clock.internal=INTERNAL_OSCILLATOR +d11d14am.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +d11d14am.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +d11d14am.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +d11d14am.menu.timer.timer_732Hz=732.4Hz (16-bit) +d11d14am.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +d11d14am.menu.timer.timer_366Hz=366.2Hz (16-bit) +d11d14am.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +d11d14am.menu.timer.timer_244Hz=244.1Hz (16-bit) +d11d14am.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +d11d14am.menu.timer.timer_183Hz=183.1Hz (16-bit) +d11d14am.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +d11d14am.menu.timer.timer_146Hz=146.5Hz (16-bit) +d11d14am.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +d11d14am.menu.timer.timer_122Hz=122.1Hz (16-bit) +d11d14am.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +d11d14am.menu.timer.timer_105Hz=104.6Hz (16-bit) +d11d14am.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +d11d14am.menu.timer.timer_81Hz=81.38Hz (16-bit) +d11d14am.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +d11d14am.menu.timer.timer_61Hz=61.04Hz (16-bit) +d11d14am.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +d11d14am.menu.timer.timer_31Hz=30.52Hz (16-bit) +d11d14am.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +d11d14am.menu.timer.timer_187500Hz=187500Hz (8-bit) +d11d14am.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +d11d14am.menu.timer.timer_93750Hz=93750Hz (8-bit) +d11d14am.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +d11d14am.menu.timer.timer_62500Hz=62500Hz (8-bit) +d11d14am.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +d11d14am.menu.timer.timer_37500Hz=37500Hz (8-bit) +d11d14am.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +d11d14am.menu.timer.timer_20833Hz=20833Hz (8-bit) +d11d14am.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +d11d14am.menu.timer.timer_12500Hz=12500Hz (8-bit) +d11d14am.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +d11d14am.menu.timer.timer_7500Hz=7500Hz (8-bit) +d11d14am.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +d11d14am.menu.timer.timer_4166Hz=4166Hz (8-bit) +d11d14am.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +d11d14am.menu.timer.timer_2930Hz=2930Hz (8-bit) +d11d14am.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +d11d14am.menu.timer.timer_1465Hz=1465Hz (8-bit) +d11d14am.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +d11d14am.build.extra_flags=-D__SAMD11D14AM__ {build.usb_flags} -DARM_MATH_CM0PLUS +d11d14am.build.ldscript=flash_16KB.ld +d11d14am.build.openocdscript=openocd_scripts/SAMD11D14AM.cfg +d11d14am.bootloader.file=zero/binaries/sam_ba_SAMD11D14AM.bin +d11d14am.menu.bootloader.4kb=4KB_BOOTLOADER +d11d14am.menu.bootloader.4kb.build.bootloader_size=__4KB_BOOTLOADER__ +d11d14am.menu.bootloader.4kb.build.ldscript_path=linker_scripts/gcc/4KB_Bootloader +d11d14am.menu.bootloader.4kb.upload.tool=Fab_SAM_Arduino:bossac +d11d14am.menu.bootloader.4kb.upload.use_1200bps_touch=true +d11d14am.menu.bootloader.4kb.upload.wait_for_upload_port=true +d11d14am.menu.bootloader.4kb.upload.native_usb=true +d11d14am.menu.bootloader.4kb.upload.maximum_size=12288 +d11d14am.menu.bootloader.4kb.upload.offset=0x1000 +d11d14am.menu.bootloader.0kb=NO_BOOTLOADER +d11d14am.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +d11d14am.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +d11d14am.menu.bootloader.0kb.upload.tool=openocd-withbootsize +d11d14am.menu.bootloader.0kb.upload.use_1200bps_touch=false +d11d14am.menu.bootloader.0kb.upload.wait_for_upload_port=false +d11d14am.menu.bootloader.0kb.upload.native_usb=false +d11d14am.menu.bootloader.0kb.upload.maximum_size=16384 +d11d14am.menu.bootloader.0kb.upload.offset=0x0000 +d11d14am.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +d11d14am.menu.serial.one_uart.build.serialcom_uart=ONE_UART +d11d14am.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +d11d14am.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +d11d14am.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +d11d14am.menu.serial.no_uart.build.serialcom_uart=NO_UART +d11d14am.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +d11d14am.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +d11d14am.menu.serial.two_uart=TWO_UART_ONE_WIRE_NO_SPI +d11d14am.menu.serial.two_uart.build.serialcom_uart=TWO_UART +d11d14am.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +d11d14am.menu.serial.two_uart.build.serialcom_spi=NO_SPI +d11d14am.menu.usb.cdc=CDC_ONLY +d11d14am.menu.usb.cdc.build.usbcom=CDC_ONLY +d11d14am.menu.usb.cdc.build.pid=0x3557 +d11d14am.menu.usb.cdc_hid=CDC_HID +d11d14am.menu.usb.cdc_hid.build.usbcom=CDC_HID +d11d14am.menu.usb.cdc_hid.build.pid=0x3856 +d11d14am.menu.usb.withcdc=WITH_CDC +d11d14am.menu.usb.withcdc.build.usbcom=WITH_CDC +d11d14am.menu.usb.withcdc.build.pid=0x3B41 +d11d14am.menu.usb.hid=HID_ONLY +d11d14am.menu.usb.hid.build.usbcom=HID_ONLY +d11d14am.menu.usb.hid.build.pid=0x3B40 +d11d14am.menu.usb.nocdc=WITHOUT_CDC +d11d14am.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +d11d14am.menu.usb.nocdc.build.pid=0x3A0C +d11d14am.menu.usb.none=USB_DISABLED +d11d14am.menu.usb.none.build.usbcom=USB_DISABLED +d11d14am.menu.usb.none.build.pid=0x3856 + +# Generic x21E +x21e.name=Generic x21E +x21e.vid.0=0x16D0 +x21e.pid.0=0x4557 +x21e.vid.1=0x16D0 +x21e.pid.1=0x4856 +x21e.vid.2=0x16D0 +x21e.pid.2=0x4B41 +x21e.vid.3=0x16D0 +x21e.pid.3=0x4B40 +x21e.vid.4=0x16D0 +x21e.pid.4=0x4A0C +x21e.vid.5=0x16D0 +x21e.pid.5=0x4856 +x21e.build.mcu=cortex-m0plus +x21e.build.mathlib=arm_cortexM0l_math +x21e.build.f_cpu=48000000L +x21e.build.usb_product="x21E" +x21e.build.usb_manufacturer="Fab Foundation" +x21e.build.board=SAMD_ZERO +x21e.build.core=arduino +x21e.build.variant=Generic_x21E +x21e.build.variant_system_lib= +x21e.build.vid=0x16D0 +x21e.upload.protocol=sam-ba +x21e.bootloader.tool=openocd-withbootsize +x21e.menu.float.default=Print & String use auto-promoted doubles only +x21e.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +x21e.menu.float.print=Print uses separate singles and doubles +x21e.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +x21e.menu.float.string=String uses separate singles and doubles +x21e.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +x21e.menu.float.both=Print & String use separate singles and doubles +x21e.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +x21e.menu.config.disabled=config.h disabled +x21e.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +x21e.menu.config.enabled=config.h enabled (mostly code size reductions) +x21e.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +x21e.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +x21e.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +x21e.menu.clock.internal=INTERNAL_OSCILLATOR +x21e.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +x21e.menu.clock.crystal_32k=32KHZ_CRYSTAL +x21e.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +x21e.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +x21e.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +x21e.menu.timer.timer_732Hz=732.4Hz (16-bit) +x21e.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +x21e.menu.timer.timer_366Hz=366.2Hz (16-bit) +x21e.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +x21e.menu.timer.timer_244Hz=244.1Hz (16-bit) +x21e.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +x21e.menu.timer.timer_183Hz=183.1Hz (16-bit) +x21e.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +x21e.menu.timer.timer_146Hz=146.5Hz (16-bit) +x21e.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +x21e.menu.timer.timer_122Hz=122.1Hz (16-bit) +x21e.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +x21e.menu.timer.timer_105Hz=104.6Hz (16-bit) +x21e.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +x21e.menu.timer.timer_81Hz=81.38Hz (16-bit) +x21e.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +x21e.menu.timer.timer_61Hz=61.04Hz (16-bit) +x21e.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +x21e.menu.timer.timer_31Hz=30.52Hz (16-bit) +x21e.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +x21e.menu.timer.timer_187500Hz=187500Hz (8-bit) +x21e.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +x21e.menu.timer.timer_93750Hz=93750Hz (8-bit) +x21e.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +x21e.menu.timer.timer_62500Hz=62500Hz (8-bit) +x21e.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +x21e.menu.timer.timer_37500Hz=37500Hz (8-bit) +x21e.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +x21e.menu.timer.timer_20833Hz=20833Hz (8-bit) +x21e.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +x21e.menu.timer.timer_12500Hz=12500Hz (8-bit) +x21e.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +x21e.menu.timer.timer_7500Hz=7500Hz (8-bit) +x21e.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +x21e.menu.timer.timer_4166Hz=4166Hz (8-bit) +x21e.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +x21e.menu.timer.timer_2930Hz=2930Hz (8-bit) +x21e.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +x21e.menu.timer.timer_1465Hz=1465Hz (8-bit) +x21e.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +x21e.menu.cpu.samd21e15a=SAMD21E15A +x21e.menu.cpu.samd21e15a.upload.maximum_size=24576 +x21e.menu.cpu.samd21e15a.build.extra_flags=-D__SAMD21E15A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.samd21e15a.build.ldscript=flash_32KB.ld +x21e.menu.cpu.samd21e15a.build.openocdscript=openocd_scripts/SAMD21E15A.cfg +x21e.menu.cpu.samd21e15a.bootloader.file=zero/binaries/sam_ba_SAMD21E15A.bin +x21e.menu.cpu.samd21e16a=SAMD21E16A +x21e.menu.cpu.samd21e16a.upload.maximum_size=57344 +x21e.menu.cpu.samd21e16a.build.extra_flags=-D__SAMD21E16A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.samd21e16a.build.ldscript=flash_64KB.ld +x21e.menu.cpu.samd21e16a.build.openocdscript=openocd_scripts/SAMD21E16A.cfg +x21e.menu.cpu.samd21e16a.bootloader.file=zero/binaries/sam_ba_SAMD21E16A.bin +x21e.menu.cpu.samd21e17a=SAMD21E17A +x21e.menu.cpu.samd21e17a.upload.maximum_size=122880 +x21e.menu.cpu.samd21e17a.build.extra_flags=-D__SAMD21E17A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.samd21e17a.build.ldscript=flash_128KB.ld +x21e.menu.cpu.samd21e17a.build.openocdscript=openocd_scripts/SAMD21E17A.cfg +x21e.menu.cpu.samd21e17a.bootloader.file=zero/binaries/sam_ba_SAMD21E17A.bin +x21e.menu.cpu.samd21e18a=SAMD21E18A +x21e.menu.cpu.samd21e18a.upload.maximum_size=253952 +x21e.menu.cpu.samd21e18a.build.extra_flags=-D__SAMD21E18A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.samd21e18a.build.ldscript=flash_256KB.ld +x21e.menu.cpu.samd21e18a.build.openocdscript=openocd_scripts/SAMD21E18A.cfg +x21e.menu.cpu.samd21e18a.bootloader.file=zero/binaries/sam_ba_SAMD21E18A.bin +x21e.menu.cpu.saml21e15b=SAML21E15B +x21e.menu.cpu.saml21e15b.upload.maximum_size=24576 +x21e.menu.cpu.saml21e15b.build.extra_flags=-D__SAML21E15B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.saml21e15b.build.ldscript=flash_32KB.ld +x21e.menu.cpu.saml21e15b.build.openocdscript=openocd_scripts/SAML21E15B.cfg +x21e.menu.cpu.saml21e15b.bootloader.file=zero/binaries/sam_ba_SAML21E15B.bin +x21e.menu.cpu.saml21e16b=SAML21E16B +x21e.menu.cpu.saml21e16b.upload.maximum_size=57344 +x21e.menu.cpu.saml21e16b.build.extra_flags=-D__SAML21E16B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.saml21e16b.build.ldscript=flash_64KB.ld +x21e.menu.cpu.saml21e16b.build.openocdscript=openocd_scripts/SAML21E16B.cfg +x21e.menu.cpu.saml21e16b.bootloader.file=zero/binaries/sam_ba_SAML21E16B.bin +x21e.menu.cpu.saml21e17b=SAML21E17B +x21e.menu.cpu.saml21e17b.upload.maximum_size=122880 +x21e.menu.cpu.saml21e17b.build.extra_flags=-D__SAML21E17B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.saml21e17b.build.ldscript=flash_128KB.ld +x21e.menu.cpu.saml21e17b.build.openocdscript=openocd_scripts/SAML21E17B.cfg +x21e.menu.cpu.saml21e17b.bootloader.file=zero/binaries/sam_ba_SAML21E17B.bin +x21e.menu.cpu.saml21e18b=SAML21E18B +x21e.menu.cpu.saml21e18b.upload.maximum_size=253952 +x21e.menu.cpu.saml21e18b.build.extra_flags=-D__SAML21E18B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.saml21e18b.build.ldscript=flash_256KB.ld +x21e.menu.cpu.saml21e18b.build.openocdscript=openocd_scripts/SAML21E18B.cfg +x21e.menu.cpu.saml21e18b.bootloader.file=zero/binaries/sam_ba_SAML21E18B.bin +x21e.menu.cpu.samc21e15a=SAMC21E15A +x21e.menu.cpu.samc21e15a.upload.maximum_size=24576 +x21e.menu.cpu.samc21e15a.build.extra_flags=-D__SAMC21E15A__ -DARM_MATH_CM0PLUS +x21e.menu.cpu.samc21e15a.build.ldscript=flash_32KB.ld +x21e.menu.cpu.samc21e15a.build.openocdscript=openocd_scripts/SAMC21E15A.cfg +x21e.menu.cpu.samc21e15a.bootloader.file=zero/binaries/sam_ba_SAMC21E15A.bin +x21e.menu.cpu.samc21e16a=SAMC21E16A +x21e.menu.cpu.samc21e16a.upload.maximum_size=57344 +x21e.menu.cpu.samc21e16a.build.extra_flags=-D__SAMC21E16A__ -DARM_MATH_CM0PLUS +x21e.menu.cpu.samc21e16a.build.ldscript=flash_64KB.ld +x21e.menu.cpu.samc21e16a.build.openocdscript=openocd_scripts/SAMC21E16A.cfg +x21e.menu.cpu.samc21e16a.bootloader.file=zero/binaries/sam_ba_SAMC21E16A.bin +x21e.menu.cpu.samc21e17a=SAMC21E17A +x21e.menu.cpu.samc21e17a.upload.maximum_size=122880 +x21e.menu.cpu.samc21e17a.build.extra_flags=-D__SAMC21E17A__ -DARM_MATH_CM0PLUS +x21e.menu.cpu.samc21e17a.build.ldscript=flash_128KB.ld +x21e.menu.cpu.samc21e17a.build.openocdscript=openocd_scripts/SAMC21E17A.cfg +x21e.menu.cpu.samc21e17a.bootloader.file=zero/binaries/sam_ba_SAMC21E17A.bin +x21e.menu.cpu.samc21e18a=SAMC21E18A +x21e.menu.cpu.samc21e18a.upload.maximum_size=253952 +x21e.menu.cpu.samc21e18a.build.extra_flags=-D__SAMC21E18A__ -DARM_MATH_CM0PLUS +x21e.menu.cpu.samc21e18a.build.ldscript=flash_256KB.ld +x21e.menu.cpu.samc21e18a.build.openocdscript=openocd_scripts/SAMC21E18A.cfg +x21e.menu.cpu.samc21e18a.bootloader.file=zero/binaries/sam_ba_SAMC21E18A.bin +x21e.menu.bootloader.8kb=8KB_BOOTLOADER +x21e.menu.bootloader.8kb.build.bootloader_size=__8KB_BOOTLOADER__ +x21e.menu.bootloader.8kb.build.ldscript_path=linker_scripts/gcc/8KB_Bootloader +x21e.menu.bootloader.8kb.upload.tool=Fab_SAM_Arduino:bossac +x21e.menu.bootloader.8kb.upload.use_1200bps_touch=true +x21e.menu.bootloader.8kb.upload.wait_for_upload_port=true +x21e.menu.bootloader.8kb.upload.native_usb=true +x21e.menu.bootloader.8kb.upload.offset=0x2000 +x21e.menu.bootloader.16kb=16KB_BOOTLOADER +x21e.menu.bootloader.16kb.build.bootloader_size=__16KB_BOOTLOADER__ +x21e.menu.bootloader.16kb.build.ldscript_path=linker_scripts/gcc/16KB_Bootloader +x21e.menu.bootloader.16kb.upload.tool=Fab_SAM_Arduino:bossac +x21e.menu.bootloader.16kb.upload.use_1200bps_touch=true +x21e.menu.bootloader.16kb.upload.wait_for_upload_port=true +x21e.menu.bootloader.16kb.upload.native_usb=true +x21e.menu.bootloader.16kb.upload.offset=0x4000 +x21e.menu.bootloader.0kb=NO_BOOTLOADER +x21e.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +x21e.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +x21e.menu.bootloader.0kb.upload.tool=openocd-withbootsize +x21e.menu.bootloader.0kb.upload.use_1200bps_touch=false +x21e.menu.bootloader.0kb.upload.wait_for_upload_port=false +x21e.menu.bootloader.0kb.upload.native_usb=false +x21e.menu.bootloader.0kb.upload.offset=0x0000 +x21e.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +x21e.menu.serial.one_uart.build.serialcom_uart=ONE_UART +x21e.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +x21e.menu.serial.one_uart_one_wire_two_spi=ONE_UART_ONE_WIRE_TWO_SPI +x21e.menu.serial.one_uart_one_wire_two_spi.build.serialcom_uart=ONE_UART +x21e.menu.serial.one_uart_one_wire_two_spi.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.one_uart_one_wire_two_spi.build.serialcom_spi=TWO_SPI +x21e.menu.serial.one_uart_two_wire_one_spi=ONE_UART_TWO_WIRE_ONE_SPI +x21e.menu.serial.one_uart_two_wire_one_spi.build.serialcom_uart=ONE_UART +x21e.menu.serial.one_uart_two_wire_one_spi.build.serialcom_wire=TWO_WIRE +x21e.menu.serial.one_uart_two_wire_one_spi.build.serialcom_spi=ONE_SPI +x21e.menu.serial.two_uart=TWO_UART_ONE_WIRE_ONE_SPI +x21e.menu.serial.two_uart.build.serialcom_uart=TWO_UART +x21e.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.two_uart.build.serialcom_spi=ONE_SPI +x21e.menu.serial.three_uart_one_wire_no_spi=THREE_UART_ONE_WIRE_NO_SPI +x21e.menu.serial.three_uart_one_wire_no_spi.build.serialcom_uart=THREE_UART +x21e.menu.serial.three_uart_one_wire_no_spi.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.three_uart_one_wire_no_spi.build.serialcom_spi=NO_SPI +x21e.menu.serial.three_uart_no_wire_one_spi=THREE_UART_NO_WIRE_ONE_SPI +x21e.menu.serial.three_uart_no_wire_one_spi.build.serialcom_uart=THREE_UART +x21e.menu.serial.three_uart_no_wire_one_spi.build.serialcom_wire=NO_WIRE +x21e.menu.serial.three_uart_no_wire_one_spi.build.serialcom_spi=ONE_SPI +x21e.menu.serial.four_uart=FOUR_UART_NO_WIRE_NO_SPI +x21e.menu.serial.four_uart.build.serialcom_uart=FOUR_UART +x21e.menu.serial.four_uart.build.serialcom_wire=NO_WIRE +x21e.menu.serial.four_uart.build.serialcom_spi=NO_SPI +x21e.menu.serial.no_uart_one_wire_two_spi=NO_UART_ONE_WIRE_TWO_SPI +x21e.menu.serial.no_uart_one_wire_two_spi.build.serialcom_uart=NO_UART +x21e.menu.serial.no_uart_one_wire_two_spi.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.no_uart_one_wire_two_spi.build.serialcom_spi=TWO_SPI +x21e.menu.serial.four_uart_one_wire_one_spi=FOUR_UART_ONE_WIRE_ONE_SPI (L21 only) +x21e.menu.serial.four_uart_one_wire_one_spi.build.serialcom_uart=FOUR_UART +x21e.menu.serial.four_uart_one_wire_one_spi.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.four_uart_one_wire_one_spi.build.serialcom_spi=ONE_SPI +x21e.menu.serial.five_uart_no_wire_one_spi=FIVE_UART_NO_WIRE_ONE_SPI (L21 only) +x21e.menu.serial.five_uart_no_wire_one_spi.build.serialcom_uart=FIVE_UART +x21e.menu.serial.five_uart_no_wire_one_spi.build.serialcom_wire=NO_WIRE +x21e.menu.serial.five_uart_no_wire_one_spi.build.serialcom_spi=ONE_SPI +x21e.menu.serial.five_uart_one_wire_no_spi=FIVE_UART_ONE_WIRE_NO_SPI (L21 only) +x21e.menu.serial.five_uart_one_wire_no_spi.build.serialcom_uart=FIVE_UART +x21e.menu.serial.five_uart_one_wire_no_spi.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.five_uart_one_wire_no_spi.build.serialcom_spi=NO_SPI +x21e.menu.serial.six_uart=SIX_UART_NO_WIRE_NO_SPI (L21 only) +x21e.menu.serial.six_uart.build.serialcom_uart=SIX_UART +x21e.menu.serial.six_uart.build.serialcom_wire=NO_WIRE +x21e.menu.serial.six_uart.build.serialcom_spi=NO_SPI +x21e.menu.usb.cdc=CDC_ONLY +x21e.menu.usb.cdc.build.usbcom=CDC_ONLY +x21e.menu.usb.cdc.build.pid=0x4557 +x21e.menu.usb.cdc_hid=CDC_HID +x21e.menu.usb.cdc_hid.build.usbcom=CDC_HID +x21e.menu.usb.cdc_hid.build.pid=0x4856 +x21e.menu.usb.withcdc=WITH_CDC +x21e.menu.usb.withcdc.build.usbcom=WITH_CDC +x21e.menu.usb.withcdc.build.pid=0x4B41 +x21e.menu.usb.hid=HID_ONLY +x21e.menu.usb.hid.build.usbcom=HID_ONLY +x21e.menu.usb.hid.build.pid=0x4B40 +x21e.menu.usb.nocdc=WITHOUT_CDC +x21e.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +x21e.menu.usb.nocdc.build.pid=0x4A0C +x21e.menu.usb.none=USB_DISABLED +x21e.menu.usb.none.build.usbcom=USB_DISABLED +x21e.menu.usb.none.build.pid=0x4856 + +# Generic x21G +x21g.name=Generic x21G +x21g.vid.0=0x16D0 +x21g.pid.0=0x5557 +x21g.vid.1=0x16D0 +x21g.pid.1=0x5856 +x21g.vid.2=0x16D0 +x21g.pid.2=0x5B41 +x21g.vid.3=0x16D0 +x21g.pid.3=0x5B40 +x21g.vid.4=0x16D0 +x21g.pid.4=0x5A0C +x21g.vid.5=0x16D0 +x21g.pid.5=0x5856 +x21g.build.usb_manufacturer="Fab Foundation" +x21g.build.board=SAMD_ZERO +x21g.build.core=arduino +x21g.build.variant=Generic_xx1G +x21g.build.variant_system_lib= +x21g.build.vid=0x16D0 +x21g.upload.protocol=sam-ba +x21g.bootloader.tool=openocd-withbootsize +x21g.menu.float.default=Print & String use auto-promoted doubles only +x21g.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +x21g.menu.float.print=Print uses separate singles and doubles +x21g.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +x21g.menu.float.string=String uses separate singles and doubles +x21g.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +x21g.menu.float.both=Print & String use separate singles and doubles +x21g.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +x21g.menu.config.disabled=config.h disabled +x21g.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +x21g.menu.config.enabled=config.h enabled (mostly code size reductions) +x21g.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +x21g.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +x21g.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +x21g.menu.clock.internal=INTERNAL_OSCILLATOR +x21g.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +x21g.menu.clock.crystal_32k=32KHZ_CRYSTAL +x21g.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +x21g.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +x21g.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +x21g.menu.timer.timer_732Hz=732.4Hz (16-bit) +x21g.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +x21g.menu.timer.timer_366Hz=366.2Hz (16-bit) +x21g.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +x21g.menu.timer.timer_244Hz=244.1Hz (16-bit) +x21g.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +x21g.menu.timer.timer_183Hz=183.1Hz (16-bit) +x21g.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +x21g.menu.timer.timer_146Hz=146.5Hz (16-bit) +x21g.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +x21g.menu.timer.timer_122Hz=122.1Hz (16-bit) +x21g.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +x21g.menu.timer.timer_105Hz=104.6Hz (16-bit) +x21g.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +x21g.menu.timer.timer_81Hz=81.38Hz (16-bit) +x21g.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +x21g.menu.timer.timer_61Hz=61.04Hz (16-bit) +x21g.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +x21g.menu.timer.timer_31Hz=30.52Hz (16-bit) +x21g.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +x21g.menu.timer.timer_187500Hz=187500Hz (8-bit) +x21g.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +x21g.menu.timer.timer_93750Hz=93750Hz (8-bit) +x21g.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +x21g.menu.timer.timer_62500Hz=62500Hz (8-bit) +x21g.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +x21g.menu.timer.timer_37500Hz=37500Hz (8-bit) +x21g.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +x21g.menu.timer.timer_20833Hz=20833Hz (8-bit) +x21g.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +x21g.menu.timer.timer_12500Hz=12500Hz (8-bit) +x21g.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +x21g.menu.timer.timer_7500Hz=7500Hz (8-bit) +x21g.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +x21g.menu.timer.timer_4166Hz=4166Hz (8-bit) +x21g.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +x21g.menu.timer.timer_2930Hz=2930Hz (8-bit) +x21g.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +x21g.menu.timer.timer_1465Hz=1465Hz (8-bit) +x21g.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +x21g.menu.cpu.samd21g17a=SAMD21G17A +x21g.menu.cpu.samd21g17a.upload.maximum_size=122880 +x21g.menu.cpu.samd21g17a.build.mcu=cortex-m0plus +x21g.menu.cpu.samd21g17a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samd21g17a.build.f_cpu=48000000L +x21g.menu.cpu.samd21g17a.build.usb_product="D21" +x21g.menu.cpu.samd21g17a.build.extra_flags=-D__SAMD21G17A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.samd21g17a.build.ldscript=flash_128KB.ld +x21g.menu.cpu.samd21g17a.build.openocdscript=openocd_scripts/SAMD21G17A.cfg +x21g.menu.cpu.samd21g17a.bootloader.file=zero/binaries/sam_ba_SAMD21G17A.bin +x21g.menu.cpu.samd21g18a=SAMD21G18A +x21g.menu.cpu.samd21g18a.upload.maximum_size=253952 +x21g.menu.cpu.samd21g18a.build.mcu=cortex-m0plus +x21g.menu.cpu.samd21g18a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samd21g18a.build.f_cpu=48000000L +x21g.menu.cpu.samd21g18a.build.usb_product="D21" +x21g.menu.cpu.samd21g18a.build.extra_flags=-D__SAMD21G18A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.samd21g18a.build.ldscript=flash_256KB.ld +x21g.menu.cpu.samd21g18a.build.openocdscript=openocd_scripts/SAMD21G18A.cfg +x21g.menu.cpu.samd21g18a.bootloader.file=zero/binaries/sam_ba_SAMD21G18A.bin +x21g.menu.cpu.samd21g15a=SAMD21G15A +x21g.menu.cpu.samd21g15a.upload.maximum_size=24576 +x21g.menu.cpu.samd21g15a.build.mcu=cortex-m0plus +x21g.menu.cpu.samd21g15a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samd21g15a.build.f_cpu=48000000L +x21g.menu.cpu.samd21g15a.build.usb_product="D21" +x21g.menu.cpu.samd21g15a.build.extra_flags=-D__SAMD21G15A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.samd21g15a.build.ldscript=flash_32KB.ld +x21g.menu.cpu.samd21g15a.build.openocdscript=openocd_scripts/SAMD21G15A.cfg +x21g.menu.cpu.samd21g15a.bootloader.file=zero/binaries/sam_ba_SAMD21G15A.bin +x21g.menu.cpu.samd21g16a=SAMD21G16A +x21g.menu.cpu.samd21g16a.upload.maximum_size=57344 +x21g.menu.cpu.samd21g16a.build.mcu=cortex-m0plus +x21g.menu.cpu.samd21g16a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samd21g16a.build.f_cpu=48000000L +x21g.menu.cpu.samd21g16a.build.usb_product="D21" +x21g.menu.cpu.samd21g16a.build.extra_flags=-D__SAMD21G16A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.samd21g16a.build.ldscript=flash_64KB.ld +x21g.menu.cpu.samd21g16a.build.openocdscript=openocd_scripts/SAMD21G16A.cfg +x21g.menu.cpu.samd21g16a.bootloader.file=zero/binaries/sam_ba_SAMD21G16A.bin +x21g.menu.cpu.saml21g17b=SAML21G17B +x21g.menu.cpu.saml21g17b.upload.maximum_size=122880 +x21g.menu.cpu.saml21g17b.build.mcu=cortex-m0plus +x21g.menu.cpu.saml21g17b.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.saml21g17b.build.f_cpu=48000000L +x21g.menu.cpu.saml21g17b.build.usb_product="L21" +x21g.menu.cpu.saml21g17b.build.extra_flags=-D__SAML21G17B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.saml21g17b.build.ldscript=flash_128KB.ld +x21g.menu.cpu.saml21g17b.build.openocdscript=openocd_scripts/SAML21G17B.cfg +x21g.menu.cpu.saml21g17b.bootloader.file=zero/binaries/sam_ba_SAML21G17B.bin +x21g.menu.cpu.saml21g18b=SAML21G18B +x21g.menu.cpu.saml21g18b.upload.maximum_size=253952 +x21g.menu.cpu.saml21g18b.build.mcu=cortex-m0plus +x21g.menu.cpu.saml21g18b.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.saml21g18b.build.f_cpu=48000000L +x21g.menu.cpu.saml21g18b.build.usb_product="L21" +x21g.menu.cpu.saml21g18b.build.extra_flags=-D__SAML21G18B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.saml21g18b.build.ldscript=flash_256KB.ld +x21g.menu.cpu.saml21g18b.build.openocdscript=openocd_scripts/SAML21G18B.cfg +x21g.menu.cpu.saml21g18b.bootloader.file=zero/binaries/sam_ba_SAML21G18B.bin +x21g.menu.cpu.saml21g15b=SAML21G15B +x21g.menu.cpu.saml21g15b.upload.maximum_size=24576 +x21g.menu.cpu.saml21g15b.build.mcu=cortex-m0plus +x21g.menu.cpu.saml21g15b.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.saml21g15b.build.f_cpu=48000000L +x21g.menu.cpu.saml21g15b.build.usb_product="L21" +x21g.menu.cpu.saml21g15b.build.extra_flags=-D__SAML21G15B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.saml21g15b.build.ldscript=flash_32KB.ld +x21g.menu.cpu.saml21g15b.build.openocdscript=openocd_scripts/SAML21G15B.cfg +x21g.menu.cpu.saml21g15b.bootloader.file=zero/binaries/sam_ba_SAML21G15B.bin +x21g.menu.cpu.saml21g16b=SAML21G16B +x21g.menu.cpu.saml21g16b.upload.maximum_size=57344 +x21g.menu.cpu.saml21g16b.build.mcu=cortex-m0plus +x21g.menu.cpu.saml21g16b.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.saml21g16b.build.f_cpu=48000000L +x21g.menu.cpu.saml21g16b.build.usb_product="L21" +x21g.menu.cpu.saml21g16b.build.extra_flags=-D__SAML21G16B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.saml21g16b.build.ldscript=flash_64KB.ld +x21g.menu.cpu.saml21g16b.build.openocdscript=openocd_scripts/SAML21G16B.cfg +x21g.menu.cpu.saml21g16b.bootloader.file=zero/binaries/sam_ba_SAML21G16B.bin +x21g.menu.cpu.samc21g17a=SAMC21G17A +x21g.menu.cpu.samc21g17a.upload.maximum_size=122880 +x21g.menu.cpu.samc21g17a.build.mcu=cortex-m0plus +x21g.menu.cpu.samc21g17a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samc21g17a.build.f_cpu=48000000L +x21g.menu.cpu.samc21g17a.build.usb_product="C21" +x21g.menu.cpu.samc21g17a.build.extra_flags=-D__SAMC21G17A__ -DARM_MATH_CM0PLUS +x21g.menu.cpu.samc21g17a.build.ldscript=flash_128KB.ld +x21g.menu.cpu.samc21g17a.build.openocdscript=openocd_scripts/SAMC21G17A.cfg +x21g.menu.cpu.samc21g17a.bootloader.file=zero/binaries/sam_ba_SAMC21G17A.bin +x21g.menu.cpu.samc21g18a=SAMC21G18A +x21g.menu.cpu.samc21g18a.upload.maximum_size=253952 +x21g.menu.cpu.samc21g18a.build.mcu=cortex-m0plus +x21g.menu.cpu.samc21g18a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samc21g18a.build.f_cpu=48000000L +x21g.menu.cpu.samc21g18a.build.usb_product="C21" +x21g.menu.cpu.samc21g18a.build.extra_flags=-D__SAMC21G18A__ -DARM_MATH_CM0PLUS +x21g.menu.cpu.samc21g18a.build.ldscript=flash_256KB.ld +x21g.menu.cpu.samc21g18a.build.openocdscript=openocd_scripts/SAMC21G18A.cfg +x21g.menu.cpu.samc21g18a.bootloader.file=zero/binaries/sam_ba_SAMC21G18A.bin +x21g.menu.cpu.samc21g15a=SAMC21G15A +x21g.menu.cpu.samc21g15a.upload.maximum_size=24576 +x21g.menu.cpu.samc21g15a.build.mcu=cortex-m0plus +x21g.menu.cpu.samc21g15a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samc21g15a.build.f_cpu=48000000L +x21g.menu.cpu.samc21g15a.build.usb_product="C21" +x21g.menu.cpu.samc21g15a.build.extra_flags=-D__SAMC21G15A__ -DARM_MATH_CM0PLUS +x21g.menu.cpu.samc21g15a.build.ldscript=flash_32KB.ld +x21g.menu.cpu.samc21g15a.build.openocdscript=openocd_scripts/SAMC21G15A.cfg +x21g.menu.cpu.samc21g15a.bootloader.file=zero/binaries/sam_ba_SAMC21G15A.bin +x21g.menu.cpu.samc21g16a=SAMC21G16A +x21g.menu.cpu.samc21g16a.upload.maximum_size=57344 +x21g.menu.cpu.samc21g16a.build.mcu=cortex-m0plus +x21g.menu.cpu.samc21g16a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samc21g16a.build.f_cpu=48000000L +x21g.menu.cpu.samc21g16a.build.usb_product="C21" +x21g.menu.cpu.samc21g16a.build.extra_flags=-D__SAMC21G16A__ -DARM_MATH_CM0PLUS +x21g.menu.cpu.samc21g16a.build.ldscript=flash_64KB.ld +x21g.menu.cpu.samc21g16a.build.openocdscript=openocd_scripts/SAMC21G16A.cfg +x21g.menu.cpu.samc21g16a.bootloader.file=zero/binaries/sam_ba_SAMC21G16A.bin +x21g.menu.bootloader.8kb=8KB_BOOTLOADER +x21g.menu.bootloader.8kb.build.bootloader_size=__8KB_BOOTLOADER__ +x21g.menu.bootloader.8kb.build.ldscript_path=linker_scripts/gcc/8KB_Bootloader +x21g.menu.bootloader.8kb.upload.tool=Fab_SAM_Arduino:bossac +x21g.menu.bootloader.8kb.upload.use_1200bps_touch=true +x21g.menu.bootloader.8kb.upload.wait_for_upload_port=true +x21g.menu.bootloader.8kb.upload.native_usb=true +x21g.menu.bootloader.8kb.upload.offset=0x2000 +x21g.menu.bootloader.16kb=16KB_BOOTLOADER +x21g.menu.bootloader.16kb.build.bootloader_size=__16KB_BOOTLOADER__ +x21g.menu.bootloader.16kb.build.ldscript_path=linker_scripts/gcc/16KB_Bootloader +x21g.menu.bootloader.16kb.upload.tool=Fab_SAM_Arduino:bossac +x21g.menu.bootloader.16kb.upload.use_1200bps_touch=true +x21g.menu.bootloader.16kb.upload.wait_for_upload_port=true +x21g.menu.bootloader.16kb.upload.native_usb=true +x21g.menu.bootloader.16kb.upload.offset=0x4000 +x21g.menu.bootloader.0kb=NO_BOOTLOADER +x21g.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +x21g.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +x21g.menu.bootloader.0kb.upload.tool=openocd-withbootsize +x21g.menu.bootloader.0kb.upload.use_1200bps_touch=false +x21g.menu.bootloader.0kb.upload.wait_for_upload_port=false +x21g.menu.bootloader.0kb.upload.native_usb=false +x21g.menu.bootloader.0kb.upload.offset=0x0000 +x21g.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +x21g.menu.serial.one_uart.build.serialcom_uart=ONE_UART +x21g.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +x21g.menu.serial.one_uart_two_spi=ONE_UART_ONE_WIRE_TWO_SPI +x21g.menu.serial.one_uart_two_spi.build.serialcom_uart=ONE_UART +x21g.menu.serial.one_uart_two_spi.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.one_uart_two_spi.build.serialcom_spi=TWO_SPI +x21g.menu.serial.one_uart_two_wire=ONE_UART_TWO_WIRE_ONE_SPI +x21g.menu.serial.one_uart_two_wire.build.serialcom_uart=ONE_UART +x21g.menu.serial.one_uart_two_wire.build.serialcom_wire=TWO_WIRE +x21g.menu.serial.one_uart_two_wire.build.serialcom_spi=ONE_SPI +x21g.menu.serial.two_uart=TWO_UART_ONE_WIRE_ONE_SPI +x21g.menu.serial.two_uart.build.serialcom_uart=TWO_UART +x21g.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.two_uart.build.serialcom_spi=ONE_SPI +x21g.menu.serial.two_uart_two_spi=TWO_UART_ONE_WIRE_TWO_SPI +x21g.menu.serial.two_uart_two_spi.build.serialcom_uart=TWO_UART +x21g.menu.serial.two_uart_two_spi.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.two_uart_two_spi.build.serialcom_spi=TWO_SPI +x21g.menu.serial.two_uart_two_wire=TWO_UART_TWO_WIRE_ONE_SPI +x21g.menu.serial.two_uart_two_wire.build.serialcom_uart=TWO_UART +x21g.menu.serial.two_uart_two_wire.build.serialcom_wire=TWO_WIRE +x21g.menu.serial.two_uart_two_wire.build.serialcom_spi=ONE_SPI +x21g.menu.serial.three_uart=THREE_UART_ONE_WIRE_ONE_SPI +x21g.menu.serial.three_uart.build.serialcom_uart=THREE_UART +x21g.menu.serial.three_uart.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.three_uart.build.serialcom_spi=ONE_SPI +x21g.menu.serial.three_uart_two_spi=THREE_UART_ONE_WIRE_TWO_SPI +x21g.menu.serial.three_uart_two_spi.build.serialcom_uart=THREE_UART +x21g.menu.serial.three_uart_two_spi.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.three_uart_two_spi.build.serialcom_spi=TWO_SPI +x21g.menu.serial.three_uart_two_wire=THREE_UART_TWO_WIRE_ONE_SPI +x21g.menu.serial.three_uart_two_wire.build.serialcom_uart=THREE_UART +x21g.menu.serial.three_uart_two_wire.build.serialcom_wire=TWO_WIRE +x21g.menu.serial.three_uart_two_wire.build.serialcom_spi=ONE_SPI +x21g.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +x21g.menu.serial.no_uart.build.serialcom_uart=NO_UART +x21g.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +x21g.menu.usb.cdc=CDC_ONLY +x21g.menu.usb.cdc.build.usbcom=CDC_ONLY +x21g.menu.usb.cdc.build.pid=0x5557 +x21g.menu.usb.cdc_hid=CDC_HID +x21g.menu.usb.cdc_hid.build.usbcom=CDC_HID +x21g.menu.usb.cdc_hid.build.pid=0x5856 +x21g.menu.usb.withcdc=WITH_CDC +x21g.menu.usb.withcdc.build.usbcom=WITH_CDC +x21g.menu.usb.withcdc.build.pid=0x5B41 +x21g.menu.usb.hid=HID_ONLY +x21g.menu.usb.hid.build.usbcom=HID_ONLY +x21g.menu.usb.hid.build.pid=0x5B40 +x21g.menu.usb.nocdc=WITHOUT_CDC +x21g.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +x21g.menu.usb.nocdc.build.pid=0x5A0C +x21g.menu.usb.none=USB_DISABLED +x21g.menu.usb.none.build.usbcom=USB_DISABLED +x21g.menu.usb.none.build.pid=0x5856 + +# Generic x21J +x21j.name=Generic x21J +x21j.vid.0=0x16D0 +x21j.pid.0=0x6557 +x21j.vid.1=0x16D0 +x21j.pid.1=0x6856 +x21j.vid.2=0x16D0 +x21j.pid.2=0x6B41 +x21j.vid.3=0x16D0 +x21j.pid.3=0x6B40 +x21j.vid.4=0x16D0 +x21j.pid.4=0x6A0C +x21j.vid.5=0x16D0 +x21j.pid.5=0x6856 +x21j.build.usb_manufacturer="Fab Foundation" +x21j.build.board=SAMD_ZERO +x21j.build.core=arduino +x21j.build.variant=Generic_xx1J +x21j.build.variant_system_lib= +x21j.build.vid=0x16D0 +x21j.upload.protocol=sam-ba +x21j.bootloader.tool=openocd-withbootsize +x21j.menu.float.default=Print & String use auto-promoted doubles only +x21j.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +x21j.menu.float.print=Print uses separate singles and doubles +x21j.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +x21j.menu.float.string=String uses separate singles and doubles +x21j.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +x21j.menu.float.both=Print & String use separate singles and doubles +x21j.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +x21j.menu.config.disabled=config.h disabled +x21j.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +x21j.menu.config.enabled=config.h enabled (mostly code size reductions) +x21j.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +x21j.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +x21j.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +x21j.menu.clock.internal=INTERNAL_OSCILLATOR +x21j.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +x21j.menu.clock.crystal_32k=32KHZ_CRYSTAL +x21j.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +x21j.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +x21j.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +x21j.menu.timer.timer_732Hz=732.4Hz (16-bit) +x21j.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +x21j.menu.timer.timer_366Hz=366.2Hz (16-bit) +x21j.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +x21j.menu.timer.timer_244Hz=244.1Hz (16-bit) +x21j.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +x21j.menu.timer.timer_183Hz=183.1Hz (16-bit) +x21j.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +x21j.menu.timer.timer_146Hz=146.5Hz (16-bit) +x21j.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +x21j.menu.timer.timer_122Hz=122.1Hz (16-bit) +x21j.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +x21j.menu.timer.timer_105Hz=104.6Hz (16-bit) +x21j.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +x21j.menu.timer.timer_81Hz=81.38Hz (16-bit) +x21j.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +x21j.menu.timer.timer_61Hz=61.04Hz (16-bit) +x21j.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +x21j.menu.timer.timer_31Hz=30.52Hz (16-bit) +x21j.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +x21j.menu.timer.timer_187500Hz=187500Hz (8-bit) +x21j.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +x21j.menu.timer.timer_93750Hz=93750Hz (8-bit) +x21j.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +x21j.menu.timer.timer_62500Hz=62500Hz (8-bit) +x21j.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +x21j.menu.timer.timer_37500Hz=37500Hz (8-bit) +x21j.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +x21j.menu.timer.timer_20833Hz=20833Hz (8-bit) +x21j.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +x21j.menu.timer.timer_12500Hz=12500Hz (8-bit) +x21j.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +x21j.menu.timer.timer_7500Hz=7500Hz (8-bit) +x21j.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +x21j.menu.timer.timer_4166Hz=4166Hz (8-bit) +x21j.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +x21j.menu.timer.timer_2930Hz=2930Hz (8-bit) +x21j.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +x21j.menu.timer.timer_1465Hz=1465Hz (8-bit) +x21j.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +x21j.menu.cpu.samd21j17a=SAMD21J17A +x21j.menu.cpu.samd21j17a.upload.maximum_size=122880 +x21j.menu.cpu.samd21j17a.build.mcu=cortex-m0plus +x21j.menu.cpu.samd21j17a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samd21j17a.build.f_cpu=48000000L +x21j.menu.cpu.samd21j17a.build.usb_product="Xeno D21" +x21j.menu.cpu.samd21j17a.build.extra_flags=-D__SAMD21J17A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.samd21j17a.build.ldscript=flash_128KB.ld +x21j.menu.cpu.samd21j17a.build.openocdscript=openocd_scripts/SAMD21J17A.cfg +x21j.menu.cpu.samd21j17a.bootloader.file=zero/binaries/sam_ba_SAMD21J17A.bin +x21j.menu.cpu.samd21j18a=SAMD21J18A +x21j.menu.cpu.samd21j18a.upload.maximum_size=253952 +x21j.menu.cpu.samd21j18a.build.mcu=cortex-m0plus +x21j.menu.cpu.samd21j18a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samd21j18a.build.f_cpu=48000000L +x21j.menu.cpu.samd21j18a.build.usb_product="Xeno D21" +x21j.menu.cpu.samd21j18a.build.extra_flags=-D__SAMD21J18A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.samd21j18a.build.ldscript=flash_256KB.ld +x21j.menu.cpu.samd21j18a.build.openocdscript=openocd_scripts/SAMD21J18A.cfg +x21j.menu.cpu.samd21j18a.bootloader.file=zero/binaries/sam_ba_SAMD21J18A.bin +x21j.menu.cpu.samd21j15a=SAMD21J15A +x21j.menu.cpu.samd21j15a.upload.maximum_size=24576 +x21j.menu.cpu.samd21j15a.build.mcu=cortex-m0plus +x21j.menu.cpu.samd21j15a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samd21j15a.build.f_cpu=48000000L +x21j.menu.cpu.samd21j15a.build.usb_product="Xeno D21" +x21j.menu.cpu.samd21j15a.build.extra_flags=-D__SAMD21J15A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.samd21j15a.build.ldscript=flash_32KB.ld +x21j.menu.cpu.samd21j15a.build.openocdscript=openocd_scripts/SAMD21J15A.cfg +x21j.menu.cpu.samd21j15a.bootloader.file=zero/binaries/sam_ba_SAMD21J15A.bin +x21j.menu.cpu.samd21j16a=SAMD21J16A +x21j.menu.cpu.samd21j16a.upload.maximum_size=57344 +x21j.menu.cpu.samd21j16a.build.mcu=cortex-m0plus +x21j.menu.cpu.samd21j16a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samd21j16a.build.f_cpu=48000000L +x21j.menu.cpu.samd21j16a.build.usb_product="Xeno D21" +x21j.menu.cpu.samd21j16a.build.extra_flags=-D__SAMD21J16A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.samd21j16a.build.ldscript=flash_64KB.ld +x21j.menu.cpu.samd21j16a.build.openocdscript=openocd_scripts/SAMD21J16A.cfg +x21j.menu.cpu.samd21j16a.bootloader.file=zero/binaries/sam_ba_SAMD21J16A.bin +x21j.menu.cpu.saml21j17b=SAML21J17B +x21j.menu.cpu.saml21j17b.upload.maximum_size=122880 +x21j.menu.cpu.saml21j17b.build.mcu=cortex-m0plus +x21j.menu.cpu.saml21j17b.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.saml21j17b.build.f_cpu=48000000L +x21j.menu.cpu.saml21j17b.build.usb_product="Xeno L21" +x21j.menu.cpu.saml21j17b.build.extra_flags=-D__SAML21J17B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.saml21j17b.build.ldscript=flash_128KB.ld +x21j.menu.cpu.saml21j17b.build.openocdscript=openocd_scripts/SAML21J17B.cfg +x21j.menu.cpu.saml21j17b.bootloader.file=zero/binaries/sam_ba_SAML21J17B.bin +x21j.menu.cpu.saml21j18b=SAML21J18B +x21j.menu.cpu.saml21j18b.upload.maximum_size=253952 +x21j.menu.cpu.saml21j18b.build.mcu=cortex-m0plus +x21j.menu.cpu.saml21j18b.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.saml21j18b.build.f_cpu=48000000L +x21j.menu.cpu.saml21j18b.build.usb_product="Xeno L21" +x21j.menu.cpu.saml21j18b.build.extra_flags=-D__SAML21J18B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.saml21j18b.build.ldscript=flash_256KB.ld +x21j.menu.cpu.saml21j18b.build.openocdscript=openocd_scripts/SAML21J18B.cfg +x21j.menu.cpu.saml21j18b.bootloader.file=zero/binaries/sam_ba_SAML21J18B.bin +x21j.menu.cpu.saml21j16b=SAML21J16B +x21j.menu.cpu.saml21j16b.upload.maximum_size=57344 +x21j.menu.cpu.saml21j16b.build.mcu=cortex-m0plus +x21j.menu.cpu.saml21j16b.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.saml21j16b.build.f_cpu=48000000L +x21j.menu.cpu.saml21j16b.build.usb_product="Xeno L21" +x21j.menu.cpu.saml21j16b.build.extra_flags=-D__SAML21J16B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.saml21j16b.build.ldscript=flash_64KB.ld +x21j.menu.cpu.saml21j16b.build.openocdscript=openocd_scripts/SAML21J16B.cfg +x21j.menu.cpu.saml21j16b.bootloader.file=zero/binaries/sam_ba_SAML21J16B.bin +x21j.menu.cpu.samc21j17a=SAMC21J17A +x21j.menu.cpu.samc21j17a.upload.maximum_size=122880 +x21j.menu.cpu.samc21j17a.build.mcu=cortex-m0plus +x21j.menu.cpu.samc21j17a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samc21j17a.build.f_cpu=48000000L +x21j.menu.cpu.samc21j17a.build.usb_product="Xeno C21" +x21j.menu.cpu.samc21j17a.build.extra_flags=-D__SAMC21J17A__ -DARM_MATH_CM0PLUS +x21j.menu.cpu.samc21j17a.build.ldscript=flash_128KB.ld +x21j.menu.cpu.samc21j17a.build.openocdscript=openocd_scripts/SAMC21J17A.cfg +x21j.menu.cpu.samc21j17a.bootloader.file=zero/binaries/sam_ba_SAMC21J17A.bin +x21j.menu.cpu.samc21j18a=SAMC21J18A +x21j.menu.cpu.samc21j18a.upload.maximum_size=253952 +x21j.menu.cpu.samc21j18a.build.mcu=cortex-m0plus +x21j.menu.cpu.samc21j18a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samc21j18a.build.f_cpu=48000000L +x21j.menu.cpu.samc21j18a.build.usb_product="Xeno C21" +x21j.menu.cpu.samc21j18a.build.extra_flags=-D__SAMC21J18A__ -DARM_MATH_CM0PLUS +x21j.menu.cpu.samc21j18a.build.ldscript=flash_256KB.ld +x21j.menu.cpu.samc21j18a.build.openocdscript=openocd_scripts/SAMC21J18A.cfg +x21j.menu.cpu.samc21j18a.bootloader.file=zero/binaries/sam_ba_SAMC21J18A.bin +x21j.menu.cpu.samc21j15a=SAMC21J15A +x21j.menu.cpu.samc21j15a.upload.maximum_size=24576 +x21j.menu.cpu.samc21j15a.build.mcu=cortex-m0plus +x21j.menu.cpu.samc21j15a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samc21j15a.build.f_cpu=48000000L +x21j.menu.cpu.samc21j15a.build.usb_product="Xeno C21" +x21j.menu.cpu.samc21j15a.build.extra_flags=-D__SAMC21J15A__ -DARM_MATH_CM0PLUS +x21j.menu.cpu.samc21j15a.build.ldscript=flash_32KB.ld +x21j.menu.cpu.samc21j15a.build.openocdscript=openocd_scripts/SAMC21J15A.cfg +x21j.menu.cpu.samc21j15a.bootloader.file=zero/binaries/sam_ba_SAMC21J15A.bin +x21j.menu.cpu.samc21j16a=SAMC21J16A +x21j.menu.cpu.samc21j16a.upload.maximum_size=57344 +x21j.menu.cpu.samc21j16a.build.mcu=cortex-m0plus +x21j.menu.cpu.samc21j16a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samc21j16a.build.f_cpu=48000000L +x21j.menu.cpu.samc21j16a.build.usb_product="Xeno C21" +x21j.menu.cpu.samc21j16a.build.extra_flags=-D__SAMC21J16A__ -DARM_MATH_CM0PLUS +x21j.menu.cpu.samc21j16a.build.ldscript=flash_64KB.ld +x21j.menu.cpu.samc21j16a.build.openocdscript=openocd_scripts/SAMC21J16A.cfg +x21j.menu.cpu.samc21j16a.bootloader.file=zero/binaries/sam_ba_SAMC21J16A.bin +x21j.menu.bootloader.8kb=8KB_BOOTLOADER +x21j.menu.bootloader.8kb.build.bootloader_size=__8KB_BOOTLOADER__ +x21j.menu.bootloader.8kb.build.ldscript_path=linker_scripts/gcc/8KB_Bootloader +x21j.menu.bootloader.8kb.upload.tool=Fab_SAM_Arduino:bossac +x21j.menu.bootloader.8kb.upload.use_1200bps_touch=true +x21j.menu.bootloader.8kb.upload.wait_for_upload_port=true +x21j.menu.bootloader.8kb.upload.native_usb=true +x21j.menu.bootloader.8kb.upload.offset=0x2000 +x21j.menu.bootloader.16kb=16KB_BOOTLOADER +x21j.menu.bootloader.16kb.build.bootloader_size=__16KB_BOOTLOADER__ +x21j.menu.bootloader.16kb.build.ldscript_path=linker_scripts/gcc/16KB_Bootloader +x21j.menu.bootloader.16kb.upload.tool=Fab_SAM_Arduino:bossac +x21j.menu.bootloader.16kb.upload.use_1200bps_touch=true +x21j.menu.bootloader.16kb.upload.wait_for_upload_port=true +x21j.menu.bootloader.16kb.upload.native_usb=true +x21j.menu.bootloader.16kb.upload.offset=0x4000 +x21j.menu.bootloader.0kb=NO_BOOTLOADER +x21j.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +x21j.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +x21j.menu.bootloader.0kb.upload.tool=openocd-withbootsize +x21j.menu.bootloader.0kb.upload.use_1200bps_touch=false +x21j.menu.bootloader.0kb.upload.wait_for_upload_port=false +x21j.menu.bootloader.0kb.upload.native_usb=false +x21j.menu.bootloader.0kb.upload.offset=0x0000 +x21j.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +x21j.menu.serial.one_uart.build.serialcom_uart=ONE_UART +x21j.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +x21j.menu.serial.one_uart_two_spi=ONE_UART_ONE_WIRE_TWO_SPI +x21j.menu.serial.one_uart_two_spi.build.serialcom_uart=ONE_UART +x21j.menu.serial.one_uart_two_spi.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.one_uart_two_spi.build.serialcom_spi=TWO_SPI +x21j.menu.serial.one_uart_two_wire=ONE_UART_TWO_WIRE_ONE_SPI +x21j.menu.serial.one_uart_two_wire.build.serialcom_uart=ONE_UART +x21j.menu.serial.one_uart_two_wire.build.serialcom_wire=TWO_WIRE +x21j.menu.serial.one_uart_two_wire.build.serialcom_spi=ONE_SPI +x21j.menu.serial.two_uart=TWO_UART_ONE_WIRE_ONE_SPI +x21j.menu.serial.two_uart.build.serialcom_uart=TWO_UART +x21j.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.two_uart.build.serialcom_spi=ONE_SPI +x21j.menu.serial.two_uart_two_spi=TWO_UART_ONE_WIRE_TWO_SPI +x21j.menu.serial.two_uart_two_spi.build.serialcom_uart=TWO_UART +x21j.menu.serial.two_uart_two_spi.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.two_uart_two_spi.build.serialcom_spi=TWO_SPI +x21j.menu.serial.two_uart_two_wire=TWO_UART_TWO_WIRE_ONE_SPI +x21j.menu.serial.two_uart_two_wire.build.serialcom_uart=TWO_UART +x21j.menu.serial.two_uart_two_wire.build.serialcom_wire=TWO_WIRE +x21j.menu.serial.two_uart_two_wire.build.serialcom_spi=ONE_SPI +x21j.menu.serial.three_uart=THREE_UART_ONE_WIRE_ONE_SPI +x21j.menu.serial.three_uart.build.serialcom_uart=THREE_UART +x21j.menu.serial.three_uart.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.three_uart.build.serialcom_spi=ONE_SPI +x21j.menu.serial.three_uart_two_spi=THREE_UART_ONE_WIRE_TWO_SPI +x21j.menu.serial.three_uart_two_spi.build.serialcom_uart=THREE_UART +x21j.menu.serial.three_uart_two_spi.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.three_uart_two_spi.build.serialcom_spi=TWO_SPI +x21j.menu.serial.three_uart_two_wire=THREE_UART_TWO_WIRE_ONE_SPI +x21j.menu.serial.three_uart_two_wire.build.serialcom_uart=THREE_UART +x21j.menu.serial.three_uart_two_wire.build.serialcom_wire=TWO_WIRE +x21j.menu.serial.three_uart_two_wire.build.serialcom_spi=ONE_SPI +x21j.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +x21j.menu.serial.no_uart.build.serialcom_uart=NO_UART +x21j.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +x21j.menu.usb.cdc=CDC_ONLY +x21j.menu.usb.cdc.build.usbcom=CDC_ONLY +x21j.menu.usb.cdc.build.pid=0x6557 +x21j.menu.usb.cdc_hid=CDC_HID +x21j.menu.usb.cdc_hid.build.usbcom=CDC_HID +x21j.menu.usb.cdc_hid.build.pid=0x6856 +x21j.menu.usb.withcdc=WITH_CDC +x21j.menu.usb.withcdc.build.usbcom=WITH_CDC +x21j.menu.usb.withcdc.build.pid=0x6B41 +x21j.menu.usb.hid=HID_ONLY +x21j.menu.usb.hid.build.usbcom=HID_ONLY +x21j.menu.usb.hid.build.pid=0x6B40 +x21j.menu.usb.nocdc=WITHOUT_CDC +x21j.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +x21j.menu.usb.nocdc.build.pid=0x6A0C +x21j.menu.usb.none=USB_DISABLED +x21j.menu.usb.none.build.usbcom=USB_DISABLED +x21j.menu.usb.none.build.pid=0x6856 + +# Generic D51G +d51g.name=Generic D51G +d51g.vid.0=0x16D0 +d51g.pid.0=0x7557 +d51g.vid.1=0x16D0 +d51g.pid.1=0x7856 +d51g.vid.2=0x16D0 +d51g.pid.2=0x7B41 +d51g.vid.3=0x16D0 +d51g.pid.3=0x7B40 +d51g.vid.4=0x16D0 +d51g.pid.4=0x7A0C +d51g.vid.5=0x16D0 +d51g.pid.5=0x7856 +d51g.build.usb_manufacturer="Fab Foundation" + +# KH mod +#d51g.build.board=SAMD_ZERO +d51g.build.board=__SAMD51__ +###### + +d51g.build.core=arduino + +# KH mod +#d51g.build.variant=Generic_D51G +d51g.build.variant=Generic_xx1G +###### + +d51g.build.variant_system_lib= +d51g.build.vid=0x16D0 +d51g.upload.protocol=sam-ba +d51g.bootloader.tool=openocd-withbootsize +d51g.menu.float.default=Print & String use auto-promoted doubles only +d51g.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +d51g.menu.float.print=Print uses separate singles and doubles +d51g.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +d51g.menu.float.string=String uses separate singles and doubles +d51g.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +d51g.menu.float.both=Print & String use separate singles and doubles +d51g.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +d51g.menu.config.disabled=config.h disabled +d51g.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +d51g.menu.config.enabled=config.h enabled (mostly code size reductions) +d51g.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +d51g.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +d51g.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +d51g.menu.clock.internal=INTERNAL_OSCILLATOR +d51g.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +d51g.menu.clock.crystal_32k=32KHZ_CRYSTAL +d51g.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +d51g.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +d51g.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +d51g.menu.timer.timer_732Hz=732.4Hz (16-bit) +d51g.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +d51g.menu.timer.timer_366Hz=366.2Hz (16-bit) +d51g.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +d51g.menu.timer.timer_244Hz=244.1Hz (16-bit) +d51g.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +d51g.menu.timer.timer_183Hz=183.1Hz (16-bit) +d51g.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +d51g.menu.timer.timer_146Hz=146.5Hz (16-bit) +d51g.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +d51g.menu.timer.timer_122Hz=122.1Hz (16-bit) +d51g.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +d51g.menu.timer.timer_105Hz=104.6Hz (16-bit) +d51g.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +d51g.menu.timer.timer_81Hz=81.38Hz (16-bit) +d51g.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +d51g.menu.timer.timer_61Hz=61.04Hz (16-bit) +d51g.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +d51g.menu.timer.timer_31Hz=30.52Hz (16-bit) +d51g.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +d51g.menu.timer.timer_187500Hz=187500Hz (8-bit) +d51g.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +d51g.menu.timer.timer_93750Hz=93750Hz (8-bit) +d51g.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +d51g.menu.timer.timer_62500Hz=62500Hz (8-bit) +d51g.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +d51g.menu.timer.timer_37500Hz=37500Hz (8-bit) +d51g.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +d51g.menu.timer.timer_20833Hz=20833Hz (8-bit) +d51g.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +d51g.menu.timer.timer_12500Hz=12500Hz (8-bit) +d51g.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +d51g.menu.timer.timer_7500Hz=7500Hz (8-bit) +d51g.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +d51g.menu.timer.timer_4166Hz=4166Hz (8-bit) +d51g.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +d51g.menu.timer.timer_2930Hz=2930Hz (8-bit) +d51g.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +d51g.menu.timer.timer_1465Hz=1465Hz (16-bit) +d51g.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +d51g.menu.cpu.samd51g18a_120=SAMD51G18A_120MHz +d51g.menu.cpu.samd51g18a_120.upload.maximum_size=253952 +d51g.menu.cpu.samd51g18a_120.build.mcu=cortex-m4 +d51g.menu.cpu.samd51g18a_120.build.mathlib=arm_cortexM4lf_math +d51g.menu.cpu.samd51g18a_120.build.f_cpu=120000000L +d51g.menu.cpu.samd51g18a_120.build.usb_product="Xeno Mini D51" + +# KH mod +#d51g.menu.cpu.samd51g18a_120.build.extra_flags=-D__SAMD51G18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +#d51g.menu.cpu.samd51g18a_120.build.extra_flags=-D__SAMD51G18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +d51g.menu.cpu.samd51g18a_120.build.extra_flags=-D__SAMD51G18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + + +d51g.menu.cpu.samd51g18a_120.build.ldscript=flash_m4f_256KB.ld +d51g.menu.cpu.samd51g18a_120.build.openocdscript=openocd_scripts/SAMD51G18A.cfg +d51g.menu.cpu.samd51g18a_120.bootloader.file=zero/binaries/sam_ba_SAMD51G18A.bin +d51g.menu.cpu.samd51g18a_48=SAMD51G18A_48MHz +d51g.menu.cpu.samd51g18a_48.upload.maximum_size=253952 +d51g.menu.cpu.samd51g18a_48.build.mcu=cortex-m4 +d51g.menu.cpu.samd51g18a_48.build.mathlib=arm_cortexM4lf_math +d51g.menu.cpu.samd51g18a_48.build.f_cpu=48000000L +d51g.menu.cpu.samd51g18a_48.build.usb_product="Xeno Mini D51" + +# KH mod +#d51g.menu.cpu.samd51g18a_48.build.extra_flags=-D__SAMD51G18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51g.menu.cpu.samd51g18a_48.build.extra_flags=-D__SAMD51G18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51g.menu.cpu.samd51g18a_48.build.ldscript=flash_m4f_256KB.ld +d51g.menu.cpu.samd51g18a_48.build.openocdscript=openocd_scripts/SAMD51G18A.cfg +d51g.menu.cpu.samd51g18a_48.bootloader.file=zero/binaries/sam_ba_SAMD51G18A.bin +d51g.menu.cpu.samd51g19a_120=SAMD51G19A_120MHz +d51g.menu.cpu.samd51g19a_120.upload.maximum_size=516096 +d51g.menu.cpu.samd51g19a_120.build.mcu=cortex-m4 +d51g.menu.cpu.samd51g19a_120.build.mathlib=arm_cortexM4lf_math +d51g.menu.cpu.samd51g19a_120.build.f_cpu=120000000L +d51g.menu.cpu.samd51g19a_120.build.usb_product="Xeno Mini D51" + +# KH mod +#d51g.menu.cpu.samd51g19a_120.build.extra_flags=-D__SAMD51G19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51g.menu.cpu.samd51g19a_120.build.extra_flags=-D__SAMD51G19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51g.menu.cpu.samd51g19a_120.build.ldscript=flash_m4f_512KB.ld +d51g.menu.cpu.samd51g19a_120.build.openocdscript=openocd_scripts/SAMD51G19A.cfg +d51g.menu.cpu.samd51g19a_120.bootloader.file=zero/binaries/sam_ba_SAMD51G19A.bin +d51g.menu.cpu.samd51g19a_48=SAMD51G19A_48MHz +d51g.menu.cpu.samd51g19a_48.upload.maximum_size=516096 +d51g.menu.cpu.samd51g19a_48.build.mcu=cortex-m4 +d51g.menu.cpu.samd51g19a_48.build.mathlib=arm_cortexM4lf_math +d51g.menu.cpu.samd51g19a_48.build.f_cpu=48000000L +d51g.menu.cpu.samd51g19a_48.build.usb_product="Xeno Mini D51" + +# KH mod +#d51g.menu.cpu.samd51g19a_48.build.extra_flags=-D__SAMD51G19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51g.menu.cpu.samd51g19a_48.build.extra_flags=-D__SAMD51G19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51g.menu.cpu.samd51g19a_48.build.ldscript=flash_m4f_512KB.ld +d51g.menu.cpu.samd51g19a_48.build.openocdscript=openocd_scripts/SAMD51G19A.cfg +d51g.menu.cpu.samd51g19a_48.bootloader.file=zero/binaries/sam_ba_SAMD51G19A.bin +d51g.menu.bootloader.8kb=8KB_BOOTLOADER +d51g.menu.bootloader.8kb.build.bootloader_size=__8KB_BOOTLOADER__ +d51g.menu.bootloader.8kb.build.ldscript_path=linker_scripts/gcc/8KB_Bootloader +d51g.menu.bootloader.8kb.upload.tool=Fab_SAM_Arduino:bossac +d51g.menu.bootloader.8kb.upload.use_1200bps_touch=true +d51g.menu.bootloader.8kb.upload.wait_for_upload_port=true +d51g.menu.bootloader.8kb.upload.native_usb=true +d51g.menu.bootloader.8kb.upload.offset=0x2000 +d51g.menu.bootloader.16kb=16KB_BOOTLOADER +d51g.menu.bootloader.16kb.build.bootloader_size=__16KB_BOOTLOADER__ +d51g.menu.bootloader.16kb.build.ldscript_path=linker_scripts/gcc/16KB_Bootloader +d51g.menu.bootloader.16kb.upload.tool=Fab_SAM_Arduino:bossac +d51g.menu.bootloader.16kb.upload.use_1200bps_touch=true +d51g.menu.bootloader.16kb.upload.wait_for_upload_port=true +d51g.menu.bootloader.16kb.upload.native_usb=true +d51g.menu.bootloader.16kb.upload.offset=0x4000 +d51g.menu.bootloader.0kb=NO_BOOTLOADER +d51g.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +d51g.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +d51g.menu.bootloader.0kb.upload.tool=openocd-withbootsize +d51g.menu.bootloader.0kb.upload.use_1200bps_touch=false +d51g.menu.bootloader.0kb.upload.wait_for_upload_port=false +d51g.menu.bootloader.0kb.upload.native_usb=false +d51g.menu.bootloader.0kb.upload.offset=0x0000 +d51g.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +d51g.menu.serial.one_uart.build.serialcom_uart=ONE_UART +d51g.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +d51g.menu.serial.one_uart_two_spi=ONE_UART_ONE_WIRE_TWO_SPI +d51g.menu.serial.one_uart_two_spi.build.serialcom_uart=ONE_UART +d51g.menu.serial.one_uart_two_spi.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.one_uart_two_spi.build.serialcom_spi=TWO_SPI +d51g.menu.serial.one_uart_two_wire=ONE_UART_TWO_WIRE_ONE_SPI +d51g.menu.serial.one_uart_two_wire.build.serialcom_uart=ONE_UART +d51g.menu.serial.one_uart_two_wire.build.serialcom_wire=TWO_WIRE +d51g.menu.serial.one_uart_two_wire.build.serialcom_spi=ONE_SPI +d51g.menu.serial.two_uart=TWO_UART_ONE_WIRE_ONE_SPI +d51g.menu.serial.two_uart.build.serialcom_uart=TWO_UART +d51g.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.two_uart.build.serialcom_spi=ONE_SPI +d51g.menu.serial.two_uart_two_spi=TWO_UART_ONE_WIRE_TWO_SPI +d51g.menu.serial.two_uart_two_spi.build.serialcom_uart=TWO_UART +d51g.menu.serial.two_uart_two_spi.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.two_uart_two_spi.build.serialcom_spi=TWO_SPI +d51g.menu.serial.two_uart_two_wire=TWO_UART_TWO_WIRE_ONE_SPI +d51g.menu.serial.two_uart_two_wire.build.serialcom_uart=TWO_UART +d51g.menu.serial.two_uart_two_wire.build.serialcom_wire=TWO_WIRE +d51g.menu.serial.two_uart_two_wire.build.serialcom_spi=ONE_SPI +d51g.menu.serial.three_uart=THREE_UART_ONE_WIRE_ONE_SPI +d51g.menu.serial.three_uart.build.serialcom_uart=THREE_UART +d51g.menu.serial.three_uart.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.three_uart.build.serialcom_spi=ONE_SPI +d51g.menu.serial.three_uart_two_spi=THREE_UART_ONE_WIRE_TWO_SPI +d51g.menu.serial.three_uart_two_spi.build.serialcom_uart=THREE_UART +d51g.menu.serial.three_uart_two_spi.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.three_uart_two_spi.build.serialcom_spi=TWO_SPI +d51g.menu.serial.three_uart_two_wire=THREE_UART_TWO_WIRE_ONE_SPI +d51g.menu.serial.three_uart_two_wire.build.serialcom_uart=THREE_UART +d51g.menu.serial.three_uart_two_wire.build.serialcom_wire=TWO_WIRE +d51g.menu.serial.three_uart_two_wire.build.serialcom_spi=ONE_SPI +d51g.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +d51g.menu.serial.no_uart.build.serialcom_uart=NO_UART +d51g.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +d51g.menu.usb.cdc=CDC_ONLY +d51g.menu.usb.cdc.build.usbcom=CDC_ONLY +d51g.menu.usb.cdc.build.pid=0x7557 +d51g.menu.usb.cdc_hid=CDC_HID +d51g.menu.usb.cdc_hid.build.usbcom=CDC_HID +d51g.menu.usb.cdc_hid.build.pid=0x7856 +d51g.menu.usb.withcdc=WITH_CDC +d51g.menu.usb.withcdc.build.usbcom=WITH_CDC +d51g.menu.usb.withcdc.build.pid=0x7B41 +d51g.menu.usb.hid=HID_ONLY +d51g.menu.usb.hid.build.usbcom=HID_ONLY +d51g.menu.usb.hid.build.pid=0x7B40 +d51g.menu.usb.nocdc=WITHOUT_CDC +d51g.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +d51g.menu.usb.nocdc.build.pid=0x7A0C +d51g.menu.usb.none=USB_DISABLED +d51g.menu.usb.none.build.usbcom=USB_DISABLED +d51g.menu.usb.none.build.pid=0x7856 + +# Generic D51J +d51j.name=Generic D51J +d51j.vid.0=0x16D0 +d51j.pid.0=0x8557 +d51j.vid.1=0x16D0 +d51j.pid.1=0x8856 +d51j.vid.2=0x16D0 +d51j.pid.2=0x8B41 +d51j.vid.3=0x16D0 +d51j.pid.3=0x8B40 +d51j.vid.4=0x16D0 +d51j.pid.4=0x8A0C +d51j.vid.5=0x16D0 +d51j.pid.5=0x8856 +d51j.build.usb_manufacturer="Fab Foundation" + +# KH mod +#d51j.build.board=SAMD_ZERO +d51j.build.board=__SAMD51__ +###### + +d51j.build.core=arduino +d51j.build.variant=Generic_xx1J +d51j.build.variant_system_lib= +d51j.build.vid=0x16D0 +d51j.upload.protocol=sam-ba +d51j.bootloader.tool=openocd-withbootsize +d51j.menu.float.default=Print & String use auto-promoted doubles only +d51j.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +d51j.menu.float.print=Print uses separate singles and doubles +d51j.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +d51j.menu.float.string=String uses separate singles and doubles +d51j.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +d51j.menu.float.both=Print & String use separate singles and doubles +d51j.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +d51j.menu.config.disabled=config.h disabled +d51j.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +d51j.menu.config.enabled=config.h enabled (mostly code size reductions) +d51j.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +d51j.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +d51j.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +d51j.menu.clock.internal=INTERNAL_OSCILLATOR +d51j.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +d51j.menu.clock.crystal_32k=32KHZ_CRYSTAL +d51j.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +d51j.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +d51j.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +d51j.menu.timer.timer_732Hz=732.4Hz (16-bit) +d51j.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +d51j.menu.timer.timer_366Hz=366.2Hz (16-bit) +d51j.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +d51j.menu.timer.timer_244Hz=244.1Hz (16-bit) +d51j.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +d51j.menu.timer.timer_183Hz=183.1Hz (16-bit) +d51j.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +d51j.menu.timer.timer_146Hz=146.5Hz (16-bit) +d51j.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +d51j.menu.timer.timer_122Hz=122.1Hz (16-bit) +d51j.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +d51j.menu.timer.timer_105Hz=104.6Hz (16-bit) +d51j.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +d51j.menu.timer.timer_81Hz=81.38Hz (16-bit) +d51j.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +d51j.menu.timer.timer_61Hz=61.04Hz (16-bit) +d51j.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +d51j.menu.timer.timer_31Hz=30.52Hz (16-bit) +d51j.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +d51j.menu.timer.timer_187500Hz=187500Hz (8-bit) +d51j.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +d51j.menu.timer.timer_93750Hz=93750Hz (8-bit) +d51j.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +d51j.menu.timer.timer_62500Hz=62500Hz (8-bit) +d51j.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +d51j.menu.timer.timer_37500Hz=37500Hz (8-bit) +d51j.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +d51j.menu.timer.timer_20833Hz=20833Hz (8-bit) +d51j.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +d51j.menu.timer.timer_12500Hz=12500Hz (8-bit) +d51j.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +d51j.menu.timer.timer_7500Hz=7500Hz (8-bit) +d51j.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +d51j.menu.timer.timer_4166Hz=4166Hz (8-bit) +d51j.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +d51j.menu.timer.timer_2930Hz=2930Hz (8-bit) +d51j.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +d51j.menu.timer.timer_1465Hz=1465Hz (16-bit) +d51j.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +d51j.menu.cpu.samd51j18a_120=SAMD51J18A_120MHz +d51j.menu.cpu.samd51j18a_120.upload.maximum_size=253952 +d51j.menu.cpu.samd51j18a_120.build.mcu=cortex-m4 +d51j.menu.cpu.samd51j18a_120.build.mathlib=arm_cortexM4lf_math +d51j.menu.cpu.samd51j18a_120.build.f_cpu=120000000L +d51j.menu.cpu.samd51j18a_120.build.usb_product="Xeno D51" + +# KH mod +#d51j.menu.cpu.samd51j18a_120.build.extra_flags=-D__SAMD51J18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51j.menu.cpu.samd51j18a_120.build.extra_flags=-D__SAMD51J18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51j.menu.cpu.samd51j18a_120.build.ldscript=flash_m4f_256KB.ld +d51j.menu.cpu.samd51j18a_120.build.openocdscript=openocd_scripts/SAMD51J18A.cfg +d51j.menu.cpu.samd51j18a_120.bootloader.file=zero/binaries/sam_ba_SAMD51J18A.bin +d51j.menu.cpu.samd51j18a_48=SAMD51J18A_48MHz +d51j.menu.cpu.samd51j18a_48.upload.maximum_size=253952 +d51j.menu.cpu.samd51j18a_48.build.mcu=cortex-m4 +d51j.menu.cpu.samd51j18a_48.build.mathlib=arm_cortexM4lf_math +d51j.menu.cpu.samd51j18a_48.build.f_cpu=48000000L +d51j.menu.cpu.samd51j18a_48.build.usb_product="Xeno D51" + +# KH mod +#d51j.menu.cpu.samd51j18a_48.build.extra_flags=-D__SAMD51J18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51j.menu.cpu.samd51j18a_48.build.extra_flags=-D__SAMD51J18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51j.menu.cpu.samd51j18a_48.build.ldscript=flash_m4f_256KB.ld +d51j.menu.cpu.samd51j18a_48.build.openocdscript=openocd_scripts/SAMD51J18A.cfg +d51j.menu.cpu.samd51j18a_48.bootloader.file=zero/binaries/sam_ba_SAMD51J18A.bin +d51j.menu.cpu.samd51j19a_120=SAMD51J19A_120MHz +d51j.menu.cpu.samd51j19a_120.upload.maximum_size=516096 +d51j.menu.cpu.samd51j19a_120.build.mcu=cortex-m4 +d51j.menu.cpu.samd51j19a_120.build.mathlib=arm_cortexM4lf_math +d51j.menu.cpu.samd51j19a_120.build.f_cpu=120000000L +d51j.menu.cpu.samd51j19a_120.build.usb_product="Xeno D51" + +# KH mod +#d51j.menu.cpu.samd51j19a_120.build.extra_flags=-D__SAMD51J19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51j.menu.cpu.samd51j19a_120.build.extra_flags=-D__SAMD51J19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51j.menu.cpu.samd51j19a_120.build.ldscript=flash_m4f_512KB.ld +d51j.menu.cpu.samd51j19a_120.build.openocdscript=openocd_scripts/SAMD51J19A.cfg +d51j.menu.cpu.samd51j19a_120.bootloader.file=zero/binaries/sam_ba_SAMD51J19A.bin +d51j.menu.cpu.samd51j19a_48=SAMD51J19A_48MHz +d51j.menu.cpu.samd51j19a_48.upload.maximum_size=516096 +d51j.menu.cpu.samd51j19a_48.build.mcu=cortex-m4 +d51j.menu.cpu.samd51j19a_48.build.mathlib=arm_cortexM4lf_math +d51j.menu.cpu.samd51j19a_48.build.f_cpu=48000000L +d51j.menu.cpu.samd51j19a_48.build.usb_product="Xeno D51" + +# KH mod +#d51j.menu.cpu.samd51j19a_48.build.extra_flags=-D__SAMD51J19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51j.menu.cpu.samd51j19a_48.build.extra_flags=-D__SAMD51J19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51j.menu.cpu.samd51j19a_48.build.ldscript=flash_m4f_512KB.ld +d51j.menu.cpu.samd51j19a_48.build.openocdscript=openocd_scripts/SAMD51J19A.cfg +d51j.menu.cpu.samd51j19a_48.bootloader.file=zero/binaries/sam_ba_SAMD51J19A.bin +d51j.menu.cpu.samd51j20a_120=SAMD51J20A_120MHz +d51j.menu.cpu.samd51j20a_120.upload.maximum_size=1040384 +d51j.menu.cpu.samd51j20a_120.build.mcu=cortex-m4 +d51j.menu.cpu.samd51j20a_120.build.mathlib=arm_cortexM4lf_math +d51j.menu.cpu.samd51j20a_120.build.f_cpu=120000000L +d51j.menu.cpu.samd51j20a_120.build.usb_product="Xeno D51" + +# KH mod +#d51j.menu.cpu.samd51j20a_120.build.extra_flags=-D__SAMD51J20A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51j.menu.cpu.samd51j20a_120.build.extra_flags=-D__SAMD51J20A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51j.menu.cpu.samd51j20a_120.build.ldscript=flash_m4f_1MB.ld +d51j.menu.cpu.samd51j20a_120.build.openocdscript=openocd_scripts/SAMD51J20A.cfg +d51j.menu.cpu.samd51j20a_120.bootloader.file=zero/binaries/sam_ba_SAMD51J20A.bin +d51j.menu.cpu.samd51j20a_48=SAMD51J20A_48MHz +d51j.menu.cpu.samd51j20a_48.upload.maximum_size=1040384 +d51j.menu.cpu.samd51j20a_48.build.mcu=cortex-m4 +d51j.menu.cpu.samd51j20a_48.build.mathlib=arm_cortexM4lf_math +d51j.menu.cpu.samd51j20a_48.build.f_cpu=48000000L +d51j.menu.cpu.samd51j20a_48.build.usb_product="Xeno D51" + +# KH mod +#d51j.menu.cpu.samd51j20a_48.build.extra_flags=-D__SAMD51J20A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51j.menu.cpu.samd51j20a_48.build.extra_flags=-D__SAMD51J20A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51j.menu.cpu.samd51j20a_48.build.ldscript=flash_m4f_1MB.ld +d51j.menu.cpu.samd51j20a_48.build.openocdscript=openocd_scripts/SAMD51J20A.cfg +d51j.menu.cpu.samd51j20a_48.bootloader.file=zero/binaries/sam_ba_SAMD51J20A.bin +d51j.menu.bootloader.8kb=8KB_BOOTLOADER +d51j.menu.bootloader.8kb.build.bootloader_size=__8KB_BOOTLOADER__ +d51j.menu.bootloader.8kb.build.ldscript_path=linker_scripts/gcc/8KB_Bootloader +d51j.menu.bootloader.8kb.upload.tool=Fab_SAM_Arduino:bossac +d51j.menu.bootloader.8kb.upload.use_1200bps_touch=true +d51j.menu.bootloader.8kb.upload.wait_for_upload_port=true +d51j.menu.bootloader.8kb.upload.native_usb=true +d51j.menu.bootloader.8kb.upload.offset=0x2000 +d51j.menu.bootloader.16kb=16KB_BOOTLOADER +d51j.menu.bootloader.16kb.build.bootloader_size=__16KB_BOOTLOADER__ +d51j.menu.bootloader.16kb.build.ldscript_path=linker_scripts/gcc/16KB_Bootloader +d51j.menu.bootloader.16kb.upload.tool=Fab_SAM_Arduino:bossac +d51j.menu.bootloader.16kb.upload.use_1200bps_touch=true +d51j.menu.bootloader.16kb.upload.wait_for_upload_port=true +d51j.menu.bootloader.16kb.upload.native_usb=true +d51j.menu.bootloader.16kb.upload.offset=0x4000 +d51j.menu.bootloader.0kb=NO_BOOTLOADER +d51j.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +d51j.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +d51j.menu.bootloader.0kb.upload.tool=openocd-withbootsize +d51j.menu.bootloader.0kb.upload.use_1200bps_touch=false +d51j.menu.bootloader.0kb.upload.wait_for_upload_port=false +d51j.menu.bootloader.0kb.upload.native_usb=false +d51j.menu.bootloader.0kb.upload.offset=0x0000 +d51j.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +d51j.menu.serial.one_uart.build.serialcom_uart=ONE_UART +d51j.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +d51j.menu.serial.one_uart_two_spi=ONE_UART_ONE_WIRE_TWO_SPI +d51j.menu.serial.one_uart_two_spi.build.serialcom_uart=ONE_UART +d51j.menu.serial.one_uart_two_spi.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.one_uart_two_spi.build.serialcom_spi=TWO_SPI +d51j.menu.serial.one_uart_two_wire=ONE_UART_TWO_WIRE_ONE_SPI +d51j.menu.serial.one_uart_two_wire.build.serialcom_uart=ONE_UART +d51j.menu.serial.one_uart_two_wire.build.serialcom_wire=TWO_WIRE +d51j.menu.serial.one_uart_two_wire.build.serialcom_spi=ONE_SPI +d51j.menu.serial.two_uart=TWO_UART_ONE_WIRE_ONE_SPI +d51j.menu.serial.two_uart.build.serialcom_uart=TWO_UART +d51j.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.two_uart.build.serialcom_spi=ONE_SPI +d51j.menu.serial.two_uart_two_spi=TWO_UART_ONE_WIRE_TWO_SPI +d51j.menu.serial.two_uart_two_spi.build.serialcom_uart=TWO_UART +d51j.menu.serial.two_uart_two_spi.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.two_uart_two_spi.build.serialcom_spi=TWO_SPI +d51j.menu.serial.two_uart_two_wire=TWO_UART_TWO_WIRE_ONE_SPI +d51j.menu.serial.two_uart_two_wire.build.serialcom_uart=TWO_UART +d51j.menu.serial.two_uart_two_wire.build.serialcom_wire=TWO_WIRE +d51j.menu.serial.two_uart_two_wire.build.serialcom_spi=ONE_SPI +d51j.menu.serial.three_uart=THREE_UART_ONE_WIRE_ONE_SPI +d51j.menu.serial.three_uart.build.serialcom_uart=THREE_UART +d51j.menu.serial.three_uart.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.three_uart.build.serialcom_spi=ONE_SPI +d51j.menu.serial.three_uart_two_spi=THREE_UART_ONE_WIRE_TWO_SPI +d51j.menu.serial.three_uart_two_spi.build.serialcom_uart=THREE_UART +d51j.menu.serial.three_uart_two_spi.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.three_uart_two_spi.build.serialcom_spi=TWO_SPI +d51j.menu.serial.three_uart_two_wire=THREE_UART_TWO_WIRE_ONE_SPI +d51j.menu.serial.three_uart_two_wire.build.serialcom_uart=THREE_UART +d51j.menu.serial.three_uart_two_wire.build.serialcom_wire=TWO_WIRE +d51j.menu.serial.three_uart_two_wire.build.serialcom_spi=ONE_SPI +d51j.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +d51j.menu.serial.no_uart.build.serialcom_uart=NO_UART +d51j.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +d51j.menu.usb.cdc=CDC_ONLY +d51j.menu.usb.cdc.build.usbcom=CDC_ONLY +d51j.menu.usb.cdc.build.pid=0x8557 +d51j.menu.usb.cdc_hid=CDC_HID +d51j.menu.usb.cdc_hid.build.usbcom=CDC_HID +d51j.menu.usb.cdc_hid.build.pid=0x8856 +d51j.menu.usb.withcdc=WITH_CDC +d51j.menu.usb.withcdc.build.usbcom=WITH_CDC +d51j.menu.usb.withcdc.build.pid=0x8B41 +d51j.menu.usb.hid=HID_ONLY +d51j.menu.usb.hid.build.usbcom=HID_ONLY +d51j.menu.usb.hid.build.pid=0x8B40 +d51j.menu.usb.nocdc=WITHOUT_CDC +d51j.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +d51j.menu.usb.nocdc.build.pid=0x8A0C +d51j.menu.usb.none=USB_DISABLED +d51j.menu.usb.none.build.usbcom=USB_DISABLED +d51j.menu.usb.none.build.pid=0x8856 diff --git a/Packages_Patches/Maixduino/hardware/k210/0.3.10/cores/arduino/Stream.h b/Packages_Patches/Maixduino/hardware/k210/0.3.10/cores/arduino/Stream.h index 490a2bad..833152a3 100644 --- a/Packages_Patches/Maixduino/hardware/k210/0.3.10/cores/arduino/Stream.h +++ b/Packages_Patches/Maixduino/hardware/k210/0.3.10/cores/arduino/Stream.h @@ -40,124 +40,126 @@ // or a time out occurs due to lack of input. enum LookaheadMode { - SKIP_ALL, // All invalid characters are ignored. - SKIP_NONE, // Nothing is skipped, and the stream is not touched unless the first waiting character is valid. - SKIP_WHITESPACE // Only tabs, spaces, line feeds & carriage returns are skipped. + SKIP_ALL, // All invalid characters are ignored. + SKIP_NONE, // Nothing is skipped, and the stream is not touched unless the first waiting character is valid. + SKIP_WHITESPACE // Only tabs, spaces, line feeds & carriage returns are skipped. }; #define NO_IGNORE_CHAR '\x01' // a char not found in a valid ASCII numeric field class Stream : public Print { - protected: - unsigned long _timeout; // number of milliseconds to wait for the next char before aborting timed read - unsigned long _startMillis = 0; // used for timeout measurement - int timedRead(); // read stream with timeout - int timedPeek(); // peek stream with timeout - int peekNextDigit(LookaheadMode lookahead, bool detectDecimal); // returns the next numeric digit in the stream or -1 if timeout - - public: - virtual int available() = 0; - virtual int read() = 0; - virtual int peek() = 0; - - Stream() - { - _timeout = 1000; - } - - // parsing methods - - void setTimeout(unsigned long timeout); // sets maximum milliseconds to wait for stream data, default is 1 second - unsigned long getTimeout(void) - { - return _timeout; - } - - bool find(char *target); // reads data from the stream until the target string is found - bool find(uint8_t *target) - { - return find ((char *)target); - } - // returns true if target string is found, false if timed out (see setTimeout) - - bool find(char *target, size_t length); // reads data from the stream until the target string of given length is found - bool find(uint8_t *target, size_t length) - { - return find ((char *)target, length); - } - // returns true if target string is found, false if timed out - - bool find(char target) - { - return find (&target, 1); - } - - bool findUntil(char *target, char *terminator); // as find but search ends if the terminator string is found - bool findUntil(uint8_t *target, char *terminator) - { - return findUntil((char *)target, terminator); - } - - bool findUntil(char *target, size_t targetLen, char *terminate, size_t termLen); // as above but search ends if the terminate string is found - bool findUntil(uint8_t *target, size_t targetLen, char *terminate, size_t termLen) - { - return findUntil((char *)target, targetLen, terminate, termLen); - } - - long parseInt(LookaheadMode lookahead = SKIP_ALL, char ignore = NO_IGNORE_CHAR); - // returns the first valid (long) integer value from the current position. - // lookahead determines how parseInt looks ahead in the stream. - // See LookaheadMode enumeration at the top of the file. - // Lookahead is terminated by the first character that is not a valid part of an integer. - // Once parsing commences, 'ignore' will be skipped in the stream. - - float parseFloat(LookaheadMode lookahead = SKIP_ALL, char ignore = NO_IGNORE_CHAR); - // float version of parseInt - - size_t readBytes( char *buffer, size_t length); // read chars from stream into buffer - size_t readBytes( uint8_t *buffer, size_t length) - { - return readBytes((char *)buffer, length); - } - // terminates if length characters have been read or timeout (see setTimeout) - // returns the number of characters placed in the buffer (0 means no valid data found) - - size_t readBytesUntil( char terminator, char *buffer, size_t length); // as readBytes with terminator character - size_t readBytesUntil( char terminator, uint8_t *buffer, size_t length) - { - return readBytesUntil(terminator, (char *)buffer, length); - } - // terminates if length characters have been read, timeout, or if the terminator character detected - // returns the number of characters placed in the buffer (0 means no valid data found) - - // Arduino String functions to be added here - String readString(); - String readStringUntil(char terminator); - - protected: - long parseInt(char ignore) - { - return parseInt(SKIP_ALL, ignore); - } - float parseFloat(char ignore) - { - return parseFloat(SKIP_ALL, ignore); - } - // These overload exists for compatibility with any class that has derived - // Stream and used parseFloat/Int with a custom ignore character. To keep - // the public API simple, these overload remains protected. - - struct MultiTarget - { - const char *str; // string you're searching for - size_t len; // length of string you're searching for - size_t index; // index used by the search routine. - }; - - // This allows you to search for an arbitrary number of strings. - // Returns index of the target that is found first or -1 if timeout occurs. - int findMulti(struct MultiTarget *targets, int tCount); + protected: + unsigned long _timeout; // number of milliseconds to wait for the next char before aborting timed read + unsigned long _startMillis = 0; // used for timeout measurement + int timedRead(); // read stream with timeout + int timedPeek(); // peek stream with timeout + int peekNextDigit(LookaheadMode lookahead, + bool detectDecimal); // returns the next numeric digit in the stream or -1 if timeout + + public: + virtual int available() = 0; + virtual int read() = 0; + virtual int peek() = 0; + + Stream() + { + _timeout = 1000; + } + + // parsing methods + + void setTimeout(unsigned long timeout); // sets maximum milliseconds to wait for stream data, default is 1 second + unsigned long getTimeout(void) + { + return _timeout; + } + + bool find(char *target); // reads data from the stream until the target string is found + bool find(uint8_t *target) + { + return find ((char *)target); + } + // returns true if target string is found, false if timed out (see setTimeout) + + bool find(char *target, size_t length); // reads data from the stream until the target string of given length is found + bool find(uint8_t *target, size_t length) + { + return find ((char *)target, length); + } + // returns true if target string is found, false if timed out + + bool find(char target) + { + return find (&target, 1); + } + + bool findUntil(char *target, char *terminator); // as find but search ends if the terminator string is found + bool findUntil(uint8_t *target, char *terminator) + { + return findUntil((char *)target, terminator); + } + + bool findUntil(char *target, size_t targetLen, char *terminate, + size_t termLen); // as above but search ends if the terminate string is found + bool findUntil(uint8_t *target, size_t targetLen, char *terminate, size_t termLen) + { + return findUntil((char *)target, targetLen, terminate, termLen); + } + + long parseInt(LookaheadMode lookahead = SKIP_ALL, char ignore = NO_IGNORE_CHAR); + // returns the first valid (long) integer value from the current position. + // lookahead determines how parseInt looks ahead in the stream. + // See LookaheadMode enumeration at the top of the file. + // Lookahead is terminated by the first character that is not a valid part of an integer. + // Once parsing commences, 'ignore' will be skipped in the stream. + + float parseFloat(LookaheadMode lookahead = SKIP_ALL, char ignore = NO_IGNORE_CHAR); + // float version of parseInt + + size_t readBytes( char *buffer, size_t length); // read chars from stream into buffer + size_t readBytes( uint8_t *buffer, size_t length) + { + return readBytes((char *)buffer, length); + } + // terminates if length characters have been read or timeout (see setTimeout) + // returns the number of characters placed in the buffer (0 means no valid data found) + + size_t readBytesUntil( char terminator, char *buffer, size_t length); // as readBytes with terminator character + size_t readBytesUntil( char terminator, uint8_t *buffer, size_t length) + { + return readBytesUntil(terminator, (char *)buffer, length); + } + // terminates if length characters have been read, timeout, or if the terminator character detected + // returns the number of characters placed in the buffer (0 means no valid data found) + + // Arduino String functions to be added here + String readString(); + String readStringUntil(char terminator); + + protected: + long parseInt(char ignore) + { + return parseInt(SKIP_ALL, ignore); + } + float parseFloat(char ignore) + { + return parseFloat(SKIP_ALL, ignore); + } + // These overload exists for compatibility with any class that has derived + // Stream and used parseFloat/Int with a custom ignore character. To keep + // the public API simple, these overload remains protected. + + struct MultiTarget + { + const char *str; // string you're searching for + size_t len; // length of string you're searching for + size_t index; // index used by the search routine. + }; + + // This allows you to search for an arbitrary number of strings. + // Returns index of the target that is found first or -1 if timeout occurs. + int findMulti(struct MultiTarget *targets, int tCount); }; #undef NO_IGNORE_CHAR diff --git a/Packages_Patches/Maixduino/hardware/k210/0.3.11/cores/arduino/Stream.h b/Packages_Patches/Maixduino/hardware/k210/0.3.11/cores/arduino/Stream.h index 490a2bad..833152a3 100644 --- a/Packages_Patches/Maixduino/hardware/k210/0.3.11/cores/arduino/Stream.h +++ b/Packages_Patches/Maixduino/hardware/k210/0.3.11/cores/arduino/Stream.h @@ -40,124 +40,126 @@ // or a time out occurs due to lack of input. enum LookaheadMode { - SKIP_ALL, // All invalid characters are ignored. - SKIP_NONE, // Nothing is skipped, and the stream is not touched unless the first waiting character is valid. - SKIP_WHITESPACE // Only tabs, spaces, line feeds & carriage returns are skipped. + SKIP_ALL, // All invalid characters are ignored. + SKIP_NONE, // Nothing is skipped, and the stream is not touched unless the first waiting character is valid. + SKIP_WHITESPACE // Only tabs, spaces, line feeds & carriage returns are skipped. }; #define NO_IGNORE_CHAR '\x01' // a char not found in a valid ASCII numeric field class Stream : public Print { - protected: - unsigned long _timeout; // number of milliseconds to wait for the next char before aborting timed read - unsigned long _startMillis = 0; // used for timeout measurement - int timedRead(); // read stream with timeout - int timedPeek(); // peek stream with timeout - int peekNextDigit(LookaheadMode lookahead, bool detectDecimal); // returns the next numeric digit in the stream or -1 if timeout - - public: - virtual int available() = 0; - virtual int read() = 0; - virtual int peek() = 0; - - Stream() - { - _timeout = 1000; - } - - // parsing methods - - void setTimeout(unsigned long timeout); // sets maximum milliseconds to wait for stream data, default is 1 second - unsigned long getTimeout(void) - { - return _timeout; - } - - bool find(char *target); // reads data from the stream until the target string is found - bool find(uint8_t *target) - { - return find ((char *)target); - } - // returns true if target string is found, false if timed out (see setTimeout) - - bool find(char *target, size_t length); // reads data from the stream until the target string of given length is found - bool find(uint8_t *target, size_t length) - { - return find ((char *)target, length); - } - // returns true if target string is found, false if timed out - - bool find(char target) - { - return find (&target, 1); - } - - bool findUntil(char *target, char *terminator); // as find but search ends if the terminator string is found - bool findUntil(uint8_t *target, char *terminator) - { - return findUntil((char *)target, terminator); - } - - bool findUntil(char *target, size_t targetLen, char *terminate, size_t termLen); // as above but search ends if the terminate string is found - bool findUntil(uint8_t *target, size_t targetLen, char *terminate, size_t termLen) - { - return findUntil((char *)target, targetLen, terminate, termLen); - } - - long parseInt(LookaheadMode lookahead = SKIP_ALL, char ignore = NO_IGNORE_CHAR); - // returns the first valid (long) integer value from the current position. - // lookahead determines how parseInt looks ahead in the stream. - // See LookaheadMode enumeration at the top of the file. - // Lookahead is terminated by the first character that is not a valid part of an integer. - // Once parsing commences, 'ignore' will be skipped in the stream. - - float parseFloat(LookaheadMode lookahead = SKIP_ALL, char ignore = NO_IGNORE_CHAR); - // float version of parseInt - - size_t readBytes( char *buffer, size_t length); // read chars from stream into buffer - size_t readBytes( uint8_t *buffer, size_t length) - { - return readBytes((char *)buffer, length); - } - // terminates if length characters have been read or timeout (see setTimeout) - // returns the number of characters placed in the buffer (0 means no valid data found) - - size_t readBytesUntil( char terminator, char *buffer, size_t length); // as readBytes with terminator character - size_t readBytesUntil( char terminator, uint8_t *buffer, size_t length) - { - return readBytesUntil(terminator, (char *)buffer, length); - } - // terminates if length characters have been read, timeout, or if the terminator character detected - // returns the number of characters placed in the buffer (0 means no valid data found) - - // Arduino String functions to be added here - String readString(); - String readStringUntil(char terminator); - - protected: - long parseInt(char ignore) - { - return parseInt(SKIP_ALL, ignore); - } - float parseFloat(char ignore) - { - return parseFloat(SKIP_ALL, ignore); - } - // These overload exists for compatibility with any class that has derived - // Stream and used parseFloat/Int with a custom ignore character. To keep - // the public API simple, these overload remains protected. - - struct MultiTarget - { - const char *str; // string you're searching for - size_t len; // length of string you're searching for - size_t index; // index used by the search routine. - }; - - // This allows you to search for an arbitrary number of strings. - // Returns index of the target that is found first or -1 if timeout occurs. - int findMulti(struct MultiTarget *targets, int tCount); + protected: + unsigned long _timeout; // number of milliseconds to wait for the next char before aborting timed read + unsigned long _startMillis = 0; // used for timeout measurement + int timedRead(); // read stream with timeout + int timedPeek(); // peek stream with timeout + int peekNextDigit(LookaheadMode lookahead, + bool detectDecimal); // returns the next numeric digit in the stream or -1 if timeout + + public: + virtual int available() = 0; + virtual int read() = 0; + virtual int peek() = 0; + + Stream() + { + _timeout = 1000; + } + + // parsing methods + + void setTimeout(unsigned long timeout); // sets maximum milliseconds to wait for stream data, default is 1 second + unsigned long getTimeout(void) + { + return _timeout; + } + + bool find(char *target); // reads data from the stream until the target string is found + bool find(uint8_t *target) + { + return find ((char *)target); + } + // returns true if target string is found, false if timed out (see setTimeout) + + bool find(char *target, size_t length); // reads data from the stream until the target string of given length is found + bool find(uint8_t *target, size_t length) + { + return find ((char *)target, length); + } + // returns true if target string is found, false if timed out + + bool find(char target) + { + return find (&target, 1); + } + + bool findUntil(char *target, char *terminator); // as find but search ends if the terminator string is found + bool findUntil(uint8_t *target, char *terminator) + { + return findUntil((char *)target, terminator); + } + + bool findUntil(char *target, size_t targetLen, char *terminate, + size_t termLen); // as above but search ends if the terminate string is found + bool findUntil(uint8_t *target, size_t targetLen, char *terminate, size_t termLen) + { + return findUntil((char *)target, targetLen, terminate, termLen); + } + + long parseInt(LookaheadMode lookahead = SKIP_ALL, char ignore = NO_IGNORE_CHAR); + // returns the first valid (long) integer value from the current position. + // lookahead determines how parseInt looks ahead in the stream. + // See LookaheadMode enumeration at the top of the file. + // Lookahead is terminated by the first character that is not a valid part of an integer. + // Once parsing commences, 'ignore' will be skipped in the stream. + + float parseFloat(LookaheadMode lookahead = SKIP_ALL, char ignore = NO_IGNORE_CHAR); + // float version of parseInt + + size_t readBytes( char *buffer, size_t length); // read chars from stream into buffer + size_t readBytes( uint8_t *buffer, size_t length) + { + return readBytes((char *)buffer, length); + } + // terminates if length characters have been read or timeout (see setTimeout) + // returns the number of characters placed in the buffer (0 means no valid data found) + + size_t readBytesUntil( char terminator, char *buffer, size_t length); // as readBytes with terminator character + size_t readBytesUntil( char terminator, uint8_t *buffer, size_t length) + { + return readBytesUntil(terminator, (char *)buffer, length); + } + // terminates if length characters have been read, timeout, or if the terminator character detected + // returns the number of characters placed in the buffer (0 means no valid data found) + + // Arduino String functions to be added here + String readString(); + String readStringUntil(char terminator); + + protected: + long parseInt(char ignore) + { + return parseInt(SKIP_ALL, ignore); + } + float parseFloat(char ignore) + { + return parseFloat(SKIP_ALL, ignore); + } + // These overload exists for compatibility with any class that has derived + // Stream and used parseFloat/Int with a custom ignore character. To keep + // the public API simple, these overload remains protected. + + struct MultiTarget + { + const char *str; // string you're searching for + size_t len; // length of string you're searching for + size_t index; // index used by the search routine. + }; + + // This allows you to search for an arbitrary number of strings. + // Returns index of the target that is found first or -1 if timeout occurs. + int findMulti(struct MultiTarget *targets, int tCount); }; #undef NO_IGNORE_CHAR diff --git a/Packages_Patches/STM32/hardware/stm32/1.9.0/variants/NUCLEO_F767ZI/variant.h b/Packages_Patches/STM32/hardware/stm32/1.9.0/variants/NUCLEO_F767ZI/variant.h index 1d61846b..fe86cf02 100644 --- a/Packages_Patches/STM32/hardware/stm32/1.9.0/variants/NUCLEO_F767ZI/variant.h +++ b/Packages_Patches/STM32/hardware/stm32/1.9.0/variants/NUCLEO_F767ZI/variant.h @@ -160,26 +160,26 @@ extern "C" { ----------------------------------------------------------------------------*/ #ifdef __cplusplus - // These serial port names are intended to allow libraries and architecture-neutral - // sketches to automatically default to the correct port name for a particular type - // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, - // the first hardware serial port whose RX/TX pins are not dedicated to another use. - // - // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor - // - // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial - // - // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library - // - // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. - // - // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX - // pins are NOT connected to anything by default. - #define SERIAL_PORT_MONITOR Serial - - // KH mod to add Serial1, for ESP-AT - //#define SERIAL_PORT_HARDWARE Serial - #define SERIAL_PORT_HARDWARE Serial1 + // These serial port names are intended to allow libraries and architecture-neutral + // sketches to automatically default to the correct port name for a particular type + // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, + // the first hardware serial port whose RX/TX pins are not dedicated to another use. + // + // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor + // + // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial + // + // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library + // + // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. + // + // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX + // pins are NOT connected to anything by default. + #define SERIAL_PORT_MONITOR Serial + + // KH mod to add Serial1, for ESP-AT + //#define SERIAL_PORT_HARDWARE Serial + #define SERIAL_PORT_HARDWARE Serial1 #endif #endif /* _VARIANT_ARDUINO_STM32_ */ diff --git a/Packages_Patches/STM32/hardware/stm32/1.9.0/variants/NUCLEO_L053R8/variant.h b/Packages_Patches/STM32/hardware/stm32/1.9.0/variants/NUCLEO_L053R8/variant.h index e7ba1e9b..012b3fcf 100644 --- a/Packages_Patches/STM32/hardware/stm32/1.9.0/variants/NUCLEO_L053R8/variant.h +++ b/Packages_Patches/STM32/hardware/stm32/1.9.0/variants/NUCLEO_L053R8/variant.h @@ -120,26 +120,26 @@ extern "C" { ----------------------------------------------------------------------------*/ #ifdef __cplusplus - // These serial port names are intended to allow libraries and architecture-neutral - // sketches to automatically default to the correct port name for a particular type - // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, - // the first hardware serial port whose RX/TX pins are not dedicated to another use. - // - // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor - // - // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial - // - // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library - // - // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. - // - // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX - // pins are NOT connected to anything by default. - #define SERIAL_PORT_MONITOR Serial - - // KH mod to add Serial1, for ESP-AT - //#define SERIAL_PORT_HARDWARE Serial - #define SERIAL_PORT_HARDWARE Serial1 + // These serial port names are intended to allow libraries and architecture-neutral + // sketches to automatically default to the correct port name for a particular type + // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, + // the first hardware serial port whose RX/TX pins are not dedicated to another use. + // + // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor + // + // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial + // + // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library + // + // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. + // + // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX + // pins are NOT connected to anything by default. + #define SERIAL_PORT_MONITOR Serial + + // KH mod to add Serial1, for ESP-AT + //#define SERIAL_PORT_HARDWARE Serial + #define SERIAL_PORT_HARDWARE Serial1 #endif #endif /* _VARIANT_ARDUINO_STM32_ */ diff --git a/Packages_Patches/STM32/hardware/stm32/2.0.0/variants/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h b/Packages_Patches/STM32/hardware/stm32/2.0.0/variants/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h index 8d7b8a86..fe1dcf86 100644 --- a/Packages_Patches/STM32/hardware/stm32/2.0.0/variants/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h +++ b/Packages_Patches/STM32/hardware/stm32/2.0.0/variants/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h @@ -188,7 +188,7 @@ // On-board LED pin number #ifndef LED_BUILTIN - #define LED_BUILTIN PB0 + #define LED_BUILTIN PB0 #endif #define LED_GREEN LED_BUILTIN #define LED_BLUE PB7 @@ -196,29 +196,29 @@ // On-board user button #ifndef USER_BTN - #define USER_BTN PC13 + #define USER_BTN PC13 #endif // Timer Definitions // Use TIM6/TIM7 when possible as servo and tone don't need GPIO output pin #ifndef TIMER_TONE - #define TIMER_TONE TIM6 + #define TIMER_TONE TIM6 #endif #ifndef TIMER_SERVO - #define TIMER_SERVO TIM7 + #define TIMER_SERVO TIM7 #endif // UART Definitions #ifndef SERIAL_UART_INSTANCE - #define SERIAL_UART_INSTANCE 3 //Connected to ST-Link + #define SERIAL_UART_INSTANCE 3 //Connected to ST-Link #endif // Serial pin used for console (ex: stlink) // Rerquired by Firmata #ifndef PIN_SERIAL_RX - #define PIN_SERIAL_RX PD9 + #define PIN_SERIAL_RX PD9 #endif #ifndef PIN_SERIAL_TX - #define PIN_SERIAL_TX PD8 + #define PIN_SERIAL_TX PD8 #endif // Value of the External oscillator in Hz @@ -226,16 +226,16 @@ /* Extra HAL modules */ #if !defined(HAL_DAC_MODULE_DISABLED) - #define HAL_DAC_MODULE_ENABLED + #define HAL_DAC_MODULE_ENABLED #endif #if !defined(HAL_ETH_MODULE_DISABLED) - #define HAL_ETH_MODULE_ENABLED + #define HAL_ETH_MODULE_ENABLED #endif #if !defined(HAL_QSPI_MODULE_DISABLED) - #define HAL_QSPI_MODULE_ENABLED + #define HAL_QSPI_MODULE_ENABLED #endif #if !defined(HAL_SD_MODULE_DISABLED) - #define HAL_SD_MODULE_ENABLED + #define HAL_SD_MODULE_ENABLED #endif // Last Flash sector used for EEPROM emulation, address/sector depends on single/dual bank configuration. @@ -248,27 +248,27 @@ ----------------------------------------------------------------------------*/ #ifdef __cplusplus - // These serial port names are intended to allow libraries and architecture-neutral - // sketches to automatically default to the correct port name for a particular type - // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, - // the first hardware serial port whose RX/TX pins are not dedicated to another use. - // - // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor - // - // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial - // - // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library - // - // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. - // - // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX - // pins are NOT connected to anything by default. - #ifndef SERIAL_PORT_MONITOR - #define SERIAL_PORT_MONITOR Serial - #endif - #ifndef SERIAL_PORT_HARDWARE - // KH mod to add Serial1, for ESP-AT - //#define SERIAL_PORT_HARDWARE Serial - #define SERIAL_PORT_HARDWARE Serial1 - #endif + // These serial port names are intended to allow libraries and architecture-neutral + // sketches to automatically default to the correct port name for a particular type + // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, + // the first hardware serial port whose RX/TX pins are not dedicated to another use. + // + // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor + // + // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial + // + // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library + // + // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. + // + // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX + // pins are NOT connected to anything by default. + #ifndef SERIAL_PORT_MONITOR + #define SERIAL_PORT_MONITOR Serial + #endif + #ifndef SERIAL_PORT_HARDWARE + // KH mod to add Serial1, for ESP-AT + //#define SERIAL_PORT_HARDWARE Serial + #define SERIAL_PORT_HARDWARE Serial1 + #endif #endif diff --git a/Packages_Patches/STM32/hardware/stm32/2.0.0/variants/L052R(6-8)H_L053R(6-8)H/variant_generic.h b/Packages_Patches/STM32/hardware/stm32/2.0.0/variants/L052R(6-8)H_L053R(6-8)H/variant_generic.h index edb4fab7..b1f98ab3 100644 --- a/Packages_Patches/STM32/hardware/stm32/2.0.0/variants/L052R(6-8)H_L053R(6-8)H/variant_generic.h +++ b/Packages_Patches/STM32/hardware/stm32/2.0.0/variants/L052R(6-8)H_L053R(6-8)H/variant_generic.h @@ -75,71 +75,71 @@ // On-board LED pin number #ifndef LED_BUILTIN - #define LED_BUILTIN PNUM_NOT_DEFINED + #define LED_BUILTIN PNUM_NOT_DEFINED #endif // On-board user button #ifndef USER_BTN - #define USER_BTN PNUM_NOT_DEFINED + #define USER_BTN PNUM_NOT_DEFINED #endif // SPI definitions #ifndef PIN_SPI_SS - #define PIN_SPI_SS PA4 + #define PIN_SPI_SS PA4 #endif #ifndef PIN_SPI_SS1 - #define PIN_SPI_SS1 PA15 + #define PIN_SPI_SS1 PA15 #endif #ifndef PIN_SPI_SS2 - #define PIN_SPI_SS2 PNUM_NOT_DEFINED + #define PIN_SPI_SS2 PNUM_NOT_DEFINED #endif #ifndef PIN_SPI_SS3 - #define PIN_SPI_SS3 PNUM_NOT_DEFINED + #define PIN_SPI_SS3 PNUM_NOT_DEFINED #endif #ifndef PIN_SPI_MOSI - #define PIN_SPI_MOSI PA7 + #define PIN_SPI_MOSI PA7 #endif #ifndef PIN_SPI_MISO - #define PIN_SPI_MISO PA6 + #define PIN_SPI_MISO PA6 #endif #ifndef PIN_SPI_SCK - #define PIN_SPI_SCK PA5 + #define PIN_SPI_SCK PA5 #endif // I2C definitions #ifndef PIN_WIRE_SDA - #define PIN_WIRE_SDA PB7 + #define PIN_WIRE_SDA PB7 #endif #ifndef PIN_WIRE_SCL - #define PIN_WIRE_SCL PB6 + #define PIN_WIRE_SCL PB6 #endif // Timer Definitions // Use TIM6/TIM7 when possible as servo and tone don't need GPIO output pin #ifndef TIMER_TONE - #define TIMER_TONE TIM6 + #define TIMER_TONE TIM6 #endif #ifndef TIMER_SERVO - #define TIMER_SERVO TIM21 + #define TIMER_SERVO TIM21 #endif // UART Definitions #ifndef SERIAL_UART_INSTANCE - #define SERIAL_UART_INSTANCE 2 + #define SERIAL_UART_INSTANCE 2 #endif // Default pin used for generic 'Serial' instance // Mandatory for Firmata #ifndef PIN_SERIAL_RX - #define PIN_SERIAL_RX PA3 + #define PIN_SERIAL_RX PA3 #endif #ifndef PIN_SERIAL_TX - #define PIN_SERIAL_TX PA2 + #define PIN_SERIAL_TX PA2 #endif // Extra HAL modules #if !defined(HAL_DAC_MODULE_DISABLED) - #define HAL_DAC_MODULE_ENABLED + #define HAL_DAC_MODULE_ENABLED #endif /*---------------------------------------------------------------------------- @@ -147,27 +147,27 @@ ----------------------------------------------------------------------------*/ #ifdef __cplusplus - // These serial port names are intended to allow libraries and architecture-neutral - // sketches to automatically default to the correct port name for a particular type - // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, - // the first hardware serial port whose RX/TX pins are not dedicated to another use. - // - // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor - // - // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial - // - // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library - // - // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. - // - // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX - // pins are NOT connected to anything by default. - #ifndef SERIAL_PORT_MONITOR - #define SERIAL_PORT_MONITOR Serial - #endif - #ifndef SERIAL_PORT_HARDWARE - // KH mod to add Serial1, for ESP-AT - //#define SERIAL_PORT_HARDWARE Serial - #define SERIAL_PORT_HARDWARE Serial1 - #endif + // These serial port names are intended to allow libraries and architecture-neutral + // sketches to automatically default to the correct port name for a particular type + // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, + // the first hardware serial port whose RX/TX pins are not dedicated to another use. + // + // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor + // + // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial + // + // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library + // + // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. + // + // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX + // pins are NOT connected to anything by default. + #ifndef SERIAL_PORT_MONITOR + #define SERIAL_PORT_MONITOR Serial + #endif + #ifndef SERIAL_PORT_HARDWARE + // KH mod to add Serial1, for ESP-AT + //#define SERIAL_PORT_HARDWARE Serial + #define SERIAL_PORT_HARDWARE Serial1 + #endif #endif diff --git a/Packages_Patches/STM32/hardware/stm32/2.0.0/variants/STM32F7xx/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h b/Packages_Patches/STM32/hardware/stm32/2.0.0/variants/STM32F7xx/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h index 8d7b8a86..fe1dcf86 100644 --- a/Packages_Patches/STM32/hardware/stm32/2.0.0/variants/STM32F7xx/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h +++ b/Packages_Patches/STM32/hardware/stm32/2.0.0/variants/STM32F7xx/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h @@ -188,7 +188,7 @@ // On-board LED pin number #ifndef LED_BUILTIN - #define LED_BUILTIN PB0 + #define LED_BUILTIN PB0 #endif #define LED_GREEN LED_BUILTIN #define LED_BLUE PB7 @@ -196,29 +196,29 @@ // On-board user button #ifndef USER_BTN - #define USER_BTN PC13 + #define USER_BTN PC13 #endif // Timer Definitions // Use TIM6/TIM7 when possible as servo and tone don't need GPIO output pin #ifndef TIMER_TONE - #define TIMER_TONE TIM6 + #define TIMER_TONE TIM6 #endif #ifndef TIMER_SERVO - #define TIMER_SERVO TIM7 + #define TIMER_SERVO TIM7 #endif // UART Definitions #ifndef SERIAL_UART_INSTANCE - #define SERIAL_UART_INSTANCE 3 //Connected to ST-Link + #define SERIAL_UART_INSTANCE 3 //Connected to ST-Link #endif // Serial pin used for console (ex: stlink) // Rerquired by Firmata #ifndef PIN_SERIAL_RX - #define PIN_SERIAL_RX PD9 + #define PIN_SERIAL_RX PD9 #endif #ifndef PIN_SERIAL_TX - #define PIN_SERIAL_TX PD8 + #define PIN_SERIAL_TX PD8 #endif // Value of the External oscillator in Hz @@ -226,16 +226,16 @@ /* Extra HAL modules */ #if !defined(HAL_DAC_MODULE_DISABLED) - #define HAL_DAC_MODULE_ENABLED + #define HAL_DAC_MODULE_ENABLED #endif #if !defined(HAL_ETH_MODULE_DISABLED) - #define HAL_ETH_MODULE_ENABLED + #define HAL_ETH_MODULE_ENABLED #endif #if !defined(HAL_QSPI_MODULE_DISABLED) - #define HAL_QSPI_MODULE_ENABLED + #define HAL_QSPI_MODULE_ENABLED #endif #if !defined(HAL_SD_MODULE_DISABLED) - #define HAL_SD_MODULE_ENABLED + #define HAL_SD_MODULE_ENABLED #endif // Last Flash sector used for EEPROM emulation, address/sector depends on single/dual bank configuration. @@ -248,27 +248,27 @@ ----------------------------------------------------------------------------*/ #ifdef __cplusplus - // These serial port names are intended to allow libraries and architecture-neutral - // sketches to automatically default to the correct port name for a particular type - // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, - // the first hardware serial port whose RX/TX pins are not dedicated to another use. - // - // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor - // - // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial - // - // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library - // - // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. - // - // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX - // pins are NOT connected to anything by default. - #ifndef SERIAL_PORT_MONITOR - #define SERIAL_PORT_MONITOR Serial - #endif - #ifndef SERIAL_PORT_HARDWARE - // KH mod to add Serial1, for ESP-AT - //#define SERIAL_PORT_HARDWARE Serial - #define SERIAL_PORT_HARDWARE Serial1 - #endif + // These serial port names are intended to allow libraries and architecture-neutral + // sketches to automatically default to the correct port name for a particular type + // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, + // the first hardware serial port whose RX/TX pins are not dedicated to another use. + // + // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor + // + // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial + // + // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library + // + // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. + // + // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX + // pins are NOT connected to anything by default. + #ifndef SERIAL_PORT_MONITOR + #define SERIAL_PORT_MONITOR Serial + #endif + #ifndef SERIAL_PORT_HARDWARE + // KH mod to add Serial1, for ESP-AT + //#define SERIAL_PORT_HARDWARE Serial + #define SERIAL_PORT_HARDWARE Serial1 + #endif #endif diff --git a/Packages_Patches/STM32/hardware/stm32/2.0.0/variants/STM32L0xx/L052R(6-8)T_L053R(6-8)T_L063R8T/variant_generic.h b/Packages_Patches/STM32/hardware/stm32/2.0.0/variants/STM32L0xx/L052R(6-8)T_L053R(6-8)T_L063R8T/variant_generic.h index edb4fab7..b1f98ab3 100644 --- a/Packages_Patches/STM32/hardware/stm32/2.0.0/variants/STM32L0xx/L052R(6-8)T_L053R(6-8)T_L063R8T/variant_generic.h +++ b/Packages_Patches/STM32/hardware/stm32/2.0.0/variants/STM32L0xx/L052R(6-8)T_L053R(6-8)T_L063R8T/variant_generic.h @@ -75,71 +75,71 @@ // On-board LED pin number #ifndef LED_BUILTIN - #define LED_BUILTIN PNUM_NOT_DEFINED + #define LED_BUILTIN PNUM_NOT_DEFINED #endif // On-board user button #ifndef USER_BTN - #define USER_BTN PNUM_NOT_DEFINED + #define USER_BTN PNUM_NOT_DEFINED #endif // SPI definitions #ifndef PIN_SPI_SS - #define PIN_SPI_SS PA4 + #define PIN_SPI_SS PA4 #endif #ifndef PIN_SPI_SS1 - #define PIN_SPI_SS1 PA15 + #define PIN_SPI_SS1 PA15 #endif #ifndef PIN_SPI_SS2 - #define PIN_SPI_SS2 PNUM_NOT_DEFINED + #define PIN_SPI_SS2 PNUM_NOT_DEFINED #endif #ifndef PIN_SPI_SS3 - #define PIN_SPI_SS3 PNUM_NOT_DEFINED + #define PIN_SPI_SS3 PNUM_NOT_DEFINED #endif #ifndef PIN_SPI_MOSI - #define PIN_SPI_MOSI PA7 + #define PIN_SPI_MOSI PA7 #endif #ifndef PIN_SPI_MISO - #define PIN_SPI_MISO PA6 + #define PIN_SPI_MISO PA6 #endif #ifndef PIN_SPI_SCK - #define PIN_SPI_SCK PA5 + #define PIN_SPI_SCK PA5 #endif // I2C definitions #ifndef PIN_WIRE_SDA - #define PIN_WIRE_SDA PB7 + #define PIN_WIRE_SDA PB7 #endif #ifndef PIN_WIRE_SCL - #define PIN_WIRE_SCL PB6 + #define PIN_WIRE_SCL PB6 #endif // Timer Definitions // Use TIM6/TIM7 when possible as servo and tone don't need GPIO output pin #ifndef TIMER_TONE - #define TIMER_TONE TIM6 + #define TIMER_TONE TIM6 #endif #ifndef TIMER_SERVO - #define TIMER_SERVO TIM21 + #define TIMER_SERVO TIM21 #endif // UART Definitions #ifndef SERIAL_UART_INSTANCE - #define SERIAL_UART_INSTANCE 2 + #define SERIAL_UART_INSTANCE 2 #endif // Default pin used for generic 'Serial' instance // Mandatory for Firmata #ifndef PIN_SERIAL_RX - #define PIN_SERIAL_RX PA3 + #define PIN_SERIAL_RX PA3 #endif #ifndef PIN_SERIAL_TX - #define PIN_SERIAL_TX PA2 + #define PIN_SERIAL_TX PA2 #endif // Extra HAL modules #if !defined(HAL_DAC_MODULE_DISABLED) - #define HAL_DAC_MODULE_ENABLED + #define HAL_DAC_MODULE_ENABLED #endif /*---------------------------------------------------------------------------- @@ -147,27 +147,27 @@ ----------------------------------------------------------------------------*/ #ifdef __cplusplus - // These serial port names are intended to allow libraries and architecture-neutral - // sketches to automatically default to the correct port name for a particular type - // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, - // the first hardware serial port whose RX/TX pins are not dedicated to another use. - // - // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor - // - // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial - // - // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library - // - // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. - // - // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX - // pins are NOT connected to anything by default. - #ifndef SERIAL_PORT_MONITOR - #define SERIAL_PORT_MONITOR Serial - #endif - #ifndef SERIAL_PORT_HARDWARE - // KH mod to add Serial1, for ESP-AT - //#define SERIAL_PORT_HARDWARE Serial - #define SERIAL_PORT_HARDWARE Serial1 - #endif + // These serial port names are intended to allow libraries and architecture-neutral + // sketches to automatically default to the correct port name for a particular type + // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, + // the first hardware serial port whose RX/TX pins are not dedicated to another use. + // + // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor + // + // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial + // + // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library + // + // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. + // + // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX + // pins are NOT connected to anything by default. + #ifndef SERIAL_PORT_MONITOR + #define SERIAL_PORT_MONITOR Serial + #endif + #ifndef SERIAL_PORT_HARDWARE + // KH mod to add Serial1, for ESP-AT + //#define SERIAL_PORT_HARDWARE Serial + #define SERIAL_PORT_HARDWARE Serial1 + #endif #endif diff --git a/Packages_Patches/STM32/hardware/stm32/2.1.0/variants/STM32F7xx/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h b/Packages_Patches/STM32/hardware/stm32/2.1.0/variants/STM32F7xx/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h index 8d7b8a86..fe1dcf86 100644 --- a/Packages_Patches/STM32/hardware/stm32/2.1.0/variants/STM32F7xx/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h +++ b/Packages_Patches/STM32/hardware/stm32/2.1.0/variants/STM32F7xx/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h @@ -188,7 +188,7 @@ // On-board LED pin number #ifndef LED_BUILTIN - #define LED_BUILTIN PB0 + #define LED_BUILTIN PB0 #endif #define LED_GREEN LED_BUILTIN #define LED_BLUE PB7 @@ -196,29 +196,29 @@ // On-board user button #ifndef USER_BTN - #define USER_BTN PC13 + #define USER_BTN PC13 #endif // Timer Definitions // Use TIM6/TIM7 when possible as servo and tone don't need GPIO output pin #ifndef TIMER_TONE - #define TIMER_TONE TIM6 + #define TIMER_TONE TIM6 #endif #ifndef TIMER_SERVO - #define TIMER_SERVO TIM7 + #define TIMER_SERVO TIM7 #endif // UART Definitions #ifndef SERIAL_UART_INSTANCE - #define SERIAL_UART_INSTANCE 3 //Connected to ST-Link + #define SERIAL_UART_INSTANCE 3 //Connected to ST-Link #endif // Serial pin used for console (ex: stlink) // Rerquired by Firmata #ifndef PIN_SERIAL_RX - #define PIN_SERIAL_RX PD9 + #define PIN_SERIAL_RX PD9 #endif #ifndef PIN_SERIAL_TX - #define PIN_SERIAL_TX PD8 + #define PIN_SERIAL_TX PD8 #endif // Value of the External oscillator in Hz @@ -226,16 +226,16 @@ /* Extra HAL modules */ #if !defined(HAL_DAC_MODULE_DISABLED) - #define HAL_DAC_MODULE_ENABLED + #define HAL_DAC_MODULE_ENABLED #endif #if !defined(HAL_ETH_MODULE_DISABLED) - #define HAL_ETH_MODULE_ENABLED + #define HAL_ETH_MODULE_ENABLED #endif #if !defined(HAL_QSPI_MODULE_DISABLED) - #define HAL_QSPI_MODULE_ENABLED + #define HAL_QSPI_MODULE_ENABLED #endif #if !defined(HAL_SD_MODULE_DISABLED) - #define HAL_SD_MODULE_ENABLED + #define HAL_SD_MODULE_ENABLED #endif // Last Flash sector used for EEPROM emulation, address/sector depends on single/dual bank configuration. @@ -248,27 +248,27 @@ ----------------------------------------------------------------------------*/ #ifdef __cplusplus - // These serial port names are intended to allow libraries and architecture-neutral - // sketches to automatically default to the correct port name for a particular type - // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, - // the first hardware serial port whose RX/TX pins are not dedicated to another use. - // - // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor - // - // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial - // - // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library - // - // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. - // - // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX - // pins are NOT connected to anything by default. - #ifndef SERIAL_PORT_MONITOR - #define SERIAL_PORT_MONITOR Serial - #endif - #ifndef SERIAL_PORT_HARDWARE - // KH mod to add Serial1, for ESP-AT - //#define SERIAL_PORT_HARDWARE Serial - #define SERIAL_PORT_HARDWARE Serial1 - #endif + // These serial port names are intended to allow libraries and architecture-neutral + // sketches to automatically default to the correct port name for a particular type + // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, + // the first hardware serial port whose RX/TX pins are not dedicated to another use. + // + // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor + // + // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial + // + // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library + // + // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. + // + // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX + // pins are NOT connected to anything by default. + #ifndef SERIAL_PORT_MONITOR + #define SERIAL_PORT_MONITOR Serial + #endif + #ifndef SERIAL_PORT_HARDWARE + // KH mod to add Serial1, for ESP-AT + //#define SERIAL_PORT_HARDWARE Serial + #define SERIAL_PORT_HARDWARE Serial1 + #endif #endif diff --git a/Packages_Patches/STM32/hardware/stm32/2.1.0/variants/STM32L0xx/L052R(6-8)T_L053R(6-8)T_L063R8T/variant_generic.h b/Packages_Patches/STM32/hardware/stm32/2.1.0/variants/STM32L0xx/L052R(6-8)T_L053R(6-8)T_L063R8T/variant_generic.h index edb4fab7..b1f98ab3 100644 --- a/Packages_Patches/STM32/hardware/stm32/2.1.0/variants/STM32L0xx/L052R(6-8)T_L053R(6-8)T_L063R8T/variant_generic.h +++ b/Packages_Patches/STM32/hardware/stm32/2.1.0/variants/STM32L0xx/L052R(6-8)T_L053R(6-8)T_L063R8T/variant_generic.h @@ -75,71 +75,71 @@ // On-board LED pin number #ifndef LED_BUILTIN - #define LED_BUILTIN PNUM_NOT_DEFINED + #define LED_BUILTIN PNUM_NOT_DEFINED #endif // On-board user button #ifndef USER_BTN - #define USER_BTN PNUM_NOT_DEFINED + #define USER_BTN PNUM_NOT_DEFINED #endif // SPI definitions #ifndef PIN_SPI_SS - #define PIN_SPI_SS PA4 + #define PIN_SPI_SS PA4 #endif #ifndef PIN_SPI_SS1 - #define PIN_SPI_SS1 PA15 + #define PIN_SPI_SS1 PA15 #endif #ifndef PIN_SPI_SS2 - #define PIN_SPI_SS2 PNUM_NOT_DEFINED + #define PIN_SPI_SS2 PNUM_NOT_DEFINED #endif #ifndef PIN_SPI_SS3 - #define PIN_SPI_SS3 PNUM_NOT_DEFINED + #define PIN_SPI_SS3 PNUM_NOT_DEFINED #endif #ifndef PIN_SPI_MOSI - #define PIN_SPI_MOSI PA7 + #define PIN_SPI_MOSI PA7 #endif #ifndef PIN_SPI_MISO - #define PIN_SPI_MISO PA6 + #define PIN_SPI_MISO PA6 #endif #ifndef PIN_SPI_SCK - #define PIN_SPI_SCK PA5 + #define PIN_SPI_SCK PA5 #endif // I2C definitions #ifndef PIN_WIRE_SDA - #define PIN_WIRE_SDA PB7 + #define PIN_WIRE_SDA PB7 #endif #ifndef PIN_WIRE_SCL - #define PIN_WIRE_SCL PB6 + #define PIN_WIRE_SCL PB6 #endif // Timer Definitions // Use TIM6/TIM7 when possible as servo and tone don't need GPIO output pin #ifndef TIMER_TONE - #define TIMER_TONE TIM6 + #define TIMER_TONE TIM6 #endif #ifndef TIMER_SERVO - #define TIMER_SERVO TIM21 + #define TIMER_SERVO TIM21 #endif // UART Definitions #ifndef SERIAL_UART_INSTANCE - #define SERIAL_UART_INSTANCE 2 + #define SERIAL_UART_INSTANCE 2 #endif // Default pin used for generic 'Serial' instance // Mandatory for Firmata #ifndef PIN_SERIAL_RX - #define PIN_SERIAL_RX PA3 + #define PIN_SERIAL_RX PA3 #endif #ifndef PIN_SERIAL_TX - #define PIN_SERIAL_TX PA2 + #define PIN_SERIAL_TX PA2 #endif // Extra HAL modules #if !defined(HAL_DAC_MODULE_DISABLED) - #define HAL_DAC_MODULE_ENABLED + #define HAL_DAC_MODULE_ENABLED #endif /*---------------------------------------------------------------------------- @@ -147,27 +147,27 @@ ----------------------------------------------------------------------------*/ #ifdef __cplusplus - // These serial port names are intended to allow libraries and architecture-neutral - // sketches to automatically default to the correct port name for a particular type - // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, - // the first hardware serial port whose RX/TX pins are not dedicated to another use. - // - // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor - // - // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial - // - // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library - // - // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. - // - // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX - // pins are NOT connected to anything by default. - #ifndef SERIAL_PORT_MONITOR - #define SERIAL_PORT_MONITOR Serial - #endif - #ifndef SERIAL_PORT_HARDWARE - // KH mod to add Serial1, for ESP-AT - //#define SERIAL_PORT_HARDWARE Serial - #define SERIAL_PORT_HARDWARE Serial1 - #endif + // These serial port names are intended to allow libraries and architecture-neutral + // sketches to automatically default to the correct port name for a particular type + // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, + // the first hardware serial port whose RX/TX pins are not dedicated to another use. + // + // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor + // + // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial + // + // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library + // + // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. + // + // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX + // pins are NOT connected to anything by default. + #ifndef SERIAL_PORT_MONITOR + #define SERIAL_PORT_MONITOR Serial + #endif + #ifndef SERIAL_PORT_HARDWARE + // KH mod to add Serial1, for ESP-AT + //#define SERIAL_PORT_HARDWARE Serial + #define SERIAL_PORT_HARDWARE Serial1 + #endif #endif diff --git a/Packages_Patches/STM32/hardware/stm32/2.2.0/variants/STM32F7xx/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h b/Packages_Patches/STM32/hardware/stm32/2.2.0/variants/STM32F7xx/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h index 8d7b8a86..fe1dcf86 100644 --- a/Packages_Patches/STM32/hardware/stm32/2.2.0/variants/STM32F7xx/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h +++ b/Packages_Patches/STM32/hardware/stm32/2.2.0/variants/STM32F7xx/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h @@ -188,7 +188,7 @@ // On-board LED pin number #ifndef LED_BUILTIN - #define LED_BUILTIN PB0 + #define LED_BUILTIN PB0 #endif #define LED_GREEN LED_BUILTIN #define LED_BLUE PB7 @@ -196,29 +196,29 @@ // On-board user button #ifndef USER_BTN - #define USER_BTN PC13 + #define USER_BTN PC13 #endif // Timer Definitions // Use TIM6/TIM7 when possible as servo and tone don't need GPIO output pin #ifndef TIMER_TONE - #define TIMER_TONE TIM6 + #define TIMER_TONE TIM6 #endif #ifndef TIMER_SERVO - #define TIMER_SERVO TIM7 + #define TIMER_SERVO TIM7 #endif // UART Definitions #ifndef SERIAL_UART_INSTANCE - #define SERIAL_UART_INSTANCE 3 //Connected to ST-Link + #define SERIAL_UART_INSTANCE 3 //Connected to ST-Link #endif // Serial pin used for console (ex: stlink) // Rerquired by Firmata #ifndef PIN_SERIAL_RX - #define PIN_SERIAL_RX PD9 + #define PIN_SERIAL_RX PD9 #endif #ifndef PIN_SERIAL_TX - #define PIN_SERIAL_TX PD8 + #define PIN_SERIAL_TX PD8 #endif // Value of the External oscillator in Hz @@ -226,16 +226,16 @@ /* Extra HAL modules */ #if !defined(HAL_DAC_MODULE_DISABLED) - #define HAL_DAC_MODULE_ENABLED + #define HAL_DAC_MODULE_ENABLED #endif #if !defined(HAL_ETH_MODULE_DISABLED) - #define HAL_ETH_MODULE_ENABLED + #define HAL_ETH_MODULE_ENABLED #endif #if !defined(HAL_QSPI_MODULE_DISABLED) - #define HAL_QSPI_MODULE_ENABLED + #define HAL_QSPI_MODULE_ENABLED #endif #if !defined(HAL_SD_MODULE_DISABLED) - #define HAL_SD_MODULE_ENABLED + #define HAL_SD_MODULE_ENABLED #endif // Last Flash sector used for EEPROM emulation, address/sector depends on single/dual bank configuration. @@ -248,27 +248,27 @@ ----------------------------------------------------------------------------*/ #ifdef __cplusplus - // These serial port names are intended to allow libraries and architecture-neutral - // sketches to automatically default to the correct port name for a particular type - // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, - // the first hardware serial port whose RX/TX pins are not dedicated to another use. - // - // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor - // - // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial - // - // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library - // - // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. - // - // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX - // pins are NOT connected to anything by default. - #ifndef SERIAL_PORT_MONITOR - #define SERIAL_PORT_MONITOR Serial - #endif - #ifndef SERIAL_PORT_HARDWARE - // KH mod to add Serial1, for ESP-AT - //#define SERIAL_PORT_HARDWARE Serial - #define SERIAL_PORT_HARDWARE Serial1 - #endif + // These serial port names are intended to allow libraries and architecture-neutral + // sketches to automatically default to the correct port name for a particular type + // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, + // the first hardware serial port whose RX/TX pins are not dedicated to another use. + // + // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor + // + // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial + // + // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library + // + // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. + // + // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX + // pins are NOT connected to anything by default. + #ifndef SERIAL_PORT_MONITOR + #define SERIAL_PORT_MONITOR Serial + #endif + #ifndef SERIAL_PORT_HARDWARE + // KH mod to add Serial1, for ESP-AT + //#define SERIAL_PORT_HARDWARE Serial + #define SERIAL_PORT_HARDWARE Serial1 + #endif #endif diff --git a/Packages_Patches/STM32/hardware/stm32/2.2.0/variants/STM32L0xx/L052R(6-8)T_L053R(6-8)T_L063R8T/variant_generic.h b/Packages_Patches/STM32/hardware/stm32/2.2.0/variants/STM32L0xx/L052R(6-8)T_L053R(6-8)T_L063R8T/variant_generic.h index edb4fab7..b1f98ab3 100644 --- a/Packages_Patches/STM32/hardware/stm32/2.2.0/variants/STM32L0xx/L052R(6-8)T_L053R(6-8)T_L063R8T/variant_generic.h +++ b/Packages_Patches/STM32/hardware/stm32/2.2.0/variants/STM32L0xx/L052R(6-8)T_L053R(6-8)T_L063R8T/variant_generic.h @@ -75,71 +75,71 @@ // On-board LED pin number #ifndef LED_BUILTIN - #define LED_BUILTIN PNUM_NOT_DEFINED + #define LED_BUILTIN PNUM_NOT_DEFINED #endif // On-board user button #ifndef USER_BTN - #define USER_BTN PNUM_NOT_DEFINED + #define USER_BTN PNUM_NOT_DEFINED #endif // SPI definitions #ifndef PIN_SPI_SS - #define PIN_SPI_SS PA4 + #define PIN_SPI_SS PA4 #endif #ifndef PIN_SPI_SS1 - #define PIN_SPI_SS1 PA15 + #define PIN_SPI_SS1 PA15 #endif #ifndef PIN_SPI_SS2 - #define PIN_SPI_SS2 PNUM_NOT_DEFINED + #define PIN_SPI_SS2 PNUM_NOT_DEFINED #endif #ifndef PIN_SPI_SS3 - #define PIN_SPI_SS3 PNUM_NOT_DEFINED + #define PIN_SPI_SS3 PNUM_NOT_DEFINED #endif #ifndef PIN_SPI_MOSI - #define PIN_SPI_MOSI PA7 + #define PIN_SPI_MOSI PA7 #endif #ifndef PIN_SPI_MISO - #define PIN_SPI_MISO PA6 + #define PIN_SPI_MISO PA6 #endif #ifndef PIN_SPI_SCK - #define PIN_SPI_SCK PA5 + #define PIN_SPI_SCK PA5 #endif // I2C definitions #ifndef PIN_WIRE_SDA - #define PIN_WIRE_SDA PB7 + #define PIN_WIRE_SDA PB7 #endif #ifndef PIN_WIRE_SCL - #define PIN_WIRE_SCL PB6 + #define PIN_WIRE_SCL PB6 #endif // Timer Definitions // Use TIM6/TIM7 when possible as servo and tone don't need GPIO output pin #ifndef TIMER_TONE - #define TIMER_TONE TIM6 + #define TIMER_TONE TIM6 #endif #ifndef TIMER_SERVO - #define TIMER_SERVO TIM21 + #define TIMER_SERVO TIM21 #endif // UART Definitions #ifndef SERIAL_UART_INSTANCE - #define SERIAL_UART_INSTANCE 2 + #define SERIAL_UART_INSTANCE 2 #endif // Default pin used for generic 'Serial' instance // Mandatory for Firmata #ifndef PIN_SERIAL_RX - #define PIN_SERIAL_RX PA3 + #define PIN_SERIAL_RX PA3 #endif #ifndef PIN_SERIAL_TX - #define PIN_SERIAL_TX PA2 + #define PIN_SERIAL_TX PA2 #endif // Extra HAL modules #if !defined(HAL_DAC_MODULE_DISABLED) - #define HAL_DAC_MODULE_ENABLED + #define HAL_DAC_MODULE_ENABLED #endif /*---------------------------------------------------------------------------- @@ -147,27 +147,27 @@ ----------------------------------------------------------------------------*/ #ifdef __cplusplus - // These serial port names are intended to allow libraries and architecture-neutral - // sketches to automatically default to the correct port name for a particular type - // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, - // the first hardware serial port whose RX/TX pins are not dedicated to another use. - // - // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor - // - // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial - // - // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library - // - // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. - // - // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX - // pins are NOT connected to anything by default. - #ifndef SERIAL_PORT_MONITOR - #define SERIAL_PORT_MONITOR Serial - #endif - #ifndef SERIAL_PORT_HARDWARE - // KH mod to add Serial1, for ESP-AT - //#define SERIAL_PORT_HARDWARE Serial - #define SERIAL_PORT_HARDWARE Serial1 - #endif + // These serial port names are intended to allow libraries and architecture-neutral + // sketches to automatically default to the correct port name for a particular type + // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, + // the first hardware serial port whose RX/TX pins are not dedicated to another use. + // + // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor + // + // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial + // + // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library + // + // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. + // + // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX + // pins are NOT connected to anything by default. + #ifndef SERIAL_PORT_MONITOR + #define SERIAL_PORT_MONITOR Serial + #endif + #ifndef SERIAL_PORT_HARDWARE + // KH mod to add Serial1, for ESP-AT + //#define SERIAL_PORT_HARDWARE Serial + #define SERIAL_PORT_HARDWARE Serial1 + #endif #endif diff --git a/Packages_Patches/STM32/hardware/stm32/2.3.0/variants/STM32F7xx/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h b/Packages_Patches/STM32/hardware/stm32/2.3.0/variants/STM32F7xx/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h index 8d7b8a86..fe1dcf86 100644 --- a/Packages_Patches/STM32/hardware/stm32/2.3.0/variants/STM32F7xx/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h +++ b/Packages_Patches/STM32/hardware/stm32/2.3.0/variants/STM32F7xx/F765Z(G-I)T_F767Z(G-I)T_F777ZIT/variant_NUCLEO_F767ZI.h @@ -188,7 +188,7 @@ // On-board LED pin number #ifndef LED_BUILTIN - #define LED_BUILTIN PB0 + #define LED_BUILTIN PB0 #endif #define LED_GREEN LED_BUILTIN #define LED_BLUE PB7 @@ -196,29 +196,29 @@ // On-board user button #ifndef USER_BTN - #define USER_BTN PC13 + #define USER_BTN PC13 #endif // Timer Definitions // Use TIM6/TIM7 when possible as servo and tone don't need GPIO output pin #ifndef TIMER_TONE - #define TIMER_TONE TIM6 + #define TIMER_TONE TIM6 #endif #ifndef TIMER_SERVO - #define TIMER_SERVO TIM7 + #define TIMER_SERVO TIM7 #endif // UART Definitions #ifndef SERIAL_UART_INSTANCE - #define SERIAL_UART_INSTANCE 3 //Connected to ST-Link + #define SERIAL_UART_INSTANCE 3 //Connected to ST-Link #endif // Serial pin used for console (ex: stlink) // Rerquired by Firmata #ifndef PIN_SERIAL_RX - #define PIN_SERIAL_RX PD9 + #define PIN_SERIAL_RX PD9 #endif #ifndef PIN_SERIAL_TX - #define PIN_SERIAL_TX PD8 + #define PIN_SERIAL_TX PD8 #endif // Value of the External oscillator in Hz @@ -226,16 +226,16 @@ /* Extra HAL modules */ #if !defined(HAL_DAC_MODULE_DISABLED) - #define HAL_DAC_MODULE_ENABLED + #define HAL_DAC_MODULE_ENABLED #endif #if !defined(HAL_ETH_MODULE_DISABLED) - #define HAL_ETH_MODULE_ENABLED + #define HAL_ETH_MODULE_ENABLED #endif #if !defined(HAL_QSPI_MODULE_DISABLED) - #define HAL_QSPI_MODULE_ENABLED + #define HAL_QSPI_MODULE_ENABLED #endif #if !defined(HAL_SD_MODULE_DISABLED) - #define HAL_SD_MODULE_ENABLED + #define HAL_SD_MODULE_ENABLED #endif // Last Flash sector used for EEPROM emulation, address/sector depends on single/dual bank configuration. @@ -248,27 +248,27 @@ ----------------------------------------------------------------------------*/ #ifdef __cplusplus - // These serial port names are intended to allow libraries and architecture-neutral - // sketches to automatically default to the correct port name for a particular type - // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, - // the first hardware serial port whose RX/TX pins are not dedicated to another use. - // - // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor - // - // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial - // - // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library - // - // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. - // - // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX - // pins are NOT connected to anything by default. - #ifndef SERIAL_PORT_MONITOR - #define SERIAL_PORT_MONITOR Serial - #endif - #ifndef SERIAL_PORT_HARDWARE - // KH mod to add Serial1, for ESP-AT - //#define SERIAL_PORT_HARDWARE Serial - #define SERIAL_PORT_HARDWARE Serial1 - #endif + // These serial port names are intended to allow libraries and architecture-neutral + // sketches to automatically default to the correct port name for a particular type + // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, + // the first hardware serial port whose RX/TX pins are not dedicated to another use. + // + // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor + // + // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial + // + // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library + // + // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. + // + // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX + // pins are NOT connected to anything by default. + #ifndef SERIAL_PORT_MONITOR + #define SERIAL_PORT_MONITOR Serial + #endif + #ifndef SERIAL_PORT_HARDWARE + // KH mod to add Serial1, for ESP-AT + //#define SERIAL_PORT_HARDWARE Serial + #define SERIAL_PORT_HARDWARE Serial1 + #endif #endif diff --git a/Packages_Patches/STM32/hardware/stm32/2.3.0/variants/STM32L0xx/L052R(6-8)T_L053R(6-8)T_L063R8T/variant_generic.h b/Packages_Patches/STM32/hardware/stm32/2.3.0/variants/STM32L0xx/L052R(6-8)T_L053R(6-8)T_L063R8T/variant_generic.h index edb4fab7..b1f98ab3 100644 --- a/Packages_Patches/STM32/hardware/stm32/2.3.0/variants/STM32L0xx/L052R(6-8)T_L053R(6-8)T_L063R8T/variant_generic.h +++ b/Packages_Patches/STM32/hardware/stm32/2.3.0/variants/STM32L0xx/L052R(6-8)T_L053R(6-8)T_L063R8T/variant_generic.h @@ -75,71 +75,71 @@ // On-board LED pin number #ifndef LED_BUILTIN - #define LED_BUILTIN PNUM_NOT_DEFINED + #define LED_BUILTIN PNUM_NOT_DEFINED #endif // On-board user button #ifndef USER_BTN - #define USER_BTN PNUM_NOT_DEFINED + #define USER_BTN PNUM_NOT_DEFINED #endif // SPI definitions #ifndef PIN_SPI_SS - #define PIN_SPI_SS PA4 + #define PIN_SPI_SS PA4 #endif #ifndef PIN_SPI_SS1 - #define PIN_SPI_SS1 PA15 + #define PIN_SPI_SS1 PA15 #endif #ifndef PIN_SPI_SS2 - #define PIN_SPI_SS2 PNUM_NOT_DEFINED + #define PIN_SPI_SS2 PNUM_NOT_DEFINED #endif #ifndef PIN_SPI_SS3 - #define PIN_SPI_SS3 PNUM_NOT_DEFINED + #define PIN_SPI_SS3 PNUM_NOT_DEFINED #endif #ifndef PIN_SPI_MOSI - #define PIN_SPI_MOSI PA7 + #define PIN_SPI_MOSI PA7 #endif #ifndef PIN_SPI_MISO - #define PIN_SPI_MISO PA6 + #define PIN_SPI_MISO PA6 #endif #ifndef PIN_SPI_SCK - #define PIN_SPI_SCK PA5 + #define PIN_SPI_SCK PA5 #endif // I2C definitions #ifndef PIN_WIRE_SDA - #define PIN_WIRE_SDA PB7 + #define PIN_WIRE_SDA PB7 #endif #ifndef PIN_WIRE_SCL - #define PIN_WIRE_SCL PB6 + #define PIN_WIRE_SCL PB6 #endif // Timer Definitions // Use TIM6/TIM7 when possible as servo and tone don't need GPIO output pin #ifndef TIMER_TONE - #define TIMER_TONE TIM6 + #define TIMER_TONE TIM6 #endif #ifndef TIMER_SERVO - #define TIMER_SERVO TIM21 + #define TIMER_SERVO TIM21 #endif // UART Definitions #ifndef SERIAL_UART_INSTANCE - #define SERIAL_UART_INSTANCE 2 + #define SERIAL_UART_INSTANCE 2 #endif // Default pin used for generic 'Serial' instance // Mandatory for Firmata #ifndef PIN_SERIAL_RX - #define PIN_SERIAL_RX PA3 + #define PIN_SERIAL_RX PA3 #endif #ifndef PIN_SERIAL_TX - #define PIN_SERIAL_TX PA2 + #define PIN_SERIAL_TX PA2 #endif // Extra HAL modules #if !defined(HAL_DAC_MODULE_DISABLED) - #define HAL_DAC_MODULE_ENABLED + #define HAL_DAC_MODULE_ENABLED #endif /*---------------------------------------------------------------------------- @@ -147,27 +147,27 @@ ----------------------------------------------------------------------------*/ #ifdef __cplusplus - // These serial port names are intended to allow libraries and architecture-neutral - // sketches to automatically default to the correct port name for a particular type - // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, - // the first hardware serial port whose RX/TX pins are not dedicated to another use. - // - // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor - // - // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial - // - // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library - // - // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. - // - // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX - // pins are NOT connected to anything by default. - #ifndef SERIAL_PORT_MONITOR - #define SERIAL_PORT_MONITOR Serial - #endif - #ifndef SERIAL_PORT_HARDWARE - // KH mod to add Serial1, for ESP-AT - //#define SERIAL_PORT_HARDWARE Serial - #define SERIAL_PORT_HARDWARE Serial1 - #endif + // These serial port names are intended to allow libraries and architecture-neutral + // sketches to automatically default to the correct port name for a particular type + // of use. For example, a GPS module would normally connect to SERIAL_PORT_HARDWARE_OPEN, + // the first hardware serial port whose RX/TX pins are not dedicated to another use. + // + // SERIAL_PORT_MONITOR Port which normally prints to the Arduino Serial Monitor + // + // SERIAL_PORT_USBVIRTUAL Port which is USB virtual serial + // + // SERIAL_PORT_LINUXBRIDGE Port which connects to a Linux system via Bridge library + // + // SERIAL_PORT_HARDWARE Hardware serial port, physical RX & TX pins. + // + // SERIAL_PORT_HARDWARE_OPEN Hardware serial ports which are open for use. Their RX & TX + // pins are NOT connected to anything by default. + #ifndef SERIAL_PORT_MONITOR + #define SERIAL_PORT_MONITOR Serial + #endif + #ifndef SERIAL_PORT_HARDWARE + // KH mod to add Serial1, for ESP-AT + //#define SERIAL_PORT_HARDWARE Serial + #define SERIAL_PORT_HARDWARE Serial1 + #endif #endif diff --git a/Packages_Patches/Seeeduino/hardware/nrf52/1.0.0/cores/nRF5/Print.cpp b/Packages_Patches/Seeeduino/hardware/nrf52/1.0.0/cores/nRF5/Print.cpp index b47efa1a..d2db9576 100644 --- a/Packages_Patches/Seeeduino/hardware/nrf52/1.0.0/cores/nRF5/Print.cpp +++ b/Packages_Patches/Seeeduino/hardware/nrf52/1.0.0/cores/nRF5/Print.cpp @@ -35,259 +35,259 @@ /* default implementation: may be overridden */ size_t Print::write(const uint8_t *buffer, size_t size) { - size_t n = 0; + size_t n = 0; - while (size--) - { - if (write(*buffer++)) - n++; - else - break; - } + while (size--) + { + if (write(*buffer++)) + n++; + else + break; + } - return n; + return n; } size_t Print::print(const __FlashStringHelper *ifsh) { - return print(reinterpret_cast(ifsh)); + return print(reinterpret_cast(ifsh)); } size_t Print::print(const String &s) { - return write(s.c_str(), s.length()); + return write(s.c_str(), s.length()); } size_t Print::print(const char str[]) { - return write(str); + return write(str); } size_t Print::print(char c) { - return write(c); + return write(c); } size_t Print::print(unsigned char b, int base) { - return print((unsigned long) b, base); + return print((unsigned long) b, base); } size_t Print::print(int n, int base) { - return print((long) n, base); + return print((long) n, base); } size_t Print::print(unsigned int n, int base) { - return print((unsigned long) n, base); + return print((unsigned long) n, base); } size_t Print::print(long n, int base) { - if (base == 0) - { - return write(n); - } - else if (base == 10) - { - if (n < 0) - { - int t = print('-'); - n = -n; - return printNumber(n, 10) + t; - } - - return printNumber(n, 10); - } - else - { - return printNumber(n, base); - } + if (base == 0) + { + return write(n); + } + else if (base == 10) + { + if (n < 0) + { + int t = print('-'); + n = -n; + return printNumber(n, 10) + t; + } + + return printNumber(n, 10); + } + else + { + return printNumber(n, base); + } } size_t Print::print(unsigned long n, int base) { - if (base == 0) - return write(n); - else - return printNumber(n, base); + if (base == 0) + return write(n); + else + return printNumber(n, base); } size_t Print::print(long long n, int base) { - if (base == 0) - { - return write(n); - } - else if (base == 10) - { - if (n < 0) - { - int t = print('-'); - n = -n; - return printULLNumber(n, 10) + t; - } - - return printULLNumber(n, 10); - } - else - { - return printULLNumber(n, base); - } + if (base == 0) + { + return write(n); + } + else if (base == 10) + { + if (n < 0) + { + int t = print('-'); + n = -n; + return printULLNumber(n, 10) + t; + } + + return printULLNumber(n, 10); + } + else + { + return printULLNumber(n, base); + } } size_t Print::print(unsigned long long n, int base) { - if (base == 0) - return write(n); - else - return printULLNumber(n, base); + if (base == 0) + return write(n); + else + return printULLNumber(n, base); } size_t Print::print(double n, int digits) { - return printFloat(n, digits); + return printFloat(n, digits); } size_t Print::println(const __FlashStringHelper *ifsh) { - size_t n = print(ifsh); - n += println(); - return n; + size_t n = print(ifsh); + n += println(); + return n; } size_t Print::print(const Printable& x) { - return x.printTo(*this); + return x.printTo(*this); } size_t Print::println(void) { - return write("\r\n"); + return write("\r\n"); } size_t Print::println(const String &s) { - size_t n = print(s); - n += println(); - return n; + size_t n = print(s); + n += println(); + return n; } size_t Print::println(const char c[]) { - size_t n = print(c); - n += println(); - return n; + size_t n = print(c); + n += println(); + return n; } size_t Print::println(char c) { - size_t n = print(c); - n += println(); - return n; + size_t n = print(c); + n += println(); + return n; } size_t Print::println(unsigned char b, int base) { - size_t n = print(b, base); - n += println(); - return n; + size_t n = print(b, base); + n += println(); + return n; } size_t Print::println(int num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned int num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(long long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned long long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(double num, int digits) { - size_t n = print(num, digits); - n += println(); - return n; + size_t n = print(num, digits); + n += println(); + return n; } size_t Print::println(const Printable& x) { - size_t n = print(x); - n += println(); - return n; + size_t n = print(x); + n += println(); + return n; } size_t Print::printf(const char * format, ...) { - char buf[256]; - int len; + char buf[256]; + int len; - va_list ap; - va_start(ap, format); + va_list ap; + va_start(ap, format); - len = vsnprintf(buf, 256, format, ap); - this->write(buf, len); + len = vsnprintf(buf, 256, format, ap); + this->write(buf, len); - va_end(ap); - return len; + va_end(ap); + return len; } // Private Methods ///////////////////////////////////////////////////////////// size_t Print::printNumber(unsigned long n, uint8_t base) { - char buf[8 * sizeof(long) + 1]; // Assumes 8-bit chars plus zero byte. - char *str = &buf[sizeof(buf) - 1]; + char buf[8 * sizeof(long) + 1]; // Assumes 8-bit chars plus zero byte. + char *str = &buf[sizeof(buf) - 1]; - *str = '\0'; + *str = '\0'; - // prevent crash if called with base == 1 - if (base < 2) - base = 10; + // prevent crash if called with base == 1 + if (base < 2) + base = 10; - do - { - char c = n % base; - n /= base; + do + { + char c = n % base; + n /= base; - *--str = c < 10 ? c + '0' : c + 'A' - 10; - } while (n); + *--str = c < 10 ? c + '0' : c + 'A' - 10; + } while (n); - return write(str); + return write(str); } // REFERENCE IMPLEMENTATION FOR ULL @@ -315,152 +315,152 @@ size_t Print::printNumber(unsigned long n, uint8_t base) // FAST IMPLEMENTATION FOR ULL size_t Print::printULLNumber(unsigned long long n64, uint8_t base) { - // if limited to base 10 and 16 the bufsize can be 20 - char buf[64]; - uint8_t i = 0; - uint8_t innerLoops = 0; + // if limited to base 10 and 16 the bufsize can be 20 + char buf[64]; + uint8_t i = 0; + uint8_t innerLoops = 0; - // prevent crash if called with base == 1 - if (base < 2) - base = 10; + // prevent crash if called with base == 1 + if (base < 2) + base = 10; - // process chunks that fit in "16 bit math". - uint16_t top = 0xFFFF / base; - uint16_t th16 = 1; + // process chunks that fit in "16 bit math". + uint16_t top = 0xFFFF / base; + uint16_t th16 = 1; - while (th16 < top) - { - th16 *= base; - innerLoops++; - } + while (th16 < top) + { + th16 *= base; + innerLoops++; + } - while (n64 > th16) - { - // 64 bit math part - uint64_t q = n64 / th16; - uint16_t r = n64 - q * th16; - n64 = q; + while (n64 > th16) + { + // 64 bit math part + uint64_t q = n64 / th16; + uint16_t r = n64 - q * th16; + n64 = q; - // 16 bit math loop to do remainder. (note buffer is filled reverse) - for (uint8_t j = 0; j < innerLoops; j++) - { - uint16_t qq = r / base; - buf[i++] = r - qq * base; - r = qq; - } - } + // 16 bit math loop to do remainder. (note buffer is filled reverse) + for (uint8_t j = 0; j < innerLoops; j++) + { + uint16_t qq = r / base; + buf[i++] = r - qq * base; + r = qq; + } + } - uint16_t n16 = n64; + uint16_t n16 = n64; - while (n16 > 0) - { - uint16_t qq = n16 / base; - buf[i++] = n16 - qq * base; - n16 = qq; - } + while (n16 > 0) + { + uint16_t qq = n16 / base; + buf[i++] = n16 - qq * base; + n16 = qq; + } - size_t bytes = i; + size_t bytes = i; - for (; i > 0; i--) - write((char) (buf[i - 1] < 10 ? - '0' + buf[i - 1] : - 'A' + buf[i - 1] - 10)); + for (; i > 0; i--) + write((char) (buf[i - 1] < 10 ? + '0' + buf[i - 1] : + 'A' + buf[i - 1] - 10)); - return bytes; + return bytes; } size_t Print::printFloat(double number, int digits) { - if (digits < 0) - digits = 2; + if (digits < 0) + digits = 2; - size_t n = 0; + size_t n = 0; - if (isnan(number)) - return print("nan"); + if (isnan(number)) + return print("nan"); - if (isinf(number)) - return print("inf"); + if (isinf(number)) + return print("inf"); - if (number > 4294967040.0) - return print ("ovf"); // constant determined empirically + if (number > 4294967040.0) + return print ("ovf"); // constant determined empirically - if (number < -4294967040.0) - return print ("ovf"); // constant determined empirically + if (number < -4294967040.0) + return print ("ovf"); // constant determined empirically - // Handle negative numbers - if (number < 0.0) - { - n += print('-'); - number = -number; - } + // Handle negative numbers + if (number < 0.0) + { + n += print('-'); + number = -number; + } - // Round correctly so that print(1.999, 2) prints as "2.00" - double rounding = 0.5; + // Round correctly so that print(1.999, 2) prints as "2.00" + double rounding = 0.5; - for (uint8_t i = 0; i < digits; ++i) - rounding /= 10.0; + for (uint8_t i = 0; i < digits; ++i) + rounding /= 10.0; - number += rounding; + number += rounding; - // Extract the integer part of the number and print it - unsigned long int_part = (unsigned long)number; - double remainder = number - (double)int_part; - n += print(int_part); + // Extract the integer part of the number and print it + unsigned long int_part = (unsigned long)number; + double remainder = number - (double)int_part; + n += print(int_part); - // Print the decimal point, but only if there are digits beyond - if (digits > 0) - { - n += print("."); - } + // Print the decimal point, but only if there are digits beyond + if (digits > 0) + { + n += print("."); + } - // Extract digits from the remainder one at a time - while (digits-- > 0) - { - remainder *= 10.0; - unsigned int toPrint = (unsigned int)remainder; - n += print(toPrint); - remainder -= toPrint; - } + // Extract digits from the remainder one at a time + while (digits-- > 0) + { + remainder *= 10.0; + unsigned int toPrint = (unsigned int)remainder; + n += print(toPrint); + remainder -= toPrint; + } - return n; + return n; } size_t Print::printBuffer(uint8_t const buffer[], int len, char delim, int byteline) { - if (buffer == NULL || len == 0) - return 0; + if (buffer == NULL || len == 0) + return 0; - for (int i = 0; i < len; i++) - { - if ( i != 0 ) - print(delim); + for (int i = 0; i < len; i++) + { + if ( i != 0 ) + print(delim); - if ( byteline && (i % byteline == 0) ) - println(); + if ( byteline && (i % byteline == 0) ) + println(); - this->printf("%02X", buffer[i]); - } + this->printf("%02X", buffer[i]); + } - return (len * 3 - 1); + return (len * 3 - 1); } size_t Print::printBufferReverse(uint8_t const buffer[], int len, char delim, int byteline) { - if (buffer == NULL || len == 0) - return 0; + if (buffer == NULL || len == 0) + return 0; - for (int i = 0; i < len; i++) - { - if (i != 0) - print(delim); + for (int i = 0; i < len; i++) + { + if (i != 0) + print(delim); - if ( byteline && (i % byteline == 0) ) - println(); + if ( byteline && (i % byteline == 0) ) + println(); - this->printf("%02X", buffer[len - 1 - i]); - } + this->printf("%02X", buffer[len - 1 - i]); + } - return (len * 3 - 1); + return (len * 3 - 1); } diff --git a/Packages_Patches/Seeeduino/hardware/nrf52/1.0.0/cores/nRF5/Print.h b/Packages_Patches/Seeeduino/hardware/nrf52/1.0.0/cores/nRF5/Print.h index 810a7704..d03d1cc8 100644 --- a/Packages_Patches/Seeeduino/hardware/nrf52/1.0.0/cores/nRF5/Print.h +++ b/Packages_Patches/Seeeduino/hardware/nrf52/1.0.0/cores/nRF5/Print.h @@ -31,93 +31,93 @@ class Print { - private: - int write_error; - size_t printNumber(unsigned long, uint8_t); - size_t printULLNumber(unsigned long long, uint8_t); - size_t printFloat(double, int); - protected: - void setWriteError(int err = 1) - { - write_error = err; - } - public: - Print() : write_error(0) {} - - int getWriteError() - { - return write_error; - } - void clearWriteError() - { - setWriteError(0); - } - - virtual size_t write(uint8_t) = 0; - size_t write(const char *str) - { - if (str == NULL) - return 0; - - return write((const uint8_t *)str, strlen(str)); - } - virtual size_t write(const uint8_t *buffer, size_t size); - size_t write(const char *buffer, size_t size) - { - return write((const uint8_t *)buffer, size); - } - - // default to zero, meaning "a single write may block" - // should be overridden by subclasses with buffering - virtual int availableForWrite() - { - return 0; - } - - size_t print(const __FlashStringHelper *); - size_t print(const String &); - size_t print(const char[]); - size_t print(char); - size_t print(unsigned char, int = DEC); - size_t print(int, int = DEC); - size_t print(unsigned int, int = DEC); - size_t print(long, int = DEC); - size_t print(unsigned long, int = DEC); - size_t print(long long, int = DEC); - size_t print(unsigned long long, int = DEC); - size_t print(double, int = 2); - size_t print(const Printable&); - - size_t println(const __FlashStringHelper *); - size_t println(const String &s); - size_t println(const char[]); - size_t println(char); - size_t println(unsigned char, int = DEC); - size_t println(int, int = DEC); - size_t println(unsigned int, int = DEC); - size_t println(long, int = DEC); - size_t println(unsigned long, int = DEC); - size_t println(long long, int = DEC); - size_t println(unsigned long long, int = DEC); - size_t println(double, int = 2); - size_t println(const Printable&); - size_t println(void); - - size_t printf(const char * format, ...); - - size_t printBuffer(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); - size_t printBuffer(char const buffer[], int size, char delim = ' ', int byteline = 0) - { - return printBuffer((uint8_t const*) buffer, size, delim, byteline); - } - - size_t printBufferReverse(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); - size_t printBufferReverse(char const buffer[], int size, char delim = ' ', int byteline = 0) - { - return printBufferReverse((uint8_t const*) buffer, size, delim, byteline); - } - - virtual void flush() { /* Empty implementation for backward compatibility */ } + private: + int write_error; + size_t printNumber(unsigned long, uint8_t); + size_t printULLNumber(unsigned long long, uint8_t); + size_t printFloat(double, int); + protected: + void setWriteError(int err = 1) + { + write_error = err; + } + public: + Print() : write_error(0) {} + + int getWriteError() + { + return write_error; + } + void clearWriteError() + { + setWriteError(0); + } + + virtual size_t write(uint8_t) = 0; + size_t write(const char *str) + { + if (str == NULL) + return 0; + + return write((const uint8_t *)str, strlen(str)); + } + virtual size_t write(const uint8_t *buffer, size_t size); + size_t write(const char *buffer, size_t size) + { + return write((const uint8_t *)buffer, size); + } + + // default to zero, meaning "a single write may block" + // should be overridden by subclasses with buffering + virtual int availableForWrite() + { + return 0; + } + + size_t print(const __FlashStringHelper *); + size_t print(const String &); + size_t print(const char[]); + size_t print(char); + size_t print(unsigned char, int = DEC); + size_t print(int, int = DEC); + size_t print(unsigned int, int = DEC); + size_t print(long, int = DEC); + size_t print(unsigned long, int = DEC); + size_t print(long long, int = DEC); + size_t print(unsigned long long, int = DEC); + size_t print(double, int = 2); + size_t print(const Printable&); + + size_t println(const __FlashStringHelper *); + size_t println(const String &s); + size_t println(const char[]); + size_t println(char); + size_t println(unsigned char, int = DEC); + size_t println(int, int = DEC); + size_t println(unsigned int, int = DEC); + size_t println(long, int = DEC); + size_t println(unsigned long, int = DEC); + size_t println(long long, int = DEC); + size_t println(unsigned long long, int = DEC); + size_t println(double, int = 2); + size_t println(const Printable&); + size_t println(void); + + size_t printf(const char * format, ...); + + size_t printBuffer(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); + size_t printBuffer(char const buffer[], int size, char delim = ' ', int byteline = 0) + { + return printBuffer((uint8_t const*) buffer, size, delim, byteline); + } + + size_t printBufferReverse(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); + size_t printBufferReverse(char const buffer[], int size, char delim = ' ', int byteline = 0) + { + return printBufferReverse((uint8_t const*) buffer, size, delim, byteline); + } + + virtual void flush() { /* Empty implementation for backward compatibility */ } }; diff --git a/Packages_Patches/Seeeduino/hardware/nrf52/1.0.0/cores/nRF5/Udp.h b/Packages_Patches/Seeeduino/hardware/nrf52/1.0.0/cores/nRF5/Udp.h index b3604ea9..c2d5824d 100644 --- a/Packages_Patches/Seeeduino/hardware/nrf52/1.0.0/cores/nRF5/Udp.h +++ b/Packages_Patches/Seeeduino/hardware/nrf52/1.0.0/cores/nRF5/Udp.h @@ -41,59 +41,60 @@ class UDP : public Stream { - public: - virtual uint8_t begin(uint16_t) = 0; // initialize, start listening on specified port. Returns 1 if successful, 0 if there are no sockets available to use - - // KH, add virtual function to support Multicast, necessary for many services (MDNS, UPnP, etc.) - virtual uint8_t beginMulticast(IPAddress, uint16_t) - { - return 0; // initialize, start listening on specified multicast IP address and port. Returns 1 if successful, 0 on failure - } - - virtual void stop() = 0; // Finish with the UDP socket - - // Sending UDP packets - - // Start building up a packet to send to the remote host specific in ip and port - // Returns 1 if successful, 0 if there was a problem with the supplied IP address or port - virtual int beginPacket(IPAddress ip, uint16_t port) = 0; - // Start building up a packet to send to the remote host specific in host and port - // Returns 1 if successful, 0 if there was a problem resolving the hostname or port - virtual int beginPacket(const char *host, uint16_t port) = 0; - // Finish off this packet and send it - // Returns 1 if the packet was sent successfully, 0 if there was an error - virtual int endPacket() = 0; - // Write a single byte into the packet - virtual size_t write(uint8_t) = 0; - // Write size bytes from buffer into the packet - virtual size_t write(const uint8_t *buffer, size_t size) = 0; - - // Start processing the next available incoming packet - // Returns the size of the packet in bytes, or 0 if no packets are available - virtual int parsePacket() = 0; - // Number of bytes remaining in the current packet - virtual int available() = 0; - // Read a single byte from the current packet - virtual int read() = 0; - // Read up to len bytes from the current packet and place them into buffer - // Returns the number of bytes read, or 0 if none are available - virtual int read(unsigned char* buffer, size_t len) = 0; - // Read up to len characters from the current packet and place them into buffer - // Returns the number of characters read, or 0 if none are available - virtual int read(char* buffer, size_t len) = 0; - // Return the next byte from the current packet without moving on to the next byte - virtual int peek() = 0; - virtual void flush() = 0; // Finish reading the current packet - - // Return the IP address of the host who sent the current incoming packet - virtual IPAddress remoteIP() = 0; - // Return the port of the host who sent the current incoming packet - virtual uint16_t remotePort() = 0; - protected: - uint8_t* rawIPAddress(IPAddress& addr) - { - return addr.raw_address(); - }; + public: + virtual uint8_t begin(uint16_t) = + 0; // initialize, start listening on specified port. Returns 1 if successful, 0 if there are no sockets available to use + + // KH, add virtual function to support Multicast, necessary for many services (MDNS, UPnP, etc.) + virtual uint8_t beginMulticast(IPAddress, uint16_t) + { + return 0; // initialize, start listening on specified multicast IP address and port. Returns 1 if successful, 0 on failure + } + + virtual void stop() = 0; // Finish with the UDP socket + + // Sending UDP packets + + // Start building up a packet to send to the remote host specific in ip and port + // Returns 1 if successful, 0 if there was a problem with the supplied IP address or port + virtual int beginPacket(IPAddress ip, uint16_t port) = 0; + // Start building up a packet to send to the remote host specific in host and port + // Returns 1 if successful, 0 if there was a problem resolving the hostname or port + virtual int beginPacket(const char *host, uint16_t port) = 0; + // Finish off this packet and send it + // Returns 1 if the packet was sent successfully, 0 if there was an error + virtual int endPacket() = 0; + // Write a single byte into the packet + virtual size_t write(uint8_t) = 0; + // Write size bytes from buffer into the packet + virtual size_t write(const uint8_t *buffer, size_t size) = 0; + + // Start processing the next available incoming packet + // Returns the size of the packet in bytes, or 0 if no packets are available + virtual int parsePacket() = 0; + // Number of bytes remaining in the current packet + virtual int available() = 0; + // Read a single byte from the current packet + virtual int read() = 0; + // Read up to len bytes from the current packet and place them into buffer + // Returns the number of bytes read, or 0 if none are available + virtual int read(unsigned char* buffer, size_t len) = 0; + // Read up to len characters from the current packet and place them into buffer + // Returns the number of characters read, or 0 if none are available + virtual int read(char* buffer, size_t len) = 0; + // Return the next byte from the current packet without moving on to the next byte + virtual int peek() = 0; + virtual void flush() = 0; // Finish reading the current packet + + // Return the IP address of the host who sent the current incoming packet + virtual IPAddress remoteIP() = 0; + // Return the port of the host who sent the current incoming packet + virtual uint16_t remotePort() = 0; + protected: + uint8_t* rawIPAddress(IPAddress& addr) + { + return addr.raw_address(); + }; }; #endif diff --git a/Packages_Patches/Seeeduino/hardware/rp2040/2.7.2/variants/Seeed_XIAO_RP2040/pins_arduino.h b/Packages_Patches/Seeeduino/hardware/rp2040/2.7.2/variants/Seeed_XIAO_RP2040/pins_arduino.h index f5d16f19..7aef303d 100644 --- a/Packages_Patches/Seeeduino/hardware/rp2040/2.7.2/variants/Seeed_XIAO_RP2040/pins_arduino.h +++ b/Packages_Patches/Seeeduino/hardware/rp2040/2.7.2/variants/Seeed_XIAO_RP2040/pins_arduino.h @@ -6,7 +6,7 @@ #define __PINS_ARDUINO__ #ifdef __cplusplus - extern "C" unsigned int PINCOUNT_fn(); + extern "C" unsigned int PINCOUNT_fn(); #endif // Pin count diff --git a/Packages_Patches/Seeeduino/hardware/samd/1.7.0/boards.txt b/Packages_Patches/Seeeduino/hardware/samd/1.7.0/boards.txt new file mode 100644 index 00000000..ec3f9ff3 --- /dev/null +++ b/Packages_Patches/Seeeduino/hardware/samd/1.7.0/boards.txt @@ -0,0 +1,1730 @@ +# Copyright (c) 2014-2017 Arduino LLC. All right reserved. +# +# 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + +menu.cpu=Microcontroller +menu.clock=Clock Source +menu.usb=USB Config +menu.serial=Serial Config +menu.bootloader=Bootloader Size +menu.timer=Timer PWM Frequency +menu.float=Floating Point +menu.config=Build Options + +# Generic D11C14A +d11c14a.name=Generic D11C14A +d11c14a.vid.0=0x16D0 +d11c14a.pid.0=0x1557 +d11c14a.vid.1=0x16D0 +d11c14a.pid.1=0x1856 +d11c14a.vid.2=0x16D0 +d11c14a.pid.2=0x1B41 +d11c14a.vid.3=0x16D0 +d11c14a.pid.3=0x1B40 +d11c14a.vid.4=0x16D0 +d11c14a.pid.4=0x1A0C +d11c14a.vid.5=0x16D0 +d11c14a.pid.5=0x1856 +d11c14a.build.mcu=cortex-m0plus +d11c14a.build.mathlib=arm_cortexM0l_math +d11c14a.build.f_cpu=48000000L +d11c14a.build.usb_product="D11C14A" +d11c14a.build.usb_manufacturer="Fab Foundation" +d11c14a.build.board=SAMD_ZERO +d11c14a.build.core=arduino +d11c14a.build.variant=Generic_D11C14A +d11c14a.build.variant_system_lib= +d11c14a.build.vid=0x16D0 +d11c14a.upload.protocol=sam-ba +d11c14a.bootloader.tool=openocd +d11c14a.menu.float.default=Print & String use auto-promoted doubles only +d11c14a.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +d11c14a.menu.float.print=Print uses separate singles and doubles +d11c14a.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +d11c14a.menu.float.string=String uses separate singles and doubles +d11c14a.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +d11c14a.menu.float.both=Print & String use separate singles and doubles +d11c14a.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +d11c14a.menu.config.disabled=config.h disabled +d11c14a.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +d11c14a.menu.config.enabled=config.h enabled (mostly code size reductions) +d11c14a.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +d11c14a.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +d11c14a.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +d11c14a.menu.clock.internal=INTERNAL_OSCILLATOR +d11c14a.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +d11c14a.menu.clock.crystal_32k=32KHZ_CRYSTAL +d11c14a.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +d11c14a.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +d11c14a.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +d11c14a.menu.timer.timer_732Hz=732.4Hz (16-bit) +d11c14a.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +d11c14a.menu.timer.timer_366Hz=366.2Hz (16-bit) +d11c14a.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +d11c14a.menu.timer.timer_244Hz=244.1Hz (16-bit) +d11c14a.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +d11c14a.menu.timer.timer_183Hz=183.1Hz (16-bit) +d11c14a.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +d11c14a.menu.timer.timer_146Hz=146.5Hz (16-bit) +d11c14a.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +d11c14a.menu.timer.timer_122Hz=122.1Hz (16-bit) +d11c14a.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +d11c14a.menu.timer.timer_105Hz=104.6Hz (16-bit) +d11c14a.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +d11c14a.menu.timer.timer_81Hz=81.38Hz (16-bit) +d11c14a.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +d11c14a.menu.timer.timer_61Hz=61.04Hz (16-bit) +d11c14a.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +d11c14a.menu.timer.timer_31Hz=30.52Hz (16-bit) +d11c14a.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +d11c14a.menu.timer.timer_187500Hz=187500Hz (8-bit) +d11c14a.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +d11c14a.menu.timer.timer_93750Hz=93750Hz (8-bit) +d11c14a.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +d11c14a.menu.timer.timer_62500Hz=62500Hz (8-bit) +d11c14a.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +d11c14a.menu.timer.timer_37500Hz=37500Hz (8-bit) +d11c14a.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +d11c14a.menu.timer.timer_20833Hz=20833Hz (8-bit) +d11c14a.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +d11c14a.menu.timer.timer_12500Hz=12500Hz (8-bit) +d11c14a.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +d11c14a.menu.timer.timer_7500Hz=7500Hz (8-bit) +d11c14a.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +d11c14a.menu.timer.timer_4166Hz=4166Hz (8-bit) +d11c14a.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +d11c14a.menu.timer.timer_2930Hz=2930Hz (8-bit) +d11c14a.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +d11c14a.menu.timer.timer_1465Hz=1465Hz (8-bit) +d11c14a.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +d11c14a.build.extra_flags=-D__SAMD11C14A__ {build.usb_flags} -DARM_MATH_CM0PLUS +d11c14a.build.ldscript=flash_16KB.ld +d11c14a.build.openocdscript=openocd_scripts/SAMD11C14A.cfg +d11c14a.bootloader.file=zero/binaries/sam_ba_SAMD11C14A.bin +d11c14a.menu.bootloader.4kb=4KB_BOOTLOADER +d11c14a.menu.bootloader.4kb.build.bootloader_size=__4KB_BOOTLOADER__ +d11c14a.menu.bootloader.4kb.build.ldscript_path=linker_scripts/gcc/4KB_Bootloader +d11c14a.menu.bootloader.4kb.upload.tool=Fab_SAM_Arduino:bossac +d11c14a.menu.bootloader.4kb.upload.use_1200bps_touch=true +d11c14a.menu.bootloader.4kb.upload.wait_for_upload_port=true +d11c14a.menu.bootloader.4kb.upload.native_usb=true +d11c14a.menu.bootloader.4kb.upload.maximum_size=12288 +d11c14a.menu.bootloader.0kb=NO_BOOTLOADER +d11c14a.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +d11c14a.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +d11c14a.menu.bootloader.0kb.upload.tool=openocd +d11c14a.menu.bootloader.0kb.upload.use_1200bps_touch=false +d11c14a.menu.bootloader.0kb.upload.wait_for_upload_port=false +d11c14a.menu.bootloader.0kb.upload.native_usb=false +d11c14a.menu.bootloader.0kb.upload.maximum_size=16384 +d11c14a.menu.serial.one_uart=ONE_UART_ONE_WIRE_NO_SPI +d11c14a.menu.serial.one_uart.build.serialcom_uart=ONE_UART +d11c14a.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +d11c14a.menu.serial.one_uart.build.serialcom_spi=NO_SPI +d11c14a.menu.serial.two_uart=TWO_UART_NO_WIRE_NO_SPI +d11c14a.menu.serial.two_uart.build.serialcom_uart=TWO_UART +d11c14a.menu.serial.two_uart.build.serialcom_wire=NO_WIRE +d11c14a.menu.serial.two_uart.build.serialcom_spi=NO_SPI +d11c14a.menu.serial.one_uart_no_wire_one_spi=ONE_UART_NO_WIRE_ONE_SPI +d11c14a.menu.serial.one_uart_no_wire_one_spi.build.serialcom_uart=ONE_UART +d11c14a.menu.serial.one_uart_no_wire_one_spi.build.serialcom_wire=NO_WIRE +d11c14a.menu.serial.one_uart_no_wire_one_spi.build.serialcom_spi=ONE_SPI +d11c14a.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +d11c14a.menu.serial.no_uart.build.serialcom_uart=NO_UART +d11c14a.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +d11c14a.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +d11c14a.menu.usb.cdc=CDC_ONLY +d11c14a.menu.usb.cdc.build.usbcom=CDC_ONLY +d11c14a.menu.usb.cdc.build.pid=0x1557 +d11c14a.menu.usb.cdc_hid=CDC_HID +d11c14a.menu.usb.cdc_hid.build.usbcom=CDC_HID +d11c14a.menu.usb.cdc_hid.build.pid=0x1856 +d11c14a.menu.usb.withcdc=WITH_CDC +d11c14a.menu.usb.withcdc.build.usbcom=WITH_CDC +d11c14a.menu.usb.withcdc.build.pid=0x1B41 +d11c14a.menu.usb.hid=HID_ONLY +d11c14a.menu.usb.hid.build.usbcom=HID_ONLY +d11c14a.menu.usb.hid.build.pid=0x1B40 +d11c14a.menu.usb.nocdc=WITHOUT_CDC +d11c14a.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +d11c14a.menu.usb.nocdc.build.pid=0x1A0C +d11c14a.menu.usb.none=USB_DISABLED +d11c14a.menu.usb.none.build.usbcom=USB_DISABLED +d11c14a.menu.usb.none.build.pid=0x1856 + +# Generic D11D14AS +d11d14as.name=Generic D11D14AS +d11d14as.vid.0=0x16D0 +d11d14as.pid.0=0x2557 +d11d14as.vid.1=0x16D0 +d11d14as.pid.1=0x2856 +d11d14as.vid.2=0x16D0 +d11d14as.pid.2=0x2B41 +d11d14as.vid.3=0x16D0 +d11d14as.pid.3=0x2B40 +d11d14as.vid.4=0x16D0 +d11d14as.pid.4=0x2A0C +d11d14as.vid.5=0x16D0 +d11d14as.pid.5=0x2856 +d11d14as.build.mcu=cortex-m0plus +d11d14as.build.mathlib=arm_cortexM0l_math +d11d14as.build.f_cpu=48000000L +d11d14as.build.usb_product="D11D14AS" +d11d14as.build.usb_manufacturer="Fab Foundation" +d11d14as.build.board=SAMD_ZERO +d11d14as.build.core=arduino +d11d14as.build.variant=Generic_D11D14AS +d11d14as.build.variant_system_lib= +d11d14as.build.vid=0x16D0 +d11d14as.upload.protocol=sam-ba +d11d14as.bootloader.tool=openocd +d11d14as.menu.float.default=Print & String use auto-promoted doubles only +d11d14as.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +d11d14as.menu.float.print=Print uses separate singles and doubles +d11d14as.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +d11d14as.menu.float.string=String uses separate singles and doubles +d11d14as.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +d11d14as.menu.float.both=Print & String use separate singles and doubles +d11d14as.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +d11d14as.menu.config.disabled=config.h disabled +d11d14as.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +d11d14as.menu.config.enabled=config.h enabled (mostly code size reductions) +d11d14as.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +d11d14as.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +d11d14as.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +d11d14as.menu.clock.internal=INTERNAL_OSCILLATOR +d11d14as.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +d11d14as.menu.clock.crystal_32k=32KHZ_CRYSTAL +d11d14as.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +d11d14as.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +d11d14as.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +d11d14as.menu.timer.timer_732Hz=732.4Hz (16-bit) +d11d14as.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +d11d14as.menu.timer.timer_366Hz=366.2Hz (16-bit) +d11d14as.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +d11d14as.menu.timer.timer_244Hz=244.1Hz (16-bit) +d11d14as.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +d11d14as.menu.timer.timer_183Hz=183.1Hz (16-bit) +d11d14as.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +d11d14as.menu.timer.timer_146Hz=146.5Hz (16-bit) +d11d14as.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +d11d14as.menu.timer.timer_122Hz=122.1Hz (16-bit) +d11d14as.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +d11d14as.menu.timer.timer_105Hz=104.6Hz (16-bit) +d11d14as.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +d11d14as.menu.timer.timer_81Hz=81.38Hz (16-bit) +d11d14as.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +d11d14as.menu.timer.timer_61Hz=61.04Hz (16-bit) +d11d14as.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +d11d14as.menu.timer.timer_31Hz=30.52Hz (16-bit) +d11d14as.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +d11d14as.menu.timer.timer_187500Hz=187500Hz (8-bit) +d11d14as.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +d11d14as.menu.timer.timer_93750Hz=93750Hz (8-bit) +d11d14as.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +d11d14as.menu.timer.timer_62500Hz=62500Hz (8-bit) +d11d14as.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +d11d14as.menu.timer.timer_37500Hz=37500Hz (8-bit) +d11d14as.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +d11d14as.menu.timer.timer_20833Hz=20833Hz (8-bit) +d11d14as.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +d11d14as.menu.timer.timer_12500Hz=12500Hz (8-bit) +d11d14as.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +d11d14as.menu.timer.timer_7500Hz=7500Hz (8-bit) +d11d14as.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +d11d14as.menu.timer.timer_4166Hz=4166Hz (8-bit) +d11d14as.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +d11d14as.menu.timer.timer_2930Hz=2930Hz (8-bit) +d11d14as.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +d11d14as.menu.timer.timer_1465Hz=1465Hz (8-bit) +d11d14as.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +d11d14as.build.extra_flags=-D__SAMD11D14AS__ {build.usb_flags} -DARM_MATH_CM0PLUS +d11d14as.build.ldscript=flash_16KB.ld +d11d14as.build.openocdscript=openocd_scripts/SAMD11D14AS.cfg +d11d14as.bootloader.file=zero/binaries/sam_ba_SAMD11D14AS.bin +d11d14as.menu.bootloader.4kb=4KB_BOOTLOADER +d11d14as.menu.bootloader.4kb.build.bootloader_size=__4KB_BOOTLOADER__ +d11d14as.menu.bootloader.4kb.build.ldscript_path=linker_scripts/gcc/4KB_Bootloader +d11d14as.menu.bootloader.4kb.upload.tool=Fab_SAM_Arduino:bossac +d11d14as.menu.bootloader.4kb.upload.use_1200bps_touch=true +d11d14as.menu.bootloader.4kb.upload.wait_for_upload_port=true +d11d14as.menu.bootloader.4kb.upload.native_usb=true +d11d14as.menu.bootloader.4kb.upload.maximum_size=12288 +d11d14as.menu.bootloader.0kb=NO_BOOTLOADER +d11d14as.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +d11d14as.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +d11d14as.menu.bootloader.0kb.upload.tool=openocd +d11d14as.menu.bootloader.0kb.upload.use_1200bps_touch=false +d11d14as.menu.bootloader.0kb.upload.wait_for_upload_port=false +d11d14as.menu.bootloader.0kb.upload.native_usb=false +d11d14as.menu.bootloader.0kb.upload.maximum_size=16384 +d11d14as.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +d11d14as.menu.serial.one_uart.build.serialcom_uart=ONE_UART +d11d14as.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +d11d14as.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +d11d14as.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +d11d14as.menu.serial.no_uart.build.serialcom_uart=NO_UART +d11d14as.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +d11d14as.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +d11d14as.menu.serial.two_uart=TWO_UART_ONE_WIRE_NO_SPI +d11d14as.menu.serial.two_uart.build.serialcom_uart=TWO_UART +d11d14as.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +d11d14as.menu.serial.two_uart.build.serialcom_spi=NO_SPI +d11d14as.menu.usb.cdc=CDC_ONLY +d11d14as.menu.usb.cdc.build.usbcom=CDC_ONLY +d11d14as.menu.usb.cdc.build.pid=0x2557 +d11d14as.menu.usb.cdc_hid=CDC_HID +d11d14as.menu.usb.cdc_hid.build.usbcom=CDC_HID +d11d14as.menu.usb.cdc_hid.build.pid=0x2856 +d11d14as.menu.usb.withcdc=WITH_CDC +d11d14as.menu.usb.withcdc.build.usbcom=WITH_CDC +d11d14as.menu.usb.withcdc.build.pid=0x2B41 +d11d14as.menu.usb.hid=HID_ONLY +d11d14as.menu.usb.hid.build.usbcom=HID_ONLY +d11d14as.menu.usb.hid.build.pid=0x2B40 +d11d14as.menu.usb.nocdc=WITHOUT_CDC +d11d14as.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +d11d14as.menu.usb.nocdc.build.pid=0x2A0C +d11d14as.menu.usb.none=USB_DISABLED +d11d14as.menu.usb.none.build.usbcom=USB_DISABLED +d11d14as.menu.usb.none.build.pid=0x2856 + +# Generic D11D14AM +d11d14am.name=Generic D11D14AM +d11d14am.vid.0=0x16D0 +d11d14am.pid.0=0x3557 +d11d14am.vid.1=0x16D0 +d11d14am.pid.1=0x3856 +d11d14am.vid.2=0x16D0 +d11d14am.pid.2=0x3B41 +d11d14am.vid.3=0x16D0 +d11d14am.pid.3=0x3B40 +d11d14am.vid.4=0x16D0 +d11d14am.pid.4=0x3A0C +d11d14am.vid.5=0x16D0 +d11d14am.pid.5=0x3856 +d11d14am.build.mcu=cortex-m0plus +d11d14am.build.mathlib=arm_cortexM0l_math +d11d14am.build.f_cpu=48000000L +d11d14am.build.usb_product="MT-D11" +d11d14am.build.usb_manufacturer="Fab Foundation" +d11d14am.build.board=SAMD_ZERO +d11d14am.build.core=arduino +d11d14am.build.variant=Generic_D11D14AM +d11d14am.build.variant_system_lib= +d11d14am.build.vid=0x16D0 +d11d14am.upload.protocol=sam-ba +d11d14am.bootloader.tool=openocd +d11d14am.menu.float.default=Print & String use auto-promoted doubles only +d11d14am.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +d11d14am.menu.float.print=Print uses separate singles and doubles +d11d14am.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +d11d14am.menu.float.string=String uses separate singles and doubles +d11d14am.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +d11d14am.menu.float.both=Print & String use separate singles and doubles +d11d14am.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +d11d14am.menu.config.disabled=config.h disabled +d11d14am.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +d11d14am.menu.config.enabled=config.h enabled (mostly code size reductions) +d11d14am.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +d11d14am.menu.clock.crystal_32k=32KHZ_CRYSTAL +d11d14am.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +d11d14am.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +d11d14am.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +d11d14am.menu.clock.internal=INTERNAL_OSCILLATOR +d11d14am.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +d11d14am.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +d11d14am.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +d11d14am.menu.timer.timer_732Hz=732.4Hz (16-bit) +d11d14am.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +d11d14am.menu.timer.timer_366Hz=366.2Hz (16-bit) +d11d14am.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +d11d14am.menu.timer.timer_244Hz=244.1Hz (16-bit) +d11d14am.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +d11d14am.menu.timer.timer_183Hz=183.1Hz (16-bit) +d11d14am.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +d11d14am.menu.timer.timer_146Hz=146.5Hz (16-bit) +d11d14am.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +d11d14am.menu.timer.timer_122Hz=122.1Hz (16-bit) +d11d14am.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +d11d14am.menu.timer.timer_105Hz=104.6Hz (16-bit) +d11d14am.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +d11d14am.menu.timer.timer_81Hz=81.38Hz (16-bit) +d11d14am.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +d11d14am.menu.timer.timer_61Hz=61.04Hz (16-bit) +d11d14am.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +d11d14am.menu.timer.timer_31Hz=30.52Hz (16-bit) +d11d14am.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +d11d14am.menu.timer.timer_187500Hz=187500Hz (8-bit) +d11d14am.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +d11d14am.menu.timer.timer_93750Hz=93750Hz (8-bit) +d11d14am.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +d11d14am.menu.timer.timer_62500Hz=62500Hz (8-bit) +d11d14am.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +d11d14am.menu.timer.timer_37500Hz=37500Hz (8-bit) +d11d14am.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +d11d14am.menu.timer.timer_20833Hz=20833Hz (8-bit) +d11d14am.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +d11d14am.menu.timer.timer_12500Hz=12500Hz (8-bit) +d11d14am.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +d11d14am.menu.timer.timer_7500Hz=7500Hz (8-bit) +d11d14am.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +d11d14am.menu.timer.timer_4166Hz=4166Hz (8-bit) +d11d14am.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +d11d14am.menu.timer.timer_2930Hz=2930Hz (8-bit) +d11d14am.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +d11d14am.menu.timer.timer_1465Hz=1465Hz (8-bit) +d11d14am.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +d11d14am.build.extra_flags=-D__SAMD11D14AM__ {build.usb_flags} -DARM_MATH_CM0PLUS +d11d14am.build.ldscript=flash_16KB.ld +d11d14am.build.openocdscript=openocd_scripts/SAMD11D14AM.cfg +d11d14am.bootloader.file=zero/binaries/sam_ba_SAMD11D14AM.bin +d11d14am.menu.bootloader.4kb=4KB_BOOTLOADER +d11d14am.menu.bootloader.4kb.build.bootloader_size=__4KB_BOOTLOADER__ +d11d14am.menu.bootloader.4kb.build.ldscript_path=linker_scripts/gcc/4KB_Bootloader +d11d14am.menu.bootloader.4kb.upload.tool=Fab_SAM_Arduino:bossac +d11d14am.menu.bootloader.4kb.upload.use_1200bps_touch=true +d11d14am.menu.bootloader.4kb.upload.wait_for_upload_port=true +d11d14am.menu.bootloader.4kb.upload.native_usb=true +d11d14am.menu.bootloader.4kb.upload.maximum_size=12288 +d11d14am.menu.bootloader.0kb=NO_BOOTLOADER +d11d14am.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +d11d14am.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +d11d14am.menu.bootloader.0kb.upload.tool=openocd +d11d14am.menu.bootloader.0kb.upload.use_1200bps_touch=false +d11d14am.menu.bootloader.0kb.upload.wait_for_upload_port=false +d11d14am.menu.bootloader.0kb.upload.native_usb=false +d11d14am.menu.bootloader.0kb.upload.maximum_size=16384 +d11d14am.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +d11d14am.menu.serial.one_uart.build.serialcom_uart=ONE_UART +d11d14am.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +d11d14am.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +d11d14am.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +d11d14am.menu.serial.no_uart.build.serialcom_uart=NO_UART +d11d14am.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +d11d14am.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +d11d14am.menu.serial.two_uart=TWO_UART_ONE_WIRE_NO_SPI +d11d14am.menu.serial.two_uart.build.serialcom_uart=TWO_UART +d11d14am.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +d11d14am.menu.serial.two_uart.build.serialcom_spi=NO_SPI +d11d14am.menu.usb.cdc=CDC_ONLY +d11d14am.menu.usb.cdc.build.usbcom=CDC_ONLY +d11d14am.menu.usb.cdc.build.pid=0x3557 +d11d14am.menu.usb.cdc_hid=CDC_HID +d11d14am.menu.usb.cdc_hid.build.usbcom=CDC_HID +d11d14am.menu.usb.cdc_hid.build.pid=0x3856 +d11d14am.menu.usb.withcdc=WITH_CDC +d11d14am.menu.usb.withcdc.build.usbcom=WITH_CDC +d11d14am.menu.usb.withcdc.build.pid=0x3B41 +d11d14am.menu.usb.hid=HID_ONLY +d11d14am.menu.usb.hid.build.usbcom=HID_ONLY +d11d14am.menu.usb.hid.build.pid=0x3B40 +d11d14am.menu.usb.nocdc=WITHOUT_CDC +d11d14am.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +d11d14am.menu.usb.nocdc.build.pid=0x3A0C +d11d14am.menu.usb.none=USB_DISABLED +d11d14am.menu.usb.none.build.usbcom=USB_DISABLED +d11d14am.menu.usb.none.build.pid=0x3856 + +# Generic x21E +x21e.name=Generic x21E +x21e.vid.0=0x16D0 +x21e.pid.0=0x4557 +x21e.vid.1=0x16D0 +x21e.pid.1=0x4856 +x21e.vid.2=0x16D0 +x21e.pid.2=0x4B41 +x21e.vid.3=0x16D0 +x21e.pid.3=0x4B40 +x21e.vid.4=0x16D0 +x21e.pid.4=0x4A0C +x21e.vid.5=0x16D0 +x21e.pid.5=0x4856 +x21e.build.mcu=cortex-m0plus +x21e.build.mathlib=arm_cortexM0l_math +x21e.build.f_cpu=48000000L +x21e.build.usb_product="x21E" +x21e.build.usb_manufacturer="Fab Foundation" +x21e.build.board=SAMD_ZERO +x21e.build.core=arduino +x21e.build.variant=Generic_x21E +x21e.build.variant_system_lib= +x21e.build.vid=0x16D0 +x21e.upload.protocol=sam-ba +x21e.bootloader.tool=openocd +x21e.menu.float.default=Print & String use auto-promoted doubles only +x21e.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +x21e.menu.float.print=Print uses separate singles and doubles +x21e.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +x21e.menu.float.string=String uses separate singles and doubles +x21e.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +x21e.menu.float.both=Print & String use separate singles and doubles +x21e.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +x21e.menu.config.disabled=config.h disabled +x21e.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +x21e.menu.config.enabled=config.h enabled (mostly code size reductions) +x21e.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +x21e.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +x21e.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +x21e.menu.clock.internal=INTERNAL_OSCILLATOR +x21e.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +x21e.menu.clock.crystal_32k=32KHZ_CRYSTAL +x21e.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +x21e.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +x21e.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +x21e.menu.timer.timer_732Hz=732.4Hz (16-bit) +x21e.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +x21e.menu.timer.timer_366Hz=366.2Hz (16-bit) +x21e.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +x21e.menu.timer.timer_244Hz=244.1Hz (16-bit) +x21e.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +x21e.menu.timer.timer_183Hz=183.1Hz (16-bit) +x21e.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +x21e.menu.timer.timer_146Hz=146.5Hz (16-bit) +x21e.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +x21e.menu.timer.timer_122Hz=122.1Hz (16-bit) +x21e.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +x21e.menu.timer.timer_105Hz=104.6Hz (16-bit) +x21e.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +x21e.menu.timer.timer_81Hz=81.38Hz (16-bit) +x21e.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +x21e.menu.timer.timer_61Hz=61.04Hz (16-bit) +x21e.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +x21e.menu.timer.timer_31Hz=30.52Hz (16-bit) +x21e.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +x21e.menu.timer.timer_187500Hz=187500Hz (8-bit) +x21e.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +x21e.menu.timer.timer_93750Hz=93750Hz (8-bit) +x21e.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +x21e.menu.timer.timer_62500Hz=62500Hz (8-bit) +x21e.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +x21e.menu.timer.timer_37500Hz=37500Hz (8-bit) +x21e.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +x21e.menu.timer.timer_20833Hz=20833Hz (8-bit) +x21e.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +x21e.menu.timer.timer_12500Hz=12500Hz (8-bit) +x21e.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +x21e.menu.timer.timer_7500Hz=7500Hz (8-bit) +x21e.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +x21e.menu.timer.timer_4166Hz=4166Hz (8-bit) +x21e.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +x21e.menu.timer.timer_2930Hz=2930Hz (8-bit) +x21e.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +x21e.menu.timer.timer_1465Hz=1465Hz (8-bit) +x21e.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +x21e.menu.cpu.samd21e15a=SAMD21E15A +x21e.menu.cpu.samd21e15a.upload.maximum_size=24576 +x21e.menu.cpu.samd21e15a.build.extra_flags=-D__SAMD21E15A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.samd21e15a.build.ldscript=flash_32KB.ld +x21e.menu.cpu.samd21e15a.build.openocdscript=openocd_scripts/SAMD21E15A.cfg +x21e.menu.cpu.samd21e15a.bootloader.file=zero/binaries/sam_ba_SAMD21E15A.bin +x21e.menu.cpu.samd21e16a=SAMD21E16A +x21e.menu.cpu.samd21e16a.upload.maximum_size=57344 +x21e.menu.cpu.samd21e16a.build.extra_flags=-D__SAMD21E16A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.samd21e16a.build.ldscript=flash_64KB.ld +x21e.menu.cpu.samd21e16a.build.openocdscript=openocd_scripts/SAMD21E16A.cfg +x21e.menu.cpu.samd21e16a.bootloader.file=zero/binaries/sam_ba_SAMD21E16A.bin +x21e.menu.cpu.samd21e17a=SAMD21E17A +x21e.menu.cpu.samd21e17a.upload.maximum_size=122880 +x21e.menu.cpu.samd21e17a.build.extra_flags=-D__SAMD21E17A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.samd21e17a.build.ldscript=flash_128KB.ld +x21e.menu.cpu.samd21e17a.build.openocdscript=openocd_scripts/SAMD21E17A.cfg +x21e.menu.cpu.samd21e17a.bootloader.file=zero/binaries/sam_ba_SAMD21E17A.bin +x21e.menu.cpu.samd21e18a=SAMD21E18A +x21e.menu.cpu.samd21e18a.upload.maximum_size=253952 +x21e.menu.cpu.samd21e18a.build.extra_flags=-D__SAMD21E18A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.samd21e18a.build.ldscript=flash_256KB.ld +x21e.menu.cpu.samd21e18a.build.openocdscript=openocd_scripts/SAMD21E18A.cfg +x21e.menu.cpu.samd21e18a.bootloader.file=zero/binaries/sam_ba_SAMD21E18A.bin +x21e.menu.cpu.saml21e15b=SAML21E15B +x21e.menu.cpu.saml21e15b.upload.maximum_size=24576 +x21e.menu.cpu.saml21e15b.build.extra_flags=-D__SAML21E15B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.saml21e15b.build.ldscript=flash_32KB.ld +x21e.menu.cpu.saml21e15b.build.openocdscript=openocd_scripts/SAML21E15B.cfg +x21e.menu.cpu.saml21e15b.bootloader.file=zero/binaries/sam_ba_SAML21E15B.bin +x21e.menu.cpu.saml21e16b=SAML21E16B +x21e.menu.cpu.saml21e16b.upload.maximum_size=57344 +x21e.menu.cpu.saml21e16b.build.extra_flags=-D__SAML21E16B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.saml21e16b.build.ldscript=flash_64KB.ld +x21e.menu.cpu.saml21e16b.build.openocdscript=openocd_scripts/SAML21E16B.cfg +x21e.menu.cpu.saml21e16b.bootloader.file=zero/binaries/sam_ba_SAML21E16B.bin +x21e.menu.cpu.saml21e17b=SAML21E17B +x21e.menu.cpu.saml21e17b.upload.maximum_size=122880 +x21e.menu.cpu.saml21e17b.build.extra_flags=-D__SAML21E17B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.saml21e17b.build.ldscript=flash_128KB.ld +x21e.menu.cpu.saml21e17b.build.openocdscript=openocd_scripts/SAML21E17B.cfg +x21e.menu.cpu.saml21e17b.bootloader.file=zero/binaries/sam_ba_SAML21E17B.bin +x21e.menu.cpu.saml21e18b=SAML21E18B +x21e.menu.cpu.saml21e18b.upload.maximum_size=253952 +x21e.menu.cpu.saml21e18b.build.extra_flags=-D__SAML21E18B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21e.menu.cpu.saml21e18b.build.ldscript=flash_256KB.ld +x21e.menu.cpu.saml21e18b.build.openocdscript=openocd_scripts/SAML21E18B.cfg +x21e.menu.cpu.saml21e18b.bootloader.file=zero/binaries/sam_ba_SAML21E18B.bin +x21e.menu.cpu.samc21e15a=SAMC21E15A +x21e.menu.cpu.samc21e15a.upload.maximum_size=24576 +x21e.menu.cpu.samc21e15a.build.extra_flags=-D__SAMC21E15A__ -DARM_MATH_CM0PLUS +x21e.menu.cpu.samc21e15a.build.ldscript=flash_32KB.ld +x21e.menu.cpu.samc21e15a.build.openocdscript=openocd_scripts/SAMC21E15A.cfg +x21e.menu.cpu.samc21e15a.bootloader.file=zero/binaries/sam_ba_SAMC21E15A.bin +x21e.menu.cpu.samc21e16a=SAMC21E16A +x21e.menu.cpu.samc21e16a.upload.maximum_size=57344 +x21e.menu.cpu.samc21e16a.build.extra_flags=-D__SAMC21E16A__ -DARM_MATH_CM0PLUS +x21e.menu.cpu.samc21e16a.build.ldscript=flash_64KB.ld +x21e.menu.cpu.samc21e16a.build.openocdscript=openocd_scripts/SAMC21E16A.cfg +x21e.menu.cpu.samc21e16a.bootloader.file=zero/binaries/sam_ba_SAMC21E16A.bin +x21e.menu.cpu.samc21e17a=SAMC21E17A +x21e.menu.cpu.samc21e17a.upload.maximum_size=122880 +x21e.menu.cpu.samc21e17a.build.extra_flags=-D__SAMC21E17A__ -DARM_MATH_CM0PLUS +x21e.menu.cpu.samc21e17a.build.ldscript=flash_128KB.ld +x21e.menu.cpu.samc21e17a.build.openocdscript=openocd_scripts/SAMC21E17A.cfg +x21e.menu.cpu.samc21e17a.bootloader.file=zero/binaries/sam_ba_SAMC21E17A.bin +x21e.menu.cpu.samc21e18a=SAMC21E18A +x21e.menu.cpu.samc21e18a.upload.maximum_size=253952 +x21e.menu.cpu.samc21e18a.build.extra_flags=-D__SAMC21E18A__ -DARM_MATH_CM0PLUS +x21e.menu.cpu.samc21e18a.build.ldscript=flash_256KB.ld +x21e.menu.cpu.samc21e18a.build.openocdscript=openocd_scripts/SAMC21E18A.cfg +x21e.menu.cpu.samc21e18a.bootloader.file=zero/binaries/sam_ba_SAMC21E18A.bin +x21e.menu.bootloader.8kb=8KB_BOOTLOADER +x21e.menu.bootloader.8kb.build.bootloader_size=__8KB_BOOTLOADER__ +x21e.menu.bootloader.8kb.build.ldscript_path=linker_scripts/gcc/8KB_Bootloader +x21e.menu.bootloader.8kb.upload.tool=Fab_SAM_Arduino:bossac +x21e.menu.bootloader.8kb.upload.use_1200bps_touch=true +x21e.menu.bootloader.8kb.upload.wait_for_upload_port=true +x21e.menu.bootloader.8kb.upload.native_usb=true +x21e.menu.bootloader.16kb=16KB_BOOTLOADER +x21e.menu.bootloader.16kb.build.bootloader_size=__16KB_BOOTLOADER__ +x21e.menu.bootloader.16kb.build.ldscript_path=linker_scripts/gcc/16KB_Bootloader +x21e.menu.bootloader.16kb.upload.tool=Fab_SAM_Arduino:bossac +x21e.menu.bootloader.16kb.upload.use_1200bps_touch=true +x21e.menu.bootloader.16kb.upload.wait_for_upload_port=true +x21e.menu.bootloader.16kb.upload.native_usb=true +x21e.menu.bootloader.0kb=NO_BOOTLOADER +x21e.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +x21e.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +x21e.menu.bootloader.0kb.upload.tool=openocd +x21e.menu.bootloader.0kb.upload.use_1200bps_touch=false +x21e.menu.bootloader.0kb.upload.wait_for_upload_port=false +x21e.menu.bootloader.0kb.upload.native_usb=false +x21e.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +x21e.menu.serial.one_uart.build.serialcom_uart=ONE_UART +x21e.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +x21e.menu.serial.one_uart_one_wire_two_spi=ONE_UART_ONE_WIRE_TWO_SPI +x21e.menu.serial.one_uart_one_wire_two_spi.build.serialcom_uart=ONE_UART +x21e.menu.serial.one_uart_one_wire_two_spi.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.one_uart_one_wire_two_spi.build.serialcom_spi=TWO_SPI +x21e.menu.serial.one_uart_two_wire_one_spi=ONE_UART_TWO_WIRE_ONE_SPI +x21e.menu.serial.one_uart_two_wire_one_spi.build.serialcom_uart=ONE_UART +x21e.menu.serial.one_uart_two_wire_one_spi.build.serialcom_wire=TWO_WIRE +x21e.menu.serial.one_uart_two_wire_one_spi.build.serialcom_spi=ONE_SPI +x21e.menu.serial.two_uart=TWO_UART_ONE_WIRE_ONE_SPI +x21e.menu.serial.two_uart.build.serialcom_uart=TWO_UART +x21e.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.two_uart.build.serialcom_spi=ONE_SPI +x21e.menu.serial.three_uart_one_wire_no_spi=THREE_UART_ONE_WIRE_NO_SPI +x21e.menu.serial.three_uart_one_wire_no_spi.build.serialcom_uart=THREE_UART +x21e.menu.serial.three_uart_one_wire_no_spi.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.three_uart_one_wire_no_spi.build.serialcom_spi=NO_SPI +x21e.menu.serial.three_uart_no_wire_one_spi=THREE_UART_NO_WIRE_ONE_SPI +x21e.menu.serial.three_uart_no_wire_one_spi.build.serialcom_uart=THREE_UART +x21e.menu.serial.three_uart_no_wire_one_spi.build.serialcom_wire=NO_WIRE +x21e.menu.serial.three_uart_no_wire_one_spi.build.serialcom_spi=ONE_SPI +x21e.menu.serial.four_uart=FOUR_UART_NO_WIRE_NO_SPI +x21e.menu.serial.four_uart.build.serialcom_uart=FOUR_UART +x21e.menu.serial.four_uart.build.serialcom_wire=NO_WIRE +x21e.menu.serial.four_uart.build.serialcom_spi=NO_SPI +x21e.menu.serial.no_uart_one_wire_two_spi=NO_UART_ONE_WIRE_TWO_SPI +x21e.menu.serial.no_uart_one_wire_two_spi.build.serialcom_uart=NO_UART +x21e.menu.serial.no_uart_one_wire_two_spi.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.no_uart_one_wire_two_spi.build.serialcom_spi=TWO_SPI +x21e.menu.serial.four_uart_one_wire_one_spi=FOUR_UART_ONE_WIRE_ONE_SPI (L21 only) +x21e.menu.serial.four_uart_one_wire_one_spi.build.serialcom_uart=FOUR_UART +x21e.menu.serial.four_uart_one_wire_one_spi.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.four_uart_one_wire_one_spi.build.serialcom_spi=ONE_SPI +x21e.menu.serial.five_uart_no_wire_one_spi=FIVE_UART_NO_WIRE_ONE_SPI (L21 only) +x21e.menu.serial.five_uart_no_wire_one_spi.build.serialcom_uart=FIVE_UART +x21e.menu.serial.five_uart_no_wire_one_spi.build.serialcom_wire=NO_WIRE +x21e.menu.serial.five_uart_no_wire_one_spi.build.serialcom_spi=ONE_SPI +x21e.menu.serial.five_uart_one_wire_no_spi=FIVE_UART_ONE_WIRE_NO_SPI (L21 only) +x21e.menu.serial.five_uart_one_wire_no_spi.build.serialcom_uart=FIVE_UART +x21e.menu.serial.five_uart_one_wire_no_spi.build.serialcom_wire=ONE_WIRE +x21e.menu.serial.five_uart_one_wire_no_spi.build.serialcom_spi=NO_SPI +x21e.menu.serial.six_uart=SIX_UART_NO_WIRE_NO_SPI (L21 only) +x21e.menu.serial.six_uart.build.serialcom_uart=SIX_UART +x21e.menu.serial.six_uart.build.serialcom_wire=NO_WIRE +x21e.menu.serial.six_uart.build.serialcom_spi=NO_SPI +x21e.menu.usb.cdc=CDC_ONLY +x21e.menu.usb.cdc.build.usbcom=CDC_ONLY +x21e.menu.usb.cdc.build.pid=0x4557 +x21e.menu.usb.cdc_hid=CDC_HID +x21e.menu.usb.cdc_hid.build.usbcom=CDC_HID +x21e.menu.usb.cdc_hid.build.pid=0x4856 +x21e.menu.usb.withcdc=WITH_CDC +x21e.menu.usb.withcdc.build.usbcom=WITH_CDC +x21e.menu.usb.withcdc.build.pid=0x4B41 +x21e.menu.usb.hid=HID_ONLY +x21e.menu.usb.hid.build.usbcom=HID_ONLY +x21e.menu.usb.hid.build.pid=0x4B40 +x21e.menu.usb.nocdc=WITHOUT_CDC +x21e.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +x21e.menu.usb.nocdc.build.pid=0x4A0C +x21e.menu.usb.none=USB_DISABLED +x21e.menu.usb.none.build.usbcom=USB_DISABLED +x21e.menu.usb.none.build.pid=0x4856 + +# Generic x21G +x21g.name=Generic x21G +x21g.vid.0=0x16D0 +x21g.pid.0=0x5557 +x21g.vid.1=0x16D0 +x21g.pid.1=0x5856 +x21g.vid.2=0x16D0 +x21g.pid.2=0x5B41 +x21g.vid.3=0x16D0 +x21g.pid.3=0x5B40 +x21g.vid.4=0x16D0 +x21g.pid.4=0x5A0C +x21g.vid.5=0x16D0 +x21g.pid.5=0x5856 +x21g.build.usb_manufacturer="Fab Foundation" +x21g.build.board=SAMD_ZERO +x21g.build.core=arduino +x21g.build.variant=Generic_xx1G +x21g.build.variant_system_lib= +x21g.build.vid=0x16D0 +x21g.upload.protocol=sam-ba +x21g.bootloader.tool=openocd +x21g.menu.float.default=Print & String use auto-promoted doubles only +x21g.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +x21g.menu.float.print=Print uses separate singles and doubles +x21g.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +x21g.menu.float.string=String uses separate singles and doubles +x21g.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +x21g.menu.float.both=Print & String use separate singles and doubles +x21g.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +x21g.menu.config.disabled=config.h disabled +x21g.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +x21g.menu.config.enabled=config.h enabled (mostly code size reductions) +x21g.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +x21g.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +x21g.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +x21g.menu.clock.internal=INTERNAL_OSCILLATOR +x21g.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +x21g.menu.clock.crystal_32k=32KHZ_CRYSTAL +x21g.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +x21g.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +x21g.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +x21g.menu.timer.timer_732Hz=732.4Hz (16-bit) +x21g.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +x21g.menu.timer.timer_366Hz=366.2Hz (16-bit) +x21g.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +x21g.menu.timer.timer_244Hz=244.1Hz (16-bit) +x21g.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +x21g.menu.timer.timer_183Hz=183.1Hz (16-bit) +x21g.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +x21g.menu.timer.timer_146Hz=146.5Hz (16-bit) +x21g.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +x21g.menu.timer.timer_122Hz=122.1Hz (16-bit) +x21g.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +x21g.menu.timer.timer_105Hz=104.6Hz (16-bit) +x21g.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +x21g.menu.timer.timer_81Hz=81.38Hz (16-bit) +x21g.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +x21g.menu.timer.timer_61Hz=61.04Hz (16-bit) +x21g.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +x21g.menu.timer.timer_31Hz=30.52Hz (16-bit) +x21g.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +x21g.menu.timer.timer_187500Hz=187500Hz (8-bit) +x21g.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +x21g.menu.timer.timer_93750Hz=93750Hz (8-bit) +x21g.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +x21g.menu.timer.timer_62500Hz=62500Hz (8-bit) +x21g.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +x21g.menu.timer.timer_37500Hz=37500Hz (8-bit) +x21g.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +x21g.menu.timer.timer_20833Hz=20833Hz (8-bit) +x21g.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +x21g.menu.timer.timer_12500Hz=12500Hz (8-bit) +x21g.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +x21g.menu.timer.timer_7500Hz=7500Hz (8-bit) +x21g.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +x21g.menu.timer.timer_4166Hz=4166Hz (8-bit) +x21g.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +x21g.menu.timer.timer_2930Hz=2930Hz (8-bit) +x21g.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +x21g.menu.timer.timer_1465Hz=1465Hz (8-bit) +x21g.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +x21g.menu.cpu.samd21g17a=SAMD21G17A +x21g.menu.cpu.samd21g17a.upload.maximum_size=122880 +x21g.menu.cpu.samd21g17a.build.mcu=cortex-m0plus +x21g.menu.cpu.samd21g17a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samd21g17a.build.f_cpu=48000000L +x21g.menu.cpu.samd21g17a.build.usb_product="D21" +x21g.menu.cpu.samd21g17a.build.extra_flags=-D__SAMD21G17A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.samd21g17a.build.ldscript=flash_128KB.ld +x21g.menu.cpu.samd21g17a.build.openocdscript=openocd_scripts/SAMD21G17A.cfg +x21g.menu.cpu.samd21g17a.bootloader.file=zero/binaries/sam_ba_SAMD21G17A.bin +x21g.menu.cpu.samd21g18a=SAMD21G18A +x21g.menu.cpu.samd21g18a.upload.maximum_size=253952 +x21g.menu.cpu.samd21g18a.build.mcu=cortex-m0plus +x21g.menu.cpu.samd21g18a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samd21g18a.build.f_cpu=48000000L +x21g.menu.cpu.samd21g18a.build.usb_product="D21" +x21g.menu.cpu.samd21g18a.build.extra_flags=-D__SAMD21G18A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.samd21g18a.build.ldscript=flash_256KB.ld +x21g.menu.cpu.samd21g18a.build.openocdscript=openocd_scripts/SAMD21G18A.cfg +x21g.menu.cpu.samd21g18a.bootloader.file=zero/binaries/sam_ba_SAMD21G18A.bin +x21g.menu.cpu.samd21g15a=SAMD21G15A +x21g.menu.cpu.samd21g15a.upload.maximum_size=24576 +x21g.menu.cpu.samd21g15a.build.mcu=cortex-m0plus +x21g.menu.cpu.samd21g15a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samd21g15a.build.f_cpu=48000000L +x21g.menu.cpu.samd21g15a.build.usb_product="D21" +x21g.menu.cpu.samd21g15a.build.extra_flags=-D__SAMD21G15A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.samd21g15a.build.ldscript=flash_32KB.ld +x21g.menu.cpu.samd21g15a.build.openocdscript=openocd_scripts/SAMD21G15A.cfg +x21g.menu.cpu.samd21g15a.bootloader.file=zero/binaries/sam_ba_SAMD21G15A.bin +x21g.menu.cpu.samd21g16a=SAMD21G16A +x21g.menu.cpu.samd21g16a.upload.maximum_size=57344 +x21g.menu.cpu.samd21g16a.build.mcu=cortex-m0plus +x21g.menu.cpu.samd21g16a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samd21g16a.build.f_cpu=48000000L +x21g.menu.cpu.samd21g16a.build.usb_product="D21" +x21g.menu.cpu.samd21g16a.build.extra_flags=-D__SAMD21G16A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.samd21g16a.build.ldscript=flash_64KB.ld +x21g.menu.cpu.samd21g16a.build.openocdscript=openocd_scripts/SAMD21G16A.cfg +x21g.menu.cpu.samd21g16a.bootloader.file=zero/binaries/sam_ba_SAMD21G16A.bin +x21g.menu.cpu.saml21g17b=SAML21G17B +x21g.menu.cpu.saml21g17b.upload.maximum_size=122880 +x21g.menu.cpu.saml21g17b.build.mcu=cortex-m0plus +x21g.menu.cpu.saml21g17b.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.saml21g17b.build.f_cpu=48000000L +x21g.menu.cpu.saml21g17b.build.usb_product="L21" +x21g.menu.cpu.saml21g17b.build.extra_flags=-D__SAML21G17B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.saml21g17b.build.ldscript=flash_128KB.ld +x21g.menu.cpu.saml21g17b.build.openocdscript=openocd_scripts/SAML21G17B.cfg +x21g.menu.cpu.saml21g17b.bootloader.file=zero/binaries/sam_ba_SAML21G17B.bin +x21g.menu.cpu.saml21g18b=SAML21G18B +x21g.menu.cpu.saml21g18b.upload.maximum_size=253952 +x21g.menu.cpu.saml21g18b.build.mcu=cortex-m0plus +x21g.menu.cpu.saml21g18b.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.saml21g18b.build.f_cpu=48000000L +x21g.menu.cpu.saml21g18b.build.usb_product="L21" +x21g.menu.cpu.saml21g18b.build.extra_flags=-D__SAML21G18B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.saml21g18b.build.ldscript=flash_256KB.ld +x21g.menu.cpu.saml21g18b.build.openocdscript=openocd_scripts/SAML21G18B.cfg +x21g.menu.cpu.saml21g18b.bootloader.file=zero/binaries/sam_ba_SAML21G18B.bin +x21g.menu.cpu.saml21g15b=SAML21G15B +x21g.menu.cpu.saml21g15b.upload.maximum_size=24576 +x21g.menu.cpu.saml21g15b.build.mcu=cortex-m0plus +x21g.menu.cpu.saml21g15b.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.saml21g15b.build.f_cpu=48000000L +x21g.menu.cpu.saml21g15b.build.usb_product="L21" +x21g.menu.cpu.saml21g15b.build.extra_flags=-D__SAML21G15B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.saml21g15b.build.ldscript=flash_32KB.ld +x21g.menu.cpu.saml21g15b.build.openocdscript=openocd_scripts/SAML21G15B.cfg +x21g.menu.cpu.saml21g15b.bootloader.file=zero/binaries/sam_ba_SAML21G15B.bin +x21g.menu.cpu.saml21g16b=SAML21G16B +x21g.menu.cpu.saml21g16b.upload.maximum_size=57344 +x21g.menu.cpu.saml21g16b.build.mcu=cortex-m0plus +x21g.menu.cpu.saml21g16b.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.saml21g16b.build.f_cpu=48000000L +x21g.menu.cpu.saml21g16b.build.usb_product="L21" +x21g.menu.cpu.saml21g16b.build.extra_flags=-D__SAML21G16B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21g.menu.cpu.saml21g16b.build.ldscript=flash_64KB.ld +x21g.menu.cpu.saml21g16b.build.openocdscript=openocd_scripts/SAML21G16B.cfg +x21g.menu.cpu.saml21g16b.bootloader.file=zero/binaries/sam_ba_SAML21G16B.bin +x21g.menu.cpu.samc21g17a=SAMC21G17A +x21g.menu.cpu.samc21g17a.upload.maximum_size=122880 +x21g.menu.cpu.samc21g17a.build.mcu=cortex-m0plus +x21g.menu.cpu.samc21g17a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samc21g17a.build.f_cpu=48000000L +x21g.menu.cpu.samc21g17a.build.usb_product="C21" +x21g.menu.cpu.samc21g17a.build.extra_flags=-D__SAMC21G17A__ -DARM_MATH_CM0PLUS +x21g.menu.cpu.samc21g17a.build.ldscript=flash_128KB.ld +x21g.menu.cpu.samc21g17a.build.openocdscript=openocd_scripts/SAMC21G17A.cfg +x21g.menu.cpu.samc21g17a.bootloader.file=zero/binaries/sam_ba_SAMC21G17A.bin +x21g.menu.cpu.samc21g18a=SAMC21G18A +x21g.menu.cpu.samc21g18a.upload.maximum_size=253952 +x21g.menu.cpu.samc21g18a.build.mcu=cortex-m0plus +x21g.menu.cpu.samc21g18a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samc21g18a.build.f_cpu=48000000L +x21g.menu.cpu.samc21g18a.build.usb_product="C21" +x21g.menu.cpu.samc21g18a.build.extra_flags=-D__SAMC21G18A__ -DARM_MATH_CM0PLUS +x21g.menu.cpu.samc21g18a.build.ldscript=flash_256KB.ld +x21g.menu.cpu.samc21g18a.build.openocdscript=openocd_scripts/SAMC21G18A.cfg +x21g.menu.cpu.samc21g18a.bootloader.file=zero/binaries/sam_ba_SAMC21G18A.bin +x21g.menu.cpu.samc21g15a=SAMC21G15A +x21g.menu.cpu.samc21g15a.upload.maximum_size=24576 +x21g.menu.cpu.samc21g15a.build.mcu=cortex-m0plus +x21g.menu.cpu.samc21g15a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samc21g15a.build.f_cpu=48000000L +x21g.menu.cpu.samc21g15a.build.usb_product="C21" +x21g.menu.cpu.samc21g15a.build.extra_flags=-D__SAMC21G15A__ -DARM_MATH_CM0PLUS +x21g.menu.cpu.samc21g15a.build.ldscript=flash_32KB.ld +x21g.menu.cpu.samc21g15a.build.openocdscript=openocd_scripts/SAMC21G15A.cfg +x21g.menu.cpu.samc21g15a.bootloader.file=zero/binaries/sam_ba_SAMC21G15A.bin +x21g.menu.cpu.samc21g16a=SAMC21G16A +x21g.menu.cpu.samc21g16a.upload.maximum_size=57344 +x21g.menu.cpu.samc21g16a.build.mcu=cortex-m0plus +x21g.menu.cpu.samc21g16a.build.mathlib=arm_cortexM0l_math +x21g.menu.cpu.samc21g16a.build.f_cpu=48000000L +x21g.menu.cpu.samc21g16a.build.usb_product="C21" +x21g.menu.cpu.samc21g16a.build.extra_flags=-D__SAMC21G16A__ -DARM_MATH_CM0PLUS +x21g.menu.cpu.samc21g16a.build.ldscript=flash_64KB.ld +x21g.menu.cpu.samc21g16a.build.openocdscript=openocd_scripts/SAMC21G16A.cfg +x21g.menu.cpu.samc21g16a.bootloader.file=zero/binaries/sam_ba_SAMC21G16A.bin +x21g.menu.bootloader.8kb=8KB_BOOTLOADER +x21g.menu.bootloader.8kb.build.bootloader_size=__8KB_BOOTLOADER__ +x21g.menu.bootloader.8kb.build.ldscript_path=linker_scripts/gcc/8KB_Bootloader +x21g.menu.bootloader.8kb.upload.tool=Fab_SAM_Arduino:bossac +x21g.menu.bootloader.8kb.upload.use_1200bps_touch=true +x21g.menu.bootloader.8kb.upload.wait_for_upload_port=true +x21g.menu.bootloader.8kb.upload.native_usb=true +x21g.menu.bootloader.16kb=16KB_BOOTLOADER +x21g.menu.bootloader.16kb.build.bootloader_size=__16KB_BOOTLOADER__ +x21g.menu.bootloader.16kb.build.ldscript_path=linker_scripts/gcc/16KB_Bootloader +x21g.menu.bootloader.16kb.upload.tool=Fab_SAM_Arduino:bossac +x21g.menu.bootloader.16kb.upload.use_1200bps_touch=true +x21g.menu.bootloader.16kb.upload.wait_for_upload_port=true +x21g.menu.bootloader.16kb.upload.native_usb=true +x21g.menu.bootloader.0kb=NO_BOOTLOADER +x21g.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +x21g.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +x21g.menu.bootloader.0kb.upload.tool=openocd +x21g.menu.bootloader.0kb.upload.use_1200bps_touch=false +x21g.menu.bootloader.0kb.upload.wait_for_upload_port=false +x21g.menu.bootloader.0kb.upload.native_usb=false +x21g.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +x21g.menu.serial.one_uart.build.serialcom_uart=ONE_UART +x21g.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +x21g.menu.serial.one_uart_two_spi=ONE_UART_ONE_WIRE_TWO_SPI +x21g.menu.serial.one_uart_two_spi.build.serialcom_uart=ONE_UART +x21g.menu.serial.one_uart_two_spi.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.one_uart_two_spi.build.serialcom_spi=TWO_SPI +x21g.menu.serial.one_uart_two_wire=ONE_UART_TWO_WIRE_ONE_SPI +x21g.menu.serial.one_uart_two_wire.build.serialcom_uart=ONE_UART +x21g.menu.serial.one_uart_two_wire.build.serialcom_wire=TWO_WIRE +x21g.menu.serial.one_uart_two_wire.build.serialcom_spi=ONE_SPI +x21g.menu.serial.two_uart=TWO_UART_ONE_WIRE_ONE_SPI +x21g.menu.serial.two_uart.build.serialcom_uart=TWO_UART +x21g.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.two_uart.build.serialcom_spi=ONE_SPI +x21g.menu.serial.two_uart_two_spi=TWO_UART_ONE_WIRE_TWO_SPI +x21g.menu.serial.two_uart_two_spi.build.serialcom_uart=TWO_UART +x21g.menu.serial.two_uart_two_spi.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.two_uart_two_spi.build.serialcom_spi=TWO_SPI +x21g.menu.serial.two_uart_two_wire=TWO_UART_TWO_WIRE_ONE_SPI +x21g.menu.serial.two_uart_two_wire.build.serialcom_uart=TWO_UART +x21g.menu.serial.two_uart_two_wire.build.serialcom_wire=TWO_WIRE +x21g.menu.serial.two_uart_two_wire.build.serialcom_spi=ONE_SPI +x21g.menu.serial.three_uart=THREE_UART_ONE_WIRE_ONE_SPI +x21g.menu.serial.three_uart.build.serialcom_uart=THREE_UART +x21g.menu.serial.three_uart.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.three_uart.build.serialcom_spi=ONE_SPI +x21g.menu.serial.three_uart_two_spi=THREE_UART_ONE_WIRE_TWO_SPI +x21g.menu.serial.three_uart_two_spi.build.serialcom_uart=THREE_UART +x21g.menu.serial.three_uart_two_spi.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.three_uart_two_spi.build.serialcom_spi=TWO_SPI +x21g.menu.serial.three_uart_two_wire=THREE_UART_TWO_WIRE_ONE_SPI +x21g.menu.serial.three_uart_two_wire.build.serialcom_uart=THREE_UART +x21g.menu.serial.three_uart_two_wire.build.serialcom_wire=TWO_WIRE +x21g.menu.serial.three_uart_two_wire.build.serialcom_spi=ONE_SPI +x21g.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +x21g.menu.serial.no_uart.build.serialcom_uart=NO_UART +x21g.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +x21g.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +x21g.menu.usb.cdc=CDC_ONLY +x21g.menu.usb.cdc.build.usbcom=CDC_ONLY +x21g.menu.usb.cdc.build.pid=0x5557 +x21g.menu.usb.cdc_hid=CDC_HID +x21g.menu.usb.cdc_hid.build.usbcom=CDC_HID +x21g.menu.usb.cdc_hid.build.pid=0x5856 +x21g.menu.usb.withcdc=WITH_CDC +x21g.menu.usb.withcdc.build.usbcom=WITH_CDC +x21g.menu.usb.withcdc.build.pid=0x5B41 +x21g.menu.usb.hid=HID_ONLY +x21g.menu.usb.hid.build.usbcom=HID_ONLY +x21g.menu.usb.hid.build.pid=0x5B40 +x21g.menu.usb.nocdc=WITHOUT_CDC +x21g.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +x21g.menu.usb.nocdc.build.pid=0x5A0C +x21g.menu.usb.none=USB_DISABLED +x21g.menu.usb.none.build.usbcom=USB_DISABLED +x21g.menu.usb.none.build.pid=0x5856 + +# Generic x21J +x21j.name=Generic x21J +x21j.vid.0=0x16D0 +x21j.pid.0=0x6557 +x21j.vid.1=0x16D0 +x21j.pid.1=0x6856 +x21j.vid.2=0x16D0 +x21j.pid.2=0x6B41 +x21j.vid.3=0x16D0 +x21j.pid.3=0x6B40 +x21j.vid.4=0x16D0 +x21j.pid.4=0x6A0C +x21j.vid.5=0x16D0 +x21j.pid.5=0x6856 +x21j.build.usb_manufacturer="Fab Foundation" +x21j.build.board=SAMD_ZERO +x21j.build.core=arduino +x21j.build.variant=Generic_xx1J +x21j.build.variant_system_lib= +x21j.build.vid=0x16D0 +x21j.upload.protocol=sam-ba +x21j.bootloader.tool=openocd +x21j.menu.float.default=Print & String use auto-promoted doubles only +x21j.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +x21j.menu.float.print=Print uses separate singles and doubles +x21j.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +x21j.menu.float.string=String uses separate singles and doubles +x21j.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +x21j.menu.float.both=Print & String use separate singles and doubles +x21j.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +x21j.menu.config.disabled=config.h disabled +x21j.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +x21j.menu.config.enabled=config.h enabled (mostly code size reductions) +x21j.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +x21j.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +x21j.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +x21j.menu.clock.internal=INTERNAL_OSCILLATOR +x21j.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +x21j.menu.clock.crystal_32k=32KHZ_CRYSTAL +x21j.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +x21j.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +x21j.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +x21j.menu.timer.timer_732Hz=732.4Hz (16-bit) +x21j.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +x21j.menu.timer.timer_366Hz=366.2Hz (16-bit) +x21j.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +x21j.menu.timer.timer_244Hz=244.1Hz (16-bit) +x21j.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +x21j.menu.timer.timer_183Hz=183.1Hz (16-bit) +x21j.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +x21j.menu.timer.timer_146Hz=146.5Hz (16-bit) +x21j.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +x21j.menu.timer.timer_122Hz=122.1Hz (16-bit) +x21j.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +x21j.menu.timer.timer_105Hz=104.6Hz (16-bit) +x21j.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +x21j.menu.timer.timer_81Hz=81.38Hz (16-bit) +x21j.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +x21j.menu.timer.timer_61Hz=61.04Hz (16-bit) +x21j.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +x21j.menu.timer.timer_31Hz=30.52Hz (16-bit) +x21j.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +x21j.menu.timer.timer_187500Hz=187500Hz (8-bit) +x21j.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +x21j.menu.timer.timer_93750Hz=93750Hz (8-bit) +x21j.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +x21j.menu.timer.timer_62500Hz=62500Hz (8-bit) +x21j.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +x21j.menu.timer.timer_37500Hz=37500Hz (8-bit) +x21j.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +x21j.menu.timer.timer_20833Hz=20833Hz (8-bit) +x21j.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +x21j.menu.timer.timer_12500Hz=12500Hz (8-bit) +x21j.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +x21j.menu.timer.timer_7500Hz=7500Hz (8-bit) +x21j.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +x21j.menu.timer.timer_4166Hz=4166Hz (8-bit) +x21j.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +x21j.menu.timer.timer_2930Hz=2930Hz (8-bit) +x21j.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +x21j.menu.timer.timer_1465Hz=1465Hz (8-bit) +x21j.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +x21j.menu.cpu.samd21j17a=SAMD21J17A +x21j.menu.cpu.samd21j17a.upload.maximum_size=122880 +x21j.menu.cpu.samd21j17a.build.mcu=cortex-m0plus +x21j.menu.cpu.samd21j17a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samd21j17a.build.f_cpu=48000000L +x21j.menu.cpu.samd21j17a.build.usb_product="Xeno D21" +x21j.menu.cpu.samd21j17a.build.extra_flags=-D__SAMD21J17A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.samd21j17a.build.ldscript=flash_128KB.ld +x21j.menu.cpu.samd21j17a.build.openocdscript=openocd_scripts/SAMD21J17A.cfg +x21j.menu.cpu.samd21j17a.bootloader.file=zero/binaries/sam_ba_SAMD21J17A.bin +x21j.menu.cpu.samd21j18a=SAMD21J18A +x21j.menu.cpu.samd21j18a.upload.maximum_size=253952 +x21j.menu.cpu.samd21j18a.build.mcu=cortex-m0plus +x21j.menu.cpu.samd21j18a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samd21j18a.build.f_cpu=48000000L +x21j.menu.cpu.samd21j18a.build.usb_product="Xeno D21" +x21j.menu.cpu.samd21j18a.build.extra_flags=-D__SAMD21J18A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.samd21j18a.build.ldscript=flash_256KB.ld +x21j.menu.cpu.samd21j18a.build.openocdscript=openocd_scripts/SAMD21J18A.cfg +x21j.menu.cpu.samd21j18a.bootloader.file=zero/binaries/sam_ba_SAMD21J18A.bin +x21j.menu.cpu.samd21j15a=SAMD21J15A +x21j.menu.cpu.samd21j15a.upload.maximum_size=24576 +x21j.menu.cpu.samd21j15a.build.mcu=cortex-m0plus +x21j.menu.cpu.samd21j15a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samd21j15a.build.f_cpu=48000000L +x21j.menu.cpu.samd21j15a.build.usb_product="Xeno D21" +x21j.menu.cpu.samd21j15a.build.extra_flags=-D__SAMD21J15A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.samd21j15a.build.ldscript=flash_32KB.ld +x21j.menu.cpu.samd21j15a.build.openocdscript=openocd_scripts/SAMD21J15A.cfg +x21j.menu.cpu.samd21j15a.bootloader.file=zero/binaries/sam_ba_SAMD21J15A.bin +x21j.menu.cpu.samd21j16a=SAMD21J16A +x21j.menu.cpu.samd21j16a.upload.maximum_size=57344 +x21j.menu.cpu.samd21j16a.build.mcu=cortex-m0plus +x21j.menu.cpu.samd21j16a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samd21j16a.build.f_cpu=48000000L +x21j.menu.cpu.samd21j16a.build.usb_product="Xeno D21" +x21j.menu.cpu.samd21j16a.build.extra_flags=-D__SAMD21J16A__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.samd21j16a.build.ldscript=flash_64KB.ld +x21j.menu.cpu.samd21j16a.build.openocdscript=openocd_scripts/SAMD21J16A.cfg +x21j.menu.cpu.samd21j16a.bootloader.file=zero/binaries/sam_ba_SAMD21J16A.bin +x21j.menu.cpu.saml21j17b=SAML21J17B +x21j.menu.cpu.saml21j17b.upload.maximum_size=122880 +x21j.menu.cpu.saml21j17b.build.mcu=cortex-m0plus +x21j.menu.cpu.saml21j17b.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.saml21j17b.build.f_cpu=48000000L +x21j.menu.cpu.saml21j17b.build.usb_product="Xeno L21" +x21j.menu.cpu.saml21j17b.build.extra_flags=-D__SAML21J17B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.saml21j17b.build.ldscript=flash_128KB.ld +x21j.menu.cpu.saml21j17b.build.openocdscript=openocd_scripts/SAML21J17B.cfg +x21j.menu.cpu.saml21j17b.bootloader.file=zero/binaries/sam_ba_SAML21J17B.bin +x21j.menu.cpu.saml21j18b=SAML21J18B +x21j.menu.cpu.saml21j18b.upload.maximum_size=253952 +x21j.menu.cpu.saml21j18b.build.mcu=cortex-m0plus +x21j.menu.cpu.saml21j18b.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.saml21j18b.build.f_cpu=48000000L +x21j.menu.cpu.saml21j18b.build.usb_product="Xeno L21" +x21j.menu.cpu.saml21j18b.build.extra_flags=-D__SAML21J18B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.saml21j18b.build.ldscript=flash_256KB.ld +x21j.menu.cpu.saml21j18b.build.openocdscript=openocd_scripts/SAML21J18B.cfg +x21j.menu.cpu.saml21j18b.bootloader.file=zero/binaries/sam_ba_SAML21J18B.bin +x21j.menu.cpu.saml21j16b=SAML21J16B +x21j.menu.cpu.saml21j16b.upload.maximum_size=57344 +x21j.menu.cpu.saml21j16b.build.mcu=cortex-m0plus +x21j.menu.cpu.saml21j16b.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.saml21j16b.build.f_cpu=48000000L +x21j.menu.cpu.saml21j16b.build.usb_product="Xeno L21" +x21j.menu.cpu.saml21j16b.build.extra_flags=-D__SAML21J16B__ {build.usb_flags} -DARM_MATH_CM0PLUS +x21j.menu.cpu.saml21j16b.build.ldscript=flash_64KB.ld +x21j.menu.cpu.saml21j16b.build.openocdscript=openocd_scripts/SAML21J16B.cfg +x21j.menu.cpu.saml21j16b.bootloader.file=zero/binaries/sam_ba_SAML21J16B.bin +x21j.menu.cpu.samc21j17a=SAMC21J17A +x21j.menu.cpu.samc21j17a.upload.maximum_size=122880 +x21j.menu.cpu.samc21j17a.build.mcu=cortex-m0plus +x21j.menu.cpu.samc21j17a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samc21j17a.build.f_cpu=48000000L +x21j.menu.cpu.samc21j17a.build.usb_product="Xeno C21" +x21j.menu.cpu.samc21j17a.build.extra_flags=-D__SAMC21J17A__ -DARM_MATH_CM0PLUS +x21j.menu.cpu.samc21j17a.build.ldscript=flash_128KB.ld +x21j.menu.cpu.samc21j17a.build.openocdscript=openocd_scripts/SAMC21J17A.cfg +x21j.menu.cpu.samc21j17a.bootloader.file=zero/binaries/sam_ba_SAMC21J17A.bin +x21j.menu.cpu.samc21j18a=SAMC21J18A +x21j.menu.cpu.samc21j18a.upload.maximum_size=253952 +x21j.menu.cpu.samc21j18a.build.mcu=cortex-m0plus +x21j.menu.cpu.samc21j18a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samc21j18a.build.f_cpu=48000000L +x21j.menu.cpu.samc21j18a.build.usb_product="Xeno C21" +x21j.menu.cpu.samc21j18a.build.extra_flags=-D__SAMC21J18A__ -DARM_MATH_CM0PLUS +x21j.menu.cpu.samc21j18a.build.ldscript=flash_256KB.ld +x21j.menu.cpu.samc21j18a.build.openocdscript=openocd_scripts/SAMC21J18A.cfg +x21j.menu.cpu.samc21j18a.bootloader.file=zero/binaries/sam_ba_SAMC21J18A.bin +x21j.menu.cpu.samc21j15a=SAMC21J15A +x21j.menu.cpu.samc21j15a.upload.maximum_size=24576 +x21j.menu.cpu.samc21j15a.build.mcu=cortex-m0plus +x21j.menu.cpu.samc21j15a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samc21j15a.build.f_cpu=48000000L +x21j.menu.cpu.samc21j15a.build.usb_product="Xeno C21" +x21j.menu.cpu.samc21j15a.build.extra_flags=-D__SAMC21J15A__ -DARM_MATH_CM0PLUS +x21j.menu.cpu.samc21j15a.build.ldscript=flash_32KB.ld +x21j.menu.cpu.samc21j15a.build.openocdscript=openocd_scripts/SAMC21J15A.cfg +x21j.menu.cpu.samc21j15a.bootloader.file=zero/binaries/sam_ba_SAMC21J15A.bin +x21j.menu.cpu.samc21j16a=SAMC21J16A +x21j.menu.cpu.samc21j16a.upload.maximum_size=57344 +x21j.menu.cpu.samc21j16a.build.mcu=cortex-m0plus +x21j.menu.cpu.samc21j16a.build.mathlib=arm_cortexM0l_math +x21j.menu.cpu.samc21j16a.build.f_cpu=48000000L +x21j.menu.cpu.samc21j16a.build.usb_product="Xeno C21" +x21j.menu.cpu.samc21j16a.build.extra_flags=-D__SAMC21J16A__ -DARM_MATH_CM0PLUS +x21j.menu.cpu.samc21j16a.build.ldscript=flash_64KB.ld +x21j.menu.cpu.samc21j16a.build.openocdscript=openocd_scripts/SAMC21J16A.cfg +x21j.menu.cpu.samc21j16a.bootloader.file=zero/binaries/sam_ba_SAMC21J16A.bin +x21j.menu.bootloader.8kb=8KB_BOOTLOADER +x21j.menu.bootloader.8kb.build.bootloader_size=__8KB_BOOTLOADER__ +x21j.menu.bootloader.8kb.build.ldscript_path=linker_scripts/gcc/8KB_Bootloader +x21j.menu.bootloader.8kb.upload.tool=Fab_SAM_Arduino:bossac +x21j.menu.bootloader.8kb.upload.use_1200bps_touch=true +x21j.menu.bootloader.8kb.upload.wait_for_upload_port=true +x21j.menu.bootloader.8kb.upload.native_usb=true +x21j.menu.bootloader.16kb=16KB_BOOTLOADER +x21j.menu.bootloader.16kb.build.bootloader_size=__16KB_BOOTLOADER__ +x21j.menu.bootloader.16kb.build.ldscript_path=linker_scripts/gcc/16KB_Bootloader +x21j.menu.bootloader.16kb.upload.tool=Fab_SAM_Arduino:bossac +x21j.menu.bootloader.16kb.upload.use_1200bps_touch=true +x21j.menu.bootloader.16kb.upload.wait_for_upload_port=true +x21j.menu.bootloader.16kb.upload.native_usb=true +x21j.menu.bootloader.0kb=NO_BOOTLOADER +x21j.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +x21j.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +x21j.menu.bootloader.0kb.upload.tool=openocd +x21j.menu.bootloader.0kb.upload.use_1200bps_touch=false +x21j.menu.bootloader.0kb.upload.wait_for_upload_port=false +x21j.menu.bootloader.0kb.upload.native_usb=false +x21j.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +x21j.menu.serial.one_uart.build.serialcom_uart=ONE_UART +x21j.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +x21j.menu.serial.one_uart_two_spi=ONE_UART_ONE_WIRE_TWO_SPI +x21j.menu.serial.one_uart_two_spi.build.serialcom_uart=ONE_UART +x21j.menu.serial.one_uart_two_spi.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.one_uart_two_spi.build.serialcom_spi=TWO_SPI +x21j.menu.serial.one_uart_two_wire=ONE_UART_TWO_WIRE_ONE_SPI +x21j.menu.serial.one_uart_two_wire.build.serialcom_uart=ONE_UART +x21j.menu.serial.one_uart_two_wire.build.serialcom_wire=TWO_WIRE +x21j.menu.serial.one_uart_two_wire.build.serialcom_spi=ONE_SPI +x21j.menu.serial.two_uart=TWO_UART_ONE_WIRE_ONE_SPI +x21j.menu.serial.two_uart.build.serialcom_uart=TWO_UART +x21j.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.two_uart.build.serialcom_spi=ONE_SPI +x21j.menu.serial.two_uart_two_spi=TWO_UART_ONE_WIRE_TWO_SPI +x21j.menu.serial.two_uart_two_spi.build.serialcom_uart=TWO_UART +x21j.menu.serial.two_uart_two_spi.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.two_uart_two_spi.build.serialcom_spi=TWO_SPI +x21j.menu.serial.two_uart_two_wire=TWO_UART_TWO_WIRE_ONE_SPI +x21j.menu.serial.two_uart_two_wire.build.serialcom_uart=TWO_UART +x21j.menu.serial.two_uart_two_wire.build.serialcom_wire=TWO_WIRE +x21j.menu.serial.two_uart_two_wire.build.serialcom_spi=ONE_SPI +x21j.menu.serial.three_uart=THREE_UART_ONE_WIRE_ONE_SPI +x21j.menu.serial.three_uart.build.serialcom_uart=THREE_UART +x21j.menu.serial.three_uart.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.three_uart.build.serialcom_spi=ONE_SPI +x21j.menu.serial.three_uart_two_spi=THREE_UART_ONE_WIRE_TWO_SPI +x21j.menu.serial.three_uart_two_spi.build.serialcom_uart=THREE_UART +x21j.menu.serial.three_uart_two_spi.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.three_uart_two_spi.build.serialcom_spi=TWO_SPI +x21j.menu.serial.three_uart_two_wire=THREE_UART_TWO_WIRE_ONE_SPI +x21j.menu.serial.three_uart_two_wire.build.serialcom_uart=THREE_UART +x21j.menu.serial.three_uart_two_wire.build.serialcom_wire=TWO_WIRE +x21j.menu.serial.three_uart_two_wire.build.serialcom_spi=ONE_SPI +x21j.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +x21j.menu.serial.no_uart.build.serialcom_uart=NO_UART +x21j.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +x21j.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +x21j.menu.usb.cdc=CDC_ONLY +x21j.menu.usb.cdc.build.usbcom=CDC_ONLY +x21j.menu.usb.cdc.build.pid=0x6557 +x21j.menu.usb.cdc_hid=CDC_HID +x21j.menu.usb.cdc_hid.build.usbcom=CDC_HID +x21j.menu.usb.cdc_hid.build.pid=0x6856 +x21j.menu.usb.withcdc=WITH_CDC +x21j.menu.usb.withcdc.build.usbcom=WITH_CDC +x21j.menu.usb.withcdc.build.pid=0x6B41 +x21j.menu.usb.hid=HID_ONLY +x21j.menu.usb.hid.build.usbcom=HID_ONLY +x21j.menu.usb.hid.build.pid=0x6B40 +x21j.menu.usb.nocdc=WITHOUT_CDC +x21j.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +x21j.menu.usb.nocdc.build.pid=0x6A0C +x21j.menu.usb.none=USB_DISABLED +x21j.menu.usb.none.build.usbcom=USB_DISABLED +x21j.menu.usb.none.build.pid=0x6856 + +# Generic D51G +d51g.name=Generic D51G +d51g.vid.0=0x16D0 +d51g.pid.0=0x7557 +d51g.vid.1=0x16D0 +d51g.pid.1=0x7856 +d51g.vid.2=0x16D0 +d51g.pid.2=0x7B41 +d51g.vid.3=0x16D0 +d51g.pid.3=0x7B40 +d51g.vid.4=0x16D0 +d51g.pid.4=0x7A0C +d51g.vid.5=0x16D0 +d51g.pid.5=0x7856 +d51g.build.usb_manufacturer="Fab Foundation" + +# KH mod +#d51g.build.board=SAMD_ZERO +d51g.build.board=__SAMD51__ +###### + +d51g.build.core=arduino + +# KH mod +#d51g.build.variant=Generic_D51G +d51g.build.variant=Generic_xx1G +###### + +d51g.build.variant_system_lib= +d51g.build.vid=0x16D0 +d51g.upload.protocol=sam-ba +d51g.bootloader.tool=openocd +d51g.menu.float.default=Print & String use auto-promoted doubles only +d51g.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +d51g.menu.float.print=Print uses separate singles and doubles +d51g.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +d51g.menu.float.string=String uses separate singles and doubles +d51g.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +d51g.menu.float.both=Print & String use separate singles and doubles +d51g.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +d51g.menu.config.disabled=config.h disabled +d51g.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +d51g.menu.config.enabled=config.h enabled (mostly code size reductions) +d51g.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +d51g.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +d51g.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +d51g.menu.clock.internal=INTERNAL_OSCILLATOR +d51g.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +d51g.menu.clock.crystal_32k=32KHZ_CRYSTAL +d51g.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +d51g.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +d51g.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +d51g.menu.timer.timer_732Hz=732.4Hz (16-bit) +d51g.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +d51g.menu.timer.timer_366Hz=366.2Hz (16-bit) +d51g.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +d51g.menu.timer.timer_244Hz=244.1Hz (16-bit) +d51g.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +d51g.menu.timer.timer_183Hz=183.1Hz (16-bit) +d51g.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +d51g.menu.timer.timer_146Hz=146.5Hz (16-bit) +d51g.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +d51g.menu.timer.timer_122Hz=122.1Hz (16-bit) +d51g.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +d51g.menu.timer.timer_105Hz=104.6Hz (16-bit) +d51g.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +d51g.menu.timer.timer_81Hz=81.38Hz (16-bit) +d51g.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +d51g.menu.timer.timer_61Hz=61.04Hz (16-bit) +d51g.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +d51g.menu.timer.timer_31Hz=30.52Hz (16-bit) +d51g.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +d51g.menu.timer.timer_187500Hz=187500Hz (8-bit) +d51g.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +d51g.menu.timer.timer_93750Hz=93750Hz (8-bit) +d51g.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +d51g.menu.timer.timer_62500Hz=62500Hz (8-bit) +d51g.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +d51g.menu.timer.timer_37500Hz=37500Hz (8-bit) +d51g.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +d51g.menu.timer.timer_20833Hz=20833Hz (8-bit) +d51g.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +d51g.menu.timer.timer_12500Hz=12500Hz (8-bit) +d51g.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +d51g.menu.timer.timer_7500Hz=7500Hz (8-bit) +d51g.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +d51g.menu.timer.timer_4166Hz=4166Hz (8-bit) +d51g.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +d51g.menu.timer.timer_2930Hz=2930Hz (8-bit) +d51g.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +d51g.menu.timer.timer_1465Hz=1465Hz (16-bit) +d51g.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +d51g.menu.cpu.samd51g18a_120=SAMD51G18A_120MHz +d51g.menu.cpu.samd51g18a_120.upload.maximum_size=253952 +d51g.menu.cpu.samd51g18a_120.build.mcu=cortex-m4 +d51g.menu.cpu.samd51g18a_120.build.mathlib=arm_cortexM4lf_math +d51g.menu.cpu.samd51g18a_120.build.f_cpu=120000000L +d51g.menu.cpu.samd51g18a_120.build.usb_product="Xeno Mini D51" + +# KH mod +#d51g.menu.cpu.samd51g18a_120.build.extra_flags=-D__SAMD51G18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +#d51g.menu.cpu.samd51g18a_120.build.extra_flags=-D__SAMD51G18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +d51g.menu.cpu.samd51g18a_120.build.extra_flags=-D__SAMD51G18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + + +d51g.menu.cpu.samd51g18a_120.build.ldscript=flash_m4f_256KB.ld +d51g.menu.cpu.samd51g18a_120.build.openocdscript=openocd_scripts/SAMD51G18A.cfg +d51g.menu.cpu.samd51g18a_120.bootloader.file=zero/binaries/sam_ba_SAMD51G18A.bin +d51g.menu.cpu.samd51g18a_48=SAMD51G18A_48MHz +d51g.menu.cpu.samd51g18a_48.upload.maximum_size=253952 +d51g.menu.cpu.samd51g18a_48.build.mcu=cortex-m4 +d51g.menu.cpu.samd51g18a_48.build.mathlib=arm_cortexM4lf_math +d51g.menu.cpu.samd51g18a_48.build.f_cpu=48000000L +d51g.menu.cpu.samd51g18a_48.build.usb_product="Xeno Mini D51" + +# KH mod +#d51g.menu.cpu.samd51g18a_48.build.extra_flags=-D__SAMD51G18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51g.menu.cpu.samd51g18a_48.build.extra_flags=-D__SAMD51G18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51g.menu.cpu.samd51g18a_48.build.ldscript=flash_m4f_256KB.ld +d51g.menu.cpu.samd51g18a_48.build.openocdscript=openocd_scripts/SAMD51G18A.cfg +d51g.menu.cpu.samd51g18a_48.bootloader.file=zero/binaries/sam_ba_SAMD51G18A.bin +d51g.menu.cpu.samd51g19a_120=SAMD51G19A_120MHz +d51g.menu.cpu.samd51g19a_120.upload.maximum_size=516096 +d51g.menu.cpu.samd51g19a_120.build.mcu=cortex-m4 +d51g.menu.cpu.samd51g19a_120.build.mathlib=arm_cortexM4lf_math +d51g.menu.cpu.samd51g19a_120.build.f_cpu=120000000L +d51g.menu.cpu.samd51g19a_120.build.usb_product="Xeno Mini D51" + +# KH mod +#d51g.menu.cpu.samd51g19a_120.build.extra_flags=-D__SAMD51G19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51g.menu.cpu.samd51g19a_120.build.extra_flags=-D__SAMD51G19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51g.menu.cpu.samd51g19a_120.build.ldscript=flash_m4f_512KB.ld +d51g.menu.cpu.samd51g19a_120.build.openocdscript=openocd_scripts/SAMD51G19A.cfg +d51g.menu.cpu.samd51g19a_120.bootloader.file=zero/binaries/sam_ba_SAMD51G19A.bin +d51g.menu.cpu.samd51g19a_48=SAMD51G19A_48MHz +d51g.menu.cpu.samd51g19a_48.upload.maximum_size=516096 +d51g.menu.cpu.samd51g19a_48.build.mcu=cortex-m4 +d51g.menu.cpu.samd51g19a_48.build.mathlib=arm_cortexM4lf_math +d51g.menu.cpu.samd51g19a_48.build.f_cpu=48000000L +d51g.menu.cpu.samd51g19a_48.build.usb_product="Xeno Mini D51" + +# KH mod +#d51g.menu.cpu.samd51g19a_48.build.extra_flags=-D__SAMD51G19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51g.menu.cpu.samd51g19a_48.build.extra_flags=-D__SAMD51G19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51g.menu.cpu.samd51g19a_48.build.ldscript=flash_m4f_512KB.ld +d51g.menu.cpu.samd51g19a_48.build.openocdscript=openocd_scripts/SAMD51G19A.cfg +d51g.menu.cpu.samd51g19a_48.bootloader.file=zero/binaries/sam_ba_SAMD51G19A.bin +d51g.menu.bootloader.8kb=8KB_BOOTLOADER +d51g.menu.bootloader.8kb.build.bootloader_size=__8KB_BOOTLOADER__ +d51g.menu.bootloader.8kb.build.ldscript_path=linker_scripts/gcc/8KB_Bootloader +d51g.menu.bootloader.8kb.upload.tool=Fab_SAM_Arduino:bossac +d51g.menu.bootloader.8kb.upload.use_1200bps_touch=true +d51g.menu.bootloader.8kb.upload.wait_for_upload_port=true +d51g.menu.bootloader.8kb.upload.native_usb=true +d51g.menu.bootloader.16kb=16KB_BOOTLOADER +d51g.menu.bootloader.16kb.build.bootloader_size=__16KB_BOOTLOADER__ +d51g.menu.bootloader.16kb.build.ldscript_path=linker_scripts/gcc/16KB_Bootloader +d51g.menu.bootloader.16kb.upload.tool=Fab_SAM_Arduino:bossac +d51g.menu.bootloader.16kb.upload.use_1200bps_touch=true +d51g.menu.bootloader.16kb.upload.wait_for_upload_port=true +d51g.menu.bootloader.16kb.upload.native_usb=true +d51g.menu.bootloader.0kb=NO_BOOTLOADER +d51g.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +d51g.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +d51g.menu.bootloader.0kb.upload.tool=openocd +d51g.menu.bootloader.0kb.upload.use_1200bps_touch=false +d51g.menu.bootloader.0kb.upload.wait_for_upload_port=false +d51g.menu.bootloader.0kb.upload.native_usb=false +d51g.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +d51g.menu.serial.one_uart.build.serialcom_uart=ONE_UART +d51g.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +d51g.menu.serial.one_uart_two_spi=ONE_UART_ONE_WIRE_TWO_SPI +d51g.menu.serial.one_uart_two_spi.build.serialcom_uart=ONE_UART +d51g.menu.serial.one_uart_two_spi.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.one_uart_two_spi.build.serialcom_spi=TWO_SPI +d51g.menu.serial.one_uart_two_wire=ONE_UART_TWO_WIRE_ONE_SPI +d51g.menu.serial.one_uart_two_wire.build.serialcom_uart=ONE_UART +d51g.menu.serial.one_uart_two_wire.build.serialcom_wire=TWO_WIRE +d51g.menu.serial.one_uart_two_wire.build.serialcom_spi=ONE_SPI +d51g.menu.serial.two_uart=TWO_UART_ONE_WIRE_ONE_SPI +d51g.menu.serial.two_uart.build.serialcom_uart=TWO_UART +d51g.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.two_uart.build.serialcom_spi=ONE_SPI +d51g.menu.serial.two_uart_two_spi=TWO_UART_ONE_WIRE_TWO_SPI +d51g.menu.serial.two_uart_two_spi.build.serialcom_uart=TWO_UART +d51g.menu.serial.two_uart_two_spi.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.two_uart_two_spi.build.serialcom_spi=TWO_SPI +d51g.menu.serial.two_uart_two_wire=TWO_UART_TWO_WIRE_ONE_SPI +d51g.menu.serial.two_uart_two_wire.build.serialcom_uart=TWO_UART +d51g.menu.serial.two_uart_two_wire.build.serialcom_wire=TWO_WIRE +d51g.menu.serial.two_uart_two_wire.build.serialcom_spi=ONE_SPI +d51g.menu.serial.three_uart=THREE_UART_ONE_WIRE_ONE_SPI +d51g.menu.serial.three_uart.build.serialcom_uart=THREE_UART +d51g.menu.serial.three_uart.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.three_uart.build.serialcom_spi=ONE_SPI +d51g.menu.serial.three_uart_two_spi=THREE_UART_ONE_WIRE_TWO_SPI +d51g.menu.serial.three_uart_two_spi.build.serialcom_uart=THREE_UART +d51g.menu.serial.three_uart_two_spi.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.three_uart_two_spi.build.serialcom_spi=TWO_SPI +d51g.menu.serial.three_uart_two_wire=THREE_UART_TWO_WIRE_ONE_SPI +d51g.menu.serial.three_uart_two_wire.build.serialcom_uart=THREE_UART +d51g.menu.serial.three_uart_two_wire.build.serialcom_wire=TWO_WIRE +d51g.menu.serial.three_uart_two_wire.build.serialcom_spi=ONE_SPI +d51g.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +d51g.menu.serial.no_uart.build.serialcom_uart=NO_UART +d51g.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +d51g.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +d51g.menu.usb.cdc=CDC_ONLY +d51g.menu.usb.cdc.build.usbcom=CDC_ONLY +d51g.menu.usb.cdc.build.pid=0x7557 +d51g.menu.usb.cdc_hid=CDC_HID +d51g.menu.usb.cdc_hid.build.usbcom=CDC_HID +d51g.menu.usb.cdc_hid.build.pid=0x7856 +d51g.menu.usb.withcdc=WITH_CDC +d51g.menu.usb.withcdc.build.usbcom=WITH_CDC +d51g.menu.usb.withcdc.build.pid=0x7B41 +d51g.menu.usb.hid=HID_ONLY +d51g.menu.usb.hid.build.usbcom=HID_ONLY +d51g.menu.usb.hid.build.pid=0x7B40 +d51g.menu.usb.nocdc=WITHOUT_CDC +d51g.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +d51g.menu.usb.nocdc.build.pid=0x7A0C +d51g.menu.usb.none=USB_DISABLED +d51g.menu.usb.none.build.usbcom=USB_DISABLED +d51g.menu.usb.none.build.pid=0x7856 + +# Generic D51J +d51j.name=Generic D51J +d51j.vid.0=0x16D0 +d51j.pid.0=0x8557 +d51j.vid.1=0x16D0 +d51j.pid.1=0x8856 +d51j.vid.2=0x16D0 +d51j.pid.2=0x8B41 +d51j.vid.3=0x16D0 +d51j.pid.3=0x8B40 +d51j.vid.4=0x16D0 +d51j.pid.4=0x8A0C +d51j.vid.5=0x16D0 +d51j.pid.5=0x8856 +d51j.build.usb_manufacturer="Fab Foundation" + +# KH mod +#d51j.build.board=SAMD_ZERO +d51j.build.board=__SAMD51__ +###### + +d51j.build.core=arduino +d51j.build.variant=Generic_xx1J +d51j.build.variant_system_lib= +d51j.build.vid=0x16D0 +d51j.upload.protocol=sam-ba +d51j.bootloader.tool=openocd +d51j.menu.float.default=Print & String use auto-promoted doubles only +d51j.menu.float.default.build.floatconfig=FLOAT_BOTH_DOUBLES_ONLY +d51j.menu.float.print=Print uses separate singles and doubles +d51j.menu.float.print.build.floatconfig=FLOAT_PRINT_SINGLES_DOUBLES +d51j.menu.float.string=String uses separate singles and doubles +d51j.menu.float.string.build.floatconfig=FLOAT_STRING_SINGLES_DOUBLES +d51j.menu.float.both=Print & String use separate singles and doubles +d51j.menu.float.both.build.floatconfig=FLOAT_BOTH_SINGLES_DOUBLES +d51j.menu.config.disabled=config.h disabled +d51j.menu.config.disabled.build.buildconfig=CONFIG_H_DISABLED +d51j.menu.config.enabled=config.h enabled (mostly code size reductions) +d51j.menu.config.enabled.build.buildconfig=CONFIG_H_ENABLED +d51j.menu.clock.internal_usb=INTERNAL_USB_CALIBRATED_OSCILLATOR +d51j.menu.clock.internal_usb.build.clockconfig=CLOCKCONFIG_INTERNAL_USB +d51j.menu.clock.internal=INTERNAL_OSCILLATOR +d51j.menu.clock.internal.build.clockconfig=CLOCKCONFIG_INTERNAL +d51j.menu.clock.crystal_32k=32KHZ_CRYSTAL +d51j.menu.clock.crystal_32k.build.clockconfig=CLOCKCONFIG_32768HZ_CRYSTAL +d51j.menu.clock.crystal_hs=HIGH_SPEED_CRYSTAL +d51j.menu.clock.crystal_hs.build.clockconfig=CLOCKCONFIG_HS_CRYSTAL +d51j.menu.timer.timer_732Hz=732.4Hz (16-bit) +d51j.menu.timer.timer_732Hz.build.timerconfig=TIMER_732Hz +d51j.menu.timer.timer_366Hz=366.2Hz (16-bit) +d51j.menu.timer.timer_366Hz.build.timerconfig=TIMER_366Hz +d51j.menu.timer.timer_244Hz=244.1Hz (16-bit) +d51j.menu.timer.timer_244Hz.build.timerconfig=TIMER_244Hz +d51j.menu.timer.timer_183Hz=183.1Hz (16-bit) +d51j.menu.timer.timer_183Hz.build.timerconfig=TIMER_183Hz +d51j.menu.timer.timer_146Hz=146.5Hz (16-bit) +d51j.menu.timer.timer_146Hz.build.timerconfig=TIMER_146Hz +d51j.menu.timer.timer_122Hz=122.1Hz (16-bit) +d51j.menu.timer.timer_122Hz.build.timerconfig=TIMER_122Hz +d51j.menu.timer.timer_105Hz=104.6Hz (16-bit) +d51j.menu.timer.timer_105Hz.build.timerconfig=TIMER_105Hz +d51j.menu.timer.timer_81Hz=81.38Hz (16-bit) +d51j.menu.timer.timer_81Hz.build.timerconfig=TIMER_81Hz +d51j.menu.timer.timer_61Hz=61.04Hz (16-bit) +d51j.menu.timer.timer_61Hz.build.timerconfig=TIMER_61Hz +d51j.menu.timer.timer_31Hz=30.52Hz (16-bit) +d51j.menu.timer.timer_31Hz.build.timerconfig=TIMER_31Hz +d51j.menu.timer.timer_187500Hz=187500Hz (8-bit) +d51j.menu.timer.timer_187500Hz.build.timerconfig=TIMER_187500Hz +d51j.menu.timer.timer_93750Hz=93750Hz (8-bit) +d51j.menu.timer.timer_93750Hz.build.timerconfig=TIMER_93750Hz +d51j.menu.timer.timer_62500Hz=62500Hz (8-bit) +d51j.menu.timer.timer_62500Hz.build.timerconfig=TIMER_62500Hz +d51j.menu.timer.timer_37500Hz=37500Hz (8-bit) +d51j.menu.timer.timer_37500Hz.build.timerconfig=TIMER_37500Hz +d51j.menu.timer.timer_20833Hz=20833Hz (8-bit) +d51j.menu.timer.timer_20833Hz.build.timerconfig=TIMER_20833Hz +d51j.menu.timer.timer_12500Hz=12500Hz (8-bit) +d51j.menu.timer.timer_12500Hz.build.timerconfig=TIMER_12500Hz +d51j.menu.timer.timer_7500Hz=7500Hz (8-bit) +d51j.menu.timer.timer_7500Hz.build.timerconfig=TIMER_7500Hz +d51j.menu.timer.timer_4166Hz=4166Hz (8-bit) +d51j.menu.timer.timer_4166Hz.build.timerconfig=TIMER_4166Hz +d51j.menu.timer.timer_2930Hz=2930Hz (8-bit) +d51j.menu.timer.timer_2930Hz.build.timerconfig=TIMER_2930Hz +d51j.menu.timer.timer_1465Hz=1465Hz (16-bit) +d51j.menu.timer.timer_1465Hz.build.timerconfig=TIMER_1465Hz +d51j.menu.cpu.samd51j18a_120=SAMD51J18A_120MHz +d51j.menu.cpu.samd51j18a_120.upload.maximum_size=253952 +d51j.menu.cpu.samd51j18a_120.build.mcu=cortex-m4 +d51j.menu.cpu.samd51j18a_120.build.mathlib=arm_cortexM4lf_math +d51j.menu.cpu.samd51j18a_120.build.f_cpu=120000000L +d51j.menu.cpu.samd51j18a_120.build.usb_product="Xeno D51" + +# KH mod +#d51j.menu.cpu.samd51j18a_120.build.extra_flags=-D__SAMD51J18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51j.menu.cpu.samd51j18a_120.build.extra_flags=-D__SAMD51J18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51j.menu.cpu.samd51j18a_120.build.ldscript=flash_m4f_256KB.ld +d51j.menu.cpu.samd51j18a_120.build.openocdscript=openocd_scripts/SAMD51J18A.cfg +d51j.menu.cpu.samd51j18a_120.bootloader.file=zero/binaries/sam_ba_SAMD51J18A.bin +d51j.menu.cpu.samd51j18a_48=SAMD51J18A_48MHz +d51j.menu.cpu.samd51j18a_48.upload.maximum_size=253952 +d51j.menu.cpu.samd51j18a_48.build.mcu=cortex-m4 +d51j.menu.cpu.samd51j18a_48.build.mathlib=arm_cortexM4lf_math +d51j.menu.cpu.samd51j18a_48.build.f_cpu=48000000L +d51j.menu.cpu.samd51j18a_48.build.usb_product="Xeno D51" + +# KH mod +#d51j.menu.cpu.samd51j18a_48.build.extra_flags=-D__SAMD51J18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51j.menu.cpu.samd51j18a_48.build.extra_flags=-D__SAMD51J18A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51j.menu.cpu.samd51j18a_48.build.ldscript=flash_m4f_256KB.ld +d51j.menu.cpu.samd51j18a_48.build.openocdscript=openocd_scripts/SAMD51J18A.cfg +d51j.menu.cpu.samd51j18a_48.bootloader.file=zero/binaries/sam_ba_SAMD51J18A.bin +d51j.menu.cpu.samd51j19a_120=SAMD51J19A_120MHz +d51j.menu.cpu.samd51j19a_120.upload.maximum_size=516096 +d51j.menu.cpu.samd51j19a_120.build.mcu=cortex-m4 +d51j.menu.cpu.samd51j19a_120.build.mathlib=arm_cortexM4lf_math +d51j.menu.cpu.samd51j19a_120.build.f_cpu=120000000L +d51j.menu.cpu.samd51j19a_120.build.usb_product="Xeno D51" + +# KH mod +#d51j.menu.cpu.samd51j19a_120.build.extra_flags=-D__SAMD51J19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51j.menu.cpu.samd51j19a_120.build.extra_flags=-D__SAMD51J19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51j.menu.cpu.samd51j19a_120.build.ldscript=flash_m4f_512KB.ld +d51j.menu.cpu.samd51j19a_120.build.openocdscript=openocd_scripts/SAMD51J19A.cfg +d51j.menu.cpu.samd51j19a_120.bootloader.file=zero/binaries/sam_ba_SAMD51J19A.bin +d51j.menu.cpu.samd51j19a_48=SAMD51J19A_48MHz +d51j.menu.cpu.samd51j19a_48.upload.maximum_size=516096 +d51j.menu.cpu.samd51j19a_48.build.mcu=cortex-m4 +d51j.menu.cpu.samd51j19a_48.build.mathlib=arm_cortexM4lf_math +d51j.menu.cpu.samd51j19a_48.build.f_cpu=48000000L +d51j.menu.cpu.samd51j19a_48.build.usb_product="Xeno D51" + +# KH mod +#d51j.menu.cpu.samd51j19a_48.build.extra_flags=-D__SAMD51J19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51j.menu.cpu.samd51j19a_48.build.extra_flags=-D__SAMD51J19A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51j.menu.cpu.samd51j19a_48.build.ldscript=flash_m4f_512KB.ld +d51j.menu.cpu.samd51j19a_48.build.openocdscript=openocd_scripts/SAMD51J19A.cfg +d51j.menu.cpu.samd51j19a_48.bootloader.file=zero/binaries/sam_ba_SAMD51J19A.bin +d51j.menu.cpu.samd51j20a_120=SAMD51J20A_120MHz +d51j.menu.cpu.samd51j20a_120.upload.maximum_size=1040384 +d51j.menu.cpu.samd51j20a_120.build.mcu=cortex-m4 +d51j.menu.cpu.samd51j20a_120.build.mathlib=arm_cortexM4lf_math +d51j.menu.cpu.samd51j20a_120.build.f_cpu=120000000L +d51j.menu.cpu.samd51j20a_120.build.usb_product="Xeno D51" + +# KH mod +#d51j.menu.cpu.samd51j20a_120.build.extra_flags=-D__SAMD51J20A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51j.menu.cpu.samd51j20a_120.build.extra_flags=-D__SAMD51J20A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51j.menu.cpu.samd51j20a_120.build.ldscript=flash_m4f_1MB.ld +d51j.menu.cpu.samd51j20a_120.build.openocdscript=openocd_scripts/SAMD51J20A.cfg +d51j.menu.cpu.samd51j20a_120.bootloader.file=zero/binaries/sam_ba_SAMD51J20A.bin +d51j.menu.cpu.samd51j20a_48=SAMD51J20A_48MHz +d51j.menu.cpu.samd51j20a_48.upload.maximum_size=1040384 +d51j.menu.cpu.samd51j20a_48.build.mcu=cortex-m4 +d51j.menu.cpu.samd51j20a_48.build.mathlib=arm_cortexM4lf_math +d51j.menu.cpu.samd51j20a_48.build.f_cpu=48000000L +d51j.menu.cpu.samd51j20a_48.build.usb_product="Xeno D51" + +# KH mod +#d51j.menu.cpu.samd51j20a_48.build.extra_flags=-D__SAMD51J20A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 +d51j.menu.cpu.samd51j20a_48.build.extra_flags=-D__SAMD51J20A__ {build.usb_flags} -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -DARM_MATH_CM4 -D__SAMD51__ +###### + +d51j.menu.cpu.samd51j20a_48.build.ldscript=flash_m4f_1MB.ld +d51j.menu.cpu.samd51j20a_48.build.openocdscript=openocd_scripts/SAMD51J20A.cfg +d51j.menu.cpu.samd51j20a_48.bootloader.file=zero/binaries/sam_ba_SAMD51J20A.bin +d51j.menu.bootloader.8kb=8KB_BOOTLOADER +d51j.menu.bootloader.8kb.build.bootloader_size=__8KB_BOOTLOADER__ +d51j.menu.bootloader.8kb.build.ldscript_path=linker_scripts/gcc/8KB_Bootloader +d51j.menu.bootloader.8kb.upload.tool=Fab_SAM_Arduino:bossac +d51j.menu.bootloader.8kb.upload.use_1200bps_touch=true +d51j.menu.bootloader.8kb.upload.wait_for_upload_port=true +d51j.menu.bootloader.8kb.upload.native_usb=true +d51j.menu.bootloader.16kb=16KB_BOOTLOADER +d51j.menu.bootloader.16kb.build.bootloader_size=__16KB_BOOTLOADER__ +d51j.menu.bootloader.16kb.build.ldscript_path=linker_scripts/gcc/16KB_Bootloader +d51j.menu.bootloader.16kb.upload.tool=Fab_SAM_Arduino:bossac +d51j.menu.bootloader.16kb.upload.use_1200bps_touch=true +d51j.menu.bootloader.16kb.upload.wait_for_upload_port=true +d51j.menu.bootloader.16kb.upload.native_usb=true +d51j.menu.bootloader.0kb=NO_BOOTLOADER +d51j.menu.bootloader.0kb.build.bootloader_size=__NO_BOOTLOADER__ +d51j.menu.bootloader.0kb.build.ldscript_path=linker_scripts/gcc/No_Bootloader +d51j.menu.bootloader.0kb.upload.tool=openocd +d51j.menu.bootloader.0kb.upload.use_1200bps_touch=false +d51j.menu.bootloader.0kb.upload.wait_for_upload_port=false +d51j.menu.bootloader.0kb.upload.native_usb=false +d51j.menu.serial.one_uart=ONE_UART_ONE_WIRE_ONE_SPI +d51j.menu.serial.one_uart.build.serialcom_uart=ONE_UART +d51j.menu.serial.one_uart.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.one_uart.build.serialcom_spi=ONE_SPI +d51j.menu.serial.one_uart_two_spi=ONE_UART_ONE_WIRE_TWO_SPI +d51j.menu.serial.one_uart_two_spi.build.serialcom_uart=ONE_UART +d51j.menu.serial.one_uart_two_spi.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.one_uart_two_spi.build.serialcom_spi=TWO_SPI +d51j.menu.serial.one_uart_two_wire=ONE_UART_TWO_WIRE_ONE_SPI +d51j.menu.serial.one_uart_two_wire.build.serialcom_uart=ONE_UART +d51j.menu.serial.one_uart_two_wire.build.serialcom_wire=TWO_WIRE +d51j.menu.serial.one_uart_two_wire.build.serialcom_spi=ONE_SPI +d51j.menu.serial.two_uart=TWO_UART_ONE_WIRE_ONE_SPI +d51j.menu.serial.two_uart.build.serialcom_uart=TWO_UART +d51j.menu.serial.two_uart.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.two_uart.build.serialcom_spi=ONE_SPI +d51j.menu.serial.two_uart_two_spi=TWO_UART_ONE_WIRE_TWO_SPI +d51j.menu.serial.two_uart_two_spi.build.serialcom_uart=TWO_UART +d51j.menu.serial.two_uart_two_spi.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.two_uart_two_spi.build.serialcom_spi=TWO_SPI +d51j.menu.serial.two_uart_two_wire=TWO_UART_TWO_WIRE_ONE_SPI +d51j.menu.serial.two_uart_two_wire.build.serialcom_uart=TWO_UART +d51j.menu.serial.two_uart_two_wire.build.serialcom_wire=TWO_WIRE +d51j.menu.serial.two_uart_two_wire.build.serialcom_spi=ONE_SPI +d51j.menu.serial.three_uart=THREE_UART_ONE_WIRE_ONE_SPI +d51j.menu.serial.three_uart.build.serialcom_uart=THREE_UART +d51j.menu.serial.three_uart.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.three_uart.build.serialcom_spi=ONE_SPI +d51j.menu.serial.three_uart_two_spi=THREE_UART_ONE_WIRE_TWO_SPI +d51j.menu.serial.three_uart_two_spi.build.serialcom_uart=THREE_UART +d51j.menu.serial.three_uart_two_spi.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.three_uart_two_spi.build.serialcom_spi=TWO_SPI +d51j.menu.serial.three_uart_two_wire=THREE_UART_TWO_WIRE_ONE_SPI +d51j.menu.serial.three_uart_two_wire.build.serialcom_uart=THREE_UART +d51j.menu.serial.three_uart_two_wire.build.serialcom_wire=TWO_WIRE +d51j.menu.serial.three_uart_two_wire.build.serialcom_spi=ONE_SPI +d51j.menu.serial.no_uart=NO_UART_ONE_WIRE_ONE_SPI +d51j.menu.serial.no_uart.build.serialcom_uart=NO_UART +d51j.menu.serial.no_uart.build.serialcom_wire=ONE_WIRE +d51j.menu.serial.no_uart.build.serialcom_spi=ONE_SPI +d51j.menu.usb.cdc=CDC_ONLY +d51j.menu.usb.cdc.build.usbcom=CDC_ONLY +d51j.menu.usb.cdc.build.pid=0x8557 +d51j.menu.usb.cdc_hid=CDC_HID +d51j.menu.usb.cdc_hid.build.usbcom=CDC_HID +d51j.menu.usb.cdc_hid.build.pid=0x8856 +d51j.menu.usb.withcdc=WITH_CDC +d51j.menu.usb.withcdc.build.usbcom=WITH_CDC +d51j.menu.usb.withcdc.build.pid=0x8B41 +d51j.menu.usb.hid=HID_ONLY +d51j.menu.usb.hid.build.usbcom=HID_ONLY +d51j.menu.usb.hid.build.pid=0x8B40 +d51j.menu.usb.nocdc=WITHOUT_CDC +d51j.menu.usb.nocdc.build.usbcom=WITHOUT_CDC +d51j.menu.usb.nocdc.build.pid=0x8A0C +d51j.menu.usb.none=USB_DISABLED +d51j.menu.usb.none.build.usbcom=USB_DISABLED +d51j.menu.usb.none.build.pid=0x8856 diff --git a/Packages_Patches/Seeeduino/hardware/samd/1.7.7/cores/arduino/Arduino.h b/Packages_Patches/Seeeduino/hardware/samd/1.7.7/cores/arduino/Arduino.h index 51db668f..c68bc8b6 100644 --- a/Packages_Patches/Seeeduino/hardware/samd/1.7.7/cores/arduino/Arduino.h +++ b/Packages_Patches/Seeeduino/hardware/samd/1.7.7/cores/arduino/Arduino.h @@ -76,16 +76,16 @@ int __debug_buf(const char* head, char* buf, int len); // The following headers are for C++ only compilation #ifdef __cplusplus - #include "WCharacter.h" - #include "WString.h" - #include "Tone.h" - #include "WMath.h" - #include "HardwareSerial.h" - #include "pulse.h" + #include "WCharacter.h" + #include "WString.h" + #include "Tone.h" + #include "WMath.h" + #include "HardwareSerial.h" + #include "pulse.h" #endif #include "delay.h" #ifdef __cplusplus - #include "Uart.h" + #include "Uart.h" #endif // Include board variant @@ -100,24 +100,24 @@ int __debug_buf(const char* head, char* buf, int len); // undefine stdlib's abs if encountered #ifdef abs - #undef abs + #undef abs #endif // abs // undefine stdlib's abs if encountered #ifdef abs - #undef abs + #undef abs #endif // abs #ifdef __cplusplus template auto min(const T& a, const L& b) -> decltype((b < a) ? b : a) { - return (b < a) ? b : a; + return (b < a) ? b : a; } template auto max(const T& a, const L& b) -> decltype((b < a) ? b : a) { - return (a < b) ? b : a; + return (a < b) ? b : a; } #else #ifndef min @@ -147,8 +147,8 @@ auto max(const T& a, const L& b) -> decltype((b < a) ? b : a) static inline unsigned char __interruptsStatus(void) __attribute__((always_inline, unused)); static inline unsigned char __interruptsStatus(void) { - // See http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0497a/CHDBIBGJ.html - return (__get_PRIMASK() ? 0 : 1); + // See http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0497a/CHDBIBGJ.html + return (__get_PRIMASK() ? 0 : 1); } #define interruptsStatus() __interruptsStatus() #endif @@ -164,18 +164,18 @@ static inline unsigned char __interruptsStatus(void) #define bit(b) (1UL << (b)) #if (ARDUINO_SAMD_VARIANT_COMPLIANCE >= 10606) - // Interrupts - #define digitalPinToInterrupt(P) ( P ) + // Interrupts + #define digitalPinToInterrupt(P) ( P ) #endif // USB #ifdef USE_TINYUSB - #include "Adafruit_TinyUSB_Core.h" + #include "Adafruit_TinyUSB_Core.h" #else - #include "USB/USBDesc.h" - #include "USB/USBCore.h" - #include "USB/USBAPI.h" - #include "USB/USB_host.h" + #include "USB/USBDesc.h" + #include "USB/USBCore.h" + #include "USB/USBAPI.h" + #include "USB/USB_host.h" #endif #endif // Arduino_h diff --git a/Packages_Patches/Seeeduino/hardware/samd/1.7.7/cores/arduino/Print.cpp b/Packages_Patches/Seeeduino/hardware/samd/1.7.7/cores/arduino/Print.cpp index b47efa1a..d2db9576 100644 --- a/Packages_Patches/Seeeduino/hardware/samd/1.7.7/cores/arduino/Print.cpp +++ b/Packages_Patches/Seeeduino/hardware/samd/1.7.7/cores/arduino/Print.cpp @@ -35,259 +35,259 @@ /* default implementation: may be overridden */ size_t Print::write(const uint8_t *buffer, size_t size) { - size_t n = 0; + size_t n = 0; - while (size--) - { - if (write(*buffer++)) - n++; - else - break; - } + while (size--) + { + if (write(*buffer++)) + n++; + else + break; + } - return n; + return n; } size_t Print::print(const __FlashStringHelper *ifsh) { - return print(reinterpret_cast(ifsh)); + return print(reinterpret_cast(ifsh)); } size_t Print::print(const String &s) { - return write(s.c_str(), s.length()); + return write(s.c_str(), s.length()); } size_t Print::print(const char str[]) { - return write(str); + return write(str); } size_t Print::print(char c) { - return write(c); + return write(c); } size_t Print::print(unsigned char b, int base) { - return print((unsigned long) b, base); + return print((unsigned long) b, base); } size_t Print::print(int n, int base) { - return print((long) n, base); + return print((long) n, base); } size_t Print::print(unsigned int n, int base) { - return print((unsigned long) n, base); + return print((unsigned long) n, base); } size_t Print::print(long n, int base) { - if (base == 0) - { - return write(n); - } - else if (base == 10) - { - if (n < 0) - { - int t = print('-'); - n = -n; - return printNumber(n, 10) + t; - } - - return printNumber(n, 10); - } - else - { - return printNumber(n, base); - } + if (base == 0) + { + return write(n); + } + else if (base == 10) + { + if (n < 0) + { + int t = print('-'); + n = -n; + return printNumber(n, 10) + t; + } + + return printNumber(n, 10); + } + else + { + return printNumber(n, base); + } } size_t Print::print(unsigned long n, int base) { - if (base == 0) - return write(n); - else - return printNumber(n, base); + if (base == 0) + return write(n); + else + return printNumber(n, base); } size_t Print::print(long long n, int base) { - if (base == 0) - { - return write(n); - } - else if (base == 10) - { - if (n < 0) - { - int t = print('-'); - n = -n; - return printULLNumber(n, 10) + t; - } - - return printULLNumber(n, 10); - } - else - { - return printULLNumber(n, base); - } + if (base == 0) + { + return write(n); + } + else if (base == 10) + { + if (n < 0) + { + int t = print('-'); + n = -n; + return printULLNumber(n, 10) + t; + } + + return printULLNumber(n, 10); + } + else + { + return printULLNumber(n, base); + } } size_t Print::print(unsigned long long n, int base) { - if (base == 0) - return write(n); - else - return printULLNumber(n, base); + if (base == 0) + return write(n); + else + return printULLNumber(n, base); } size_t Print::print(double n, int digits) { - return printFloat(n, digits); + return printFloat(n, digits); } size_t Print::println(const __FlashStringHelper *ifsh) { - size_t n = print(ifsh); - n += println(); - return n; + size_t n = print(ifsh); + n += println(); + return n; } size_t Print::print(const Printable& x) { - return x.printTo(*this); + return x.printTo(*this); } size_t Print::println(void) { - return write("\r\n"); + return write("\r\n"); } size_t Print::println(const String &s) { - size_t n = print(s); - n += println(); - return n; + size_t n = print(s); + n += println(); + return n; } size_t Print::println(const char c[]) { - size_t n = print(c); - n += println(); - return n; + size_t n = print(c); + n += println(); + return n; } size_t Print::println(char c) { - size_t n = print(c); - n += println(); - return n; + size_t n = print(c); + n += println(); + return n; } size_t Print::println(unsigned char b, int base) { - size_t n = print(b, base); - n += println(); - return n; + size_t n = print(b, base); + n += println(); + return n; } size_t Print::println(int num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned int num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(long long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned long long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(double num, int digits) { - size_t n = print(num, digits); - n += println(); - return n; + size_t n = print(num, digits); + n += println(); + return n; } size_t Print::println(const Printable& x) { - size_t n = print(x); - n += println(); - return n; + size_t n = print(x); + n += println(); + return n; } size_t Print::printf(const char * format, ...) { - char buf[256]; - int len; + char buf[256]; + int len; - va_list ap; - va_start(ap, format); + va_list ap; + va_start(ap, format); - len = vsnprintf(buf, 256, format, ap); - this->write(buf, len); + len = vsnprintf(buf, 256, format, ap); + this->write(buf, len); - va_end(ap); - return len; + va_end(ap); + return len; } // Private Methods ///////////////////////////////////////////////////////////// size_t Print::printNumber(unsigned long n, uint8_t base) { - char buf[8 * sizeof(long) + 1]; // Assumes 8-bit chars plus zero byte. - char *str = &buf[sizeof(buf) - 1]; + char buf[8 * sizeof(long) + 1]; // Assumes 8-bit chars plus zero byte. + char *str = &buf[sizeof(buf) - 1]; - *str = '\0'; + *str = '\0'; - // prevent crash if called with base == 1 - if (base < 2) - base = 10; + // prevent crash if called with base == 1 + if (base < 2) + base = 10; - do - { - char c = n % base; - n /= base; + do + { + char c = n % base; + n /= base; - *--str = c < 10 ? c + '0' : c + 'A' - 10; - } while (n); + *--str = c < 10 ? c + '0' : c + 'A' - 10; + } while (n); - return write(str); + return write(str); } // REFERENCE IMPLEMENTATION FOR ULL @@ -315,152 +315,152 @@ size_t Print::printNumber(unsigned long n, uint8_t base) // FAST IMPLEMENTATION FOR ULL size_t Print::printULLNumber(unsigned long long n64, uint8_t base) { - // if limited to base 10 and 16 the bufsize can be 20 - char buf[64]; - uint8_t i = 0; - uint8_t innerLoops = 0; + // if limited to base 10 and 16 the bufsize can be 20 + char buf[64]; + uint8_t i = 0; + uint8_t innerLoops = 0; - // prevent crash if called with base == 1 - if (base < 2) - base = 10; + // prevent crash if called with base == 1 + if (base < 2) + base = 10; - // process chunks that fit in "16 bit math". - uint16_t top = 0xFFFF / base; - uint16_t th16 = 1; + // process chunks that fit in "16 bit math". + uint16_t top = 0xFFFF / base; + uint16_t th16 = 1; - while (th16 < top) - { - th16 *= base; - innerLoops++; - } + while (th16 < top) + { + th16 *= base; + innerLoops++; + } - while (n64 > th16) - { - // 64 bit math part - uint64_t q = n64 / th16; - uint16_t r = n64 - q * th16; - n64 = q; + while (n64 > th16) + { + // 64 bit math part + uint64_t q = n64 / th16; + uint16_t r = n64 - q * th16; + n64 = q; - // 16 bit math loop to do remainder. (note buffer is filled reverse) - for (uint8_t j = 0; j < innerLoops; j++) - { - uint16_t qq = r / base; - buf[i++] = r - qq * base; - r = qq; - } - } + // 16 bit math loop to do remainder. (note buffer is filled reverse) + for (uint8_t j = 0; j < innerLoops; j++) + { + uint16_t qq = r / base; + buf[i++] = r - qq * base; + r = qq; + } + } - uint16_t n16 = n64; + uint16_t n16 = n64; - while (n16 > 0) - { - uint16_t qq = n16 / base; - buf[i++] = n16 - qq * base; - n16 = qq; - } + while (n16 > 0) + { + uint16_t qq = n16 / base; + buf[i++] = n16 - qq * base; + n16 = qq; + } - size_t bytes = i; + size_t bytes = i; - for (; i > 0; i--) - write((char) (buf[i - 1] < 10 ? - '0' + buf[i - 1] : - 'A' + buf[i - 1] - 10)); + for (; i > 0; i--) + write((char) (buf[i - 1] < 10 ? + '0' + buf[i - 1] : + 'A' + buf[i - 1] - 10)); - return bytes; + return bytes; } size_t Print::printFloat(double number, int digits) { - if (digits < 0) - digits = 2; + if (digits < 0) + digits = 2; - size_t n = 0; + size_t n = 0; - if (isnan(number)) - return print("nan"); + if (isnan(number)) + return print("nan"); - if (isinf(number)) - return print("inf"); + if (isinf(number)) + return print("inf"); - if (number > 4294967040.0) - return print ("ovf"); // constant determined empirically + if (number > 4294967040.0) + return print ("ovf"); // constant determined empirically - if (number < -4294967040.0) - return print ("ovf"); // constant determined empirically + if (number < -4294967040.0) + return print ("ovf"); // constant determined empirically - // Handle negative numbers - if (number < 0.0) - { - n += print('-'); - number = -number; - } + // Handle negative numbers + if (number < 0.0) + { + n += print('-'); + number = -number; + } - // Round correctly so that print(1.999, 2) prints as "2.00" - double rounding = 0.5; + // Round correctly so that print(1.999, 2) prints as "2.00" + double rounding = 0.5; - for (uint8_t i = 0; i < digits; ++i) - rounding /= 10.0; + for (uint8_t i = 0; i < digits; ++i) + rounding /= 10.0; - number += rounding; + number += rounding; - // Extract the integer part of the number and print it - unsigned long int_part = (unsigned long)number; - double remainder = number - (double)int_part; - n += print(int_part); + // Extract the integer part of the number and print it + unsigned long int_part = (unsigned long)number; + double remainder = number - (double)int_part; + n += print(int_part); - // Print the decimal point, but only if there are digits beyond - if (digits > 0) - { - n += print("."); - } + // Print the decimal point, but only if there are digits beyond + if (digits > 0) + { + n += print("."); + } - // Extract digits from the remainder one at a time - while (digits-- > 0) - { - remainder *= 10.0; - unsigned int toPrint = (unsigned int)remainder; - n += print(toPrint); - remainder -= toPrint; - } + // Extract digits from the remainder one at a time + while (digits-- > 0) + { + remainder *= 10.0; + unsigned int toPrint = (unsigned int)remainder; + n += print(toPrint); + remainder -= toPrint; + } - return n; + return n; } size_t Print::printBuffer(uint8_t const buffer[], int len, char delim, int byteline) { - if (buffer == NULL || len == 0) - return 0; + if (buffer == NULL || len == 0) + return 0; - for (int i = 0; i < len; i++) - { - if ( i != 0 ) - print(delim); + for (int i = 0; i < len; i++) + { + if ( i != 0 ) + print(delim); - if ( byteline && (i % byteline == 0) ) - println(); + if ( byteline && (i % byteline == 0) ) + println(); - this->printf("%02X", buffer[i]); - } + this->printf("%02X", buffer[i]); + } - return (len * 3 - 1); + return (len * 3 - 1); } size_t Print::printBufferReverse(uint8_t const buffer[], int len, char delim, int byteline) { - if (buffer == NULL || len == 0) - return 0; + if (buffer == NULL || len == 0) + return 0; - for (int i = 0; i < len; i++) - { - if (i != 0) - print(delim); + for (int i = 0; i < len; i++) + { + if (i != 0) + print(delim); - if ( byteline && (i % byteline == 0) ) - println(); + if ( byteline && (i % byteline == 0) ) + println(); - this->printf("%02X", buffer[len - 1 - i]); - } + this->printf("%02X", buffer[len - 1 - i]); + } - return (len * 3 - 1); + return (len * 3 - 1); } diff --git a/Packages_Patches/Seeeduino/hardware/samd/1.7.7/cores/arduino/Print.h b/Packages_Patches/Seeeduino/hardware/samd/1.7.7/cores/arduino/Print.h index a465eddb..d03d1cc8 100644 --- a/Packages_Patches/Seeeduino/hardware/samd/1.7.7/cores/arduino/Print.h +++ b/Packages_Patches/Seeeduino/hardware/samd/1.7.7/cores/arduino/Print.h @@ -20,7 +20,6 @@ #include #include // for size_t -#include // for printf #include "WString.h" #include "Printable.h" @@ -32,93 +31,93 @@ class Print { - private: - int write_error; - size_t printNumber(unsigned long, uint8_t); - size_t printULLNumber(unsigned long long, uint8_t); - size_t printFloat(double, int); - protected: - void setWriteError(int err = 1) - { - write_error = err; - } - public: - Print() : write_error(0) {} - - int getWriteError() - { - return write_error; - } - void clearWriteError() - { - setWriteError(0); - } - - virtual size_t write(uint8_t) = 0; - size_t write(const char *str) - { - if (str == NULL) - return 0; - - return write((const uint8_t *)str, strlen(str)); - } - virtual size_t write(const uint8_t *buffer, size_t size); - size_t write(const char *buffer, size_t size) - { - return write((const uint8_t *)buffer, size); - } - - // default to zero, meaning "a single write may block" - // should be overridden by subclasses with buffering - virtual int availableForWrite() - { - return 0; - } - - size_t print(const __FlashStringHelper *); - size_t print(const String &); - size_t print(const char[]); - size_t print(char); - size_t print(unsigned char, int = DEC); - size_t print(int, int = DEC); - size_t print(unsigned int, int = DEC); - size_t print(long, int = DEC); - size_t print(unsigned long, int = DEC); - size_t print(long long, int = DEC); - size_t print(unsigned long long, int = DEC); - size_t print(double, int = 2); - size_t print(const Printable&); - - size_t println(const __FlashStringHelper *); - size_t println(const String &s); - size_t println(const char[]); - size_t println(char); - size_t println(unsigned char, int = DEC); - size_t println(int, int = DEC); - size_t println(unsigned int, int = DEC); - size_t println(long, int = DEC); - size_t println(unsigned long, int = DEC); - size_t println(long long, int = DEC); - size_t println(unsigned long long, int = DEC); - size_t println(double, int = 2); - size_t println(const Printable&); - size_t println(void); - - size_t printf(const char * format, ...); - - size_t printBuffer(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); - size_t printBuffer(char const buffer[], int size, char delim = ' ', int byteline = 0) - { - return printBuffer((uint8_t const*) buffer, size, delim, byteline); - } - - size_t printBufferReverse(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); - size_t printBufferReverse(char const buffer[], int size, char delim = ' ', int byteline = 0) - { - return printBufferReverse((uint8_t const*) buffer, size, delim, byteline); - } - - virtual void flush() { /* Empty implementation for backward compatibility */ } + private: + int write_error; + size_t printNumber(unsigned long, uint8_t); + size_t printULLNumber(unsigned long long, uint8_t); + size_t printFloat(double, int); + protected: + void setWriteError(int err = 1) + { + write_error = err; + } + public: + Print() : write_error(0) {} + + int getWriteError() + { + return write_error; + } + void clearWriteError() + { + setWriteError(0); + } + + virtual size_t write(uint8_t) = 0; + size_t write(const char *str) + { + if (str == NULL) + return 0; + + return write((const uint8_t *)str, strlen(str)); + } + virtual size_t write(const uint8_t *buffer, size_t size); + size_t write(const char *buffer, size_t size) + { + return write((const uint8_t *)buffer, size); + } + + // default to zero, meaning "a single write may block" + // should be overridden by subclasses with buffering + virtual int availableForWrite() + { + return 0; + } + + size_t print(const __FlashStringHelper *); + size_t print(const String &); + size_t print(const char[]); + size_t print(char); + size_t print(unsigned char, int = DEC); + size_t print(int, int = DEC); + size_t print(unsigned int, int = DEC); + size_t print(long, int = DEC); + size_t print(unsigned long, int = DEC); + size_t print(long long, int = DEC); + size_t print(unsigned long long, int = DEC); + size_t print(double, int = 2); + size_t print(const Printable&); + + size_t println(const __FlashStringHelper *); + size_t println(const String &s); + size_t println(const char[]); + size_t println(char); + size_t println(unsigned char, int = DEC); + size_t println(int, int = DEC); + size_t println(unsigned int, int = DEC); + size_t println(long, int = DEC); + size_t println(unsigned long, int = DEC); + size_t println(long long, int = DEC); + size_t println(unsigned long long, int = DEC); + size_t println(double, int = 2); + size_t println(const Printable&); + size_t println(void); + + size_t printf(const char * format, ...); + + size_t printBuffer(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); + size_t printBuffer(char const buffer[], int size, char delim = ' ', int byteline = 0) + { + return printBuffer((uint8_t const*) buffer, size, delim, byteline); + } + + size_t printBufferReverse(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); + size_t printBufferReverse(char const buffer[], int size, char delim = ' ', int byteline = 0) + { + return printBufferReverse((uint8_t const*) buffer, size, delim, byteline); + } + + virtual void flush() { /* Empty implementation for backward compatibility */ } }; diff --git a/Packages_Patches/Seeeduino/hardware/samd/1.7.8/cores/arduino/Arduino.h b/Packages_Patches/Seeeduino/hardware/samd/1.7.8/cores/arduino/Arduino.h index 51db668f..c68bc8b6 100644 --- a/Packages_Patches/Seeeduino/hardware/samd/1.7.8/cores/arduino/Arduino.h +++ b/Packages_Patches/Seeeduino/hardware/samd/1.7.8/cores/arduino/Arduino.h @@ -76,16 +76,16 @@ int __debug_buf(const char* head, char* buf, int len); // The following headers are for C++ only compilation #ifdef __cplusplus - #include "WCharacter.h" - #include "WString.h" - #include "Tone.h" - #include "WMath.h" - #include "HardwareSerial.h" - #include "pulse.h" + #include "WCharacter.h" + #include "WString.h" + #include "Tone.h" + #include "WMath.h" + #include "HardwareSerial.h" + #include "pulse.h" #endif #include "delay.h" #ifdef __cplusplus - #include "Uart.h" + #include "Uart.h" #endif // Include board variant @@ -100,24 +100,24 @@ int __debug_buf(const char* head, char* buf, int len); // undefine stdlib's abs if encountered #ifdef abs - #undef abs + #undef abs #endif // abs // undefine stdlib's abs if encountered #ifdef abs - #undef abs + #undef abs #endif // abs #ifdef __cplusplus template auto min(const T& a, const L& b) -> decltype((b < a) ? b : a) { - return (b < a) ? b : a; + return (b < a) ? b : a; } template auto max(const T& a, const L& b) -> decltype((b < a) ? b : a) { - return (a < b) ? b : a; + return (a < b) ? b : a; } #else #ifndef min @@ -147,8 +147,8 @@ auto max(const T& a, const L& b) -> decltype((b < a) ? b : a) static inline unsigned char __interruptsStatus(void) __attribute__((always_inline, unused)); static inline unsigned char __interruptsStatus(void) { - // See http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0497a/CHDBIBGJ.html - return (__get_PRIMASK() ? 0 : 1); + // See http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0497a/CHDBIBGJ.html + return (__get_PRIMASK() ? 0 : 1); } #define interruptsStatus() __interruptsStatus() #endif @@ -164,18 +164,18 @@ static inline unsigned char __interruptsStatus(void) #define bit(b) (1UL << (b)) #if (ARDUINO_SAMD_VARIANT_COMPLIANCE >= 10606) - // Interrupts - #define digitalPinToInterrupt(P) ( P ) + // Interrupts + #define digitalPinToInterrupt(P) ( P ) #endif // USB #ifdef USE_TINYUSB - #include "Adafruit_TinyUSB_Core.h" + #include "Adafruit_TinyUSB_Core.h" #else - #include "USB/USBDesc.h" - #include "USB/USBCore.h" - #include "USB/USBAPI.h" - #include "USB/USB_host.h" + #include "USB/USBDesc.h" + #include "USB/USBCore.h" + #include "USB/USBAPI.h" + #include "USB/USB_host.h" #endif #endif // Arduino_h diff --git a/Packages_Patches/Seeeduino/hardware/samd/1.7.8/cores/arduino/Print.cpp b/Packages_Patches/Seeeduino/hardware/samd/1.7.8/cores/arduino/Print.cpp index b47efa1a..d2db9576 100644 --- a/Packages_Patches/Seeeduino/hardware/samd/1.7.8/cores/arduino/Print.cpp +++ b/Packages_Patches/Seeeduino/hardware/samd/1.7.8/cores/arduino/Print.cpp @@ -35,259 +35,259 @@ /* default implementation: may be overridden */ size_t Print::write(const uint8_t *buffer, size_t size) { - size_t n = 0; + size_t n = 0; - while (size--) - { - if (write(*buffer++)) - n++; - else - break; - } + while (size--) + { + if (write(*buffer++)) + n++; + else + break; + } - return n; + return n; } size_t Print::print(const __FlashStringHelper *ifsh) { - return print(reinterpret_cast(ifsh)); + return print(reinterpret_cast(ifsh)); } size_t Print::print(const String &s) { - return write(s.c_str(), s.length()); + return write(s.c_str(), s.length()); } size_t Print::print(const char str[]) { - return write(str); + return write(str); } size_t Print::print(char c) { - return write(c); + return write(c); } size_t Print::print(unsigned char b, int base) { - return print((unsigned long) b, base); + return print((unsigned long) b, base); } size_t Print::print(int n, int base) { - return print((long) n, base); + return print((long) n, base); } size_t Print::print(unsigned int n, int base) { - return print((unsigned long) n, base); + return print((unsigned long) n, base); } size_t Print::print(long n, int base) { - if (base == 0) - { - return write(n); - } - else if (base == 10) - { - if (n < 0) - { - int t = print('-'); - n = -n; - return printNumber(n, 10) + t; - } - - return printNumber(n, 10); - } - else - { - return printNumber(n, base); - } + if (base == 0) + { + return write(n); + } + else if (base == 10) + { + if (n < 0) + { + int t = print('-'); + n = -n; + return printNumber(n, 10) + t; + } + + return printNumber(n, 10); + } + else + { + return printNumber(n, base); + } } size_t Print::print(unsigned long n, int base) { - if (base == 0) - return write(n); - else - return printNumber(n, base); + if (base == 0) + return write(n); + else + return printNumber(n, base); } size_t Print::print(long long n, int base) { - if (base == 0) - { - return write(n); - } - else if (base == 10) - { - if (n < 0) - { - int t = print('-'); - n = -n; - return printULLNumber(n, 10) + t; - } - - return printULLNumber(n, 10); - } - else - { - return printULLNumber(n, base); - } + if (base == 0) + { + return write(n); + } + else if (base == 10) + { + if (n < 0) + { + int t = print('-'); + n = -n; + return printULLNumber(n, 10) + t; + } + + return printULLNumber(n, 10); + } + else + { + return printULLNumber(n, base); + } } size_t Print::print(unsigned long long n, int base) { - if (base == 0) - return write(n); - else - return printULLNumber(n, base); + if (base == 0) + return write(n); + else + return printULLNumber(n, base); } size_t Print::print(double n, int digits) { - return printFloat(n, digits); + return printFloat(n, digits); } size_t Print::println(const __FlashStringHelper *ifsh) { - size_t n = print(ifsh); - n += println(); - return n; + size_t n = print(ifsh); + n += println(); + return n; } size_t Print::print(const Printable& x) { - return x.printTo(*this); + return x.printTo(*this); } size_t Print::println(void) { - return write("\r\n"); + return write("\r\n"); } size_t Print::println(const String &s) { - size_t n = print(s); - n += println(); - return n; + size_t n = print(s); + n += println(); + return n; } size_t Print::println(const char c[]) { - size_t n = print(c); - n += println(); - return n; + size_t n = print(c); + n += println(); + return n; } size_t Print::println(char c) { - size_t n = print(c); - n += println(); - return n; + size_t n = print(c); + n += println(); + return n; } size_t Print::println(unsigned char b, int base) { - size_t n = print(b, base); - n += println(); - return n; + size_t n = print(b, base); + n += println(); + return n; } size_t Print::println(int num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned int num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(long long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned long long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(double num, int digits) { - size_t n = print(num, digits); - n += println(); - return n; + size_t n = print(num, digits); + n += println(); + return n; } size_t Print::println(const Printable& x) { - size_t n = print(x); - n += println(); - return n; + size_t n = print(x); + n += println(); + return n; } size_t Print::printf(const char * format, ...) { - char buf[256]; - int len; + char buf[256]; + int len; - va_list ap; - va_start(ap, format); + va_list ap; + va_start(ap, format); - len = vsnprintf(buf, 256, format, ap); - this->write(buf, len); + len = vsnprintf(buf, 256, format, ap); + this->write(buf, len); - va_end(ap); - return len; + va_end(ap); + return len; } // Private Methods ///////////////////////////////////////////////////////////// size_t Print::printNumber(unsigned long n, uint8_t base) { - char buf[8 * sizeof(long) + 1]; // Assumes 8-bit chars plus zero byte. - char *str = &buf[sizeof(buf) - 1]; + char buf[8 * sizeof(long) + 1]; // Assumes 8-bit chars plus zero byte. + char *str = &buf[sizeof(buf) - 1]; - *str = '\0'; + *str = '\0'; - // prevent crash if called with base == 1 - if (base < 2) - base = 10; + // prevent crash if called with base == 1 + if (base < 2) + base = 10; - do - { - char c = n % base; - n /= base; + do + { + char c = n % base; + n /= base; - *--str = c < 10 ? c + '0' : c + 'A' - 10; - } while (n); + *--str = c < 10 ? c + '0' : c + 'A' - 10; + } while (n); - return write(str); + return write(str); } // REFERENCE IMPLEMENTATION FOR ULL @@ -315,152 +315,152 @@ size_t Print::printNumber(unsigned long n, uint8_t base) // FAST IMPLEMENTATION FOR ULL size_t Print::printULLNumber(unsigned long long n64, uint8_t base) { - // if limited to base 10 and 16 the bufsize can be 20 - char buf[64]; - uint8_t i = 0; - uint8_t innerLoops = 0; + // if limited to base 10 and 16 the bufsize can be 20 + char buf[64]; + uint8_t i = 0; + uint8_t innerLoops = 0; - // prevent crash if called with base == 1 - if (base < 2) - base = 10; + // prevent crash if called with base == 1 + if (base < 2) + base = 10; - // process chunks that fit in "16 bit math". - uint16_t top = 0xFFFF / base; - uint16_t th16 = 1; + // process chunks that fit in "16 bit math". + uint16_t top = 0xFFFF / base; + uint16_t th16 = 1; - while (th16 < top) - { - th16 *= base; - innerLoops++; - } + while (th16 < top) + { + th16 *= base; + innerLoops++; + } - while (n64 > th16) - { - // 64 bit math part - uint64_t q = n64 / th16; - uint16_t r = n64 - q * th16; - n64 = q; + while (n64 > th16) + { + // 64 bit math part + uint64_t q = n64 / th16; + uint16_t r = n64 - q * th16; + n64 = q; - // 16 bit math loop to do remainder. (note buffer is filled reverse) - for (uint8_t j = 0; j < innerLoops; j++) - { - uint16_t qq = r / base; - buf[i++] = r - qq * base; - r = qq; - } - } + // 16 bit math loop to do remainder. (note buffer is filled reverse) + for (uint8_t j = 0; j < innerLoops; j++) + { + uint16_t qq = r / base; + buf[i++] = r - qq * base; + r = qq; + } + } - uint16_t n16 = n64; + uint16_t n16 = n64; - while (n16 > 0) - { - uint16_t qq = n16 / base; - buf[i++] = n16 - qq * base; - n16 = qq; - } + while (n16 > 0) + { + uint16_t qq = n16 / base; + buf[i++] = n16 - qq * base; + n16 = qq; + } - size_t bytes = i; + size_t bytes = i; - for (; i > 0; i--) - write((char) (buf[i - 1] < 10 ? - '0' + buf[i - 1] : - 'A' + buf[i - 1] - 10)); + for (; i > 0; i--) + write((char) (buf[i - 1] < 10 ? + '0' + buf[i - 1] : + 'A' + buf[i - 1] - 10)); - return bytes; + return bytes; } size_t Print::printFloat(double number, int digits) { - if (digits < 0) - digits = 2; + if (digits < 0) + digits = 2; - size_t n = 0; + size_t n = 0; - if (isnan(number)) - return print("nan"); + if (isnan(number)) + return print("nan"); - if (isinf(number)) - return print("inf"); + if (isinf(number)) + return print("inf"); - if (number > 4294967040.0) - return print ("ovf"); // constant determined empirically + if (number > 4294967040.0) + return print ("ovf"); // constant determined empirically - if (number < -4294967040.0) - return print ("ovf"); // constant determined empirically + if (number < -4294967040.0) + return print ("ovf"); // constant determined empirically - // Handle negative numbers - if (number < 0.0) - { - n += print('-'); - number = -number; - } + // Handle negative numbers + if (number < 0.0) + { + n += print('-'); + number = -number; + } - // Round correctly so that print(1.999, 2) prints as "2.00" - double rounding = 0.5; + // Round correctly so that print(1.999, 2) prints as "2.00" + double rounding = 0.5; - for (uint8_t i = 0; i < digits; ++i) - rounding /= 10.0; + for (uint8_t i = 0; i < digits; ++i) + rounding /= 10.0; - number += rounding; + number += rounding; - // Extract the integer part of the number and print it - unsigned long int_part = (unsigned long)number; - double remainder = number - (double)int_part; - n += print(int_part); + // Extract the integer part of the number and print it + unsigned long int_part = (unsigned long)number; + double remainder = number - (double)int_part; + n += print(int_part); - // Print the decimal point, but only if there are digits beyond - if (digits > 0) - { - n += print("."); - } + // Print the decimal point, but only if there are digits beyond + if (digits > 0) + { + n += print("."); + } - // Extract digits from the remainder one at a time - while (digits-- > 0) - { - remainder *= 10.0; - unsigned int toPrint = (unsigned int)remainder; - n += print(toPrint); - remainder -= toPrint; - } + // Extract digits from the remainder one at a time + while (digits-- > 0) + { + remainder *= 10.0; + unsigned int toPrint = (unsigned int)remainder; + n += print(toPrint); + remainder -= toPrint; + } - return n; + return n; } size_t Print::printBuffer(uint8_t const buffer[], int len, char delim, int byteline) { - if (buffer == NULL || len == 0) - return 0; + if (buffer == NULL || len == 0) + return 0; - for (int i = 0; i < len; i++) - { - if ( i != 0 ) - print(delim); + for (int i = 0; i < len; i++) + { + if ( i != 0 ) + print(delim); - if ( byteline && (i % byteline == 0) ) - println(); + if ( byteline && (i % byteline == 0) ) + println(); - this->printf("%02X", buffer[i]); - } + this->printf("%02X", buffer[i]); + } - return (len * 3 - 1); + return (len * 3 - 1); } size_t Print::printBufferReverse(uint8_t const buffer[], int len, char delim, int byteline) { - if (buffer == NULL || len == 0) - return 0; + if (buffer == NULL || len == 0) + return 0; - for (int i = 0; i < len; i++) - { - if (i != 0) - print(delim); + for (int i = 0; i < len; i++) + { + if (i != 0) + print(delim); - if ( byteline && (i % byteline == 0) ) - println(); + if ( byteline && (i % byteline == 0) ) + println(); - this->printf("%02X", buffer[len - 1 - i]); - } + this->printf("%02X", buffer[len - 1 - i]); + } - return (len * 3 - 1); + return (len * 3 - 1); } diff --git a/Packages_Patches/Seeeduino/hardware/samd/1.7.8/cores/arduino/Print.h b/Packages_Patches/Seeeduino/hardware/samd/1.7.8/cores/arduino/Print.h index a465eddb..d03d1cc8 100644 --- a/Packages_Patches/Seeeduino/hardware/samd/1.7.8/cores/arduino/Print.h +++ b/Packages_Patches/Seeeduino/hardware/samd/1.7.8/cores/arduino/Print.h @@ -20,7 +20,6 @@ #include #include // for size_t -#include // for printf #include "WString.h" #include "Printable.h" @@ -32,93 +31,93 @@ class Print { - private: - int write_error; - size_t printNumber(unsigned long, uint8_t); - size_t printULLNumber(unsigned long long, uint8_t); - size_t printFloat(double, int); - protected: - void setWriteError(int err = 1) - { - write_error = err; - } - public: - Print() : write_error(0) {} - - int getWriteError() - { - return write_error; - } - void clearWriteError() - { - setWriteError(0); - } - - virtual size_t write(uint8_t) = 0; - size_t write(const char *str) - { - if (str == NULL) - return 0; - - return write((const uint8_t *)str, strlen(str)); - } - virtual size_t write(const uint8_t *buffer, size_t size); - size_t write(const char *buffer, size_t size) - { - return write((const uint8_t *)buffer, size); - } - - // default to zero, meaning "a single write may block" - // should be overridden by subclasses with buffering - virtual int availableForWrite() - { - return 0; - } - - size_t print(const __FlashStringHelper *); - size_t print(const String &); - size_t print(const char[]); - size_t print(char); - size_t print(unsigned char, int = DEC); - size_t print(int, int = DEC); - size_t print(unsigned int, int = DEC); - size_t print(long, int = DEC); - size_t print(unsigned long, int = DEC); - size_t print(long long, int = DEC); - size_t print(unsigned long long, int = DEC); - size_t print(double, int = 2); - size_t print(const Printable&); - - size_t println(const __FlashStringHelper *); - size_t println(const String &s); - size_t println(const char[]); - size_t println(char); - size_t println(unsigned char, int = DEC); - size_t println(int, int = DEC); - size_t println(unsigned int, int = DEC); - size_t println(long, int = DEC); - size_t println(unsigned long, int = DEC); - size_t println(long long, int = DEC); - size_t println(unsigned long long, int = DEC); - size_t println(double, int = 2); - size_t println(const Printable&); - size_t println(void); - - size_t printf(const char * format, ...); - - size_t printBuffer(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); - size_t printBuffer(char const buffer[], int size, char delim = ' ', int byteline = 0) - { - return printBuffer((uint8_t const*) buffer, size, delim, byteline); - } - - size_t printBufferReverse(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); - size_t printBufferReverse(char const buffer[], int size, char delim = ' ', int byteline = 0) - { - return printBufferReverse((uint8_t const*) buffer, size, delim, byteline); - } - - virtual void flush() { /* Empty implementation for backward compatibility */ } + private: + int write_error; + size_t printNumber(unsigned long, uint8_t); + size_t printULLNumber(unsigned long long, uint8_t); + size_t printFloat(double, int); + protected: + void setWriteError(int err = 1) + { + write_error = err; + } + public: + Print() : write_error(0) {} + + int getWriteError() + { + return write_error; + } + void clearWriteError() + { + setWriteError(0); + } + + virtual size_t write(uint8_t) = 0; + size_t write(const char *str) + { + if (str == NULL) + return 0; + + return write((const uint8_t *)str, strlen(str)); + } + virtual size_t write(const uint8_t *buffer, size_t size); + size_t write(const char *buffer, size_t size) + { + return write((const uint8_t *)buffer, size); + } + + // default to zero, meaning "a single write may block" + // should be overridden by subclasses with buffering + virtual int availableForWrite() + { + return 0; + } + + size_t print(const __FlashStringHelper *); + size_t print(const String &); + size_t print(const char[]); + size_t print(char); + size_t print(unsigned char, int = DEC); + size_t print(int, int = DEC); + size_t print(unsigned int, int = DEC); + size_t print(long, int = DEC); + size_t print(unsigned long, int = DEC); + size_t print(long long, int = DEC); + size_t print(unsigned long long, int = DEC); + size_t print(double, int = 2); + size_t print(const Printable&); + + size_t println(const __FlashStringHelper *); + size_t println(const String &s); + size_t println(const char[]); + size_t println(char); + size_t println(unsigned char, int = DEC); + size_t println(int, int = DEC); + size_t println(unsigned int, int = DEC); + size_t println(long, int = DEC); + size_t println(unsigned long, int = DEC); + size_t println(long long, int = DEC); + size_t println(unsigned long long, int = DEC); + size_t println(double, int = 2); + size_t println(const Printable&); + size_t println(void); + + size_t printf(const char * format, ...); + + size_t printBuffer(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); + size_t printBuffer(char const buffer[], int size, char delim = ' ', int byteline = 0) + { + return printBuffer((uint8_t const*) buffer, size, delim, byteline); + } + + size_t printBufferReverse(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); + size_t printBufferReverse(char const buffer[], int size, char delim = ' ', int byteline = 0) + { + return printBufferReverse((uint8_t const*) buffer, size, delim, byteline); + } + + virtual void flush() { /* Empty implementation for backward compatibility */ } }; diff --git a/Packages_Patches/Seeeduino/hardware/samd/1.7.9/cores/arduino/Arduino.h b/Packages_Patches/Seeeduino/hardware/samd/1.7.9/cores/arduino/Arduino.h index 51db668f..c68bc8b6 100644 --- a/Packages_Patches/Seeeduino/hardware/samd/1.7.9/cores/arduino/Arduino.h +++ b/Packages_Patches/Seeeduino/hardware/samd/1.7.9/cores/arduino/Arduino.h @@ -76,16 +76,16 @@ int __debug_buf(const char* head, char* buf, int len); // The following headers are for C++ only compilation #ifdef __cplusplus - #include "WCharacter.h" - #include "WString.h" - #include "Tone.h" - #include "WMath.h" - #include "HardwareSerial.h" - #include "pulse.h" + #include "WCharacter.h" + #include "WString.h" + #include "Tone.h" + #include "WMath.h" + #include "HardwareSerial.h" + #include "pulse.h" #endif #include "delay.h" #ifdef __cplusplus - #include "Uart.h" + #include "Uart.h" #endif // Include board variant @@ -100,24 +100,24 @@ int __debug_buf(const char* head, char* buf, int len); // undefine stdlib's abs if encountered #ifdef abs - #undef abs + #undef abs #endif // abs // undefine stdlib's abs if encountered #ifdef abs - #undef abs + #undef abs #endif // abs #ifdef __cplusplus template auto min(const T& a, const L& b) -> decltype((b < a) ? b : a) { - return (b < a) ? b : a; + return (b < a) ? b : a; } template auto max(const T& a, const L& b) -> decltype((b < a) ? b : a) { - return (a < b) ? b : a; + return (a < b) ? b : a; } #else #ifndef min @@ -147,8 +147,8 @@ auto max(const T& a, const L& b) -> decltype((b < a) ? b : a) static inline unsigned char __interruptsStatus(void) __attribute__((always_inline, unused)); static inline unsigned char __interruptsStatus(void) { - // See http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0497a/CHDBIBGJ.html - return (__get_PRIMASK() ? 0 : 1); + // See http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0497a/CHDBIBGJ.html + return (__get_PRIMASK() ? 0 : 1); } #define interruptsStatus() __interruptsStatus() #endif @@ -164,18 +164,18 @@ static inline unsigned char __interruptsStatus(void) #define bit(b) (1UL << (b)) #if (ARDUINO_SAMD_VARIANT_COMPLIANCE >= 10606) - // Interrupts - #define digitalPinToInterrupt(P) ( P ) + // Interrupts + #define digitalPinToInterrupt(P) ( P ) #endif // USB #ifdef USE_TINYUSB - #include "Adafruit_TinyUSB_Core.h" + #include "Adafruit_TinyUSB_Core.h" #else - #include "USB/USBDesc.h" - #include "USB/USBCore.h" - #include "USB/USBAPI.h" - #include "USB/USB_host.h" + #include "USB/USBDesc.h" + #include "USB/USBCore.h" + #include "USB/USBAPI.h" + #include "USB/USB_host.h" #endif #endif // Arduino_h diff --git a/Packages_Patches/Seeeduino/hardware/samd/1.7.9/cores/arduino/Print.cpp b/Packages_Patches/Seeeduino/hardware/samd/1.7.9/cores/arduino/Print.cpp index b47efa1a..d2db9576 100644 --- a/Packages_Patches/Seeeduino/hardware/samd/1.7.9/cores/arduino/Print.cpp +++ b/Packages_Patches/Seeeduino/hardware/samd/1.7.9/cores/arduino/Print.cpp @@ -35,259 +35,259 @@ /* default implementation: may be overridden */ size_t Print::write(const uint8_t *buffer, size_t size) { - size_t n = 0; + size_t n = 0; - while (size--) - { - if (write(*buffer++)) - n++; - else - break; - } + while (size--) + { + if (write(*buffer++)) + n++; + else + break; + } - return n; + return n; } size_t Print::print(const __FlashStringHelper *ifsh) { - return print(reinterpret_cast(ifsh)); + return print(reinterpret_cast(ifsh)); } size_t Print::print(const String &s) { - return write(s.c_str(), s.length()); + return write(s.c_str(), s.length()); } size_t Print::print(const char str[]) { - return write(str); + return write(str); } size_t Print::print(char c) { - return write(c); + return write(c); } size_t Print::print(unsigned char b, int base) { - return print((unsigned long) b, base); + return print((unsigned long) b, base); } size_t Print::print(int n, int base) { - return print((long) n, base); + return print((long) n, base); } size_t Print::print(unsigned int n, int base) { - return print((unsigned long) n, base); + return print((unsigned long) n, base); } size_t Print::print(long n, int base) { - if (base == 0) - { - return write(n); - } - else if (base == 10) - { - if (n < 0) - { - int t = print('-'); - n = -n; - return printNumber(n, 10) + t; - } - - return printNumber(n, 10); - } - else - { - return printNumber(n, base); - } + if (base == 0) + { + return write(n); + } + else if (base == 10) + { + if (n < 0) + { + int t = print('-'); + n = -n; + return printNumber(n, 10) + t; + } + + return printNumber(n, 10); + } + else + { + return printNumber(n, base); + } } size_t Print::print(unsigned long n, int base) { - if (base == 0) - return write(n); - else - return printNumber(n, base); + if (base == 0) + return write(n); + else + return printNumber(n, base); } size_t Print::print(long long n, int base) { - if (base == 0) - { - return write(n); - } - else if (base == 10) - { - if (n < 0) - { - int t = print('-'); - n = -n; - return printULLNumber(n, 10) + t; - } - - return printULLNumber(n, 10); - } - else - { - return printULLNumber(n, base); - } + if (base == 0) + { + return write(n); + } + else if (base == 10) + { + if (n < 0) + { + int t = print('-'); + n = -n; + return printULLNumber(n, 10) + t; + } + + return printULLNumber(n, 10); + } + else + { + return printULLNumber(n, base); + } } size_t Print::print(unsigned long long n, int base) { - if (base == 0) - return write(n); - else - return printULLNumber(n, base); + if (base == 0) + return write(n); + else + return printULLNumber(n, base); } size_t Print::print(double n, int digits) { - return printFloat(n, digits); + return printFloat(n, digits); } size_t Print::println(const __FlashStringHelper *ifsh) { - size_t n = print(ifsh); - n += println(); - return n; + size_t n = print(ifsh); + n += println(); + return n; } size_t Print::print(const Printable& x) { - return x.printTo(*this); + return x.printTo(*this); } size_t Print::println(void) { - return write("\r\n"); + return write("\r\n"); } size_t Print::println(const String &s) { - size_t n = print(s); - n += println(); - return n; + size_t n = print(s); + n += println(); + return n; } size_t Print::println(const char c[]) { - size_t n = print(c); - n += println(); - return n; + size_t n = print(c); + n += println(); + return n; } size_t Print::println(char c) { - size_t n = print(c); - n += println(); - return n; + size_t n = print(c); + n += println(); + return n; } size_t Print::println(unsigned char b, int base) { - size_t n = print(b, base); - n += println(); - return n; + size_t n = print(b, base); + n += println(); + return n; } size_t Print::println(int num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned int num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(long long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned long long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(double num, int digits) { - size_t n = print(num, digits); - n += println(); - return n; + size_t n = print(num, digits); + n += println(); + return n; } size_t Print::println(const Printable& x) { - size_t n = print(x); - n += println(); - return n; + size_t n = print(x); + n += println(); + return n; } size_t Print::printf(const char * format, ...) { - char buf[256]; - int len; + char buf[256]; + int len; - va_list ap; - va_start(ap, format); + va_list ap; + va_start(ap, format); - len = vsnprintf(buf, 256, format, ap); - this->write(buf, len); + len = vsnprintf(buf, 256, format, ap); + this->write(buf, len); - va_end(ap); - return len; + va_end(ap); + return len; } // Private Methods ///////////////////////////////////////////////////////////// size_t Print::printNumber(unsigned long n, uint8_t base) { - char buf[8 * sizeof(long) + 1]; // Assumes 8-bit chars plus zero byte. - char *str = &buf[sizeof(buf) - 1]; + char buf[8 * sizeof(long) + 1]; // Assumes 8-bit chars plus zero byte. + char *str = &buf[sizeof(buf) - 1]; - *str = '\0'; + *str = '\0'; - // prevent crash if called with base == 1 - if (base < 2) - base = 10; + // prevent crash if called with base == 1 + if (base < 2) + base = 10; - do - { - char c = n % base; - n /= base; + do + { + char c = n % base; + n /= base; - *--str = c < 10 ? c + '0' : c + 'A' - 10; - } while (n); + *--str = c < 10 ? c + '0' : c + 'A' - 10; + } while (n); - return write(str); + return write(str); } // REFERENCE IMPLEMENTATION FOR ULL @@ -315,152 +315,152 @@ size_t Print::printNumber(unsigned long n, uint8_t base) // FAST IMPLEMENTATION FOR ULL size_t Print::printULLNumber(unsigned long long n64, uint8_t base) { - // if limited to base 10 and 16 the bufsize can be 20 - char buf[64]; - uint8_t i = 0; - uint8_t innerLoops = 0; + // if limited to base 10 and 16 the bufsize can be 20 + char buf[64]; + uint8_t i = 0; + uint8_t innerLoops = 0; - // prevent crash if called with base == 1 - if (base < 2) - base = 10; + // prevent crash if called with base == 1 + if (base < 2) + base = 10; - // process chunks that fit in "16 bit math". - uint16_t top = 0xFFFF / base; - uint16_t th16 = 1; + // process chunks that fit in "16 bit math". + uint16_t top = 0xFFFF / base; + uint16_t th16 = 1; - while (th16 < top) - { - th16 *= base; - innerLoops++; - } + while (th16 < top) + { + th16 *= base; + innerLoops++; + } - while (n64 > th16) - { - // 64 bit math part - uint64_t q = n64 / th16; - uint16_t r = n64 - q * th16; - n64 = q; + while (n64 > th16) + { + // 64 bit math part + uint64_t q = n64 / th16; + uint16_t r = n64 - q * th16; + n64 = q; - // 16 bit math loop to do remainder. (note buffer is filled reverse) - for (uint8_t j = 0; j < innerLoops; j++) - { - uint16_t qq = r / base; - buf[i++] = r - qq * base; - r = qq; - } - } + // 16 bit math loop to do remainder. (note buffer is filled reverse) + for (uint8_t j = 0; j < innerLoops; j++) + { + uint16_t qq = r / base; + buf[i++] = r - qq * base; + r = qq; + } + } - uint16_t n16 = n64; + uint16_t n16 = n64; - while (n16 > 0) - { - uint16_t qq = n16 / base; - buf[i++] = n16 - qq * base; - n16 = qq; - } + while (n16 > 0) + { + uint16_t qq = n16 / base; + buf[i++] = n16 - qq * base; + n16 = qq; + } - size_t bytes = i; + size_t bytes = i; - for (; i > 0; i--) - write((char) (buf[i - 1] < 10 ? - '0' + buf[i - 1] : - 'A' + buf[i - 1] - 10)); + for (; i > 0; i--) + write((char) (buf[i - 1] < 10 ? + '0' + buf[i - 1] : + 'A' + buf[i - 1] - 10)); - return bytes; + return bytes; } size_t Print::printFloat(double number, int digits) { - if (digits < 0) - digits = 2; + if (digits < 0) + digits = 2; - size_t n = 0; + size_t n = 0; - if (isnan(number)) - return print("nan"); + if (isnan(number)) + return print("nan"); - if (isinf(number)) - return print("inf"); + if (isinf(number)) + return print("inf"); - if (number > 4294967040.0) - return print ("ovf"); // constant determined empirically + if (number > 4294967040.0) + return print ("ovf"); // constant determined empirically - if (number < -4294967040.0) - return print ("ovf"); // constant determined empirically + if (number < -4294967040.0) + return print ("ovf"); // constant determined empirically - // Handle negative numbers - if (number < 0.0) - { - n += print('-'); - number = -number; - } + // Handle negative numbers + if (number < 0.0) + { + n += print('-'); + number = -number; + } - // Round correctly so that print(1.999, 2) prints as "2.00" - double rounding = 0.5; + // Round correctly so that print(1.999, 2) prints as "2.00" + double rounding = 0.5; - for (uint8_t i = 0; i < digits; ++i) - rounding /= 10.0; + for (uint8_t i = 0; i < digits; ++i) + rounding /= 10.0; - number += rounding; + number += rounding; - // Extract the integer part of the number and print it - unsigned long int_part = (unsigned long)number; - double remainder = number - (double)int_part; - n += print(int_part); + // Extract the integer part of the number and print it + unsigned long int_part = (unsigned long)number; + double remainder = number - (double)int_part; + n += print(int_part); - // Print the decimal point, but only if there are digits beyond - if (digits > 0) - { - n += print("."); - } + // Print the decimal point, but only if there are digits beyond + if (digits > 0) + { + n += print("."); + } - // Extract digits from the remainder one at a time - while (digits-- > 0) - { - remainder *= 10.0; - unsigned int toPrint = (unsigned int)remainder; - n += print(toPrint); - remainder -= toPrint; - } + // Extract digits from the remainder one at a time + while (digits-- > 0) + { + remainder *= 10.0; + unsigned int toPrint = (unsigned int)remainder; + n += print(toPrint); + remainder -= toPrint; + } - return n; + return n; } size_t Print::printBuffer(uint8_t const buffer[], int len, char delim, int byteline) { - if (buffer == NULL || len == 0) - return 0; + if (buffer == NULL || len == 0) + return 0; - for (int i = 0; i < len; i++) - { - if ( i != 0 ) - print(delim); + for (int i = 0; i < len; i++) + { + if ( i != 0 ) + print(delim); - if ( byteline && (i % byteline == 0) ) - println(); + if ( byteline && (i % byteline == 0) ) + println(); - this->printf("%02X", buffer[i]); - } + this->printf("%02X", buffer[i]); + } - return (len * 3 - 1); + return (len * 3 - 1); } size_t Print::printBufferReverse(uint8_t const buffer[], int len, char delim, int byteline) { - if (buffer == NULL || len == 0) - return 0; + if (buffer == NULL || len == 0) + return 0; - for (int i = 0; i < len; i++) - { - if (i != 0) - print(delim); + for (int i = 0; i < len; i++) + { + if (i != 0) + print(delim); - if ( byteline && (i % byteline == 0) ) - println(); + if ( byteline && (i % byteline == 0) ) + println(); - this->printf("%02X", buffer[len - 1 - i]); - } + this->printf("%02X", buffer[len - 1 - i]); + } - return (len * 3 - 1); + return (len * 3 - 1); } diff --git a/Packages_Patches/Seeeduino/hardware/samd/1.7.9/cores/arduino/Print.h b/Packages_Patches/Seeeduino/hardware/samd/1.7.9/cores/arduino/Print.h index a465eddb..d03d1cc8 100644 --- a/Packages_Patches/Seeeduino/hardware/samd/1.7.9/cores/arduino/Print.h +++ b/Packages_Patches/Seeeduino/hardware/samd/1.7.9/cores/arduino/Print.h @@ -20,7 +20,6 @@ #include #include // for size_t -#include // for printf #include "WString.h" #include "Printable.h" @@ -32,93 +31,93 @@ class Print { - private: - int write_error; - size_t printNumber(unsigned long, uint8_t); - size_t printULLNumber(unsigned long long, uint8_t); - size_t printFloat(double, int); - protected: - void setWriteError(int err = 1) - { - write_error = err; - } - public: - Print() : write_error(0) {} - - int getWriteError() - { - return write_error; - } - void clearWriteError() - { - setWriteError(0); - } - - virtual size_t write(uint8_t) = 0; - size_t write(const char *str) - { - if (str == NULL) - return 0; - - return write((const uint8_t *)str, strlen(str)); - } - virtual size_t write(const uint8_t *buffer, size_t size); - size_t write(const char *buffer, size_t size) - { - return write((const uint8_t *)buffer, size); - } - - // default to zero, meaning "a single write may block" - // should be overridden by subclasses with buffering - virtual int availableForWrite() - { - return 0; - } - - size_t print(const __FlashStringHelper *); - size_t print(const String &); - size_t print(const char[]); - size_t print(char); - size_t print(unsigned char, int = DEC); - size_t print(int, int = DEC); - size_t print(unsigned int, int = DEC); - size_t print(long, int = DEC); - size_t print(unsigned long, int = DEC); - size_t print(long long, int = DEC); - size_t print(unsigned long long, int = DEC); - size_t print(double, int = 2); - size_t print(const Printable&); - - size_t println(const __FlashStringHelper *); - size_t println(const String &s); - size_t println(const char[]); - size_t println(char); - size_t println(unsigned char, int = DEC); - size_t println(int, int = DEC); - size_t println(unsigned int, int = DEC); - size_t println(long, int = DEC); - size_t println(unsigned long, int = DEC); - size_t println(long long, int = DEC); - size_t println(unsigned long long, int = DEC); - size_t println(double, int = 2); - size_t println(const Printable&); - size_t println(void); - - size_t printf(const char * format, ...); - - size_t printBuffer(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); - size_t printBuffer(char const buffer[], int size, char delim = ' ', int byteline = 0) - { - return printBuffer((uint8_t const*) buffer, size, delim, byteline); - } - - size_t printBufferReverse(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); - size_t printBufferReverse(char const buffer[], int size, char delim = ' ', int byteline = 0) - { - return printBufferReverse((uint8_t const*) buffer, size, delim, byteline); - } - - virtual void flush() { /* Empty implementation for backward compatibility */ } + private: + int write_error; + size_t printNumber(unsigned long, uint8_t); + size_t printULLNumber(unsigned long long, uint8_t); + size_t printFloat(double, int); + protected: + void setWriteError(int err = 1) + { + write_error = err; + } + public: + Print() : write_error(0) {} + + int getWriteError() + { + return write_error; + } + void clearWriteError() + { + setWriteError(0); + } + + virtual size_t write(uint8_t) = 0; + size_t write(const char *str) + { + if (str == NULL) + return 0; + + return write((const uint8_t *)str, strlen(str)); + } + virtual size_t write(const uint8_t *buffer, size_t size); + size_t write(const char *buffer, size_t size) + { + return write((const uint8_t *)buffer, size); + } + + // default to zero, meaning "a single write may block" + // should be overridden by subclasses with buffering + virtual int availableForWrite() + { + return 0; + } + + size_t print(const __FlashStringHelper *); + size_t print(const String &); + size_t print(const char[]); + size_t print(char); + size_t print(unsigned char, int = DEC); + size_t print(int, int = DEC); + size_t print(unsigned int, int = DEC); + size_t print(long, int = DEC); + size_t print(unsigned long, int = DEC); + size_t print(long long, int = DEC); + size_t print(unsigned long long, int = DEC); + size_t print(double, int = 2); + size_t print(const Printable&); + + size_t println(const __FlashStringHelper *); + size_t println(const String &s); + size_t println(const char[]); + size_t println(char); + size_t println(unsigned char, int = DEC); + size_t println(int, int = DEC); + size_t println(unsigned int, int = DEC); + size_t println(long, int = DEC); + size_t println(unsigned long, int = DEC); + size_t println(long long, int = DEC); + size_t println(unsigned long long, int = DEC); + size_t println(double, int = 2); + size_t println(const Printable&); + size_t println(void); + + size_t printf(const char * format, ...); + + size_t printBuffer(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); + size_t printBuffer(char const buffer[], int size, char delim = ' ', int byteline = 0) + { + return printBuffer((uint8_t const*) buffer, size, delim, byteline); + } + + size_t printBufferReverse(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); + size_t printBufferReverse(char const buffer[], int size, char delim = ' ', int byteline = 0) + { + return printBufferReverse((uint8_t const*) buffer, size, delim, byteline); + } + + virtual void flush() { /* Empty implementation for backward compatibility */ } }; diff --git a/Packages_Patches/Seeeduino/hardware/samd/1.8.1/cores/arduino/Arduino.h b/Packages_Patches/Seeeduino/hardware/samd/1.8.1/cores/arduino/Arduino.h index 51db668f..c68bc8b6 100644 --- a/Packages_Patches/Seeeduino/hardware/samd/1.8.1/cores/arduino/Arduino.h +++ b/Packages_Patches/Seeeduino/hardware/samd/1.8.1/cores/arduino/Arduino.h @@ -76,16 +76,16 @@ int __debug_buf(const char* head, char* buf, int len); // The following headers are for C++ only compilation #ifdef __cplusplus - #include "WCharacter.h" - #include "WString.h" - #include "Tone.h" - #include "WMath.h" - #include "HardwareSerial.h" - #include "pulse.h" + #include "WCharacter.h" + #include "WString.h" + #include "Tone.h" + #include "WMath.h" + #include "HardwareSerial.h" + #include "pulse.h" #endif #include "delay.h" #ifdef __cplusplus - #include "Uart.h" + #include "Uart.h" #endif // Include board variant @@ -100,24 +100,24 @@ int __debug_buf(const char* head, char* buf, int len); // undefine stdlib's abs if encountered #ifdef abs - #undef abs + #undef abs #endif // abs // undefine stdlib's abs if encountered #ifdef abs - #undef abs + #undef abs #endif // abs #ifdef __cplusplus template auto min(const T& a, const L& b) -> decltype((b < a) ? b : a) { - return (b < a) ? b : a; + return (b < a) ? b : a; } template auto max(const T& a, const L& b) -> decltype((b < a) ? b : a) { - return (a < b) ? b : a; + return (a < b) ? b : a; } #else #ifndef min @@ -147,8 +147,8 @@ auto max(const T& a, const L& b) -> decltype((b < a) ? b : a) static inline unsigned char __interruptsStatus(void) __attribute__((always_inline, unused)); static inline unsigned char __interruptsStatus(void) { - // See http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0497a/CHDBIBGJ.html - return (__get_PRIMASK() ? 0 : 1); + // See http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0497a/CHDBIBGJ.html + return (__get_PRIMASK() ? 0 : 1); } #define interruptsStatus() __interruptsStatus() #endif @@ -164,18 +164,18 @@ static inline unsigned char __interruptsStatus(void) #define bit(b) (1UL << (b)) #if (ARDUINO_SAMD_VARIANT_COMPLIANCE >= 10606) - // Interrupts - #define digitalPinToInterrupt(P) ( P ) + // Interrupts + #define digitalPinToInterrupt(P) ( P ) #endif // USB #ifdef USE_TINYUSB - #include "Adafruit_TinyUSB_Core.h" + #include "Adafruit_TinyUSB_Core.h" #else - #include "USB/USBDesc.h" - #include "USB/USBCore.h" - #include "USB/USBAPI.h" - #include "USB/USB_host.h" + #include "USB/USBDesc.h" + #include "USB/USBCore.h" + #include "USB/USBAPI.h" + #include "USB/USB_host.h" #endif #endif // Arduino_h diff --git a/Packages_Patches/Seeeduino/hardware/samd/1.8.1/cores/arduino/Print.cpp b/Packages_Patches/Seeeduino/hardware/samd/1.8.1/cores/arduino/Print.cpp index b47efa1a..d2db9576 100644 --- a/Packages_Patches/Seeeduino/hardware/samd/1.8.1/cores/arduino/Print.cpp +++ b/Packages_Patches/Seeeduino/hardware/samd/1.8.1/cores/arduino/Print.cpp @@ -35,259 +35,259 @@ /* default implementation: may be overridden */ size_t Print::write(const uint8_t *buffer, size_t size) { - size_t n = 0; + size_t n = 0; - while (size--) - { - if (write(*buffer++)) - n++; - else - break; - } + while (size--) + { + if (write(*buffer++)) + n++; + else + break; + } - return n; + return n; } size_t Print::print(const __FlashStringHelper *ifsh) { - return print(reinterpret_cast(ifsh)); + return print(reinterpret_cast(ifsh)); } size_t Print::print(const String &s) { - return write(s.c_str(), s.length()); + return write(s.c_str(), s.length()); } size_t Print::print(const char str[]) { - return write(str); + return write(str); } size_t Print::print(char c) { - return write(c); + return write(c); } size_t Print::print(unsigned char b, int base) { - return print((unsigned long) b, base); + return print((unsigned long) b, base); } size_t Print::print(int n, int base) { - return print((long) n, base); + return print((long) n, base); } size_t Print::print(unsigned int n, int base) { - return print((unsigned long) n, base); + return print((unsigned long) n, base); } size_t Print::print(long n, int base) { - if (base == 0) - { - return write(n); - } - else if (base == 10) - { - if (n < 0) - { - int t = print('-'); - n = -n; - return printNumber(n, 10) + t; - } - - return printNumber(n, 10); - } - else - { - return printNumber(n, base); - } + if (base == 0) + { + return write(n); + } + else if (base == 10) + { + if (n < 0) + { + int t = print('-'); + n = -n; + return printNumber(n, 10) + t; + } + + return printNumber(n, 10); + } + else + { + return printNumber(n, base); + } } size_t Print::print(unsigned long n, int base) { - if (base == 0) - return write(n); - else - return printNumber(n, base); + if (base == 0) + return write(n); + else + return printNumber(n, base); } size_t Print::print(long long n, int base) { - if (base == 0) - { - return write(n); - } - else if (base == 10) - { - if (n < 0) - { - int t = print('-'); - n = -n; - return printULLNumber(n, 10) + t; - } - - return printULLNumber(n, 10); - } - else - { - return printULLNumber(n, base); - } + if (base == 0) + { + return write(n); + } + else if (base == 10) + { + if (n < 0) + { + int t = print('-'); + n = -n; + return printULLNumber(n, 10) + t; + } + + return printULLNumber(n, 10); + } + else + { + return printULLNumber(n, base); + } } size_t Print::print(unsigned long long n, int base) { - if (base == 0) - return write(n); - else - return printULLNumber(n, base); + if (base == 0) + return write(n); + else + return printULLNumber(n, base); } size_t Print::print(double n, int digits) { - return printFloat(n, digits); + return printFloat(n, digits); } size_t Print::println(const __FlashStringHelper *ifsh) { - size_t n = print(ifsh); - n += println(); - return n; + size_t n = print(ifsh); + n += println(); + return n; } size_t Print::print(const Printable& x) { - return x.printTo(*this); + return x.printTo(*this); } size_t Print::println(void) { - return write("\r\n"); + return write("\r\n"); } size_t Print::println(const String &s) { - size_t n = print(s); - n += println(); - return n; + size_t n = print(s); + n += println(); + return n; } size_t Print::println(const char c[]) { - size_t n = print(c); - n += println(); - return n; + size_t n = print(c); + n += println(); + return n; } size_t Print::println(char c) { - size_t n = print(c); - n += println(); - return n; + size_t n = print(c); + n += println(); + return n; } size_t Print::println(unsigned char b, int base) { - size_t n = print(b, base); - n += println(); - return n; + size_t n = print(b, base); + n += println(); + return n; } size_t Print::println(int num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned int num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(long long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned long long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(double num, int digits) { - size_t n = print(num, digits); - n += println(); - return n; + size_t n = print(num, digits); + n += println(); + return n; } size_t Print::println(const Printable& x) { - size_t n = print(x); - n += println(); - return n; + size_t n = print(x); + n += println(); + return n; } size_t Print::printf(const char * format, ...) { - char buf[256]; - int len; + char buf[256]; + int len; - va_list ap; - va_start(ap, format); + va_list ap; + va_start(ap, format); - len = vsnprintf(buf, 256, format, ap); - this->write(buf, len); + len = vsnprintf(buf, 256, format, ap); + this->write(buf, len); - va_end(ap); - return len; + va_end(ap); + return len; } // Private Methods ///////////////////////////////////////////////////////////// size_t Print::printNumber(unsigned long n, uint8_t base) { - char buf[8 * sizeof(long) + 1]; // Assumes 8-bit chars plus zero byte. - char *str = &buf[sizeof(buf) - 1]; + char buf[8 * sizeof(long) + 1]; // Assumes 8-bit chars plus zero byte. + char *str = &buf[sizeof(buf) - 1]; - *str = '\0'; + *str = '\0'; - // prevent crash if called with base == 1 - if (base < 2) - base = 10; + // prevent crash if called with base == 1 + if (base < 2) + base = 10; - do - { - char c = n % base; - n /= base; + do + { + char c = n % base; + n /= base; - *--str = c < 10 ? c + '0' : c + 'A' - 10; - } while (n); + *--str = c < 10 ? c + '0' : c + 'A' - 10; + } while (n); - return write(str); + return write(str); } // REFERENCE IMPLEMENTATION FOR ULL @@ -315,152 +315,152 @@ size_t Print::printNumber(unsigned long n, uint8_t base) // FAST IMPLEMENTATION FOR ULL size_t Print::printULLNumber(unsigned long long n64, uint8_t base) { - // if limited to base 10 and 16 the bufsize can be 20 - char buf[64]; - uint8_t i = 0; - uint8_t innerLoops = 0; + // if limited to base 10 and 16 the bufsize can be 20 + char buf[64]; + uint8_t i = 0; + uint8_t innerLoops = 0; - // prevent crash if called with base == 1 - if (base < 2) - base = 10; + // prevent crash if called with base == 1 + if (base < 2) + base = 10; - // process chunks that fit in "16 bit math". - uint16_t top = 0xFFFF / base; - uint16_t th16 = 1; + // process chunks that fit in "16 bit math". + uint16_t top = 0xFFFF / base; + uint16_t th16 = 1; - while (th16 < top) - { - th16 *= base; - innerLoops++; - } + while (th16 < top) + { + th16 *= base; + innerLoops++; + } - while (n64 > th16) - { - // 64 bit math part - uint64_t q = n64 / th16; - uint16_t r = n64 - q * th16; - n64 = q; + while (n64 > th16) + { + // 64 bit math part + uint64_t q = n64 / th16; + uint16_t r = n64 - q * th16; + n64 = q; - // 16 bit math loop to do remainder. (note buffer is filled reverse) - for (uint8_t j = 0; j < innerLoops; j++) - { - uint16_t qq = r / base; - buf[i++] = r - qq * base; - r = qq; - } - } + // 16 bit math loop to do remainder. (note buffer is filled reverse) + for (uint8_t j = 0; j < innerLoops; j++) + { + uint16_t qq = r / base; + buf[i++] = r - qq * base; + r = qq; + } + } - uint16_t n16 = n64; + uint16_t n16 = n64; - while (n16 > 0) - { - uint16_t qq = n16 / base; - buf[i++] = n16 - qq * base; - n16 = qq; - } + while (n16 > 0) + { + uint16_t qq = n16 / base; + buf[i++] = n16 - qq * base; + n16 = qq; + } - size_t bytes = i; + size_t bytes = i; - for (; i > 0; i--) - write((char) (buf[i - 1] < 10 ? - '0' + buf[i - 1] : - 'A' + buf[i - 1] - 10)); + for (; i > 0; i--) + write((char) (buf[i - 1] < 10 ? + '0' + buf[i - 1] : + 'A' + buf[i - 1] - 10)); - return bytes; + return bytes; } size_t Print::printFloat(double number, int digits) { - if (digits < 0) - digits = 2; + if (digits < 0) + digits = 2; - size_t n = 0; + size_t n = 0; - if (isnan(number)) - return print("nan"); + if (isnan(number)) + return print("nan"); - if (isinf(number)) - return print("inf"); + if (isinf(number)) + return print("inf"); - if (number > 4294967040.0) - return print ("ovf"); // constant determined empirically + if (number > 4294967040.0) + return print ("ovf"); // constant determined empirically - if (number < -4294967040.0) - return print ("ovf"); // constant determined empirically + if (number < -4294967040.0) + return print ("ovf"); // constant determined empirically - // Handle negative numbers - if (number < 0.0) - { - n += print('-'); - number = -number; - } + // Handle negative numbers + if (number < 0.0) + { + n += print('-'); + number = -number; + } - // Round correctly so that print(1.999, 2) prints as "2.00" - double rounding = 0.5; + // Round correctly so that print(1.999, 2) prints as "2.00" + double rounding = 0.5; - for (uint8_t i = 0; i < digits; ++i) - rounding /= 10.0; + for (uint8_t i = 0; i < digits; ++i) + rounding /= 10.0; - number += rounding; + number += rounding; - // Extract the integer part of the number and print it - unsigned long int_part = (unsigned long)number; - double remainder = number - (double)int_part; - n += print(int_part); + // Extract the integer part of the number and print it + unsigned long int_part = (unsigned long)number; + double remainder = number - (double)int_part; + n += print(int_part); - // Print the decimal point, but only if there are digits beyond - if (digits > 0) - { - n += print("."); - } + // Print the decimal point, but only if there are digits beyond + if (digits > 0) + { + n += print("."); + } - // Extract digits from the remainder one at a time - while (digits-- > 0) - { - remainder *= 10.0; - unsigned int toPrint = (unsigned int)remainder; - n += print(toPrint); - remainder -= toPrint; - } + // Extract digits from the remainder one at a time + while (digits-- > 0) + { + remainder *= 10.0; + unsigned int toPrint = (unsigned int)remainder; + n += print(toPrint); + remainder -= toPrint; + } - return n; + return n; } size_t Print::printBuffer(uint8_t const buffer[], int len, char delim, int byteline) { - if (buffer == NULL || len == 0) - return 0; + if (buffer == NULL || len == 0) + return 0; - for (int i = 0; i < len; i++) - { - if ( i != 0 ) - print(delim); + for (int i = 0; i < len; i++) + { + if ( i != 0 ) + print(delim); - if ( byteline && (i % byteline == 0) ) - println(); + if ( byteline && (i % byteline == 0) ) + println(); - this->printf("%02X", buffer[i]); - } + this->printf("%02X", buffer[i]); + } - return (len * 3 - 1); + return (len * 3 - 1); } size_t Print::printBufferReverse(uint8_t const buffer[], int len, char delim, int byteline) { - if (buffer == NULL || len == 0) - return 0; + if (buffer == NULL || len == 0) + return 0; - for (int i = 0; i < len; i++) - { - if (i != 0) - print(delim); + for (int i = 0; i < len; i++) + { + if (i != 0) + print(delim); - if ( byteline && (i % byteline == 0) ) - println(); + if ( byteline && (i % byteline == 0) ) + println(); - this->printf("%02X", buffer[len - 1 - i]); - } + this->printf("%02X", buffer[len - 1 - i]); + } - return (len * 3 - 1); + return (len * 3 - 1); } diff --git a/Packages_Patches/Seeeduino/hardware/samd/1.8.1/cores/arduino/Print.h b/Packages_Patches/Seeeduino/hardware/samd/1.8.1/cores/arduino/Print.h index a465eddb..6c08258b 100644 --- a/Packages_Patches/Seeeduino/hardware/samd/1.8.1/cores/arduino/Print.h +++ b/Packages_Patches/Seeeduino/hardware/samd/1.8.1/cores/arduino/Print.h @@ -32,93 +32,93 @@ class Print { - private: - int write_error; - size_t printNumber(unsigned long, uint8_t); - size_t printULLNumber(unsigned long long, uint8_t); - size_t printFloat(double, int); - protected: - void setWriteError(int err = 1) - { - write_error = err; - } - public: - Print() : write_error(0) {} - - int getWriteError() - { - return write_error; - } - void clearWriteError() - { - setWriteError(0); - } - - virtual size_t write(uint8_t) = 0; - size_t write(const char *str) - { - if (str == NULL) - return 0; - - return write((const uint8_t *)str, strlen(str)); - } - virtual size_t write(const uint8_t *buffer, size_t size); - size_t write(const char *buffer, size_t size) - { - return write((const uint8_t *)buffer, size); - } - - // default to zero, meaning "a single write may block" - // should be overridden by subclasses with buffering - virtual int availableForWrite() - { - return 0; - } - - size_t print(const __FlashStringHelper *); - size_t print(const String &); - size_t print(const char[]); - size_t print(char); - size_t print(unsigned char, int = DEC); - size_t print(int, int = DEC); - size_t print(unsigned int, int = DEC); - size_t print(long, int = DEC); - size_t print(unsigned long, int = DEC); - size_t print(long long, int = DEC); - size_t print(unsigned long long, int = DEC); - size_t print(double, int = 2); - size_t print(const Printable&); - - size_t println(const __FlashStringHelper *); - size_t println(const String &s); - size_t println(const char[]); - size_t println(char); - size_t println(unsigned char, int = DEC); - size_t println(int, int = DEC); - size_t println(unsigned int, int = DEC); - size_t println(long, int = DEC); - size_t println(unsigned long, int = DEC); - size_t println(long long, int = DEC); - size_t println(unsigned long long, int = DEC); - size_t println(double, int = 2); - size_t println(const Printable&); - size_t println(void); - - size_t printf(const char * format, ...); - - size_t printBuffer(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); - size_t printBuffer(char const buffer[], int size, char delim = ' ', int byteline = 0) - { - return printBuffer((uint8_t const*) buffer, size, delim, byteline); - } - - size_t printBufferReverse(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); - size_t printBufferReverse(char const buffer[], int size, char delim = ' ', int byteline = 0) - { - return printBufferReverse((uint8_t const*) buffer, size, delim, byteline); - } - - virtual void flush() { /* Empty implementation for backward compatibility */ } + private: + int write_error; + size_t printNumber(unsigned long, uint8_t); + size_t printULLNumber(unsigned long long, uint8_t); + size_t printFloat(double, int); + protected: + void setWriteError(int err = 1) + { + write_error = err; + } + public: + Print() : write_error(0) {} + + int getWriteError() + { + return write_error; + } + void clearWriteError() + { + setWriteError(0); + } + + virtual size_t write(uint8_t) = 0; + size_t write(const char *str) + { + if (str == NULL) + return 0; + + return write((const uint8_t *)str, strlen(str)); + } + virtual size_t write(const uint8_t *buffer, size_t size); + size_t write(const char *buffer, size_t size) + { + return write((const uint8_t *)buffer, size); + } + + // default to zero, meaning "a single write may block" + // should be overridden by subclasses with buffering + virtual int availableForWrite() + { + return 0; + } + + size_t print(const __FlashStringHelper *); + size_t print(const String &); + size_t print(const char[]); + size_t print(char); + size_t print(unsigned char, int = DEC); + size_t print(int, int = DEC); + size_t print(unsigned int, int = DEC); + size_t print(long, int = DEC); + size_t print(unsigned long, int = DEC); + size_t print(long long, int = DEC); + size_t print(unsigned long long, int = DEC); + size_t print(double, int = 2); + size_t print(const Printable&); + + size_t println(const __FlashStringHelper *); + size_t println(const String &s); + size_t println(const char[]); + size_t println(char); + size_t println(unsigned char, int = DEC); + size_t println(int, int = DEC); + size_t println(unsigned int, int = DEC); + size_t println(long, int = DEC); + size_t println(unsigned long, int = DEC); + size_t println(long long, int = DEC); + size_t println(unsigned long long, int = DEC); + size_t println(double, int = 2); + size_t println(const Printable&); + size_t println(void); + + size_t printf(const char * format, ...); + + size_t printBuffer(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); + size_t printBuffer(char const buffer[], int size, char delim = ' ', int byteline = 0) + { + return printBuffer((uint8_t const*) buffer, size, delim, byteline); + } + + size_t printBufferReverse(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); + size_t printBufferReverse(char const buffer[], int size, char delim = ' ', int byteline = 0) + { + return printBufferReverse((uint8_t const*) buffer, size, delim, byteline); + } + + virtual void flush() { /* Empty implementation for backward compatibility */ } }; diff --git a/Packages_Patches/Seeeduino/hardware/samd/1.8.2/cores/arduino/Arduino.h b/Packages_Patches/Seeeduino/hardware/samd/1.8.2/cores/arduino/Arduino.h index 51db668f..c68bc8b6 100644 --- a/Packages_Patches/Seeeduino/hardware/samd/1.8.2/cores/arduino/Arduino.h +++ b/Packages_Patches/Seeeduino/hardware/samd/1.8.2/cores/arduino/Arduino.h @@ -76,16 +76,16 @@ int __debug_buf(const char* head, char* buf, int len); // The following headers are for C++ only compilation #ifdef __cplusplus - #include "WCharacter.h" - #include "WString.h" - #include "Tone.h" - #include "WMath.h" - #include "HardwareSerial.h" - #include "pulse.h" + #include "WCharacter.h" + #include "WString.h" + #include "Tone.h" + #include "WMath.h" + #include "HardwareSerial.h" + #include "pulse.h" #endif #include "delay.h" #ifdef __cplusplus - #include "Uart.h" + #include "Uart.h" #endif // Include board variant @@ -100,24 +100,24 @@ int __debug_buf(const char* head, char* buf, int len); // undefine stdlib's abs if encountered #ifdef abs - #undef abs + #undef abs #endif // abs // undefine stdlib's abs if encountered #ifdef abs - #undef abs + #undef abs #endif // abs #ifdef __cplusplus template auto min(const T& a, const L& b) -> decltype((b < a) ? b : a) { - return (b < a) ? b : a; + return (b < a) ? b : a; } template auto max(const T& a, const L& b) -> decltype((b < a) ? b : a) { - return (a < b) ? b : a; + return (a < b) ? b : a; } #else #ifndef min @@ -147,8 +147,8 @@ auto max(const T& a, const L& b) -> decltype((b < a) ? b : a) static inline unsigned char __interruptsStatus(void) __attribute__((always_inline, unused)); static inline unsigned char __interruptsStatus(void) { - // See http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0497a/CHDBIBGJ.html - return (__get_PRIMASK() ? 0 : 1); + // See http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0497a/CHDBIBGJ.html + return (__get_PRIMASK() ? 0 : 1); } #define interruptsStatus() __interruptsStatus() #endif @@ -164,18 +164,18 @@ static inline unsigned char __interruptsStatus(void) #define bit(b) (1UL << (b)) #if (ARDUINO_SAMD_VARIANT_COMPLIANCE >= 10606) - // Interrupts - #define digitalPinToInterrupt(P) ( P ) + // Interrupts + #define digitalPinToInterrupt(P) ( P ) #endif // USB #ifdef USE_TINYUSB - #include "Adafruit_TinyUSB_Core.h" + #include "Adafruit_TinyUSB_Core.h" #else - #include "USB/USBDesc.h" - #include "USB/USBCore.h" - #include "USB/USBAPI.h" - #include "USB/USB_host.h" + #include "USB/USBDesc.h" + #include "USB/USBCore.h" + #include "USB/USBAPI.h" + #include "USB/USB_host.h" #endif #endif // Arduino_h diff --git a/Packages_Patches/Seeeduino/hardware/samd/1.8.2/cores/arduino/Print.cpp b/Packages_Patches/Seeeduino/hardware/samd/1.8.2/cores/arduino/Print.cpp index b47efa1a..d2db9576 100644 --- a/Packages_Patches/Seeeduino/hardware/samd/1.8.2/cores/arduino/Print.cpp +++ b/Packages_Patches/Seeeduino/hardware/samd/1.8.2/cores/arduino/Print.cpp @@ -35,259 +35,259 @@ /* default implementation: may be overridden */ size_t Print::write(const uint8_t *buffer, size_t size) { - size_t n = 0; + size_t n = 0; - while (size--) - { - if (write(*buffer++)) - n++; - else - break; - } + while (size--) + { + if (write(*buffer++)) + n++; + else + break; + } - return n; + return n; } size_t Print::print(const __FlashStringHelper *ifsh) { - return print(reinterpret_cast(ifsh)); + return print(reinterpret_cast(ifsh)); } size_t Print::print(const String &s) { - return write(s.c_str(), s.length()); + return write(s.c_str(), s.length()); } size_t Print::print(const char str[]) { - return write(str); + return write(str); } size_t Print::print(char c) { - return write(c); + return write(c); } size_t Print::print(unsigned char b, int base) { - return print((unsigned long) b, base); + return print((unsigned long) b, base); } size_t Print::print(int n, int base) { - return print((long) n, base); + return print((long) n, base); } size_t Print::print(unsigned int n, int base) { - return print((unsigned long) n, base); + return print((unsigned long) n, base); } size_t Print::print(long n, int base) { - if (base == 0) - { - return write(n); - } - else if (base == 10) - { - if (n < 0) - { - int t = print('-'); - n = -n; - return printNumber(n, 10) + t; - } - - return printNumber(n, 10); - } - else - { - return printNumber(n, base); - } + if (base == 0) + { + return write(n); + } + else if (base == 10) + { + if (n < 0) + { + int t = print('-'); + n = -n; + return printNumber(n, 10) + t; + } + + return printNumber(n, 10); + } + else + { + return printNumber(n, base); + } } size_t Print::print(unsigned long n, int base) { - if (base == 0) - return write(n); - else - return printNumber(n, base); + if (base == 0) + return write(n); + else + return printNumber(n, base); } size_t Print::print(long long n, int base) { - if (base == 0) - { - return write(n); - } - else if (base == 10) - { - if (n < 0) - { - int t = print('-'); - n = -n; - return printULLNumber(n, 10) + t; - } - - return printULLNumber(n, 10); - } - else - { - return printULLNumber(n, base); - } + if (base == 0) + { + return write(n); + } + else if (base == 10) + { + if (n < 0) + { + int t = print('-'); + n = -n; + return printULLNumber(n, 10) + t; + } + + return printULLNumber(n, 10); + } + else + { + return printULLNumber(n, base); + } } size_t Print::print(unsigned long long n, int base) { - if (base == 0) - return write(n); - else - return printULLNumber(n, base); + if (base == 0) + return write(n); + else + return printULLNumber(n, base); } size_t Print::print(double n, int digits) { - return printFloat(n, digits); + return printFloat(n, digits); } size_t Print::println(const __FlashStringHelper *ifsh) { - size_t n = print(ifsh); - n += println(); - return n; + size_t n = print(ifsh); + n += println(); + return n; } size_t Print::print(const Printable& x) { - return x.printTo(*this); + return x.printTo(*this); } size_t Print::println(void) { - return write("\r\n"); + return write("\r\n"); } size_t Print::println(const String &s) { - size_t n = print(s); - n += println(); - return n; + size_t n = print(s); + n += println(); + return n; } size_t Print::println(const char c[]) { - size_t n = print(c); - n += println(); - return n; + size_t n = print(c); + n += println(); + return n; } size_t Print::println(char c) { - size_t n = print(c); - n += println(); - return n; + size_t n = print(c); + n += println(); + return n; } size_t Print::println(unsigned char b, int base) { - size_t n = print(b, base); - n += println(); - return n; + size_t n = print(b, base); + n += println(); + return n; } size_t Print::println(int num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned int num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(long long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned long long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(double num, int digits) { - size_t n = print(num, digits); - n += println(); - return n; + size_t n = print(num, digits); + n += println(); + return n; } size_t Print::println(const Printable& x) { - size_t n = print(x); - n += println(); - return n; + size_t n = print(x); + n += println(); + return n; } size_t Print::printf(const char * format, ...) { - char buf[256]; - int len; + char buf[256]; + int len; - va_list ap; - va_start(ap, format); + va_list ap; + va_start(ap, format); - len = vsnprintf(buf, 256, format, ap); - this->write(buf, len); + len = vsnprintf(buf, 256, format, ap); + this->write(buf, len); - va_end(ap); - return len; + va_end(ap); + return len; } // Private Methods ///////////////////////////////////////////////////////////// size_t Print::printNumber(unsigned long n, uint8_t base) { - char buf[8 * sizeof(long) + 1]; // Assumes 8-bit chars plus zero byte. - char *str = &buf[sizeof(buf) - 1]; + char buf[8 * sizeof(long) + 1]; // Assumes 8-bit chars plus zero byte. + char *str = &buf[sizeof(buf) - 1]; - *str = '\0'; + *str = '\0'; - // prevent crash if called with base == 1 - if (base < 2) - base = 10; + // prevent crash if called with base == 1 + if (base < 2) + base = 10; - do - { - char c = n % base; - n /= base; + do + { + char c = n % base; + n /= base; - *--str = c < 10 ? c + '0' : c + 'A' - 10; - } while (n); + *--str = c < 10 ? c + '0' : c + 'A' - 10; + } while (n); - return write(str); + return write(str); } // REFERENCE IMPLEMENTATION FOR ULL @@ -315,152 +315,152 @@ size_t Print::printNumber(unsigned long n, uint8_t base) // FAST IMPLEMENTATION FOR ULL size_t Print::printULLNumber(unsigned long long n64, uint8_t base) { - // if limited to base 10 and 16 the bufsize can be 20 - char buf[64]; - uint8_t i = 0; - uint8_t innerLoops = 0; + // if limited to base 10 and 16 the bufsize can be 20 + char buf[64]; + uint8_t i = 0; + uint8_t innerLoops = 0; - // prevent crash if called with base == 1 - if (base < 2) - base = 10; + // prevent crash if called with base == 1 + if (base < 2) + base = 10; - // process chunks that fit in "16 bit math". - uint16_t top = 0xFFFF / base; - uint16_t th16 = 1; + // process chunks that fit in "16 bit math". + uint16_t top = 0xFFFF / base; + uint16_t th16 = 1; - while (th16 < top) - { - th16 *= base; - innerLoops++; - } + while (th16 < top) + { + th16 *= base; + innerLoops++; + } - while (n64 > th16) - { - // 64 bit math part - uint64_t q = n64 / th16; - uint16_t r = n64 - q * th16; - n64 = q; + while (n64 > th16) + { + // 64 bit math part + uint64_t q = n64 / th16; + uint16_t r = n64 - q * th16; + n64 = q; - // 16 bit math loop to do remainder. (note buffer is filled reverse) - for (uint8_t j = 0; j < innerLoops; j++) - { - uint16_t qq = r / base; - buf[i++] = r - qq * base; - r = qq; - } - } + // 16 bit math loop to do remainder. (note buffer is filled reverse) + for (uint8_t j = 0; j < innerLoops; j++) + { + uint16_t qq = r / base; + buf[i++] = r - qq * base; + r = qq; + } + } - uint16_t n16 = n64; + uint16_t n16 = n64; - while (n16 > 0) - { - uint16_t qq = n16 / base; - buf[i++] = n16 - qq * base; - n16 = qq; - } + while (n16 > 0) + { + uint16_t qq = n16 / base; + buf[i++] = n16 - qq * base; + n16 = qq; + } - size_t bytes = i; + size_t bytes = i; - for (; i > 0; i--) - write((char) (buf[i - 1] < 10 ? - '0' + buf[i - 1] : - 'A' + buf[i - 1] - 10)); + for (; i > 0; i--) + write((char) (buf[i - 1] < 10 ? + '0' + buf[i - 1] : + 'A' + buf[i - 1] - 10)); - return bytes; + return bytes; } size_t Print::printFloat(double number, int digits) { - if (digits < 0) - digits = 2; + if (digits < 0) + digits = 2; - size_t n = 0; + size_t n = 0; - if (isnan(number)) - return print("nan"); + if (isnan(number)) + return print("nan"); - if (isinf(number)) - return print("inf"); + if (isinf(number)) + return print("inf"); - if (number > 4294967040.0) - return print ("ovf"); // constant determined empirically + if (number > 4294967040.0) + return print ("ovf"); // constant determined empirically - if (number < -4294967040.0) - return print ("ovf"); // constant determined empirically + if (number < -4294967040.0) + return print ("ovf"); // constant determined empirically - // Handle negative numbers - if (number < 0.0) - { - n += print('-'); - number = -number; - } + // Handle negative numbers + if (number < 0.0) + { + n += print('-'); + number = -number; + } - // Round correctly so that print(1.999, 2) prints as "2.00" - double rounding = 0.5; + // Round correctly so that print(1.999, 2) prints as "2.00" + double rounding = 0.5; - for (uint8_t i = 0; i < digits; ++i) - rounding /= 10.0; + for (uint8_t i = 0; i < digits; ++i) + rounding /= 10.0; - number += rounding; + number += rounding; - // Extract the integer part of the number and print it - unsigned long int_part = (unsigned long)number; - double remainder = number - (double)int_part; - n += print(int_part); + // Extract the integer part of the number and print it + unsigned long int_part = (unsigned long)number; + double remainder = number - (double)int_part; + n += print(int_part); - // Print the decimal point, but only if there are digits beyond - if (digits > 0) - { - n += print("."); - } + // Print the decimal point, but only if there are digits beyond + if (digits > 0) + { + n += print("."); + } - // Extract digits from the remainder one at a time - while (digits-- > 0) - { - remainder *= 10.0; - unsigned int toPrint = (unsigned int)remainder; - n += print(toPrint); - remainder -= toPrint; - } + // Extract digits from the remainder one at a time + while (digits-- > 0) + { + remainder *= 10.0; + unsigned int toPrint = (unsigned int)remainder; + n += print(toPrint); + remainder -= toPrint; + } - return n; + return n; } size_t Print::printBuffer(uint8_t const buffer[], int len, char delim, int byteline) { - if (buffer == NULL || len == 0) - return 0; + if (buffer == NULL || len == 0) + return 0; - for (int i = 0; i < len; i++) - { - if ( i != 0 ) - print(delim); + for (int i = 0; i < len; i++) + { + if ( i != 0 ) + print(delim); - if ( byteline && (i % byteline == 0) ) - println(); + if ( byteline && (i % byteline == 0) ) + println(); - this->printf("%02X", buffer[i]); - } + this->printf("%02X", buffer[i]); + } - return (len * 3 - 1); + return (len * 3 - 1); } size_t Print::printBufferReverse(uint8_t const buffer[], int len, char delim, int byteline) { - if (buffer == NULL || len == 0) - return 0; + if (buffer == NULL || len == 0) + return 0; - for (int i = 0; i < len; i++) - { - if (i != 0) - print(delim); + for (int i = 0; i < len; i++) + { + if (i != 0) + print(delim); - if ( byteline && (i % byteline == 0) ) - println(); + if ( byteline && (i % byteline == 0) ) + println(); - this->printf("%02X", buffer[len - 1 - i]); - } + this->printf("%02X", buffer[len - 1 - i]); + } - return (len * 3 - 1); + return (len * 3 - 1); } diff --git a/Packages_Patches/Seeeduino/hardware/samd/1.8.2/cores/arduino/Print.h b/Packages_Patches/Seeeduino/hardware/samd/1.8.2/cores/arduino/Print.h index a465eddb..6c08258b 100644 --- a/Packages_Patches/Seeeduino/hardware/samd/1.8.2/cores/arduino/Print.h +++ b/Packages_Patches/Seeeduino/hardware/samd/1.8.2/cores/arduino/Print.h @@ -32,93 +32,93 @@ class Print { - private: - int write_error; - size_t printNumber(unsigned long, uint8_t); - size_t printULLNumber(unsigned long long, uint8_t); - size_t printFloat(double, int); - protected: - void setWriteError(int err = 1) - { - write_error = err; - } - public: - Print() : write_error(0) {} - - int getWriteError() - { - return write_error; - } - void clearWriteError() - { - setWriteError(0); - } - - virtual size_t write(uint8_t) = 0; - size_t write(const char *str) - { - if (str == NULL) - return 0; - - return write((const uint8_t *)str, strlen(str)); - } - virtual size_t write(const uint8_t *buffer, size_t size); - size_t write(const char *buffer, size_t size) - { - return write((const uint8_t *)buffer, size); - } - - // default to zero, meaning "a single write may block" - // should be overridden by subclasses with buffering - virtual int availableForWrite() - { - return 0; - } - - size_t print(const __FlashStringHelper *); - size_t print(const String &); - size_t print(const char[]); - size_t print(char); - size_t print(unsigned char, int = DEC); - size_t print(int, int = DEC); - size_t print(unsigned int, int = DEC); - size_t print(long, int = DEC); - size_t print(unsigned long, int = DEC); - size_t print(long long, int = DEC); - size_t print(unsigned long long, int = DEC); - size_t print(double, int = 2); - size_t print(const Printable&); - - size_t println(const __FlashStringHelper *); - size_t println(const String &s); - size_t println(const char[]); - size_t println(char); - size_t println(unsigned char, int = DEC); - size_t println(int, int = DEC); - size_t println(unsigned int, int = DEC); - size_t println(long, int = DEC); - size_t println(unsigned long, int = DEC); - size_t println(long long, int = DEC); - size_t println(unsigned long long, int = DEC); - size_t println(double, int = 2); - size_t println(const Printable&); - size_t println(void); - - size_t printf(const char * format, ...); - - size_t printBuffer(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); - size_t printBuffer(char const buffer[], int size, char delim = ' ', int byteline = 0) - { - return printBuffer((uint8_t const*) buffer, size, delim, byteline); - } - - size_t printBufferReverse(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); - size_t printBufferReverse(char const buffer[], int size, char delim = ' ', int byteline = 0) - { - return printBufferReverse((uint8_t const*) buffer, size, delim, byteline); - } - - virtual void flush() { /* Empty implementation for backward compatibility */ } + private: + int write_error; + size_t printNumber(unsigned long, uint8_t); + size_t printULLNumber(unsigned long long, uint8_t); + size_t printFloat(double, int); + protected: + void setWriteError(int err = 1) + { + write_error = err; + } + public: + Print() : write_error(0) {} + + int getWriteError() + { + return write_error; + } + void clearWriteError() + { + setWriteError(0); + } + + virtual size_t write(uint8_t) = 0; + size_t write(const char *str) + { + if (str == NULL) + return 0; + + return write((const uint8_t *)str, strlen(str)); + } + virtual size_t write(const uint8_t *buffer, size_t size); + size_t write(const char *buffer, size_t size) + { + return write((const uint8_t *)buffer, size); + } + + // default to zero, meaning "a single write may block" + // should be overridden by subclasses with buffering + virtual int availableForWrite() + { + return 0; + } + + size_t print(const __FlashStringHelper *); + size_t print(const String &); + size_t print(const char[]); + size_t print(char); + size_t print(unsigned char, int = DEC); + size_t print(int, int = DEC); + size_t print(unsigned int, int = DEC); + size_t print(long, int = DEC); + size_t print(unsigned long, int = DEC); + size_t print(long long, int = DEC); + size_t print(unsigned long long, int = DEC); + size_t print(double, int = 2); + size_t print(const Printable&); + + size_t println(const __FlashStringHelper *); + size_t println(const String &s); + size_t println(const char[]); + size_t println(char); + size_t println(unsigned char, int = DEC); + size_t println(int, int = DEC); + size_t println(unsigned int, int = DEC); + size_t println(long, int = DEC); + size_t println(unsigned long, int = DEC); + size_t println(long long, int = DEC); + size_t println(unsigned long long, int = DEC); + size_t println(double, int = 2); + size_t println(const Printable&); + size_t println(void); + + size_t printf(const char * format, ...); + + size_t printBuffer(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); + size_t printBuffer(char const buffer[], int size, char delim = ' ', int byteline = 0) + { + return printBuffer((uint8_t const*) buffer, size, delim, byteline); + } + + size_t printBufferReverse(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); + size_t printBufferReverse(char const buffer[], int size, char delim = ' ', int byteline = 0) + { + return printBufferReverse((uint8_t const*) buffer, size, delim, byteline); + } + + virtual void flush() { /* Empty implementation for backward compatibility */ } }; diff --git a/Packages_Patches/Seeeduino/hardware/samd/1.8.3/cores/arduino/Arduino.h b/Packages_Patches/Seeeduino/hardware/samd/1.8.3/cores/arduino/Arduino.h index 51db668f..c68bc8b6 100644 --- a/Packages_Patches/Seeeduino/hardware/samd/1.8.3/cores/arduino/Arduino.h +++ b/Packages_Patches/Seeeduino/hardware/samd/1.8.3/cores/arduino/Arduino.h @@ -76,16 +76,16 @@ int __debug_buf(const char* head, char* buf, int len); // The following headers are for C++ only compilation #ifdef __cplusplus - #include "WCharacter.h" - #include "WString.h" - #include "Tone.h" - #include "WMath.h" - #include "HardwareSerial.h" - #include "pulse.h" + #include "WCharacter.h" + #include "WString.h" + #include "Tone.h" + #include "WMath.h" + #include "HardwareSerial.h" + #include "pulse.h" #endif #include "delay.h" #ifdef __cplusplus - #include "Uart.h" + #include "Uart.h" #endif // Include board variant @@ -100,24 +100,24 @@ int __debug_buf(const char* head, char* buf, int len); // undefine stdlib's abs if encountered #ifdef abs - #undef abs + #undef abs #endif // abs // undefine stdlib's abs if encountered #ifdef abs - #undef abs + #undef abs #endif // abs #ifdef __cplusplus template auto min(const T& a, const L& b) -> decltype((b < a) ? b : a) { - return (b < a) ? b : a; + return (b < a) ? b : a; } template auto max(const T& a, const L& b) -> decltype((b < a) ? b : a) { - return (a < b) ? b : a; + return (a < b) ? b : a; } #else #ifndef min @@ -147,8 +147,8 @@ auto max(const T& a, const L& b) -> decltype((b < a) ? b : a) static inline unsigned char __interruptsStatus(void) __attribute__((always_inline, unused)); static inline unsigned char __interruptsStatus(void) { - // See http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0497a/CHDBIBGJ.html - return (__get_PRIMASK() ? 0 : 1); + // See http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0497a/CHDBIBGJ.html + return (__get_PRIMASK() ? 0 : 1); } #define interruptsStatus() __interruptsStatus() #endif @@ -164,18 +164,18 @@ static inline unsigned char __interruptsStatus(void) #define bit(b) (1UL << (b)) #if (ARDUINO_SAMD_VARIANT_COMPLIANCE >= 10606) - // Interrupts - #define digitalPinToInterrupt(P) ( P ) + // Interrupts + #define digitalPinToInterrupt(P) ( P ) #endif // USB #ifdef USE_TINYUSB - #include "Adafruit_TinyUSB_Core.h" + #include "Adafruit_TinyUSB_Core.h" #else - #include "USB/USBDesc.h" - #include "USB/USBCore.h" - #include "USB/USBAPI.h" - #include "USB/USB_host.h" + #include "USB/USBDesc.h" + #include "USB/USBCore.h" + #include "USB/USBAPI.h" + #include "USB/USB_host.h" #endif #endif // Arduino_h diff --git a/Packages_Patches/Seeeduino/hardware/samd/1.8.3/cores/arduino/Print.cpp b/Packages_Patches/Seeeduino/hardware/samd/1.8.3/cores/arduino/Print.cpp index b47efa1a..d2db9576 100644 --- a/Packages_Patches/Seeeduino/hardware/samd/1.8.3/cores/arduino/Print.cpp +++ b/Packages_Patches/Seeeduino/hardware/samd/1.8.3/cores/arduino/Print.cpp @@ -35,259 +35,259 @@ /* default implementation: may be overridden */ size_t Print::write(const uint8_t *buffer, size_t size) { - size_t n = 0; + size_t n = 0; - while (size--) - { - if (write(*buffer++)) - n++; - else - break; - } + while (size--) + { + if (write(*buffer++)) + n++; + else + break; + } - return n; + return n; } size_t Print::print(const __FlashStringHelper *ifsh) { - return print(reinterpret_cast(ifsh)); + return print(reinterpret_cast(ifsh)); } size_t Print::print(const String &s) { - return write(s.c_str(), s.length()); + return write(s.c_str(), s.length()); } size_t Print::print(const char str[]) { - return write(str); + return write(str); } size_t Print::print(char c) { - return write(c); + return write(c); } size_t Print::print(unsigned char b, int base) { - return print((unsigned long) b, base); + return print((unsigned long) b, base); } size_t Print::print(int n, int base) { - return print((long) n, base); + return print((long) n, base); } size_t Print::print(unsigned int n, int base) { - return print((unsigned long) n, base); + return print((unsigned long) n, base); } size_t Print::print(long n, int base) { - if (base == 0) - { - return write(n); - } - else if (base == 10) - { - if (n < 0) - { - int t = print('-'); - n = -n; - return printNumber(n, 10) + t; - } - - return printNumber(n, 10); - } - else - { - return printNumber(n, base); - } + if (base == 0) + { + return write(n); + } + else if (base == 10) + { + if (n < 0) + { + int t = print('-'); + n = -n; + return printNumber(n, 10) + t; + } + + return printNumber(n, 10); + } + else + { + return printNumber(n, base); + } } size_t Print::print(unsigned long n, int base) { - if (base == 0) - return write(n); - else - return printNumber(n, base); + if (base == 0) + return write(n); + else + return printNumber(n, base); } size_t Print::print(long long n, int base) { - if (base == 0) - { - return write(n); - } - else if (base == 10) - { - if (n < 0) - { - int t = print('-'); - n = -n; - return printULLNumber(n, 10) + t; - } - - return printULLNumber(n, 10); - } - else - { - return printULLNumber(n, base); - } + if (base == 0) + { + return write(n); + } + else if (base == 10) + { + if (n < 0) + { + int t = print('-'); + n = -n; + return printULLNumber(n, 10) + t; + } + + return printULLNumber(n, 10); + } + else + { + return printULLNumber(n, base); + } } size_t Print::print(unsigned long long n, int base) { - if (base == 0) - return write(n); - else - return printULLNumber(n, base); + if (base == 0) + return write(n); + else + return printULLNumber(n, base); } size_t Print::print(double n, int digits) { - return printFloat(n, digits); + return printFloat(n, digits); } size_t Print::println(const __FlashStringHelper *ifsh) { - size_t n = print(ifsh); - n += println(); - return n; + size_t n = print(ifsh); + n += println(); + return n; } size_t Print::print(const Printable& x) { - return x.printTo(*this); + return x.printTo(*this); } size_t Print::println(void) { - return write("\r\n"); + return write("\r\n"); } size_t Print::println(const String &s) { - size_t n = print(s); - n += println(); - return n; + size_t n = print(s); + n += println(); + return n; } size_t Print::println(const char c[]) { - size_t n = print(c); - n += println(); - return n; + size_t n = print(c); + n += println(); + return n; } size_t Print::println(char c) { - size_t n = print(c); - n += println(); - return n; + size_t n = print(c); + n += println(); + return n; } size_t Print::println(unsigned char b, int base) { - size_t n = print(b, base); - n += println(); - return n; + size_t n = print(b, base); + n += println(); + return n; } size_t Print::println(int num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned int num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(long long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned long long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(double num, int digits) { - size_t n = print(num, digits); - n += println(); - return n; + size_t n = print(num, digits); + n += println(); + return n; } size_t Print::println(const Printable& x) { - size_t n = print(x); - n += println(); - return n; + size_t n = print(x); + n += println(); + return n; } size_t Print::printf(const char * format, ...) { - char buf[256]; - int len; + char buf[256]; + int len; - va_list ap; - va_start(ap, format); + va_list ap; + va_start(ap, format); - len = vsnprintf(buf, 256, format, ap); - this->write(buf, len); + len = vsnprintf(buf, 256, format, ap); + this->write(buf, len); - va_end(ap); - return len; + va_end(ap); + return len; } // Private Methods ///////////////////////////////////////////////////////////// size_t Print::printNumber(unsigned long n, uint8_t base) { - char buf[8 * sizeof(long) + 1]; // Assumes 8-bit chars plus zero byte. - char *str = &buf[sizeof(buf) - 1]; + char buf[8 * sizeof(long) + 1]; // Assumes 8-bit chars plus zero byte. + char *str = &buf[sizeof(buf) - 1]; - *str = '\0'; + *str = '\0'; - // prevent crash if called with base == 1 - if (base < 2) - base = 10; + // prevent crash if called with base == 1 + if (base < 2) + base = 10; - do - { - char c = n % base; - n /= base; + do + { + char c = n % base; + n /= base; - *--str = c < 10 ? c + '0' : c + 'A' - 10; - } while (n); + *--str = c < 10 ? c + '0' : c + 'A' - 10; + } while (n); - return write(str); + return write(str); } // REFERENCE IMPLEMENTATION FOR ULL @@ -315,152 +315,152 @@ size_t Print::printNumber(unsigned long n, uint8_t base) // FAST IMPLEMENTATION FOR ULL size_t Print::printULLNumber(unsigned long long n64, uint8_t base) { - // if limited to base 10 and 16 the bufsize can be 20 - char buf[64]; - uint8_t i = 0; - uint8_t innerLoops = 0; + // if limited to base 10 and 16 the bufsize can be 20 + char buf[64]; + uint8_t i = 0; + uint8_t innerLoops = 0; - // prevent crash if called with base == 1 - if (base < 2) - base = 10; + // prevent crash if called with base == 1 + if (base < 2) + base = 10; - // process chunks that fit in "16 bit math". - uint16_t top = 0xFFFF / base; - uint16_t th16 = 1; + // process chunks that fit in "16 bit math". + uint16_t top = 0xFFFF / base; + uint16_t th16 = 1; - while (th16 < top) - { - th16 *= base; - innerLoops++; - } + while (th16 < top) + { + th16 *= base; + innerLoops++; + } - while (n64 > th16) - { - // 64 bit math part - uint64_t q = n64 / th16; - uint16_t r = n64 - q * th16; - n64 = q; + while (n64 > th16) + { + // 64 bit math part + uint64_t q = n64 / th16; + uint16_t r = n64 - q * th16; + n64 = q; - // 16 bit math loop to do remainder. (note buffer is filled reverse) - for (uint8_t j = 0; j < innerLoops; j++) - { - uint16_t qq = r / base; - buf[i++] = r - qq * base; - r = qq; - } - } + // 16 bit math loop to do remainder. (note buffer is filled reverse) + for (uint8_t j = 0; j < innerLoops; j++) + { + uint16_t qq = r / base; + buf[i++] = r - qq * base; + r = qq; + } + } - uint16_t n16 = n64; + uint16_t n16 = n64; - while (n16 > 0) - { - uint16_t qq = n16 / base; - buf[i++] = n16 - qq * base; - n16 = qq; - } + while (n16 > 0) + { + uint16_t qq = n16 / base; + buf[i++] = n16 - qq * base; + n16 = qq; + } - size_t bytes = i; + size_t bytes = i; - for (; i > 0; i--) - write((char) (buf[i - 1] < 10 ? - '0' + buf[i - 1] : - 'A' + buf[i - 1] - 10)); + for (; i > 0; i--) + write((char) (buf[i - 1] < 10 ? + '0' + buf[i - 1] : + 'A' + buf[i - 1] - 10)); - return bytes; + return bytes; } size_t Print::printFloat(double number, int digits) { - if (digits < 0) - digits = 2; + if (digits < 0) + digits = 2; - size_t n = 0; + size_t n = 0; - if (isnan(number)) - return print("nan"); + if (isnan(number)) + return print("nan"); - if (isinf(number)) - return print("inf"); + if (isinf(number)) + return print("inf"); - if (number > 4294967040.0) - return print ("ovf"); // constant determined empirically + if (number > 4294967040.0) + return print ("ovf"); // constant determined empirically - if (number < -4294967040.0) - return print ("ovf"); // constant determined empirically + if (number < -4294967040.0) + return print ("ovf"); // constant determined empirically - // Handle negative numbers - if (number < 0.0) - { - n += print('-'); - number = -number; - } + // Handle negative numbers + if (number < 0.0) + { + n += print('-'); + number = -number; + } - // Round correctly so that print(1.999, 2) prints as "2.00" - double rounding = 0.5; + // Round correctly so that print(1.999, 2) prints as "2.00" + double rounding = 0.5; - for (uint8_t i = 0; i < digits; ++i) - rounding /= 10.0; + for (uint8_t i = 0; i < digits; ++i) + rounding /= 10.0; - number += rounding; + number += rounding; - // Extract the integer part of the number and print it - unsigned long int_part = (unsigned long)number; - double remainder = number - (double)int_part; - n += print(int_part); + // Extract the integer part of the number and print it + unsigned long int_part = (unsigned long)number; + double remainder = number - (double)int_part; + n += print(int_part); - // Print the decimal point, but only if there are digits beyond - if (digits > 0) - { - n += print("."); - } + // Print the decimal point, but only if there are digits beyond + if (digits > 0) + { + n += print("."); + } - // Extract digits from the remainder one at a time - while (digits-- > 0) - { - remainder *= 10.0; - unsigned int toPrint = (unsigned int)remainder; - n += print(toPrint); - remainder -= toPrint; - } + // Extract digits from the remainder one at a time + while (digits-- > 0) + { + remainder *= 10.0; + unsigned int toPrint = (unsigned int)remainder; + n += print(toPrint); + remainder -= toPrint; + } - return n; + return n; } size_t Print::printBuffer(uint8_t const buffer[], int len, char delim, int byteline) { - if (buffer == NULL || len == 0) - return 0; + if (buffer == NULL || len == 0) + return 0; - for (int i = 0; i < len; i++) - { - if ( i != 0 ) - print(delim); + for (int i = 0; i < len; i++) + { + if ( i != 0 ) + print(delim); - if ( byteline && (i % byteline == 0) ) - println(); + if ( byteline && (i % byteline == 0) ) + println(); - this->printf("%02X", buffer[i]); - } + this->printf("%02X", buffer[i]); + } - return (len * 3 - 1); + return (len * 3 - 1); } size_t Print::printBufferReverse(uint8_t const buffer[], int len, char delim, int byteline) { - if (buffer == NULL || len == 0) - return 0; + if (buffer == NULL || len == 0) + return 0; - for (int i = 0; i < len; i++) - { - if (i != 0) - print(delim); + for (int i = 0; i < len; i++) + { + if (i != 0) + print(delim); - if ( byteline && (i % byteline == 0) ) - println(); + if ( byteline && (i % byteline == 0) ) + println(); - this->printf("%02X", buffer[len - 1 - i]); - } + this->printf("%02X", buffer[len - 1 - i]); + } - return (len * 3 - 1); + return (len * 3 - 1); } diff --git a/Packages_Patches/Seeeduino/hardware/samd/1.8.3/cores/arduino/Print.h b/Packages_Patches/Seeeduino/hardware/samd/1.8.3/cores/arduino/Print.h index a465eddb..6c08258b 100644 --- a/Packages_Patches/Seeeduino/hardware/samd/1.8.3/cores/arduino/Print.h +++ b/Packages_Patches/Seeeduino/hardware/samd/1.8.3/cores/arduino/Print.h @@ -32,93 +32,93 @@ class Print { - private: - int write_error; - size_t printNumber(unsigned long, uint8_t); - size_t printULLNumber(unsigned long long, uint8_t); - size_t printFloat(double, int); - protected: - void setWriteError(int err = 1) - { - write_error = err; - } - public: - Print() : write_error(0) {} - - int getWriteError() - { - return write_error; - } - void clearWriteError() - { - setWriteError(0); - } - - virtual size_t write(uint8_t) = 0; - size_t write(const char *str) - { - if (str == NULL) - return 0; - - return write((const uint8_t *)str, strlen(str)); - } - virtual size_t write(const uint8_t *buffer, size_t size); - size_t write(const char *buffer, size_t size) - { - return write((const uint8_t *)buffer, size); - } - - // default to zero, meaning "a single write may block" - // should be overridden by subclasses with buffering - virtual int availableForWrite() - { - return 0; - } - - size_t print(const __FlashStringHelper *); - size_t print(const String &); - size_t print(const char[]); - size_t print(char); - size_t print(unsigned char, int = DEC); - size_t print(int, int = DEC); - size_t print(unsigned int, int = DEC); - size_t print(long, int = DEC); - size_t print(unsigned long, int = DEC); - size_t print(long long, int = DEC); - size_t print(unsigned long long, int = DEC); - size_t print(double, int = 2); - size_t print(const Printable&); - - size_t println(const __FlashStringHelper *); - size_t println(const String &s); - size_t println(const char[]); - size_t println(char); - size_t println(unsigned char, int = DEC); - size_t println(int, int = DEC); - size_t println(unsigned int, int = DEC); - size_t println(long, int = DEC); - size_t println(unsigned long, int = DEC); - size_t println(long long, int = DEC); - size_t println(unsigned long long, int = DEC); - size_t println(double, int = 2); - size_t println(const Printable&); - size_t println(void); - - size_t printf(const char * format, ...); - - size_t printBuffer(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); - size_t printBuffer(char const buffer[], int size, char delim = ' ', int byteline = 0) - { - return printBuffer((uint8_t const*) buffer, size, delim, byteline); - } - - size_t printBufferReverse(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); - size_t printBufferReverse(char const buffer[], int size, char delim = ' ', int byteline = 0) - { - return printBufferReverse((uint8_t const*) buffer, size, delim, byteline); - } - - virtual void flush() { /* Empty implementation for backward compatibility */ } + private: + int write_error; + size_t printNumber(unsigned long, uint8_t); + size_t printULLNumber(unsigned long long, uint8_t); + size_t printFloat(double, int); + protected: + void setWriteError(int err = 1) + { + write_error = err; + } + public: + Print() : write_error(0) {} + + int getWriteError() + { + return write_error; + } + void clearWriteError() + { + setWriteError(0); + } + + virtual size_t write(uint8_t) = 0; + size_t write(const char *str) + { + if (str == NULL) + return 0; + + return write((const uint8_t *)str, strlen(str)); + } + virtual size_t write(const uint8_t *buffer, size_t size); + size_t write(const char *buffer, size_t size) + { + return write((const uint8_t *)buffer, size); + } + + // default to zero, meaning "a single write may block" + // should be overridden by subclasses with buffering + virtual int availableForWrite() + { + return 0; + } + + size_t print(const __FlashStringHelper *); + size_t print(const String &); + size_t print(const char[]); + size_t print(char); + size_t print(unsigned char, int = DEC); + size_t print(int, int = DEC); + size_t print(unsigned int, int = DEC); + size_t print(long, int = DEC); + size_t print(unsigned long, int = DEC); + size_t print(long long, int = DEC); + size_t print(unsigned long long, int = DEC); + size_t print(double, int = 2); + size_t print(const Printable&); + + size_t println(const __FlashStringHelper *); + size_t println(const String &s); + size_t println(const char[]); + size_t println(char); + size_t println(unsigned char, int = DEC); + size_t println(int, int = DEC); + size_t println(unsigned int, int = DEC); + size_t println(long, int = DEC); + size_t println(unsigned long, int = DEC); + size_t println(long long, int = DEC); + size_t println(unsigned long long, int = DEC); + size_t println(double, int = 2); + size_t println(const Printable&); + size_t println(void); + + size_t printf(const char * format, ...); + + size_t printBuffer(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); + size_t printBuffer(char const buffer[], int size, char delim = ' ', int byteline = 0) + { + return printBuffer((uint8_t const*) buffer, size, delim, byteline); + } + + size_t printBufferReverse(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); + size_t printBufferReverse(char const buffer[], int size, char delim = ' ', int byteline = 0) + { + return printBufferReverse((uint8_t const*) buffer, size, delim, byteline); + } + + virtual void flush() { /* Empty implementation for backward compatibility */ } }; diff --git a/Packages_Patches/SparkFun/hardware/samd/1.8.3/cores/arduino/Print.cpp b/Packages_Patches/SparkFun/hardware/samd/1.8.3/cores/arduino/Print.cpp index b47efa1a..d2db9576 100644 --- a/Packages_Patches/SparkFun/hardware/samd/1.8.3/cores/arduino/Print.cpp +++ b/Packages_Patches/SparkFun/hardware/samd/1.8.3/cores/arduino/Print.cpp @@ -35,259 +35,259 @@ /* default implementation: may be overridden */ size_t Print::write(const uint8_t *buffer, size_t size) { - size_t n = 0; + size_t n = 0; - while (size--) - { - if (write(*buffer++)) - n++; - else - break; - } + while (size--) + { + if (write(*buffer++)) + n++; + else + break; + } - return n; + return n; } size_t Print::print(const __FlashStringHelper *ifsh) { - return print(reinterpret_cast(ifsh)); + return print(reinterpret_cast(ifsh)); } size_t Print::print(const String &s) { - return write(s.c_str(), s.length()); + return write(s.c_str(), s.length()); } size_t Print::print(const char str[]) { - return write(str); + return write(str); } size_t Print::print(char c) { - return write(c); + return write(c); } size_t Print::print(unsigned char b, int base) { - return print((unsigned long) b, base); + return print((unsigned long) b, base); } size_t Print::print(int n, int base) { - return print((long) n, base); + return print((long) n, base); } size_t Print::print(unsigned int n, int base) { - return print((unsigned long) n, base); + return print((unsigned long) n, base); } size_t Print::print(long n, int base) { - if (base == 0) - { - return write(n); - } - else if (base == 10) - { - if (n < 0) - { - int t = print('-'); - n = -n; - return printNumber(n, 10) + t; - } - - return printNumber(n, 10); - } - else - { - return printNumber(n, base); - } + if (base == 0) + { + return write(n); + } + else if (base == 10) + { + if (n < 0) + { + int t = print('-'); + n = -n; + return printNumber(n, 10) + t; + } + + return printNumber(n, 10); + } + else + { + return printNumber(n, base); + } } size_t Print::print(unsigned long n, int base) { - if (base == 0) - return write(n); - else - return printNumber(n, base); + if (base == 0) + return write(n); + else + return printNumber(n, base); } size_t Print::print(long long n, int base) { - if (base == 0) - { - return write(n); - } - else if (base == 10) - { - if (n < 0) - { - int t = print('-'); - n = -n; - return printULLNumber(n, 10) + t; - } - - return printULLNumber(n, 10); - } - else - { - return printULLNumber(n, base); - } + if (base == 0) + { + return write(n); + } + else if (base == 10) + { + if (n < 0) + { + int t = print('-'); + n = -n; + return printULLNumber(n, 10) + t; + } + + return printULLNumber(n, 10); + } + else + { + return printULLNumber(n, base); + } } size_t Print::print(unsigned long long n, int base) { - if (base == 0) - return write(n); - else - return printULLNumber(n, base); + if (base == 0) + return write(n); + else + return printULLNumber(n, base); } size_t Print::print(double n, int digits) { - return printFloat(n, digits); + return printFloat(n, digits); } size_t Print::println(const __FlashStringHelper *ifsh) { - size_t n = print(ifsh); - n += println(); - return n; + size_t n = print(ifsh); + n += println(); + return n; } size_t Print::print(const Printable& x) { - return x.printTo(*this); + return x.printTo(*this); } size_t Print::println(void) { - return write("\r\n"); + return write("\r\n"); } size_t Print::println(const String &s) { - size_t n = print(s); - n += println(); - return n; + size_t n = print(s); + n += println(); + return n; } size_t Print::println(const char c[]) { - size_t n = print(c); - n += println(); - return n; + size_t n = print(c); + n += println(); + return n; } size_t Print::println(char c) { - size_t n = print(c); - n += println(); - return n; + size_t n = print(c); + n += println(); + return n; } size_t Print::println(unsigned char b, int base) { - size_t n = print(b, base); - n += println(); - return n; + size_t n = print(b, base); + n += println(); + return n; } size_t Print::println(int num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned int num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(long long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned long long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(double num, int digits) { - size_t n = print(num, digits); - n += println(); - return n; + size_t n = print(num, digits); + n += println(); + return n; } size_t Print::println(const Printable& x) { - size_t n = print(x); - n += println(); - return n; + size_t n = print(x); + n += println(); + return n; } size_t Print::printf(const char * format, ...) { - char buf[256]; - int len; + char buf[256]; + int len; - va_list ap; - va_start(ap, format); + va_list ap; + va_start(ap, format); - len = vsnprintf(buf, 256, format, ap); - this->write(buf, len); + len = vsnprintf(buf, 256, format, ap); + this->write(buf, len); - va_end(ap); - return len; + va_end(ap); + return len; } // Private Methods ///////////////////////////////////////////////////////////// size_t Print::printNumber(unsigned long n, uint8_t base) { - char buf[8 * sizeof(long) + 1]; // Assumes 8-bit chars plus zero byte. - char *str = &buf[sizeof(buf) - 1]; + char buf[8 * sizeof(long) + 1]; // Assumes 8-bit chars plus zero byte. + char *str = &buf[sizeof(buf) - 1]; - *str = '\0'; + *str = '\0'; - // prevent crash if called with base == 1 - if (base < 2) - base = 10; + // prevent crash if called with base == 1 + if (base < 2) + base = 10; - do - { - char c = n % base; - n /= base; + do + { + char c = n % base; + n /= base; - *--str = c < 10 ? c + '0' : c + 'A' - 10; - } while (n); + *--str = c < 10 ? c + '0' : c + 'A' - 10; + } while (n); - return write(str); + return write(str); } // REFERENCE IMPLEMENTATION FOR ULL @@ -315,152 +315,152 @@ size_t Print::printNumber(unsigned long n, uint8_t base) // FAST IMPLEMENTATION FOR ULL size_t Print::printULLNumber(unsigned long long n64, uint8_t base) { - // if limited to base 10 and 16 the bufsize can be 20 - char buf[64]; - uint8_t i = 0; - uint8_t innerLoops = 0; + // if limited to base 10 and 16 the bufsize can be 20 + char buf[64]; + uint8_t i = 0; + uint8_t innerLoops = 0; - // prevent crash if called with base == 1 - if (base < 2) - base = 10; + // prevent crash if called with base == 1 + if (base < 2) + base = 10; - // process chunks that fit in "16 bit math". - uint16_t top = 0xFFFF / base; - uint16_t th16 = 1; + // process chunks that fit in "16 bit math". + uint16_t top = 0xFFFF / base; + uint16_t th16 = 1; - while (th16 < top) - { - th16 *= base; - innerLoops++; - } + while (th16 < top) + { + th16 *= base; + innerLoops++; + } - while (n64 > th16) - { - // 64 bit math part - uint64_t q = n64 / th16; - uint16_t r = n64 - q * th16; - n64 = q; + while (n64 > th16) + { + // 64 bit math part + uint64_t q = n64 / th16; + uint16_t r = n64 - q * th16; + n64 = q; - // 16 bit math loop to do remainder. (note buffer is filled reverse) - for (uint8_t j = 0; j < innerLoops; j++) - { - uint16_t qq = r / base; - buf[i++] = r - qq * base; - r = qq; - } - } + // 16 bit math loop to do remainder. (note buffer is filled reverse) + for (uint8_t j = 0; j < innerLoops; j++) + { + uint16_t qq = r / base; + buf[i++] = r - qq * base; + r = qq; + } + } - uint16_t n16 = n64; + uint16_t n16 = n64; - while (n16 > 0) - { - uint16_t qq = n16 / base; - buf[i++] = n16 - qq * base; - n16 = qq; - } + while (n16 > 0) + { + uint16_t qq = n16 / base; + buf[i++] = n16 - qq * base; + n16 = qq; + } - size_t bytes = i; + size_t bytes = i; - for (; i > 0; i--) - write((char) (buf[i - 1] < 10 ? - '0' + buf[i - 1] : - 'A' + buf[i - 1] - 10)); + for (; i > 0; i--) + write((char) (buf[i - 1] < 10 ? + '0' + buf[i - 1] : + 'A' + buf[i - 1] - 10)); - return bytes; + return bytes; } size_t Print::printFloat(double number, int digits) { - if (digits < 0) - digits = 2; + if (digits < 0) + digits = 2; - size_t n = 0; + size_t n = 0; - if (isnan(number)) - return print("nan"); + if (isnan(number)) + return print("nan"); - if (isinf(number)) - return print("inf"); + if (isinf(number)) + return print("inf"); - if (number > 4294967040.0) - return print ("ovf"); // constant determined empirically + if (number > 4294967040.0) + return print ("ovf"); // constant determined empirically - if (number < -4294967040.0) - return print ("ovf"); // constant determined empirically + if (number < -4294967040.0) + return print ("ovf"); // constant determined empirically - // Handle negative numbers - if (number < 0.0) - { - n += print('-'); - number = -number; - } + // Handle negative numbers + if (number < 0.0) + { + n += print('-'); + number = -number; + } - // Round correctly so that print(1.999, 2) prints as "2.00" - double rounding = 0.5; + // Round correctly so that print(1.999, 2) prints as "2.00" + double rounding = 0.5; - for (uint8_t i = 0; i < digits; ++i) - rounding /= 10.0; + for (uint8_t i = 0; i < digits; ++i) + rounding /= 10.0; - number += rounding; + number += rounding; - // Extract the integer part of the number and print it - unsigned long int_part = (unsigned long)number; - double remainder = number - (double)int_part; - n += print(int_part); + // Extract the integer part of the number and print it + unsigned long int_part = (unsigned long)number; + double remainder = number - (double)int_part; + n += print(int_part); - // Print the decimal point, but only if there are digits beyond - if (digits > 0) - { - n += print("."); - } + // Print the decimal point, but only if there are digits beyond + if (digits > 0) + { + n += print("."); + } - // Extract digits from the remainder one at a time - while (digits-- > 0) - { - remainder *= 10.0; - unsigned int toPrint = (unsigned int)remainder; - n += print(toPrint); - remainder -= toPrint; - } + // Extract digits from the remainder one at a time + while (digits-- > 0) + { + remainder *= 10.0; + unsigned int toPrint = (unsigned int)remainder; + n += print(toPrint); + remainder -= toPrint; + } - return n; + return n; } size_t Print::printBuffer(uint8_t const buffer[], int len, char delim, int byteline) { - if (buffer == NULL || len == 0) - return 0; + if (buffer == NULL || len == 0) + return 0; - for (int i = 0; i < len; i++) - { - if ( i != 0 ) - print(delim); + for (int i = 0; i < len; i++) + { + if ( i != 0 ) + print(delim); - if ( byteline && (i % byteline == 0) ) - println(); + if ( byteline && (i % byteline == 0) ) + println(); - this->printf("%02X", buffer[i]); - } + this->printf("%02X", buffer[i]); + } - return (len * 3 - 1); + return (len * 3 - 1); } size_t Print::printBufferReverse(uint8_t const buffer[], int len, char delim, int byteline) { - if (buffer == NULL || len == 0) - return 0; + if (buffer == NULL || len == 0) + return 0; - for (int i = 0; i < len; i++) - { - if (i != 0) - print(delim); + for (int i = 0; i < len; i++) + { + if (i != 0) + print(delim); - if ( byteline && (i % byteline == 0) ) - println(); + if ( byteline && (i % byteline == 0) ) + println(); - this->printf("%02X", buffer[len - 1 - i]); - } + this->printf("%02X", buffer[len - 1 - i]); + } - return (len * 3 - 1); + return (len * 3 - 1); } diff --git a/Packages_Patches/SparkFun/hardware/samd/1.8.3/cores/arduino/Print.h b/Packages_Patches/SparkFun/hardware/samd/1.8.3/cores/arduino/Print.h index 810a7704..d03d1cc8 100644 --- a/Packages_Patches/SparkFun/hardware/samd/1.8.3/cores/arduino/Print.h +++ b/Packages_Patches/SparkFun/hardware/samd/1.8.3/cores/arduino/Print.h @@ -31,93 +31,93 @@ class Print { - private: - int write_error; - size_t printNumber(unsigned long, uint8_t); - size_t printULLNumber(unsigned long long, uint8_t); - size_t printFloat(double, int); - protected: - void setWriteError(int err = 1) - { - write_error = err; - } - public: - Print() : write_error(0) {} - - int getWriteError() - { - return write_error; - } - void clearWriteError() - { - setWriteError(0); - } - - virtual size_t write(uint8_t) = 0; - size_t write(const char *str) - { - if (str == NULL) - return 0; - - return write((const uint8_t *)str, strlen(str)); - } - virtual size_t write(const uint8_t *buffer, size_t size); - size_t write(const char *buffer, size_t size) - { - return write((const uint8_t *)buffer, size); - } - - // default to zero, meaning "a single write may block" - // should be overridden by subclasses with buffering - virtual int availableForWrite() - { - return 0; - } - - size_t print(const __FlashStringHelper *); - size_t print(const String &); - size_t print(const char[]); - size_t print(char); - size_t print(unsigned char, int = DEC); - size_t print(int, int = DEC); - size_t print(unsigned int, int = DEC); - size_t print(long, int = DEC); - size_t print(unsigned long, int = DEC); - size_t print(long long, int = DEC); - size_t print(unsigned long long, int = DEC); - size_t print(double, int = 2); - size_t print(const Printable&); - - size_t println(const __FlashStringHelper *); - size_t println(const String &s); - size_t println(const char[]); - size_t println(char); - size_t println(unsigned char, int = DEC); - size_t println(int, int = DEC); - size_t println(unsigned int, int = DEC); - size_t println(long, int = DEC); - size_t println(unsigned long, int = DEC); - size_t println(long long, int = DEC); - size_t println(unsigned long long, int = DEC); - size_t println(double, int = 2); - size_t println(const Printable&); - size_t println(void); - - size_t printf(const char * format, ...); - - size_t printBuffer(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); - size_t printBuffer(char const buffer[], int size, char delim = ' ', int byteline = 0) - { - return printBuffer((uint8_t const*) buffer, size, delim, byteline); - } - - size_t printBufferReverse(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); - size_t printBufferReverse(char const buffer[], int size, char delim = ' ', int byteline = 0) - { - return printBufferReverse((uint8_t const*) buffer, size, delim, byteline); - } - - virtual void flush() { /* Empty implementation for backward compatibility */ } + private: + int write_error; + size_t printNumber(unsigned long, uint8_t); + size_t printULLNumber(unsigned long long, uint8_t); + size_t printFloat(double, int); + protected: + void setWriteError(int err = 1) + { + write_error = err; + } + public: + Print() : write_error(0) {} + + int getWriteError() + { + return write_error; + } + void clearWriteError() + { + setWriteError(0); + } + + virtual size_t write(uint8_t) = 0; + size_t write(const char *str) + { + if (str == NULL) + return 0; + + return write((const uint8_t *)str, strlen(str)); + } + virtual size_t write(const uint8_t *buffer, size_t size); + size_t write(const char *buffer, size_t size) + { + return write((const uint8_t *)buffer, size); + } + + // default to zero, meaning "a single write may block" + // should be overridden by subclasses with buffering + virtual int availableForWrite() + { + return 0; + } + + size_t print(const __FlashStringHelper *); + size_t print(const String &); + size_t print(const char[]); + size_t print(char); + size_t print(unsigned char, int = DEC); + size_t print(int, int = DEC); + size_t print(unsigned int, int = DEC); + size_t print(long, int = DEC); + size_t print(unsigned long, int = DEC); + size_t print(long long, int = DEC); + size_t print(unsigned long long, int = DEC); + size_t print(double, int = 2); + size_t print(const Printable&); + + size_t println(const __FlashStringHelper *); + size_t println(const String &s); + size_t println(const char[]); + size_t println(char); + size_t println(unsigned char, int = DEC); + size_t println(int, int = DEC); + size_t println(unsigned int, int = DEC); + size_t println(long, int = DEC); + size_t println(unsigned long, int = DEC); + size_t println(long long, int = DEC); + size_t println(unsigned long long, int = DEC); + size_t println(double, int = 2); + size_t println(const Printable&); + size_t println(void); + + size_t printf(const char * format, ...); + + size_t printBuffer(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); + size_t printBuffer(char const buffer[], int size, char delim = ' ', int byteline = 0) + { + return printBuffer((uint8_t const*) buffer, size, delim, byteline); + } + + size_t printBufferReverse(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); + size_t printBufferReverse(char const buffer[], int size, char delim = ' ', int byteline = 0) + { + return printBufferReverse((uint8_t const*) buffer, size, delim, byteline); + } + + virtual void flush() { /* Empty implementation for backward compatibility */ } }; diff --git a/Packages_Patches/SparkFun/hardware/samd/1.8.3/cores/arduino51/Print.cpp b/Packages_Patches/SparkFun/hardware/samd/1.8.3/cores/arduino51/Print.cpp index b47efa1a..d2db9576 100644 --- a/Packages_Patches/SparkFun/hardware/samd/1.8.3/cores/arduino51/Print.cpp +++ b/Packages_Patches/SparkFun/hardware/samd/1.8.3/cores/arduino51/Print.cpp @@ -35,259 +35,259 @@ /* default implementation: may be overridden */ size_t Print::write(const uint8_t *buffer, size_t size) { - size_t n = 0; + size_t n = 0; - while (size--) - { - if (write(*buffer++)) - n++; - else - break; - } + while (size--) + { + if (write(*buffer++)) + n++; + else + break; + } - return n; + return n; } size_t Print::print(const __FlashStringHelper *ifsh) { - return print(reinterpret_cast(ifsh)); + return print(reinterpret_cast(ifsh)); } size_t Print::print(const String &s) { - return write(s.c_str(), s.length()); + return write(s.c_str(), s.length()); } size_t Print::print(const char str[]) { - return write(str); + return write(str); } size_t Print::print(char c) { - return write(c); + return write(c); } size_t Print::print(unsigned char b, int base) { - return print((unsigned long) b, base); + return print((unsigned long) b, base); } size_t Print::print(int n, int base) { - return print((long) n, base); + return print((long) n, base); } size_t Print::print(unsigned int n, int base) { - return print((unsigned long) n, base); + return print((unsigned long) n, base); } size_t Print::print(long n, int base) { - if (base == 0) - { - return write(n); - } - else if (base == 10) - { - if (n < 0) - { - int t = print('-'); - n = -n; - return printNumber(n, 10) + t; - } - - return printNumber(n, 10); - } - else - { - return printNumber(n, base); - } + if (base == 0) + { + return write(n); + } + else if (base == 10) + { + if (n < 0) + { + int t = print('-'); + n = -n; + return printNumber(n, 10) + t; + } + + return printNumber(n, 10); + } + else + { + return printNumber(n, base); + } } size_t Print::print(unsigned long n, int base) { - if (base == 0) - return write(n); - else - return printNumber(n, base); + if (base == 0) + return write(n); + else + return printNumber(n, base); } size_t Print::print(long long n, int base) { - if (base == 0) - { - return write(n); - } - else if (base == 10) - { - if (n < 0) - { - int t = print('-'); - n = -n; - return printULLNumber(n, 10) + t; - } - - return printULLNumber(n, 10); - } - else - { - return printULLNumber(n, base); - } + if (base == 0) + { + return write(n); + } + else if (base == 10) + { + if (n < 0) + { + int t = print('-'); + n = -n; + return printULLNumber(n, 10) + t; + } + + return printULLNumber(n, 10); + } + else + { + return printULLNumber(n, base); + } } size_t Print::print(unsigned long long n, int base) { - if (base == 0) - return write(n); - else - return printULLNumber(n, base); + if (base == 0) + return write(n); + else + return printULLNumber(n, base); } size_t Print::print(double n, int digits) { - return printFloat(n, digits); + return printFloat(n, digits); } size_t Print::println(const __FlashStringHelper *ifsh) { - size_t n = print(ifsh); - n += println(); - return n; + size_t n = print(ifsh); + n += println(); + return n; } size_t Print::print(const Printable& x) { - return x.printTo(*this); + return x.printTo(*this); } size_t Print::println(void) { - return write("\r\n"); + return write("\r\n"); } size_t Print::println(const String &s) { - size_t n = print(s); - n += println(); - return n; + size_t n = print(s); + n += println(); + return n; } size_t Print::println(const char c[]) { - size_t n = print(c); - n += println(); - return n; + size_t n = print(c); + n += println(); + return n; } size_t Print::println(char c) { - size_t n = print(c); - n += println(); - return n; + size_t n = print(c); + n += println(); + return n; } size_t Print::println(unsigned char b, int base) { - size_t n = print(b, base); - n += println(); - return n; + size_t n = print(b, base); + n += println(); + return n; } size_t Print::println(int num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned int num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(long long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(unsigned long long num, int base) { - size_t n = print(num, base); - n += println(); - return n; + size_t n = print(num, base); + n += println(); + return n; } size_t Print::println(double num, int digits) { - size_t n = print(num, digits); - n += println(); - return n; + size_t n = print(num, digits); + n += println(); + return n; } size_t Print::println(const Printable& x) { - size_t n = print(x); - n += println(); - return n; + size_t n = print(x); + n += println(); + return n; } size_t Print::printf(const char * format, ...) { - char buf[256]; - int len; + char buf[256]; + int len; - va_list ap; - va_start(ap, format); + va_list ap; + va_start(ap, format); - len = vsnprintf(buf, 256, format, ap); - this->write(buf, len); + len = vsnprintf(buf, 256, format, ap); + this->write(buf, len); - va_end(ap); - return len; + va_end(ap); + return len; } // Private Methods ///////////////////////////////////////////////////////////// size_t Print::printNumber(unsigned long n, uint8_t base) { - char buf[8 * sizeof(long) + 1]; // Assumes 8-bit chars plus zero byte. - char *str = &buf[sizeof(buf) - 1]; + char buf[8 * sizeof(long) + 1]; // Assumes 8-bit chars plus zero byte. + char *str = &buf[sizeof(buf) - 1]; - *str = '\0'; + *str = '\0'; - // prevent crash if called with base == 1 - if (base < 2) - base = 10; + // prevent crash if called with base == 1 + if (base < 2) + base = 10; - do - { - char c = n % base; - n /= base; + do + { + char c = n % base; + n /= base; - *--str = c < 10 ? c + '0' : c + 'A' - 10; - } while (n); + *--str = c < 10 ? c + '0' : c + 'A' - 10; + } while (n); - return write(str); + return write(str); } // REFERENCE IMPLEMENTATION FOR ULL @@ -315,152 +315,152 @@ size_t Print::printNumber(unsigned long n, uint8_t base) // FAST IMPLEMENTATION FOR ULL size_t Print::printULLNumber(unsigned long long n64, uint8_t base) { - // if limited to base 10 and 16 the bufsize can be 20 - char buf[64]; - uint8_t i = 0; - uint8_t innerLoops = 0; + // if limited to base 10 and 16 the bufsize can be 20 + char buf[64]; + uint8_t i = 0; + uint8_t innerLoops = 0; - // prevent crash if called with base == 1 - if (base < 2) - base = 10; + // prevent crash if called with base == 1 + if (base < 2) + base = 10; - // process chunks that fit in "16 bit math". - uint16_t top = 0xFFFF / base; - uint16_t th16 = 1; + // process chunks that fit in "16 bit math". + uint16_t top = 0xFFFF / base; + uint16_t th16 = 1; - while (th16 < top) - { - th16 *= base; - innerLoops++; - } + while (th16 < top) + { + th16 *= base; + innerLoops++; + } - while (n64 > th16) - { - // 64 bit math part - uint64_t q = n64 / th16; - uint16_t r = n64 - q * th16; - n64 = q; + while (n64 > th16) + { + // 64 bit math part + uint64_t q = n64 / th16; + uint16_t r = n64 - q * th16; + n64 = q; - // 16 bit math loop to do remainder. (note buffer is filled reverse) - for (uint8_t j = 0; j < innerLoops; j++) - { - uint16_t qq = r / base; - buf[i++] = r - qq * base; - r = qq; - } - } + // 16 bit math loop to do remainder. (note buffer is filled reverse) + for (uint8_t j = 0; j < innerLoops; j++) + { + uint16_t qq = r / base; + buf[i++] = r - qq * base; + r = qq; + } + } - uint16_t n16 = n64; + uint16_t n16 = n64; - while (n16 > 0) - { - uint16_t qq = n16 / base; - buf[i++] = n16 - qq * base; - n16 = qq; - } + while (n16 > 0) + { + uint16_t qq = n16 / base; + buf[i++] = n16 - qq * base; + n16 = qq; + } - size_t bytes = i; + size_t bytes = i; - for (; i > 0; i--) - write((char) (buf[i - 1] < 10 ? - '0' + buf[i - 1] : - 'A' + buf[i - 1] - 10)); + for (; i > 0; i--) + write((char) (buf[i - 1] < 10 ? + '0' + buf[i - 1] : + 'A' + buf[i - 1] - 10)); - return bytes; + return bytes; } size_t Print::printFloat(double number, int digits) { - if (digits < 0) - digits = 2; + if (digits < 0) + digits = 2; - size_t n = 0; + size_t n = 0; - if (isnan(number)) - return print("nan"); + if (isnan(number)) + return print("nan"); - if (isinf(number)) - return print("inf"); + if (isinf(number)) + return print("inf"); - if (number > 4294967040.0) - return print ("ovf"); // constant determined empirically + if (number > 4294967040.0) + return print ("ovf"); // constant determined empirically - if (number < -4294967040.0) - return print ("ovf"); // constant determined empirically + if (number < -4294967040.0) + return print ("ovf"); // constant determined empirically - // Handle negative numbers - if (number < 0.0) - { - n += print('-'); - number = -number; - } + // Handle negative numbers + if (number < 0.0) + { + n += print('-'); + number = -number; + } - // Round correctly so that print(1.999, 2) prints as "2.00" - double rounding = 0.5; + // Round correctly so that print(1.999, 2) prints as "2.00" + double rounding = 0.5; - for (uint8_t i = 0; i < digits; ++i) - rounding /= 10.0; + for (uint8_t i = 0; i < digits; ++i) + rounding /= 10.0; - number += rounding; + number += rounding; - // Extract the integer part of the number and print it - unsigned long int_part = (unsigned long)number; - double remainder = number - (double)int_part; - n += print(int_part); + // Extract the integer part of the number and print it + unsigned long int_part = (unsigned long)number; + double remainder = number - (double)int_part; + n += print(int_part); - // Print the decimal point, but only if there are digits beyond - if (digits > 0) - { - n += print("."); - } + // Print the decimal point, but only if there are digits beyond + if (digits > 0) + { + n += print("."); + } - // Extract digits from the remainder one at a time - while (digits-- > 0) - { - remainder *= 10.0; - unsigned int toPrint = (unsigned int)remainder; - n += print(toPrint); - remainder -= toPrint; - } + // Extract digits from the remainder one at a time + while (digits-- > 0) + { + remainder *= 10.0; + unsigned int toPrint = (unsigned int)remainder; + n += print(toPrint); + remainder -= toPrint; + } - return n; + return n; } size_t Print::printBuffer(uint8_t const buffer[], int len, char delim, int byteline) { - if (buffer == NULL || len == 0) - return 0; + if (buffer == NULL || len == 0) + return 0; - for (int i = 0; i < len; i++) - { - if ( i != 0 ) - print(delim); + for (int i = 0; i < len; i++) + { + if ( i != 0 ) + print(delim); - if ( byteline && (i % byteline == 0) ) - println(); + if ( byteline && (i % byteline == 0) ) + println(); - this->printf("%02X", buffer[i]); - } + this->printf("%02X", buffer[i]); + } - return (len * 3 - 1); + return (len * 3 - 1); } size_t Print::printBufferReverse(uint8_t const buffer[], int len, char delim, int byteline) { - if (buffer == NULL || len == 0) - return 0; + if (buffer == NULL || len == 0) + return 0; - for (int i = 0; i < len; i++) - { - if (i != 0) - print(delim); + for (int i = 0; i < len; i++) + { + if (i != 0) + print(delim); - if ( byteline && (i % byteline == 0) ) - println(); + if ( byteline && (i % byteline == 0) ) + println(); - this->printf("%02X", buffer[len - 1 - i]); - } + this->printf("%02X", buffer[len - 1 - i]); + } - return (len * 3 - 1); + return (len * 3 - 1); } diff --git a/Packages_Patches/SparkFun/hardware/samd/1.8.3/cores/arduino51/Print.h b/Packages_Patches/SparkFun/hardware/samd/1.8.3/cores/arduino51/Print.h index 810a7704..d03d1cc8 100644 --- a/Packages_Patches/SparkFun/hardware/samd/1.8.3/cores/arduino51/Print.h +++ b/Packages_Patches/SparkFun/hardware/samd/1.8.3/cores/arduino51/Print.h @@ -31,93 +31,93 @@ class Print { - private: - int write_error; - size_t printNumber(unsigned long, uint8_t); - size_t printULLNumber(unsigned long long, uint8_t); - size_t printFloat(double, int); - protected: - void setWriteError(int err = 1) - { - write_error = err; - } - public: - Print() : write_error(0) {} - - int getWriteError() - { - return write_error; - } - void clearWriteError() - { - setWriteError(0); - } - - virtual size_t write(uint8_t) = 0; - size_t write(const char *str) - { - if (str == NULL) - return 0; - - return write((const uint8_t *)str, strlen(str)); - } - virtual size_t write(const uint8_t *buffer, size_t size); - size_t write(const char *buffer, size_t size) - { - return write((const uint8_t *)buffer, size); - } - - // default to zero, meaning "a single write may block" - // should be overridden by subclasses with buffering - virtual int availableForWrite() - { - return 0; - } - - size_t print(const __FlashStringHelper *); - size_t print(const String &); - size_t print(const char[]); - size_t print(char); - size_t print(unsigned char, int = DEC); - size_t print(int, int = DEC); - size_t print(unsigned int, int = DEC); - size_t print(long, int = DEC); - size_t print(unsigned long, int = DEC); - size_t print(long long, int = DEC); - size_t print(unsigned long long, int = DEC); - size_t print(double, int = 2); - size_t print(const Printable&); - - size_t println(const __FlashStringHelper *); - size_t println(const String &s); - size_t println(const char[]); - size_t println(char); - size_t println(unsigned char, int = DEC); - size_t println(int, int = DEC); - size_t println(unsigned int, int = DEC); - size_t println(long, int = DEC); - size_t println(unsigned long, int = DEC); - size_t println(long long, int = DEC); - size_t println(unsigned long long, int = DEC); - size_t println(double, int = 2); - size_t println(const Printable&); - size_t println(void); - - size_t printf(const char * format, ...); - - size_t printBuffer(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); - size_t printBuffer(char const buffer[], int size, char delim = ' ', int byteline = 0) - { - return printBuffer((uint8_t const*) buffer, size, delim, byteline); - } - - size_t printBufferReverse(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); - size_t printBufferReverse(char const buffer[], int size, char delim = ' ', int byteline = 0) - { - return printBufferReverse((uint8_t const*) buffer, size, delim, byteline); - } - - virtual void flush() { /* Empty implementation for backward compatibility */ } + private: + int write_error; + size_t printNumber(unsigned long, uint8_t); + size_t printULLNumber(unsigned long long, uint8_t); + size_t printFloat(double, int); + protected: + void setWriteError(int err = 1) + { + write_error = err; + } + public: + Print() : write_error(0) {} + + int getWriteError() + { + return write_error; + } + void clearWriteError() + { + setWriteError(0); + } + + virtual size_t write(uint8_t) = 0; + size_t write(const char *str) + { + if (str == NULL) + return 0; + + return write((const uint8_t *)str, strlen(str)); + } + virtual size_t write(const uint8_t *buffer, size_t size); + size_t write(const char *buffer, size_t size) + { + return write((const uint8_t *)buffer, size); + } + + // default to zero, meaning "a single write may block" + // should be overridden by subclasses with buffering + virtual int availableForWrite() + { + return 0; + } + + size_t print(const __FlashStringHelper *); + size_t print(const String &); + size_t print(const char[]); + size_t print(char); + size_t print(unsigned char, int = DEC); + size_t print(int, int = DEC); + size_t print(unsigned int, int = DEC); + size_t print(long, int = DEC); + size_t print(unsigned long, int = DEC); + size_t print(long long, int = DEC); + size_t print(unsigned long long, int = DEC); + size_t print(double, int = 2); + size_t print(const Printable&); + + size_t println(const __FlashStringHelper *); + size_t println(const String &s); + size_t println(const char[]); + size_t println(char); + size_t println(unsigned char, int = DEC); + size_t println(int, int = DEC); + size_t println(unsigned int, int = DEC); + size_t println(long, int = DEC); + size_t println(unsigned long, int = DEC); + size_t println(long long, int = DEC); + size_t println(unsigned long long, int = DEC); + size_t println(double, int = 2); + size_t println(const Printable&); + size_t println(void); + + size_t printf(const char * format, ...); + + size_t printBuffer(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); + size_t printBuffer(char const buffer[], int size, char delim = ' ', int byteline = 0) + { + return printBuffer((uint8_t const*) buffer, size, delim, byteline); + } + + size_t printBufferReverse(uint8_t const buffer[], int len, char delim = ' ', int byteline = 0); + size_t printBufferReverse(char const buffer[], int size, char delim = ' ', int byteline = 0) + { + return printBufferReverse((uint8_t const*) buffer, size, delim, byteline); + } + + virtual void flush() { /* Empty implementation for backward compatibility */ } }; diff --git a/Packages_Patches/hardware/teensy/avr/cores/teensy/Stream.cpp b/Packages_Patches/hardware/teensy/avr/cores/teensy/Stream.cpp index 09903ebf..85c879b6 100644 --- a/Packages_Patches/hardware/teensy/avr/cores/teensy/Stream.cpp +++ b/Packages_Patches/hardware/teensy/avr/cores/teensy/Stream.cpp @@ -28,65 +28,65 @@ // private method to read stream with timeout int Stream::timedRead() { - int c; - unsigned long startMillis = millis(); + int c; + unsigned long startMillis = millis(); - do - { - c = read(); + do + { + c = read(); - if (c >= 0) - return c; + if (c >= 0) + return c; - yield(); - } while (millis() - startMillis < _timeout); + yield(); + } while (millis() - startMillis < _timeout); - Serial.print(("timedRead timeout = ")); - Serial.println(_timeout); + Serial.print(("timedRead timeout = ")); + Serial.println(_timeout); - return -1; // -1 indicates timeout + return -1; // -1 indicates timeout } // private method to peek stream with timeout int Stream::timedPeek() { - int c; - unsigned long startMillis = millis(); + int c; + unsigned long startMillis = millis(); - do - { - c = peek(); + do + { + c = peek(); - if (c >= 0) - return c; + if (c >= 0) + return c; - yield(); - } while (millis() - startMillis < _timeout); + yield(); + } while (millis() - startMillis < _timeout); - return -1; // -1 indicates timeout + return -1; // -1 indicates timeout } // returns peek of the next digit in the stream or -1 if timeout // discards non-numeric characters int Stream::peekNextDigit() { - int c; + int c; - while (1) - { - c = timedPeek(); + while (1) + { + c = timedPeek(); - if (c < 0) - return c; // timeout + if (c < 0) + return c; // timeout - if (c == '-') - return c; + if (c == '-') + return c; - if (c >= '0' && c <= '9') - return c; + if (c >= '0' && c <= '9') + return c; - read(); // discard non-numeric - } + read(); // discard non-numeric + } } // Public Methods @@ -94,31 +94,31 @@ int Stream::peekNextDigit() void Stream::setTimeout(unsigned long timeout) // sets the maximum number of milliseconds to wait { - _timeout = timeout; + _timeout = timeout; } // find returns true if the target string is found bool Stream::find(const char *target) { - return findUntil(target, NULL); + return findUntil(target, NULL); } // reads data from the stream until the target string of given length is found // returns true if target string is found, false if timed out bool Stream::find(const char *target, size_t length) { - return findUntil(target, length, NULL, 0); + return findUntil(target, length, NULL, 0); } // as find but search ends if the terminator string is found bool Stream::findUntil(const char *target, const char *terminator) { - if (target == nullptr) - return true; + if (target == nullptr) + return true; - size_t tlen = (terminator == nullptr) ? 0 : strlen(terminator); + size_t tlen = (terminator == nullptr) ? 0 : strlen(terminator); - return findUntil(target, strlen(target), terminator, tlen); + return findUntil(target, strlen(target), terminator, tlen); } // reads data from the stream until the target string of the given length is found @@ -126,45 +126,45 @@ bool Stream::findUntil(const char *target, const char *terminator) // returns true if target string is found, false if terminated or timed out bool Stream::findUntil(const char *target, size_t targetLen, const char *terminator, size_t termLen) { - size_t index = 0; // maximum target string length is 64k bytes! - size_t termIndex = 0; - int c; - - if ( target == nullptr) - return true; - - if ( *target == 0) - return true; // return true if target is a null string - - if (terminator == nullptr) - termLen = 0; - - while ( (c = timedRead()) > 0) - { - if ( c == target[index]) - { - //////Serial.print("found "); Serial.write(c); Serial.print("index now"); Serial.println(index+1); - if (++index >= targetLen) - { - // return true if all chars in the target match - return true; - } - } - else - { - index = 0; // reset index if any char does not match - } - - if (termLen > 0 && c == terminator[termIndex]) - { - if (++termIndex >= termLen) - return false; // return false if terminate string found before target string - } - else - termIndex = 0; - } - - return false; + size_t index = 0; // maximum target string length is 64k bytes! + size_t termIndex = 0; + int c; + + if ( target == nullptr) + return true; + + if ( *target == 0) + return true; // return true if target is a null string + + if (terminator == nullptr) + termLen = 0; + + while ( (c = timedRead()) > 0) + { + if ( c == target[index]) + { + //////Serial.print("found "); Serial.write(c); Serial.print("index now"); Serial.println(index+1); + if (++index >= targetLen) + { + // return true if all chars in the target match + return true; + } + } + else + { + index = 0; // reset index if any char does not match + } + + if (termLen > 0 && c == terminator[termIndex]) + { + if (++termIndex >= termLen) + return false; // return false if terminate string found before target string + } + else + termIndex = 0; + } + + return false; } @@ -173,93 +173,93 @@ bool Stream::findUntil(const char *target, size_t targetLen, const char *termina // function is terminated by the first character that is not a digit. long Stream::parseInt() { - return parseInt(NO_SKIP_CHAR); // terminate on first non-digit character (or timeout) + return parseInt(NO_SKIP_CHAR); // terminate on first non-digit character (or timeout) } // as above but a given skipChar is ignored // this allows format characters (typically commas) in values to be ignored long Stream::parseInt(char skipChar) { - boolean isNegative = false; - long value = 0; - int c; + boolean isNegative = false; + long value = 0; + int c; - c = peekNextDigit(); + c = peekNextDigit(); - // ignore non numeric leading characters - if (c < 0) - return 0; // zero returned if timeout + // ignore non numeric leading characters + if (c < 0) + return 0; // zero returned if timeout - do - { - if (c == skipChar) - ; // ignore this charactor - else if (c == '-') - isNegative = true; - else if (c >= '0' && c <= '9') // is c a digit? - value = value * 10 + c - '0'; + do + { + if (c == skipChar) + ; // ignore this charactor + else if (c == '-') + isNegative = true; + else if (c >= '0' && c <= '9') // is c a digit? + value = value * 10 + c - '0'; - read(); // consume the character we got with peek - c = timedPeek(); - } while ( (c >= '0' && c <= '9') || c == skipChar ); + read(); // consume the character we got with peek + c = timedPeek(); + } while ( (c >= '0' && c <= '9') || c == skipChar ); - if (isNegative) - value = -value; + if (isNegative) + value = -value; - return value; + return value; } // as parseInt but returns a floating point value float Stream::parseFloat() { - return parseFloat(NO_SKIP_CHAR); + return parseFloat(NO_SKIP_CHAR); } // as above but the given skipChar is ignored // this allows format characters (typically commas) in values to be ignored float Stream::parseFloat(char skipChar) { - boolean isNegative = false; - boolean isFraction = false; - long value = 0; - int c; - float fraction = 1.0; - - c = peekNextDigit(); - - // ignore non numeric leading characters - if (c < 0) - return 0; // zero returned if timeout - - do - { - if (c == skipChar) - ; // ignore - else if (c == '-') - isNegative = true; - else if (c == '.') - isFraction = true; - else if (c >= '0' && c <= '9') - { - // is c a digit? - value = value * 10 + c - '0'; - - if (isFraction) - fraction *= 0.1f; - } - - read(); // consume the character we got with peek - c = timedPeek(); - } while ( (c >= '0' && c <= '9') || c == '.' || c == skipChar ); - - if (isNegative) - value = -value; - - if (isFraction) - return value * fraction; - else - return value; + boolean isNegative = false; + boolean isFraction = false; + long value = 0; + int c; + float fraction = 1.0; + + c = peekNextDigit(); + + // ignore non numeric leading characters + if (c < 0) + return 0; // zero returned if timeout + + do + { + if (c == skipChar) + ; // ignore + else if (c == '-') + isNegative = true; + else if (c == '.') + isFraction = true; + else if (c >= '0' && c <= '9') + { + // is c a digit? + value = value * 10 + c - '0'; + + if (isFraction) + fraction *= 0.1f; + } + + read(); // consume the character we got with peek + c = timedPeek(); + } while ( (c >= '0' && c <= '9') || c == '.' || c == skipChar ); + + if (isNegative) + value = -value; + + if (isFraction) + return value * fraction; + else + return value; } // read characters from stream into buffer @@ -269,26 +269,26 @@ float Stream::parseFloat(char skipChar) // size_t Stream::readBytes(char *buffer, size_t length) { - if (buffer == nullptr) - return 0; + if (buffer == nullptr) + return 0; - size_t count = 0; + size_t count = 0; - while (count < length) - { - int c = timedRead(); + while (count < length) + { + int c = timedRead(); - if (c < 0) - { - setReadError(); - break; - } + if (c < 0) + { + setReadError(); + break; + } - *buffer++ = (char)c; - count++; - } + *buffer++ = (char)c; + count++; + } - return count; + return count; } @@ -298,34 +298,34 @@ size_t Stream::readBytes(char *buffer, size_t length) size_t Stream::readBytesUntil(char terminator, char *buffer, size_t length) { - if (buffer == nullptr) - return 0; + if (buffer == nullptr) + return 0; - if (length < 1) - return 0; + if (length < 1) + return 0; - length--; - size_t index = 0; + length--; + size_t index = 0; - while (index < length) - { - int c = timedRead(); + while (index < length) + { + int c = timedRead(); - if (c == terminator) - break; + if (c == terminator) + break; - if (c < 0) - { - setReadError(); - break; - } + if (c < 0) + { + setReadError(); + break; + } - *buffer++ = (char)c; - index++; - } + *buffer++ = (char)c; + index++; + } - *buffer = 0; - return index; // return number of characters, not including null terminator + *buffer = 0; + return index; // return number of characters, not including null terminator } #if 1 @@ -333,112 +333,112 @@ size_t Stream::readBytesUntil(char terminator, char *buffer, size_t length) String Stream::readString(size_t max) { - String ret; - int c = timedRead(); + String ret; + int c = timedRead(); - while (c >= 0) - { - ret += (char)c; - c = timedRead(); - } + while (c >= 0) + { + ret += (char)c; + c = timedRead(); + } - return ret; + return ret; } char readStringBuffer[2048]; char* Stream::readCharsUntil(char terminator, size_t max) { - uint16_t offset = 0; + uint16_t offset = 0; - int c = timedRead(); + int c = timedRead(); - readStringBuffer[offset++] = c; + readStringBuffer[offset++] = c; - while (c >= 0 && c != terminator) - { - c = timedRead(); + while (c >= 0 && c != terminator) + { + c = timedRead(); - readStringBuffer[offset++] = c; - } + readStringBuffer[offset++] = c; + } - readStringBuffer[offset] = 0; + readStringBuffer[offset] = 0; - return readStringBuffer; + return readStringBuffer; } String Stream::readStringUntil(char terminator, size_t max) { - String ret; - uint16_t offset = 0; + String ret; + uint16_t offset = 0; - int c = timedRead(); + int c = timedRead(); - readStringBuffer[offset++] = c; + readStringBuffer[offset++] = c; - while (c >= 0 && c != terminator) - { - c = timedRead(); + while (c >= 0 && c != terminator) + { + c = timedRead(); - readStringBuffer[offset++] = c; - } + readStringBuffer[offset++] = c; + } - readStringBuffer[offset] = 0; + readStringBuffer[offset] = 0; - ret = String(readStringBuffer); + ret = String(readStringBuffer); - return String(readStringBuffer); + return String(readStringBuffer); } #else String Stream::readString(size_t max) { - String str; - size_t length = 0; + String str; + size_t length = 0; - while (length < max) - { - int c = timedRead(); + while (length < max) + { + int c = timedRead(); - if (c < 0) - { - setReadError(); - break; // timeout - } + if (c < 0) + { + setReadError(); + break; // timeout + } - if (c == 0) - break; + if (c == 0) + break; - str += (char)c; - length++; - } + str += (char)c; + length++; + } - return str; + return str; } String Stream::readStringUntil(char terminator, size_t max) { - String str; - size_t length = 0; + String str; + size_t length = 0; - while (length < max) - { - int c = timedRead(); + while (length < max) + { + int c = timedRead(); - if (c < 0) - { - setReadError(); - break; // timeout - } + if (c < 0) + { + setReadError(); + break; // timeout + } - if (c == 0 || c == terminator) - break; + if (c == 0 || c == terminator) + break; - str += (char)c; - length++; - } + str += (char)c; + length++; + } - return str; + return str; } #endif diff --git a/Packages_Patches/hardware/teensy/avr/cores/teensy/Stream.h b/Packages_Patches/hardware/teensy/avr/cores/teensy/Stream.h index b3cea254..7f407cda 100644 --- a/Packages_Patches/hardware/teensy/avr/cores/teensy/Stream.h +++ b/Packages_Patches/hardware/teensy/avr/cores/teensy/Stream.h @@ -25,124 +25,124 @@ class Stream : public Print { - public: - constexpr Stream() : _timeout(1000), read_error(0) {} - virtual int available() = 0; - virtual int read() = 0; - virtual int peek() = 0; - - void setTimeout(unsigned long timeout); - bool find(const char *target); - - bool find(const uint8_t *target) - { - return find ((const char *)target); - } - - bool find(const String &target) - { - return find(target.c_str()); - } - - bool find(const char *target, size_t length); - - bool find(const uint8_t *target, size_t length) - { - return find ((const char *)target, length); - } - - bool find(const String &target, size_t length) - { - return find(target.c_str(), length); - } - - bool findUntil(const char *target, const char *terminator); - - bool findUntil(const uint8_t *target, const char *terminator) - { - return findUntil((const char *)target, terminator); - } - - bool findUntil(const String &target, const char *terminator) - { - return findUntil(target.c_str(), terminator); - } - - bool findUntil(const char *target, const String &terminator) - { - return findUntil(target, terminator.c_str()); - } - - bool findUntil(const String &target, const String &terminator) - { - return findUntil(target.c_str(), terminator.c_str()); - } - - bool findUntil(const char *target, size_t targetLen, const char *terminate, size_t termLen); - - bool findUntil(const uint8_t *target, size_t targetLen, const char *terminate, size_t termLen) - { - return findUntil((const char *)target, targetLen, terminate, termLen); - } - - bool findUntil(const String &target, size_t targetLen, const char *terminate, size_t termLen); - bool findUntil(const char *target, size_t targetLen, const String &terminate, size_t termLen); - bool findUntil(const String &target, size_t targetLen, const String &terminate, size_t termLen); - - long parseInt(); - long parseInt(char skipChar); - - float parseFloat(); - float parseFloat(char skipChar); - - size_t readBytes(char *buffer, size_t length); - - size_t readBytes(uint8_t *buffer, size_t length) - { - return readBytes((char *)buffer, length); - } - - size_t readBytesUntil(char terminator, char *buffer, size_t length); - - size_t readBytesUntil(char terminator, uint8_t *buffer, size_t length) - { - return readBytesUntil(terminator, (char *)buffer, length); - } - - //////////////////////////////////////////////////////////// - String readString(size_t max = 512); - String readStringUntil(char terminator, size_t max = 512); - - // KH, to not use String - char* readCharsUntil(char terminator, size_t max = 512); - //////////////////////////////////////////////////////////// - - int getReadError() - { - return read_error; - } - - void clearReadError() - { - setReadError(0); - } - - protected: - void setReadError(int err = 1) - { - read_error = err; - } + public: + constexpr Stream() : _timeout(1000), read_error(0) {} + virtual int available() = 0; + virtual int read() = 0; + virtual int peek() = 0; + + void setTimeout(unsigned long timeout); + bool find(const char *target); + + bool find(const uint8_t *target) + { + return find ((const char *)target); + } + + bool find(const String &target) + { + return find(target.c_str()); + } + + bool find(const char *target, size_t length); + + bool find(const uint8_t *target, size_t length) + { + return find ((const char *)target, length); + } + + bool find(const String &target, size_t length) + { + return find(target.c_str(), length); + } + + bool findUntil(const char *target, const char *terminator); + + bool findUntil(const uint8_t *target, const char *terminator) + { + return findUntil((const char *)target, terminator); + } + + bool findUntil(const String &target, const char *terminator) + { + return findUntil(target.c_str(), terminator); + } + + bool findUntil(const char *target, const String &terminator) + { + return findUntil(target, terminator.c_str()); + } + + bool findUntil(const String &target, const String &terminator) + { + return findUntil(target.c_str(), terminator.c_str()); + } + + bool findUntil(const char *target, size_t targetLen, const char *terminate, size_t termLen); + + bool findUntil(const uint8_t *target, size_t targetLen, const char *terminate, size_t termLen) + { + return findUntil((const char *)target, targetLen, terminate, termLen); + } + + bool findUntil(const String &target, size_t targetLen, const char *terminate, size_t termLen); + bool findUntil(const char *target, size_t targetLen, const String &terminate, size_t termLen); + bool findUntil(const String &target, size_t targetLen, const String &terminate, size_t termLen); + + long parseInt(); + long parseInt(char skipChar); + + float parseFloat(); + float parseFloat(char skipChar); + + size_t readBytes(char *buffer, size_t length); + + size_t readBytes(uint8_t *buffer, size_t length) + { + return readBytes((char *)buffer, length); + } + + size_t readBytesUntil(char terminator, char *buffer, size_t length); + + size_t readBytesUntil(char terminator, uint8_t *buffer, size_t length) + { + return readBytesUntil(terminator, (char *)buffer, length); + } + + //////////////////////////////////////////////////////////// + String readString(size_t max = 512); + String readStringUntil(char terminator, size_t max = 512); + + // KH, to not use String + char* readCharsUntil(char terminator, size_t max = 512); + //////////////////////////////////////////////////////////// + + int getReadError() + { + return read_error; + } + + void clearReadError() + { + setReadError(0); + } + + protected: + void setReadError(int err = 1) + { + read_error = err; + } - unsigned long _timeout; - - // KH - int timedRead(); - int timedPeek(); - int peekNextDigit(); - ////// + unsigned long _timeout; + + // KH + int timedRead(); + int timedPeek(); + int peekNextDigit(); + ////// - private: - char read_error; + private: + char read_error; }; #endif diff --git a/Packages_Patches/hardware/teensy/avr/cores/teensy3/Stream.cpp b/Packages_Patches/hardware/teensy/avr/cores/teensy3/Stream.cpp index 09903ebf..85c879b6 100644 --- a/Packages_Patches/hardware/teensy/avr/cores/teensy3/Stream.cpp +++ b/Packages_Patches/hardware/teensy/avr/cores/teensy3/Stream.cpp @@ -28,65 +28,65 @@ // private method to read stream with timeout int Stream::timedRead() { - int c; - unsigned long startMillis = millis(); + int c; + unsigned long startMillis = millis(); - do - { - c = read(); + do + { + c = read(); - if (c >= 0) - return c; + if (c >= 0) + return c; - yield(); - } while (millis() - startMillis < _timeout); + yield(); + } while (millis() - startMillis < _timeout); - Serial.print(("timedRead timeout = ")); - Serial.println(_timeout); + Serial.print(("timedRead timeout = ")); + Serial.println(_timeout); - return -1; // -1 indicates timeout + return -1; // -1 indicates timeout } // private method to peek stream with timeout int Stream::timedPeek() { - int c; - unsigned long startMillis = millis(); + int c; + unsigned long startMillis = millis(); - do - { - c = peek(); + do + { + c = peek(); - if (c >= 0) - return c; + if (c >= 0) + return c; - yield(); - } while (millis() - startMillis < _timeout); + yield(); + } while (millis() - startMillis < _timeout); - return -1; // -1 indicates timeout + return -1; // -1 indicates timeout } // returns peek of the next digit in the stream or -1 if timeout // discards non-numeric characters int Stream::peekNextDigit() { - int c; + int c; - while (1) - { - c = timedPeek(); + while (1) + { + c = timedPeek(); - if (c < 0) - return c; // timeout + if (c < 0) + return c; // timeout - if (c == '-') - return c; + if (c == '-') + return c; - if (c >= '0' && c <= '9') - return c; + if (c >= '0' && c <= '9') + return c; - read(); // discard non-numeric - } + read(); // discard non-numeric + } } // Public Methods @@ -94,31 +94,31 @@ int Stream::peekNextDigit() void Stream::setTimeout(unsigned long timeout) // sets the maximum number of milliseconds to wait { - _timeout = timeout; + _timeout = timeout; } // find returns true if the target string is found bool Stream::find(const char *target) { - return findUntil(target, NULL); + return findUntil(target, NULL); } // reads data from the stream until the target string of given length is found // returns true if target string is found, false if timed out bool Stream::find(const char *target, size_t length) { - return findUntil(target, length, NULL, 0); + return findUntil(target, length, NULL, 0); } // as find but search ends if the terminator string is found bool Stream::findUntil(const char *target, const char *terminator) { - if (target == nullptr) - return true; + if (target == nullptr) + return true; - size_t tlen = (terminator == nullptr) ? 0 : strlen(terminator); + size_t tlen = (terminator == nullptr) ? 0 : strlen(terminator); - return findUntil(target, strlen(target), terminator, tlen); + return findUntil(target, strlen(target), terminator, tlen); } // reads data from the stream until the target string of the given length is found @@ -126,45 +126,45 @@ bool Stream::findUntil(const char *target, const char *terminator) // returns true if target string is found, false if terminated or timed out bool Stream::findUntil(const char *target, size_t targetLen, const char *terminator, size_t termLen) { - size_t index = 0; // maximum target string length is 64k bytes! - size_t termIndex = 0; - int c; - - if ( target == nullptr) - return true; - - if ( *target == 0) - return true; // return true if target is a null string - - if (terminator == nullptr) - termLen = 0; - - while ( (c = timedRead()) > 0) - { - if ( c == target[index]) - { - //////Serial.print("found "); Serial.write(c); Serial.print("index now"); Serial.println(index+1); - if (++index >= targetLen) - { - // return true if all chars in the target match - return true; - } - } - else - { - index = 0; // reset index if any char does not match - } - - if (termLen > 0 && c == terminator[termIndex]) - { - if (++termIndex >= termLen) - return false; // return false if terminate string found before target string - } - else - termIndex = 0; - } - - return false; + size_t index = 0; // maximum target string length is 64k bytes! + size_t termIndex = 0; + int c; + + if ( target == nullptr) + return true; + + if ( *target == 0) + return true; // return true if target is a null string + + if (terminator == nullptr) + termLen = 0; + + while ( (c = timedRead()) > 0) + { + if ( c == target[index]) + { + //////Serial.print("found "); Serial.write(c); Serial.print("index now"); Serial.println(index+1); + if (++index >= targetLen) + { + // return true if all chars in the target match + return true; + } + } + else + { + index = 0; // reset index if any char does not match + } + + if (termLen > 0 && c == terminator[termIndex]) + { + if (++termIndex >= termLen) + return false; // return false if terminate string found before target string + } + else + termIndex = 0; + } + + return false; } @@ -173,93 +173,93 @@ bool Stream::findUntil(const char *target, size_t targetLen, const char *termina // function is terminated by the first character that is not a digit. long Stream::parseInt() { - return parseInt(NO_SKIP_CHAR); // terminate on first non-digit character (or timeout) + return parseInt(NO_SKIP_CHAR); // terminate on first non-digit character (or timeout) } // as above but a given skipChar is ignored // this allows format characters (typically commas) in values to be ignored long Stream::parseInt(char skipChar) { - boolean isNegative = false; - long value = 0; - int c; + boolean isNegative = false; + long value = 0; + int c; - c = peekNextDigit(); + c = peekNextDigit(); - // ignore non numeric leading characters - if (c < 0) - return 0; // zero returned if timeout + // ignore non numeric leading characters + if (c < 0) + return 0; // zero returned if timeout - do - { - if (c == skipChar) - ; // ignore this charactor - else if (c == '-') - isNegative = true; - else if (c >= '0' && c <= '9') // is c a digit? - value = value * 10 + c - '0'; + do + { + if (c == skipChar) + ; // ignore this charactor + else if (c == '-') + isNegative = true; + else if (c >= '0' && c <= '9') // is c a digit? + value = value * 10 + c - '0'; - read(); // consume the character we got with peek - c = timedPeek(); - } while ( (c >= '0' && c <= '9') || c == skipChar ); + read(); // consume the character we got with peek + c = timedPeek(); + } while ( (c >= '0' && c <= '9') || c == skipChar ); - if (isNegative) - value = -value; + if (isNegative) + value = -value; - return value; + return value; } // as parseInt but returns a floating point value float Stream::parseFloat() { - return parseFloat(NO_SKIP_CHAR); + return parseFloat(NO_SKIP_CHAR); } // as above but the given skipChar is ignored // this allows format characters (typically commas) in values to be ignored float Stream::parseFloat(char skipChar) { - boolean isNegative = false; - boolean isFraction = false; - long value = 0; - int c; - float fraction = 1.0; - - c = peekNextDigit(); - - // ignore non numeric leading characters - if (c < 0) - return 0; // zero returned if timeout - - do - { - if (c == skipChar) - ; // ignore - else if (c == '-') - isNegative = true; - else if (c == '.') - isFraction = true; - else if (c >= '0' && c <= '9') - { - // is c a digit? - value = value * 10 + c - '0'; - - if (isFraction) - fraction *= 0.1f; - } - - read(); // consume the character we got with peek - c = timedPeek(); - } while ( (c >= '0' && c <= '9') || c == '.' || c == skipChar ); - - if (isNegative) - value = -value; - - if (isFraction) - return value * fraction; - else - return value; + boolean isNegative = false; + boolean isFraction = false; + long value = 0; + int c; + float fraction = 1.0; + + c = peekNextDigit(); + + // ignore non numeric leading characters + if (c < 0) + return 0; // zero returned if timeout + + do + { + if (c == skipChar) + ; // ignore + else if (c == '-') + isNegative = true; + else if (c == '.') + isFraction = true; + else if (c >= '0' && c <= '9') + { + // is c a digit? + value = value * 10 + c - '0'; + + if (isFraction) + fraction *= 0.1f; + } + + read(); // consume the character we got with peek + c = timedPeek(); + } while ( (c >= '0' && c <= '9') || c == '.' || c == skipChar ); + + if (isNegative) + value = -value; + + if (isFraction) + return value * fraction; + else + return value; } // read characters from stream into buffer @@ -269,26 +269,26 @@ float Stream::parseFloat(char skipChar) // size_t Stream::readBytes(char *buffer, size_t length) { - if (buffer == nullptr) - return 0; + if (buffer == nullptr) + return 0; - size_t count = 0; + size_t count = 0; - while (count < length) - { - int c = timedRead(); + while (count < length) + { + int c = timedRead(); - if (c < 0) - { - setReadError(); - break; - } + if (c < 0) + { + setReadError(); + break; + } - *buffer++ = (char)c; - count++; - } + *buffer++ = (char)c; + count++; + } - return count; + return count; } @@ -298,34 +298,34 @@ size_t Stream::readBytes(char *buffer, size_t length) size_t Stream::readBytesUntil(char terminator, char *buffer, size_t length) { - if (buffer == nullptr) - return 0; + if (buffer == nullptr) + return 0; - if (length < 1) - return 0; + if (length < 1) + return 0; - length--; - size_t index = 0; + length--; + size_t index = 0; - while (index < length) - { - int c = timedRead(); + while (index < length) + { + int c = timedRead(); - if (c == terminator) - break; + if (c == terminator) + break; - if (c < 0) - { - setReadError(); - break; - } + if (c < 0) + { + setReadError(); + break; + } - *buffer++ = (char)c; - index++; - } + *buffer++ = (char)c; + index++; + } - *buffer = 0; - return index; // return number of characters, not including null terminator + *buffer = 0; + return index; // return number of characters, not including null terminator } #if 1 @@ -333,112 +333,112 @@ size_t Stream::readBytesUntil(char terminator, char *buffer, size_t length) String Stream::readString(size_t max) { - String ret; - int c = timedRead(); + String ret; + int c = timedRead(); - while (c >= 0) - { - ret += (char)c; - c = timedRead(); - } + while (c >= 0) + { + ret += (char)c; + c = timedRead(); + } - return ret; + return ret; } char readStringBuffer[2048]; char* Stream::readCharsUntil(char terminator, size_t max) { - uint16_t offset = 0; + uint16_t offset = 0; - int c = timedRead(); + int c = timedRead(); - readStringBuffer[offset++] = c; + readStringBuffer[offset++] = c; - while (c >= 0 && c != terminator) - { - c = timedRead(); + while (c >= 0 && c != terminator) + { + c = timedRead(); - readStringBuffer[offset++] = c; - } + readStringBuffer[offset++] = c; + } - readStringBuffer[offset] = 0; + readStringBuffer[offset] = 0; - return readStringBuffer; + return readStringBuffer; } String Stream::readStringUntil(char terminator, size_t max) { - String ret; - uint16_t offset = 0; + String ret; + uint16_t offset = 0; - int c = timedRead(); + int c = timedRead(); - readStringBuffer[offset++] = c; + readStringBuffer[offset++] = c; - while (c >= 0 && c != terminator) - { - c = timedRead(); + while (c >= 0 && c != terminator) + { + c = timedRead(); - readStringBuffer[offset++] = c; - } + readStringBuffer[offset++] = c; + } - readStringBuffer[offset] = 0; + readStringBuffer[offset] = 0; - ret = String(readStringBuffer); + ret = String(readStringBuffer); - return String(readStringBuffer); + return String(readStringBuffer); } #else String Stream::readString(size_t max) { - String str; - size_t length = 0; + String str; + size_t length = 0; - while (length < max) - { - int c = timedRead(); + while (length < max) + { + int c = timedRead(); - if (c < 0) - { - setReadError(); - break; // timeout - } + if (c < 0) + { + setReadError(); + break; // timeout + } - if (c == 0) - break; + if (c == 0) + break; - str += (char)c; - length++; - } + str += (char)c; + length++; + } - return str; + return str; } String Stream::readStringUntil(char terminator, size_t max) { - String str; - size_t length = 0; + String str; + size_t length = 0; - while (length < max) - { - int c = timedRead(); + while (length < max) + { + int c = timedRead(); - if (c < 0) - { - setReadError(); - break; // timeout - } + if (c < 0) + { + setReadError(); + break; // timeout + } - if (c == 0 || c == terminator) - break; + if (c == 0 || c == terminator) + break; - str += (char)c; - length++; - } + str += (char)c; + length++; + } - return str; + return str; } #endif diff --git a/Packages_Patches/hardware/teensy/avr/cores/teensy3/Stream.h b/Packages_Patches/hardware/teensy/avr/cores/teensy3/Stream.h index b3cea254..7f407cda 100644 --- a/Packages_Patches/hardware/teensy/avr/cores/teensy3/Stream.h +++ b/Packages_Patches/hardware/teensy/avr/cores/teensy3/Stream.h @@ -25,124 +25,124 @@ class Stream : public Print { - public: - constexpr Stream() : _timeout(1000), read_error(0) {} - virtual int available() = 0; - virtual int read() = 0; - virtual int peek() = 0; - - void setTimeout(unsigned long timeout); - bool find(const char *target); - - bool find(const uint8_t *target) - { - return find ((const char *)target); - } - - bool find(const String &target) - { - return find(target.c_str()); - } - - bool find(const char *target, size_t length); - - bool find(const uint8_t *target, size_t length) - { - return find ((const char *)target, length); - } - - bool find(const String &target, size_t length) - { - return find(target.c_str(), length); - } - - bool findUntil(const char *target, const char *terminator); - - bool findUntil(const uint8_t *target, const char *terminator) - { - return findUntil((const char *)target, terminator); - } - - bool findUntil(const String &target, const char *terminator) - { - return findUntil(target.c_str(), terminator); - } - - bool findUntil(const char *target, const String &terminator) - { - return findUntil(target, terminator.c_str()); - } - - bool findUntil(const String &target, const String &terminator) - { - return findUntil(target.c_str(), terminator.c_str()); - } - - bool findUntil(const char *target, size_t targetLen, const char *terminate, size_t termLen); - - bool findUntil(const uint8_t *target, size_t targetLen, const char *terminate, size_t termLen) - { - return findUntil((const char *)target, targetLen, terminate, termLen); - } - - bool findUntil(const String &target, size_t targetLen, const char *terminate, size_t termLen); - bool findUntil(const char *target, size_t targetLen, const String &terminate, size_t termLen); - bool findUntil(const String &target, size_t targetLen, const String &terminate, size_t termLen); - - long parseInt(); - long parseInt(char skipChar); - - float parseFloat(); - float parseFloat(char skipChar); - - size_t readBytes(char *buffer, size_t length); - - size_t readBytes(uint8_t *buffer, size_t length) - { - return readBytes((char *)buffer, length); - } - - size_t readBytesUntil(char terminator, char *buffer, size_t length); - - size_t readBytesUntil(char terminator, uint8_t *buffer, size_t length) - { - return readBytesUntil(terminator, (char *)buffer, length); - } - - //////////////////////////////////////////////////////////// - String readString(size_t max = 512); - String readStringUntil(char terminator, size_t max = 512); - - // KH, to not use String - char* readCharsUntil(char terminator, size_t max = 512); - //////////////////////////////////////////////////////////// - - int getReadError() - { - return read_error; - } - - void clearReadError() - { - setReadError(0); - } - - protected: - void setReadError(int err = 1) - { - read_error = err; - } + public: + constexpr Stream() : _timeout(1000), read_error(0) {} + virtual int available() = 0; + virtual int read() = 0; + virtual int peek() = 0; + + void setTimeout(unsigned long timeout); + bool find(const char *target); + + bool find(const uint8_t *target) + { + return find ((const char *)target); + } + + bool find(const String &target) + { + return find(target.c_str()); + } + + bool find(const char *target, size_t length); + + bool find(const uint8_t *target, size_t length) + { + return find ((const char *)target, length); + } + + bool find(const String &target, size_t length) + { + return find(target.c_str(), length); + } + + bool findUntil(const char *target, const char *terminator); + + bool findUntil(const uint8_t *target, const char *terminator) + { + return findUntil((const char *)target, terminator); + } + + bool findUntil(const String &target, const char *terminator) + { + return findUntil(target.c_str(), terminator); + } + + bool findUntil(const char *target, const String &terminator) + { + return findUntil(target, terminator.c_str()); + } + + bool findUntil(const String &target, const String &terminator) + { + return findUntil(target.c_str(), terminator.c_str()); + } + + bool findUntil(const char *target, size_t targetLen, const char *terminate, size_t termLen); + + bool findUntil(const uint8_t *target, size_t targetLen, const char *terminate, size_t termLen) + { + return findUntil((const char *)target, targetLen, terminate, termLen); + } + + bool findUntil(const String &target, size_t targetLen, const char *terminate, size_t termLen); + bool findUntil(const char *target, size_t targetLen, const String &terminate, size_t termLen); + bool findUntil(const String &target, size_t targetLen, const String &terminate, size_t termLen); + + long parseInt(); + long parseInt(char skipChar); + + float parseFloat(); + float parseFloat(char skipChar); + + size_t readBytes(char *buffer, size_t length); + + size_t readBytes(uint8_t *buffer, size_t length) + { + return readBytes((char *)buffer, length); + } + + size_t readBytesUntil(char terminator, char *buffer, size_t length); + + size_t readBytesUntil(char terminator, uint8_t *buffer, size_t length) + { + return readBytesUntil(terminator, (char *)buffer, length); + } + + //////////////////////////////////////////////////////////// + String readString(size_t max = 512); + String readStringUntil(char terminator, size_t max = 512); + + // KH, to not use String + char* readCharsUntil(char terminator, size_t max = 512); + //////////////////////////////////////////////////////////// + + int getReadError() + { + return read_error; + } + + void clearReadError() + { + setReadError(0); + } + + protected: + void setReadError(int err = 1) + { + read_error = err; + } - unsigned long _timeout; - - // KH - int timedRead(); - int timedPeek(); - int peekNextDigit(); - ////// + unsigned long _timeout; + + // KH + int timedRead(); + int timedPeek(); + int peekNextDigit(); + ////// - private: - char read_error; + private: + char read_error; }; #endif diff --git a/Packages_Patches/hardware/teensy/avr/cores/teensy4/Stream.cpp b/Packages_Patches/hardware/teensy/avr/cores/teensy4/Stream.cpp index 09903ebf..85c879b6 100644 --- a/Packages_Patches/hardware/teensy/avr/cores/teensy4/Stream.cpp +++ b/Packages_Patches/hardware/teensy/avr/cores/teensy4/Stream.cpp @@ -28,65 +28,65 @@ // private method to read stream with timeout int Stream::timedRead() { - int c; - unsigned long startMillis = millis(); + int c; + unsigned long startMillis = millis(); - do - { - c = read(); + do + { + c = read(); - if (c >= 0) - return c; + if (c >= 0) + return c; - yield(); - } while (millis() - startMillis < _timeout); + yield(); + } while (millis() - startMillis < _timeout); - Serial.print(("timedRead timeout = ")); - Serial.println(_timeout); + Serial.print(("timedRead timeout = ")); + Serial.println(_timeout); - return -1; // -1 indicates timeout + return -1; // -1 indicates timeout } // private method to peek stream with timeout int Stream::timedPeek() { - int c; - unsigned long startMillis = millis(); + int c; + unsigned long startMillis = millis(); - do - { - c = peek(); + do + { + c = peek(); - if (c >= 0) - return c; + if (c >= 0) + return c; - yield(); - } while (millis() - startMillis < _timeout); + yield(); + } while (millis() - startMillis < _timeout); - return -1; // -1 indicates timeout + return -1; // -1 indicates timeout } // returns peek of the next digit in the stream or -1 if timeout // discards non-numeric characters int Stream::peekNextDigit() { - int c; + int c; - while (1) - { - c = timedPeek(); + while (1) + { + c = timedPeek(); - if (c < 0) - return c; // timeout + if (c < 0) + return c; // timeout - if (c == '-') - return c; + if (c == '-') + return c; - if (c >= '0' && c <= '9') - return c; + if (c >= '0' && c <= '9') + return c; - read(); // discard non-numeric - } + read(); // discard non-numeric + } } // Public Methods @@ -94,31 +94,31 @@ int Stream::peekNextDigit() void Stream::setTimeout(unsigned long timeout) // sets the maximum number of milliseconds to wait { - _timeout = timeout; + _timeout = timeout; } // find returns true if the target string is found bool Stream::find(const char *target) { - return findUntil(target, NULL); + return findUntil(target, NULL); } // reads data from the stream until the target string of given length is found // returns true if target string is found, false if timed out bool Stream::find(const char *target, size_t length) { - return findUntil(target, length, NULL, 0); + return findUntil(target, length, NULL, 0); } // as find but search ends if the terminator string is found bool Stream::findUntil(const char *target, const char *terminator) { - if (target == nullptr) - return true; + if (target == nullptr) + return true; - size_t tlen = (terminator == nullptr) ? 0 : strlen(terminator); + size_t tlen = (terminator == nullptr) ? 0 : strlen(terminator); - return findUntil(target, strlen(target), terminator, tlen); + return findUntil(target, strlen(target), terminator, tlen); } // reads data from the stream until the target string of the given length is found @@ -126,45 +126,45 @@ bool Stream::findUntil(const char *target, const char *terminator) // returns true if target string is found, false if terminated or timed out bool Stream::findUntil(const char *target, size_t targetLen, const char *terminator, size_t termLen) { - size_t index = 0; // maximum target string length is 64k bytes! - size_t termIndex = 0; - int c; - - if ( target == nullptr) - return true; - - if ( *target == 0) - return true; // return true if target is a null string - - if (terminator == nullptr) - termLen = 0; - - while ( (c = timedRead()) > 0) - { - if ( c == target[index]) - { - //////Serial.print("found "); Serial.write(c); Serial.print("index now"); Serial.println(index+1); - if (++index >= targetLen) - { - // return true if all chars in the target match - return true; - } - } - else - { - index = 0; // reset index if any char does not match - } - - if (termLen > 0 && c == terminator[termIndex]) - { - if (++termIndex >= termLen) - return false; // return false if terminate string found before target string - } - else - termIndex = 0; - } - - return false; + size_t index = 0; // maximum target string length is 64k bytes! + size_t termIndex = 0; + int c; + + if ( target == nullptr) + return true; + + if ( *target == 0) + return true; // return true if target is a null string + + if (terminator == nullptr) + termLen = 0; + + while ( (c = timedRead()) > 0) + { + if ( c == target[index]) + { + //////Serial.print("found "); Serial.write(c); Serial.print("index now"); Serial.println(index+1); + if (++index >= targetLen) + { + // return true if all chars in the target match + return true; + } + } + else + { + index = 0; // reset index if any char does not match + } + + if (termLen > 0 && c == terminator[termIndex]) + { + if (++termIndex >= termLen) + return false; // return false if terminate string found before target string + } + else + termIndex = 0; + } + + return false; } @@ -173,93 +173,93 @@ bool Stream::findUntil(const char *target, size_t targetLen, const char *termina // function is terminated by the first character that is not a digit. long Stream::parseInt() { - return parseInt(NO_SKIP_CHAR); // terminate on first non-digit character (or timeout) + return parseInt(NO_SKIP_CHAR); // terminate on first non-digit character (or timeout) } // as above but a given skipChar is ignored // this allows format characters (typically commas) in values to be ignored long Stream::parseInt(char skipChar) { - boolean isNegative = false; - long value = 0; - int c; + boolean isNegative = false; + long value = 0; + int c; - c = peekNextDigit(); + c = peekNextDigit(); - // ignore non numeric leading characters - if (c < 0) - return 0; // zero returned if timeout + // ignore non numeric leading characters + if (c < 0) + return 0; // zero returned if timeout - do - { - if (c == skipChar) - ; // ignore this charactor - else if (c == '-') - isNegative = true; - else if (c >= '0' && c <= '9') // is c a digit? - value = value * 10 + c - '0'; + do + { + if (c == skipChar) + ; // ignore this charactor + else if (c == '-') + isNegative = true; + else if (c >= '0' && c <= '9') // is c a digit? + value = value * 10 + c - '0'; - read(); // consume the character we got with peek - c = timedPeek(); - } while ( (c >= '0' && c <= '9') || c == skipChar ); + read(); // consume the character we got with peek + c = timedPeek(); + } while ( (c >= '0' && c <= '9') || c == skipChar ); - if (isNegative) - value = -value; + if (isNegative) + value = -value; - return value; + return value; } // as parseInt but returns a floating point value float Stream::parseFloat() { - return parseFloat(NO_SKIP_CHAR); + return parseFloat(NO_SKIP_CHAR); } // as above but the given skipChar is ignored // this allows format characters (typically commas) in values to be ignored float Stream::parseFloat(char skipChar) { - boolean isNegative = false; - boolean isFraction = false; - long value = 0; - int c; - float fraction = 1.0; - - c = peekNextDigit(); - - // ignore non numeric leading characters - if (c < 0) - return 0; // zero returned if timeout - - do - { - if (c == skipChar) - ; // ignore - else if (c == '-') - isNegative = true; - else if (c == '.') - isFraction = true; - else if (c >= '0' && c <= '9') - { - // is c a digit? - value = value * 10 + c - '0'; - - if (isFraction) - fraction *= 0.1f; - } - - read(); // consume the character we got with peek - c = timedPeek(); - } while ( (c >= '0' && c <= '9') || c == '.' || c == skipChar ); - - if (isNegative) - value = -value; - - if (isFraction) - return value * fraction; - else - return value; + boolean isNegative = false; + boolean isFraction = false; + long value = 0; + int c; + float fraction = 1.0; + + c = peekNextDigit(); + + // ignore non numeric leading characters + if (c < 0) + return 0; // zero returned if timeout + + do + { + if (c == skipChar) + ; // ignore + else if (c == '-') + isNegative = true; + else if (c == '.') + isFraction = true; + else if (c >= '0' && c <= '9') + { + // is c a digit? + value = value * 10 + c - '0'; + + if (isFraction) + fraction *= 0.1f; + } + + read(); // consume the character we got with peek + c = timedPeek(); + } while ( (c >= '0' && c <= '9') || c == '.' || c == skipChar ); + + if (isNegative) + value = -value; + + if (isFraction) + return value * fraction; + else + return value; } // read characters from stream into buffer @@ -269,26 +269,26 @@ float Stream::parseFloat(char skipChar) // size_t Stream::readBytes(char *buffer, size_t length) { - if (buffer == nullptr) - return 0; + if (buffer == nullptr) + return 0; - size_t count = 0; + size_t count = 0; - while (count < length) - { - int c = timedRead(); + while (count < length) + { + int c = timedRead(); - if (c < 0) - { - setReadError(); - break; - } + if (c < 0) + { + setReadError(); + break; + } - *buffer++ = (char)c; - count++; - } + *buffer++ = (char)c; + count++; + } - return count; + return count; } @@ -298,34 +298,34 @@ size_t Stream::readBytes(char *buffer, size_t length) size_t Stream::readBytesUntil(char terminator, char *buffer, size_t length) { - if (buffer == nullptr) - return 0; + if (buffer == nullptr) + return 0; - if (length < 1) - return 0; + if (length < 1) + return 0; - length--; - size_t index = 0; + length--; + size_t index = 0; - while (index < length) - { - int c = timedRead(); + while (index < length) + { + int c = timedRead(); - if (c == terminator) - break; + if (c == terminator) + break; - if (c < 0) - { - setReadError(); - break; - } + if (c < 0) + { + setReadError(); + break; + } - *buffer++ = (char)c; - index++; - } + *buffer++ = (char)c; + index++; + } - *buffer = 0; - return index; // return number of characters, not including null terminator + *buffer = 0; + return index; // return number of characters, not including null terminator } #if 1 @@ -333,112 +333,112 @@ size_t Stream::readBytesUntil(char terminator, char *buffer, size_t length) String Stream::readString(size_t max) { - String ret; - int c = timedRead(); + String ret; + int c = timedRead(); - while (c >= 0) - { - ret += (char)c; - c = timedRead(); - } + while (c >= 0) + { + ret += (char)c; + c = timedRead(); + } - return ret; + return ret; } char readStringBuffer[2048]; char* Stream::readCharsUntil(char terminator, size_t max) { - uint16_t offset = 0; + uint16_t offset = 0; - int c = timedRead(); + int c = timedRead(); - readStringBuffer[offset++] = c; + readStringBuffer[offset++] = c; - while (c >= 0 && c != terminator) - { - c = timedRead(); + while (c >= 0 && c != terminator) + { + c = timedRead(); - readStringBuffer[offset++] = c; - } + readStringBuffer[offset++] = c; + } - readStringBuffer[offset] = 0; + readStringBuffer[offset] = 0; - return readStringBuffer; + return readStringBuffer; } String Stream::readStringUntil(char terminator, size_t max) { - String ret; - uint16_t offset = 0; + String ret; + uint16_t offset = 0; - int c = timedRead(); + int c = timedRead(); - readStringBuffer[offset++] = c; + readStringBuffer[offset++] = c; - while (c >= 0 && c != terminator) - { - c = timedRead(); + while (c >= 0 && c != terminator) + { + c = timedRead(); - readStringBuffer[offset++] = c; - } + readStringBuffer[offset++] = c; + } - readStringBuffer[offset] = 0; + readStringBuffer[offset] = 0; - ret = String(readStringBuffer); + ret = String(readStringBuffer); - return String(readStringBuffer); + return String(readStringBuffer); } #else String Stream::readString(size_t max) { - String str; - size_t length = 0; + String str; + size_t length = 0; - while (length < max) - { - int c = timedRead(); + while (length < max) + { + int c = timedRead(); - if (c < 0) - { - setReadError(); - break; // timeout - } + if (c < 0) + { + setReadError(); + break; // timeout + } - if (c == 0) - break; + if (c == 0) + break; - str += (char)c; - length++; - } + str += (char)c; + length++; + } - return str; + return str; } String Stream::readStringUntil(char terminator, size_t max) { - String str; - size_t length = 0; + String str; + size_t length = 0; - while (length < max) - { - int c = timedRead(); + while (length < max) + { + int c = timedRead(); - if (c < 0) - { - setReadError(); - break; // timeout - } + if (c < 0) + { + setReadError(); + break; // timeout + } - if (c == 0 || c == terminator) - break; + if (c == 0 || c == terminator) + break; - str += (char)c; - length++; - } + str += (char)c; + length++; + } - return str; + return str; } #endif diff --git a/Packages_Patches/hardware/teensy/avr/cores/teensy4/Stream.h b/Packages_Patches/hardware/teensy/avr/cores/teensy4/Stream.h index b3cea254..7f407cda 100644 --- a/Packages_Patches/hardware/teensy/avr/cores/teensy4/Stream.h +++ b/Packages_Patches/hardware/teensy/avr/cores/teensy4/Stream.h @@ -25,124 +25,124 @@ class Stream : public Print { - public: - constexpr Stream() : _timeout(1000), read_error(0) {} - virtual int available() = 0; - virtual int read() = 0; - virtual int peek() = 0; - - void setTimeout(unsigned long timeout); - bool find(const char *target); - - bool find(const uint8_t *target) - { - return find ((const char *)target); - } - - bool find(const String &target) - { - return find(target.c_str()); - } - - bool find(const char *target, size_t length); - - bool find(const uint8_t *target, size_t length) - { - return find ((const char *)target, length); - } - - bool find(const String &target, size_t length) - { - return find(target.c_str(), length); - } - - bool findUntil(const char *target, const char *terminator); - - bool findUntil(const uint8_t *target, const char *terminator) - { - return findUntil((const char *)target, terminator); - } - - bool findUntil(const String &target, const char *terminator) - { - return findUntil(target.c_str(), terminator); - } - - bool findUntil(const char *target, const String &terminator) - { - return findUntil(target, terminator.c_str()); - } - - bool findUntil(const String &target, const String &terminator) - { - return findUntil(target.c_str(), terminator.c_str()); - } - - bool findUntil(const char *target, size_t targetLen, const char *terminate, size_t termLen); - - bool findUntil(const uint8_t *target, size_t targetLen, const char *terminate, size_t termLen) - { - return findUntil((const char *)target, targetLen, terminate, termLen); - } - - bool findUntil(const String &target, size_t targetLen, const char *terminate, size_t termLen); - bool findUntil(const char *target, size_t targetLen, const String &terminate, size_t termLen); - bool findUntil(const String &target, size_t targetLen, const String &terminate, size_t termLen); - - long parseInt(); - long parseInt(char skipChar); - - float parseFloat(); - float parseFloat(char skipChar); - - size_t readBytes(char *buffer, size_t length); - - size_t readBytes(uint8_t *buffer, size_t length) - { - return readBytes((char *)buffer, length); - } - - size_t readBytesUntil(char terminator, char *buffer, size_t length); - - size_t readBytesUntil(char terminator, uint8_t *buffer, size_t length) - { - return readBytesUntil(terminator, (char *)buffer, length); - } - - //////////////////////////////////////////////////////////// - String readString(size_t max = 512); - String readStringUntil(char terminator, size_t max = 512); - - // KH, to not use String - char* readCharsUntil(char terminator, size_t max = 512); - //////////////////////////////////////////////////////////// - - int getReadError() - { - return read_error; - } - - void clearReadError() - { - setReadError(0); - } - - protected: - void setReadError(int err = 1) - { - read_error = err; - } + public: + constexpr Stream() : _timeout(1000), read_error(0) {} + virtual int available() = 0; + virtual int read() = 0; + virtual int peek() = 0; + + void setTimeout(unsigned long timeout); + bool find(const char *target); + + bool find(const uint8_t *target) + { + return find ((const char *)target); + } + + bool find(const String &target) + { + return find(target.c_str()); + } + + bool find(const char *target, size_t length); + + bool find(const uint8_t *target, size_t length) + { + return find ((const char *)target, length); + } + + bool find(const String &target, size_t length) + { + return find(target.c_str(), length); + } + + bool findUntil(const char *target, const char *terminator); + + bool findUntil(const uint8_t *target, const char *terminator) + { + return findUntil((const char *)target, terminator); + } + + bool findUntil(const String &target, const char *terminator) + { + return findUntil(target.c_str(), terminator); + } + + bool findUntil(const char *target, const String &terminator) + { + return findUntil(target, terminator.c_str()); + } + + bool findUntil(const String &target, const String &terminator) + { + return findUntil(target.c_str(), terminator.c_str()); + } + + bool findUntil(const char *target, size_t targetLen, const char *terminate, size_t termLen); + + bool findUntil(const uint8_t *target, size_t targetLen, const char *terminate, size_t termLen) + { + return findUntil((const char *)target, targetLen, terminate, termLen); + } + + bool findUntil(const String &target, size_t targetLen, const char *terminate, size_t termLen); + bool findUntil(const char *target, size_t targetLen, const String &terminate, size_t termLen); + bool findUntil(const String &target, size_t targetLen, const String &terminate, size_t termLen); + + long parseInt(); + long parseInt(char skipChar); + + float parseFloat(); + float parseFloat(char skipChar); + + size_t readBytes(char *buffer, size_t length); + + size_t readBytes(uint8_t *buffer, size_t length) + { + return readBytes((char *)buffer, length); + } + + size_t readBytesUntil(char terminator, char *buffer, size_t length); + + size_t readBytesUntil(char terminator, uint8_t *buffer, size_t length) + { + return readBytesUntil(terminator, (char *)buffer, length); + } + + //////////////////////////////////////////////////////////// + String readString(size_t max = 512); + String readStringUntil(char terminator, size_t max = 512); + + // KH, to not use String + char* readCharsUntil(char terminator, size_t max = 512); + //////////////////////////////////////////////////////////// + + int getReadError() + { + return read_error; + } + + void clearReadError() + { + setReadError(0); + } + + protected: + void setReadError(int err = 1) + { + read_error = err; + } - unsigned long _timeout; - - // KH - int timedRead(); - int timedPeek(); - int peekNextDigit(); - ////// + unsigned long _timeout; + + // KH + int timedRead(); + int timedPeek(); + int peekNextDigit(); + ////// - private: - char read_error; + private: + char read_error; }; #endif diff --git a/Packages_Patches/industrialshields/hardware/avr/1.1.36/cores/industrialshields/Udp.h b/Packages_Patches/industrialshields/hardware/avr/1.1.36/cores/industrialshields/Udp.h index 267b221b..810e745e 100644 --- a/Packages_Patches/industrialshields/hardware/avr/1.1.36/cores/industrialshields/Udp.h +++ b/Packages_Patches/industrialshields/hardware/avr/1.1.36/cores/industrialshields/Udp.h @@ -41,56 +41,57 @@ class UDP : public Stream { - public: - virtual uint8_t begin(uint16_t) = 0; // initialize, start listening on specified port. Returns 1 if successful, 0 if there are no sockets available to use - virtual uint8_t beginMulticast(IPAddress, uint16_t) - { - return 0; // initialize, start listening on specified multicast IP address and port. Returns 1 if successful, 0 on failure - } - virtual void stop() = 0; // Finish with the UDP socket + public: + virtual uint8_t begin(uint16_t) = + 0; // initialize, start listening on specified port. Returns 1 if successful, 0 if there are no sockets available to use + virtual uint8_t beginMulticast(IPAddress, uint16_t) + { + return 0; // initialize, start listening on specified multicast IP address and port. Returns 1 if successful, 0 on failure + } + virtual void stop() = 0; // Finish with the UDP socket - // Sending UDP packets + // Sending UDP packets - // Start building up a packet to send to the remote host specific in ip and port - // Returns 1 if successful, 0 if there was a problem with the supplied IP address or port - virtual int beginPacket(IPAddress ip, uint16_t port) = 0; - // Start building up a packet to send to the remote host specific in host and port - // Returns 1 if successful, 0 if there was a problem resolving the hostname or port - virtual int beginPacket(const char *host, uint16_t port) = 0; - // Finish off this packet and send it - // Returns 1 if the packet was sent successfully, 0 if there was an error - virtual int endPacket() = 0; - // Write a single byte into the packet - virtual size_t write(uint8_t) = 0; - // Write size bytes from buffer into the packet - virtual size_t write(const uint8_t *buffer, size_t size) = 0; + // Start building up a packet to send to the remote host specific in ip and port + // Returns 1 if successful, 0 if there was a problem with the supplied IP address or port + virtual int beginPacket(IPAddress ip, uint16_t port) = 0; + // Start building up a packet to send to the remote host specific in host and port + // Returns 1 if successful, 0 if there was a problem resolving the hostname or port + virtual int beginPacket(const char *host, uint16_t port) = 0; + // Finish off this packet and send it + // Returns 1 if the packet was sent successfully, 0 if there was an error + virtual int endPacket() = 0; + // Write a single byte into the packet + virtual size_t write(uint8_t) = 0; + // Write size bytes from buffer into the packet + virtual size_t write(const uint8_t *buffer, size_t size) = 0; - // Start processing the next available incoming packet - // Returns the size of the packet in bytes, or 0 if no packets are available - virtual int parsePacket() = 0; - // Number of bytes remaining in the current packet - virtual int available() = 0; - // Read a single byte from the current packet - virtual int read() = 0; - // Read up to len bytes from the current packet and place them into buffer - // Returns the number of bytes read, or 0 if none are available - virtual int read(unsigned char* buffer, size_t len) = 0; - // Read up to len characters from the current packet and place them into buffer - // Returns the number of characters read, or 0 if none are available - virtual int read(char* buffer, size_t len) = 0; - // Return the next byte from the current packet without moving on to the next byte - virtual int peek() = 0; - virtual void flush() = 0; // Finish reading the current packet + // Start processing the next available incoming packet + // Returns the size of the packet in bytes, or 0 if no packets are available + virtual int parsePacket() = 0; + // Number of bytes remaining in the current packet + virtual int available() = 0; + // Read a single byte from the current packet + virtual int read() = 0; + // Read up to len bytes from the current packet and place them into buffer + // Returns the number of bytes read, or 0 if none are available + virtual int read(unsigned char* buffer, size_t len) = 0; + // Read up to len characters from the current packet and place them into buffer + // Returns the number of characters read, or 0 if none are available + virtual int read(char* buffer, size_t len) = 0; + // Return the next byte from the current packet without moving on to the next byte + virtual int peek() = 0; + virtual void flush() = 0; // Finish reading the current packet - // Return the IP address of the host who sent the current incoming packet - virtual IPAddress remoteIP() = 0; - // Return the port of the host who sent the current incoming packet - virtual uint16_t remotePort() = 0; - protected: - uint8_t* rawIPAddress(IPAddress& addr) - { - return addr.raw_address(); - }; + // Return the IP address of the host who sent the current incoming packet + virtual IPAddress remoteIP() = 0; + // Return the port of the host who sent the current incoming packet + virtual uint16_t remotePort() = 0; + protected: + uint8_t* rawIPAddress(IPAddress& addr) + { + return addr.raw_address(); + }; }; #endif diff --git a/Packages_Patches/industrialshields/hardware/avr/1.1.37/cores/industrialshields/Udp.h b/Packages_Patches/industrialshields/hardware/avr/1.1.37/cores/industrialshields/Udp.h index 267b221b..810e745e 100644 --- a/Packages_Patches/industrialshields/hardware/avr/1.1.37/cores/industrialshields/Udp.h +++ b/Packages_Patches/industrialshields/hardware/avr/1.1.37/cores/industrialshields/Udp.h @@ -41,56 +41,57 @@ class UDP : public Stream { - public: - virtual uint8_t begin(uint16_t) = 0; // initialize, start listening on specified port. Returns 1 if successful, 0 if there are no sockets available to use - virtual uint8_t beginMulticast(IPAddress, uint16_t) - { - return 0; // initialize, start listening on specified multicast IP address and port. Returns 1 if successful, 0 on failure - } - virtual void stop() = 0; // Finish with the UDP socket + public: + virtual uint8_t begin(uint16_t) = + 0; // initialize, start listening on specified port. Returns 1 if successful, 0 if there are no sockets available to use + virtual uint8_t beginMulticast(IPAddress, uint16_t) + { + return 0; // initialize, start listening on specified multicast IP address and port. Returns 1 if successful, 0 on failure + } + virtual void stop() = 0; // Finish with the UDP socket - // Sending UDP packets + // Sending UDP packets - // Start building up a packet to send to the remote host specific in ip and port - // Returns 1 if successful, 0 if there was a problem with the supplied IP address or port - virtual int beginPacket(IPAddress ip, uint16_t port) = 0; - // Start building up a packet to send to the remote host specific in host and port - // Returns 1 if successful, 0 if there was a problem resolving the hostname or port - virtual int beginPacket(const char *host, uint16_t port) = 0; - // Finish off this packet and send it - // Returns 1 if the packet was sent successfully, 0 if there was an error - virtual int endPacket() = 0; - // Write a single byte into the packet - virtual size_t write(uint8_t) = 0; - // Write size bytes from buffer into the packet - virtual size_t write(const uint8_t *buffer, size_t size) = 0; + // Start building up a packet to send to the remote host specific in ip and port + // Returns 1 if successful, 0 if there was a problem with the supplied IP address or port + virtual int beginPacket(IPAddress ip, uint16_t port) = 0; + // Start building up a packet to send to the remote host specific in host and port + // Returns 1 if successful, 0 if there was a problem resolving the hostname or port + virtual int beginPacket(const char *host, uint16_t port) = 0; + // Finish off this packet and send it + // Returns 1 if the packet was sent successfully, 0 if there was an error + virtual int endPacket() = 0; + // Write a single byte into the packet + virtual size_t write(uint8_t) = 0; + // Write size bytes from buffer into the packet + virtual size_t write(const uint8_t *buffer, size_t size) = 0; - // Start processing the next available incoming packet - // Returns the size of the packet in bytes, or 0 if no packets are available - virtual int parsePacket() = 0; - // Number of bytes remaining in the current packet - virtual int available() = 0; - // Read a single byte from the current packet - virtual int read() = 0; - // Read up to len bytes from the current packet and place them into buffer - // Returns the number of bytes read, or 0 if none are available - virtual int read(unsigned char* buffer, size_t len) = 0; - // Read up to len characters from the current packet and place them into buffer - // Returns the number of characters read, or 0 if none are available - virtual int read(char* buffer, size_t len) = 0; - // Return the next byte from the current packet without moving on to the next byte - virtual int peek() = 0; - virtual void flush() = 0; // Finish reading the current packet + // Start processing the next available incoming packet + // Returns the size of the packet in bytes, or 0 if no packets are available + virtual int parsePacket() = 0; + // Number of bytes remaining in the current packet + virtual int available() = 0; + // Read a single byte from the current packet + virtual int read() = 0; + // Read up to len bytes from the current packet and place them into buffer + // Returns the number of bytes read, or 0 if none are available + virtual int read(unsigned char* buffer, size_t len) = 0; + // Read up to len characters from the current packet and place them into buffer + // Returns the number of characters read, or 0 if none are available + virtual int read(char* buffer, size_t len) = 0; + // Return the next byte from the current packet without moving on to the next byte + virtual int peek() = 0; + virtual void flush() = 0; // Finish reading the current packet - // Return the IP address of the host who sent the current incoming packet - virtual IPAddress remoteIP() = 0; - // Return the port of the host who sent the current incoming packet - virtual uint16_t remotePort() = 0; - protected: - uint8_t* rawIPAddress(IPAddress& addr) - { - return addr.raw_address(); - }; + // Return the IP address of the host who sent the current incoming packet + virtual IPAddress remoteIP() = 0; + // Return the port of the host who sent the current incoming packet + virtual uint16_t remotePort() = 0; + protected: + uint8_t* rawIPAddress(IPAddress& addr) + { + return addr.raw_address(); + }; }; #endif diff --git a/Packages_Patches/rp2040/hardware/rp2040/1.3.1/cores/rp2040/Arduino.h b/Packages_Patches/rp2040/hardware/rp2040/1.3.1/cores/rp2040/Arduino.h index f1a61729..bb60ccfa 100644 --- a/Packages_Patches/rp2040/hardware/rp2040/1.3.1/cores/rp2040/Arduino.h +++ b/Packages_Patches/rp2040/hardware/rp2040/1.3.1/cores/rp2040/Arduino.h @@ -105,7 +105,7 @@ unsigned long millis(); template constexpr uint32_t __bitset(const int (&a)[N], size_t i = 0U) { - return i < N ? (1L << a[i]) | __bitset(a, i + 1) : 0; + return i < N ? (1L << a[i]) | __bitset(a, i + 1) : 0; } #endif diff --git a/Packages_Patches/rp2040/hardware/rp2040/1.4.0/cores/rp2040/Arduino.h b/Packages_Patches/rp2040/hardware/rp2040/1.4.0/cores/rp2040/Arduino.h index f1a61729..bb60ccfa 100644 --- a/Packages_Patches/rp2040/hardware/rp2040/1.4.0/cores/rp2040/Arduino.h +++ b/Packages_Patches/rp2040/hardware/rp2040/1.4.0/cores/rp2040/Arduino.h @@ -105,7 +105,7 @@ unsigned long millis(); template constexpr uint32_t __bitset(const int (&a)[N], size_t i = 0U) { - return i < N ? (1L << a[i]) | __bitset(a, i + 1) : 0; + return i < N ? (1L << a[i]) | __bitset(a, i + 1) : 0; } #endif