From b3d76d56e08362300939f2ed66f7e4ab43e3d8e8 Mon Sep 17 00:00:00 2001 From: Nicolas Stalder Date: Tue, 29 Jan 2019 02:55:04 +0100 Subject: [PATCH] Add `docker-build` make target, adjust instructions, remove Python2 support --- Dockerfile | 2 +- README.md | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 83ca59b..67fba89 100644 --- a/Dockerfile +++ b/Dockerfile @@ -26,7 +26,7 @@ RUN . solo/env3/bin/activate && cd solo/targets/stm32l432 && \ make cbor && \ make build-hacker -# Would prefer `FROM scratch`, not sure how to copy firmware out though? +# would prefer `FROM scratch`, not sure how to copy firmware out though? FROM alpine COPY --from=0 /solo/targets/stm32l432/solo.elf . COPY --from=0 /solo/targets/stm32l432/solo.hex . diff --git a/README.md b/README.md index 6685c14..cb46c69 100644 --- a/README.md +++ b/README.md @@ -35,7 +35,7 @@ Solo for Hacker is a special version of Solo that let you customize its firmware You can only buy Solo for Hacker at [solokeys.com](https://solokeys.com), as we don't sell it on Amazon and other places to avoid confusing customers. If you buy a Hacker, you can permanently lock it into a regular Solo, but viceversa you can NOT take a regular Solo and turn it a Hacker. -If you have a Solo for Hacker, here's how you can load your own code on it. You can find more details, including how to permanently lock it, in our [documentation](https://docs.solokeys.io/solo/building/). +If you have a Solo for Hacker, here's how you can load your own code on it. You can find more details, including how to permanently lock it, in our [documentation](https://docs.solokeys.io/solo/building/). We only support Python3. ```bash git clone --recurse-submodules https://github.com/solokeys/solo @@ -43,7 +43,7 @@ cd solo cd targets/stm32l432 make cbor -make all-hacker +make build-hacker cd ../.. make venv @@ -51,6 +51,8 @@ source venv/bin/activate python tools/solotool.py program targets/stm32l432/solo.hex ``` +Alternatively, run `make docker-build` and use the firmware generated in `/tmp`. + If you forgot the `--recurse-submodules` when cloning, simply `git submodule update --init --recursive`. For example, if you want to turn off any blue light emission, you can edit [`led_rgb()`](https://github.com/solokeys/solo/blob/master/targets/stm32l432/src/led.c#L15) and force: