aboutsummaryrefslogtreecommitdiffhomepage
path: root/targets/pygamer.json
diff options
context:
space:
mode:
authorAyke van Laethem <[email protected]>2021-06-01 13:27:58 +0200
committerRon Evans <[email protected]>2021-06-25 17:58:39 +0200
commit96e863f0f37cef0e8f36cb0d5f1c94fe062bc03d (patch)
treef4044fca721e0d1f58f64e7a312b6fb92215f64f /targets/pygamer.json
parent75298bb84bcb966998ca00f3cc5506a9757a5038 (diff)
downloadtinygo-96e863f0f37cef0e8f36cb0d5f1c94fe062bc03d.tar.gz
tinygo-96e863f0f37cef0e8f36cb0d5f1c94fe062bc03d.zip
all: add a flag to the command line to select the serial implementation
This can be very useful for some purposes: * It makes it possible to disable the UART in cases where it is not needed or needs to be disabled to conserve power. * It makes it possible to disable the serial output to reduce code size, which may be important for some chips. Sometimes, a few kB can be saved this way. * It makes it possible to override the default, for example you might want to use an actual UART to debug the USB-CDC implementation. It also lowers the dependency on having machine.Serial defined, which is often not defined when targeting a chip. Eventually, we might want to make it possible to write `-target=nrf52` or `-target=atmega328p` for example to target the chip itself with no board specific assumptions. The defaults don't change. I checked this by running `make smoketest` before and after and comparing the results.
Diffstat (limited to 'targets/pygamer.json')
-rw-r--r--targets/pygamer.json1
1 files changed, 1 insertions, 0 deletions
diff --git a/targets/pygamer.json b/targets/pygamer.json
index 63dc34a18..03147e08a 100644
--- a/targets/pygamer.json
+++ b/targets/pygamer.json
@@ -1,6 +1,7 @@
{
"inherits": ["atsamd51j19a"],
"build-tags": ["pygamer"],
+ "serial": "usb",
"flash-1200-bps-reset": "true",
"flash-method": "msd",
"msd-volume-name": "PYGAMERBOOT",