Commit graph

706 commits

Author SHA1 Message Date
John Whittington
bdeaf1576b ARM_TOOL_PATH detection, use latest version of tool if multiple found 2019-07-17 10:19:03 +02:00
Sudar Muthu
3817dbeb28
Merge pull request #604 from stv0g/fix-issue-601
Fix regression: PARSE_BOARD chops off flags which contain '=' signs
2019-06-03 11:52:05 +05:30
Steffen Vogel
6cf275f0e7 fix regression: PARSE_BOARD chops off flags which contain '=' signs (closes #601) 2019-05-03 20:07:13 +02:00
Sudar Muthu
8c85ca7001
Merge pull request #598 from Dukejung/master
Add OpenCR.mk for OpenCR 1.0 board example sketch
2019-04-20 14:37:12 +05:30
Simon John
4e465c693c
Update HISTORY.md 2019-04-01 10:30:33 +01:00
Simon John
f5893dc7a1
Merge pull request #603 from tuna-f1sh/master
add swtich for ARM 'avr-size' so that .elf is passed as arg
2019-04-01 10:26:33 +01:00
John Whittington
9783e68bc8 add swtich for ARM 'avr-size' so that .elf is passed as arg
`avr-size` was defaulting to AVR non-aware when using ARM builds, which
meant passing .hex rather than .elf to size and limiting size readout.
Adding a switch for defining `avr-size` and SIZEFLAGS to Sam.mk seems
like the best way to include proper ARM support (despite conflicting
naming).
2019-03-25 13:36:03 +00:00
Simon John
591855b890
Merge pull request #600 from HorkusBoy/samd-typo-pr
Fixed typo in variable name BOARDS_TXT in Sam.mk
2019-03-02 23:38:21 +00:00
Ben B
d2d7d4ec16 Fixed typo in var name BOARDS_TXT in Sam.mk 2019-03-02 10:01:25 -06:00
Dukejung
12c62dd200
Update runtests.sh 2019-02-11 18:04:09 +09:00
Dukejung
c9d9c9f34d
Update HISTORY.md 2019-02-11 17:50:05 +09:00
Dukejung
17a69524ee Add OpenCR.mk for OpenCR 1.0 board and add example code(example/BlinkOpenCR) 2019-02-11 16:54:35 +09:00
Simon John
4452f7790a
Merge pull request #597 from tuna-f1sh/master
Fix #594 and sam flag for ardmk-init
2019-01-11 19:55:14 +00:00
John Whittington
e3a99fdf4e Only add USB_PRODUCT and USB_MANUFACTURER to flags if defined 2019-01-11 13:49:40 +00:00
John Whittington
8a313c5d94 Populate USB_PRODUCT and USB_MANUFACTURER if in boards file using Caterina 2019-01-11 11:17:16 +00:00
John Whittington
e88f7e1a9f Add 'sam' flag to ardmk-init to include Sam.mk rather than Arduino.mk 2018-12-24 09:24:14 +00:00
Simon John
fd24677719
Updated history
Added ArchLinux documentation uplift
2018-11-27 15:45:59 +00:00
Simon John
2938a0f5b4
Merge pull request #593 from Akram-Chehaima/master
Change & add repo to install package on Arch linux
2018-11-27 14:18:37 +00:00
Akram Chehaima
ccd3a5289c
Change & add repo to install package onArch linux
yaourt is "Discontinued" it's not save must use alternatives like yay On Arch Linux
add commands to install python-pyserial on Arch Linux
2018-11-27 13:59:12 +01:00
Simon John
d3be28b500
Merge pull request #592 from dewhisna/cpu_speed_select
Add support for BOARD_CLOCK setting
2018-11-17 18:59:48 +00:00
Donna Whisnant
35fece8b9c Change BOARD_SPEED to BOARD_CLOCK setting and extend to menu.clock and menu.speed.
This is needed to specify CPU speed and fuses for boards.txt files that use this format:
"{board_tag}.menu.clock.{board_clock}.build.f_cpu"
"{board_tag}.menu.clock.{board_clock}.bootloader.low_fuses"
"{board_tag}.menu.clock.{board_clock}.bootloader.high_fuses"
"{board_tag}.menu.clock.{board_clock}.bootloader.extended_fuses"
For example ATtiny processors.

It also works for speed-only settings like the Watterott ATmega328PB library: https://github.com/watterott/ATmega328PB-Testing
"{board_tag}.menu.speed.{board_clock}.build.f_cpu"
2018-11-11 17:14:11 -06:00
Donna Whisnant
66e0211878 Update documentation for BOARD_SPEED. 2018-11-11 13:27:11 -06:00
Donna Whisnant
0f02622467 Add support for BOARD_SPEED setting.
This is needed to specify CPU speed for boards.txt files that use this format:
"{board_tag}.menu.speed.{board_speed}.build.f_cpu"
For example, the Watterott ATmega328PB library: https://github.com/watterott/ATmega328PB-Testing
2018-11-11 13:01:52 -06:00
Sudar Muthu
5a0c80bf0c
Merge pull request #583 from wingunder/move_core_link_last
Moved CORE_LIB to the last position of the defined linked objects.
2018-10-07 11:19:56 +05:30
Pieter du Preez
ed608ce658 Merge remote-tracking branch 'origin/fix-travis-sudo-required' into move_core_link_last 2018-10-03 21:19:16 +02:00
Pieter du Preez
50e883b640
Fix "does not allow use of 'sudo'" error in travis
Pull requests seem to fail with the following error:
> This job is running on container-based infrastructure, which does not allow use of 'sudo', setuid, and setgid executables.
> If you require sudo, add 'sudo: required' to your .travis.yml

This commit fixes it, by adding 'sudo: required' to .travis.yml, as suggested by the error message.
2018-10-03 14:36:49 +02:00
Pieter du Preez
a285810cb5 Added a test case for moving CORE_LIB in PR #583.
This patch is meant to test the link order, if the OTHER_OBJS
variable gets used to add 3rd party archives, that depend on the
Arduino core lib (the archive pointed to by the CORE_LIB variable).

The examples/Blink3rdPartyLib directory contains a stripped down Blink
and includes a library in the examples/Blink3rdPartyLib/Toggle
sub-directory. The archive, built inside the Toggle directory mimics a
3rd party library. The archive gets built and linked in by using the
OTHER_OBS variable in examples/Blink3rdPartyLib/Makefile.
2018-10-02 23:00:14 +02:00
Pieter du Preez
d4d3d3d6c3 Merge remote-tracking branch 'org/master' into move_core_link_last 2018-10-02 22:53:12 +02:00
Sudar Muthu
fe84c59194
Merge pull request #580 from wingunder/master
Moved the PARSE_BOARD macro and added the TOOL_PREFIX variable for setting up tool chains.
2018-09-30 20:13:29 +05:30
Sudar Muthu
089b535601
Merge pull request #582 from tuna-f1sh/master
Pass OpenOCD options to debug_init target
2018-09-30 20:12:49 +05:30
Pieter du Preez
ddf7210407 Moved CORE_LIB to the last position of the defined linked objects.
The linking order was changed from:
   $(LOCAL_OBJS) $(CORE_LIB) $(OTHER_OBJS) $(OTHER_LIBS)
to:
   $(LOCAL_OBJS) $(OTHER_OBJS) $(OTHER_LIBS) $(CORE_LIB)

This makes more sense, as OTHER_OBJS would rather depend on CORE_LIB,
than the other way around.

Apart from libc and libm, CORE_LIB should conceptually _always_ be
the last lib in the link list, as it is the core (base of everything).
BTW, this was implemented correctly for the 'sam' architecture.
2018-09-30 00:27:18 +02:00
John Whittington
0692c13e98 Pass OpenOCD options to debug_init target 2018-09-28 18:25:56 +01:00
Pieter du Preez
62d23d66a2 Moved the BOARDS_TXT section and stop if BOARDS_TXT is not a file.
The section of Arduino.mk that calculates BOARDS_TXT was moved to just
before the point where it gets used for the first time (a call to
PARSE_BOARD). An error gets generated if BOARDS_TXT is not pointing to a
valid file, directly after the BOARDS_TXT calculation.

In addition, the PARSE_BOARD macro will now be bypassed if the
BOARDS_TXT variable points to a non-existing file. If a user makefile
uses PARSE_BOARD before including Arduino.mk, and the BOARDS_TXT is
wrong, the error will only be caught in the Arduino.mk file, which is
probably acceptable.
2018-09-15 14:31:39 +02:00
Pieter du Preez
e44540043e Added the TOOL_PREFIX variable for setting up the executable tools.
Currently three different tool chains seem to be used:
   * avr-*
   * pic32-*
   * arm-none-eabi-*

These all get set up independently. This patch centralizes the
definitions of the executable tools and does it generically, by means
of the newly introduced TOOL_PREFIX variable. Setting up a
tool chain is now simply a matter of defining the TOOL_PREFIX
variable. For the currently supported tool chains it gets set to avr,
pic32 or arm-none-eabi. Arbitrary tool chains can now easily be set up,
by the TOOL_PREFIX variable.

Although the use of the OVERRIDE_EXECUTABLES variable is now almost
not justifiable, it was left as-is, in order to assure backwards
compatibility.
2018-09-14 16:14:14 +02:00
Pieter du Preez
2442dafb4f Moved the PARSE_BOARD macro from Arduino.mk to Common.mk.
There seems to be 3 different macros to parse the boards.txt file.
This patch moves the PARSE_BOARD macro from Arduino.mk to Common.mk.
The PARSE_OPENCM and PARSE_TEENSY macros in Teensy.mk and OpenCM.mk
were removed and the common PARSE_BOARD is now being called from
everywhere.

Advantages of this fix are:
  1. Less code, i.e. no redundant parse macros.
  2. A single standardized algorithm to parse the boards.txt file.
2018-09-13 23:44:12 +02:00
Simon John
22ca63614d
Merge pull request #578 from TE-HiroakiYamazoe/fix_typo_of_avrdude_isp_opt
Fix typo of AVRDUDE_ISP_OPT
2018-08-10 19:41:18 +01:00
Hiroaki Yamazoe
300ec05328 Fix typo of AVRDUDE_ISP_OPT 2018-08-09 18:48:50 +09:00
Sudar Muthu
b2d1ff23a2
Merge pull request #567 from tuna-f1sh/due
Support for Arduino Due added
2018-06-22 09:45:03 +05:30
John Whittington
3f32563683 Support for Arduino Due added
Update HISTORY.md

Add avr core emulation to C sources
2018-06-14 07:29:06 +01:00
Sudar Muthu
0809b54606
Merge pull request #556 from wingunder/master
Added the DIAGNOSTICS_COLOR_WHEN var for controlling diagnostics-color.
2018-03-18 22:36:23 +05:30
Pieter du Preez
36b6b233eb Added the DIAGNOSTICS_COLOR_WHEN var for controlling diagnostics-color.
Some IDEs do not work nicely with the recently added diagnostics-color
compiler switch. This patch adds the DIAGNOSTICS_COLOR_WHEN variable,
for controlling diagnostics-color switch. The default was chosen to be
'always', which makes the Arduino.mk file backwards compatible with
everything up to commit fa82c3a9db (Sat Sep 2 15:32:52 2017 +0100).

The supported values for DIAGNOSTICS_COLOR_WHEN are: `always`, `never`
and `auto`, and as with all Arduino.mk variables, it can easily be
overridden. For more details on the diagnostics-color compiler switch,
see: https://gcc.gnu.org/onlinedocs/gcc-4.9.2/gcc/Language-Independent-Options.html#Language-Independent-Options
2018-03-18 16:54:39 +01:00
Simon John
a7b8084ac6
Merge pull request #546 from kierdavis/disable-prog-types-compat
Allow compatibility with old pgmspace API to be disabled by the user
2018-02-24 16:06:09 +00:00
Simon John
139b5dbc49
Merge branch 'master' into disable-prog-types-compat 2018-02-24 16:03:37 +00:00
Simon John
c10eaa4f48
Merge pull request #533 from doronbehar/detect-archlinux
Set `ARDMK_VENDOR` differently if OS is Arch Linux.
2018-02-24 16:02:18 +00:00
Simon John
80b8167206
Merge pull request #543 from tuna-f1sh/sam
Arduino Atmel SAM family Support (ARM architecture)

Thanks @tuna-f1sh !
2018-02-24 16:01:00 +00:00
John Whittington
f804866095 SAMD Cortex M0 device support (Zero, MKR1000, etc)
Compilation improvements by adding variant as other obj but not working on device

Arduino Zero devices with OpenOCD working

Created ARM_TOOLS_DIR and define arm toolchain executables in Sam.mk

Check avr-gcc on last AVR_TOOLS_DIR detect and indenting formatting

GDB debugging and programming added

Documentation updates and define ARDMK_VENDOR rather than include Sam.mk

Expand all parse_boards when defined rather than when used

Trim extra defines regex working on both macOS and Linux but need better fix

Print USB ids and added debug usage to readme

Add note on Arduino package dir and made board.txt work

Do ARM ARDUINO_ARCH define in Arduino.mk]

