Skip to content

Commit

Permalink
Latest version DIY firmware and instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
chill117 committed Jun 11, 2021
1 parent eccf6d4 commit a700a73
Show file tree
Hide file tree
Showing 58 changed files with 1,282 additions and 7,392 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1 @@
bleskomat.conf
.pio/
File renamed without changes.
File renamed without changes.
48 changes: 12 additions & 36 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -21,57 +21,33 @@
# $ make compile # compile the device firmware
# $ make upload # compile then upload the device firmware
# $ make monitor # start the serial monitor
# $ make server # start an instance of the HTTP server
#

## Variables
DEVICE_DIR=./device
SERVER_DIR=./server

CONFIG=$(SERVER)/config.json

## Targets
#
# The format goes:
#
# target: list of dependencies
# commands to build target
#
# If something isn't re-compiling double-check the changed file is in the
# target's dependencies list.
DEVICE ?= /dev/ttyUSB0
BAUDRATE ?= 115200
PLATFORM=espressif32

## Phony targets - these are for when the target-side of a definition
# (such as "install" below) isn't a file but instead a just label. Declaring
# (such as "install" below) isn't a file but instead just a label. Declaring
# it as phony ensures that it always run, even if a file by the same name
# exists.
.PHONY: install\
compile\
upload\
monitor\
server\
signedLnurl

.SILENT: signedLnurl\
config
monitor

install:
cd $(DEVICE_DIR) && platformio lib install
cd $(SERVER_DIR) && npm install
platformio lib install
platformio platform install ${PLATFORM}

compile:
cd $(DEVICE_DIR) && npm run compile:only
platformio run

upload:
cd $(DEVICE_DIR) && DEVICE=${DEVICE} npm run compile:upload
sudo chown ${USER}:${USER} ${DEVICE}
platformio run --upload-port ${DEVICE} --target upload

monitor:
cd $(DEVICE_DIR) && DEVICE=${DEVICE} npm run monitor

server:
cd $(SERVER_DIR) && npm start

config:
cd $(DEVICE_DIR) && npm run --silent print:config

signedLnurl:
cd $(SERVER_DIR) && npm run --silent generate:signedLnurl -- "${AMOUNT}"
sudo chown ${USER}:${USER} ${DEVICE}
platformio device monitor --baud ${BAUDRATE} --port ${DEVICE}
447 changes: 162 additions & 285 deletions README.md

Large diffs are not rendered by default.

2 changes: 0 additions & 2 deletions device/.gitignore

This file was deleted.

38 changes: 0 additions & 38 deletions device/package.json

This file was deleted.

66 changes: 0 additions & 66 deletions device/scripts/printConfig.js

This file was deleted.

101 changes: 0 additions & 101 deletions device/src/config.cpp

This file was deleted.

Loading

0 comments on commit a700a73

Please sign in to comment.