aboutsummaryrefslogtreecommitdiff
path: root/arduino-mk-vars.md
diff options
context:
space:
mode:
authorDonna Whisnant <dewhisna@users.noreply.github.com>2018-11-11 16:55:52 -0600
committerDonna Whisnant <dewhisna@users.noreply.github.com>2018-11-11 17:14:11 -0600
commit35fece8b9cd05542068bfff5d0134c4b88a5f6bf (patch)
treeb75e967baf58d68eb21ab01424d3a0e772fbce96 /arduino-mk-vars.md
parent66e0211878ac843db3ad52e8643dd98d632217eb (diff)
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"
Diffstat (limited to 'arduino-mk-vars.md')
-rw-r--r--arduino-mk-vars.md19
1 files changed, 14 insertions, 5 deletions
diff --git a/arduino-mk-vars.md b/arduino-mk-vars.md
index f08b0a2..3ee05d0 100644
--- a/arduino-mk-vars.md
+++ b/arduino-mk-vars.md
@@ -344,21 +344,30 @@ BOARD_SUB=atmega168
----
-### BOARD_SPEED
+### BOARD_CLOCK
**Description:**
-Allow selection of f_cpu value specified in `boards.txt` as `board_tag.menu.speed.board_speed`.
+Allow selection of f_cpu and fuses specified in `boards.txt` as `{BOARD_TAG}.menu.clock.{BOARD_CLOCK}`.
+This works for microprocessor board definitions like ATtiny that specify not only the clock speed but fuse settings as clock overrides.
+
+It also works for f_cpu values specified in `boards.txt` as `{BOARD_TAG}.menu.speed.{BOARD_CLOCK}`.
For example, the Watterott ATmega328PB library [https://github.com/watterott/ATmega328PB-Testing](https://github.com/watterott/ATmega328PB-Testing).
**Example:**
```Makefile
-# Select 20MHz clock
-BOARD_SPEED=20mhz
+# Select external 16 MHz clock
+BOARD_CLOCK=external16
+```
+
+**Example:**
+```Makefile
+# Select 20MHz speed
+BOARD_CLOCK=20mhz
```
-**Requirement:** *Optional to override main board f_cpu setting*
+**Requirement:** *Optional to override main board f_cpu and/or fuse settings.*
----