Add MZeroBlink to non-testable examples for now

Remove \B from extra defines grep

Add ARDUINO_PACKAGE_DIR for board support files

Fix a typo in the README

Fix typo in arduino-mk-vars.md

Prevent re-including Arduino.mk from Sam.mk when make restarts for upload

Add catrina to ARD_REST_OPTS if/else

Remove realpath in Sam.mk for cygwin compatability

SAMD bootloader support in ard-reset using --zero

Enters bootloader using open/close of port at 1200 BAUD, then polls the
attached devices for new port enumerating (bootloader). This is how the
Arduino IDE operates

Bossa support for Zero, MKR1000 etc

Re-word Arm README section after Native USB development

Reset for zero refactored like IDE

Zero bootloader reset tested on macOS and comments added

Re-word ARM bootloader and remove imports from testing

Patch changes ARDMK_VENDOR->ARCHITECHTURE, show_config_vars, ignore CORE_VER if emtpy

Common.mk header guard, openocd/bossac avoid separator, typos

Documentation update for patch changes

Move ARM tools to Sam.mk and auto-detect include

Correct accidental commit of Blink Makefile change

Lib fix with alternative core and documentation

Append zero to ARD_RESET_OPTS rather than set

Prioritise package ARM upload tools over path installed

Add note in README on ARM tools versions

Move openocd variant config script flag to OPTS
2018-02-24 11:15:53 +00:00
Sudar Muthu
8480373477
Merge pull request #548 from kierdavis/fix-typo
Fix typo in arduino-mk-vars.md
2018-01-25 09:38:47 +05:30
Kier Davis
b4c381c4b7
Fix typo in arduino-mk-vars.md 2018-01-24 22:12:01 +00:00
Kier Davis
b3c5127be2
Allow compatibility with old pgmspace API to be disabled by the user
When this compatibility mode is enabled, code that is entirely
compliant with the new pgmspace API can still raise deprecation
warnings when symbols present in both the old and new APIs (for
example, PGM_P) are used. Clearly, these warnings are false
positives. They can be avoided by disabling the compatibility mode.

This functionality is achieved by prepending the flag that enables
the compatibility mode to CPPFLAGS instead of appending it, thus
allowing the user to override the default behaviour and disable the
compatibility mode by putting the negation of the flag in the
CPPFLAGS variable in their top-level Makefile.
2018-01-24 21:52:22 +00:00
Sudar Muthu
5869c98344
Merge pull request #545 from kierdavis/fix-readme-typo
Fix a typo in the README
2018-01-22 15:00:28 +05:30