Ian Burgmyer
4 years ago
commit
63ce4a17af
5 changed files with 88 additions and 0 deletions
@ -0,0 +1,20 @@
|
||||
Copyright (c) 2020 Ian Burgmyer |
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of |
||||
this software and associated documentation files (the "Software"), to deal in |
||||
the Software without restriction, including without limitation the rights to |
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies |
||||
of the Software, and to permit persons to whom the Software is furnished to do |
||||
so, subject to the following conditions: |
||||
|
||||
The above copyright notice and this permission notice shall be included in all |
||||
copies or substantial portions of the Software. |
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR |
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, |
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE |
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER |
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, |
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE |
||||
SOFTWARE. |
||||
|
@ -0,0 +1,45 @@
|
||||
# Arduboy project Makefile, by Spectere.
|
||||
#
|
||||
# Calling "make setup" will install the required components and libraries to
|
||||
# your system.
|
||||
#
|
||||
# Requires: arduino-cli, GNU make (probably)
|
||||
|
||||
PROJECT_NAME = hello
|
||||
|
||||
ARDUINO-CLI = arduino-cli
|
||||
AVRDUDE = avrdude
|
||||
|
||||
BIN = bin
|
||||
SRC = ${PROJECT_NAME}
|
||||
|
||||
# credit: kenorb
|
||||
# https://stackoverflow.com/questions/18136918/how-to-get-current-relative-directory-of-your-makefile
|
||||
CWD := $(abspath $(patsubst %/,%,$(dir $(abspath $(lastword $(MAKEFILE_LIST))))))
|
||||
|
||||
all: compile |
||||
|
||||
setup: |
||||
# Platforms
|
||||
${ARDUINO-CLI} core install arduino:avr
|
||||
|
||||
# Libraries
|
||||
${ARDUINO-CLI} lib install Arduboy
|
||||
${ARDUINO-CLI} lib install Arduboy2
|
||||
${ARDUINO-CLI} lib install ArdBitmap
|
||||
${ARDUINO-CLI} lib install ArdVoice
|
||||
${ARDUINO-CLI} lib install ArduboyPlaytune
|
||||
${ARDUINO-CLI} lib install Arduboy-TinyFont
|
||||
${ARDUINO-CLI} lib install ArduboyTones
|
||||
${ARDUINO-CLI} lib install FixedPoints
|
||||
|
||||
# Fin
|
||||
${ARDUINO-CLI} core update-index
|
||||
|
||||
compile: |
||||
cd ${CWD}
|
||||
${ARDUINO-CLI} compile --fqbn arduino:avr:leonardo ${SRC} --output-dir ${CWD}/${BIN}
|
||||
|
||||
upload: compile |
||||
cd ${CWD}
|
||||
${ARDUINO-CLI} upload --fqbn arduino:avr:leonardo --input-dir ${BIN} -p ${TARGET} ${PROJECT_NAME}
|
@ -0,0 +1,8 @@
|
||||
{ |
||||
"folders": |
||||
[ |
||||
{ |
||||
"path": "." |
||||
} |
||||
] |
||||
} |
Loading…
Reference in new issue