This commit is contained in:
Dmitriy Pleshevskiy 2021-08-23 23:28:41 +03:00
commit c5d5c9d079
6 changed files with 66 additions and 0 deletions

1
.gitignore vendored Normal file
View file

@ -0,0 +1 @@
target.js

3
.vscode/settings.json vendored Normal file
View file

@ -0,0 +1,3 @@
{
"editor.tabSize": 2
}

3
README.md Normal file
View file

@ -0,0 +1,3 @@
# Espruino starter
This repository is a template that allows you to quickly start creating your new project on the espruino board or a board based on it.

34
espruino.json Normal file
View file

@ -0,0 +1,34 @@
{
"espruino": {
"RESET_BEFORE_SEND": true,
"STORE_LINE_NUMBERS": true,
"ENV_ON_CONNECT": true,
"MODULE_URL": "https://www.espruino.com/modules",
"MODULE_EXTENSIONS": ".min.js|.js",
"MODULE_AS_FUNCTION": true,
"MODULE_PROXY_ENABLED": false,
"MODULE_PROXY_URL": "",
"MODULE_PROXY_PORT": "",
"BAUD_RATE": 9600,
"SERIAL_IGNORE": "/dev/ttyS*|/dev/*.SOC|/dev/*.MALS",
"SERIAL_FLOW_CONTROL": true,
"BLUETOOTH_LOW_ENERGY": true,
"SERIAL_AUDIO": "0",
"WEB_BLUETOOTH": true,
"WEB_SERIAL": true,
"BOARD_JSON_URL": "https://www.espruino.com/json",
"COMPILATION": true,
"COMPILATION_URL": "https://www.espruino.com/service/compiler",
"MINIFICATION_LEVEL": "",
"MODULE_MINIFICATION_LEVEL": "ESPRIMA",
"MINIFICATION_Mangle": true,
"PRETOKENISE": false,
"SAVE_ON_SEND": 0,
"SAVE_STORAGE_FILE": "myapp",
"LOAD_STORAGE_FILE": 2,
"SET_TIME_ON_WRITE": false,
"SERIAL_THROTTLE_SEND": false
},
"ports": [],
"storageContents": {}
}

5
main.js Normal file
View file

@ -0,0 +1,5 @@
var on = false;
setInterval(function() {
on = !on;
LED1.write(on);
}, 500);

20
makefile Normal file
View file

@ -0,0 +1,20 @@
ESP := espruino -j espruino.json
watch: build-w
all: build
build: clean
$(ESP) main.js -o target.js
build-w:
$(ESP) main.js -w
clean:
rm -f target.js
ide:
$(ESP) --ide
deps:
npm install -g espruino