Skip to content

Commit

Permalink
Merge pull request #8 from amperka/iskrajs_2V22_uf2
Browse files Browse the repository at this point in the history
Iskrajs 2v22 uf2
  • Loading branch information
nomad605dis authored Jun 7, 2024
2 parents efefb96 + a0c87c7 commit 85d83cd
Show file tree
Hide file tree
Showing 1,961 changed files with 839,755 additions and 759,181 deletions.
34 changes: 17 additions & 17 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
# Auto detect text files and perform LF normalization
* text=lf

# Custom for Visual Studio
*.cs diff=csharp

# Standard to msysgit
*.doc diff=astextplain
*.DOC diff=astextplain
*.docx diff=astextplain
*.DOCX diff=astextplain
*.dot diff=astextplain
*.DOT diff=astextplain
*.pdf diff=astextplain
*.PDF diff=astextplain
*.rtf diff=astextplain
*.RTF diff=astextplain
# Auto detect text files and perform LF normalization
* text=auto eol=lf

# Custom for Visual Studio
*.cs diff=csharp

# Standard to msysgit
*.doc diff=astextplain
*.DOC diff=astextplain
*.docx diff=astextplain
*.DOCX diff=astextplain
*.dot diff=astextplain
*.DOT diff=astextplain
*.pdf diff=astextplain
*.PDF diff=astextplain
*.rtf diff=astextplain
*.RTF diff=astextplain
6 changes: 6 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
97 changes: 91 additions & 6 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,39 @@ name: Firmware build

on:
push:
branches: [ master ]
branches: [ '*' ]
pull_request:
branches: [ master ]
branches: [ '*' ]

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
inputs:
enable_main:
description: Build default boards (linux, ESP, Microbit)
type: boolean
default: true
enable_dfu:
description: Build boards with DFU (puckjs, pixljs, banglejs)
type: boolean
default: true
enable_padded:
description: Build boards with bootloader padding (espruinoboard, -wifi, pico)
type: boolean
default: true
enable_emulator:
description: Build emulator for banglejs
type: boolean
default: true


permissions:
contents: read

jobs:

# normal builds
build_main:
if: ${{ github.event_name != 'workflow_dispatch' || inputs.enable_main }}
runs-on: ubuntu-20.04
strategy:
# devices to build for
Expand All @@ -18,7 +43,7 @@ jobs:
# try and build for all devices even if one fails
fail-fast: false
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: make ${{ matrix.board }}
Expand All @@ -31,18 +56,29 @@ jobs:
source ./scripts/provision.sh ${{ matrix.board }}
make
./scripts/ci_upload.sh
- name: Upload ${{ matrix.board }} build artifact
uses: actions/[email protected]
with:
name: ${{ matrix.board }}
path: |
bin/*.bin
bin/*.hex
bin/*.tgz
bin/*.zip

# Builds with DFU_UPDATE_BUILD=1
build_dfu:
if: ${{ github.event_name != 'workflow_dispatch' || inputs.enable_dfu }}
runs-on: ubuntu-20.04
strategy:
# devices to build for
matrix:
board: [PUCKJS, PIXLJS, MDBT42Q, BANGLEJS, BANGLEJS2]
board: [PUCKJS, PIXLJS, MDBT42Q, BANGLEJS, BANGLEJS2, PUCKJS_MINIMAL]
# try and build for all devices even if one fails
fail-fast: false
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: make ${{ matrix.board }}
Expand All @@ -56,9 +92,19 @@ jobs:
source ./scripts/provision.sh ${{ matrix.board }}
make
./scripts/ci_upload.sh
- name: Upload ${{ matrix.board }} build artifact
uses: actions/[email protected]
with:
name: ${{ matrix.board }}
path: |
bin/*.bin
bin/*.hex
bin/*.tgz
bin/*.zip
# Builds with PAD_FOR_BOOTLOADER=1
build_padded:
if: ${{ github.event_name != 'workflow_dispatch' || inputs.enable_padded }}
runs-on: ubuntu-20.04
strategy:
# devices to build for
Expand All @@ -67,7 +113,7 @@ jobs:
# try and build for all devices even if one fails
fail-fast: false
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: make ${{ matrix.board }}
Expand All @@ -81,7 +127,46 @@ jobs:
source ./scripts/provision.sh ${{ matrix.board }}
make
./scripts/ci_upload.sh
- name: Upload ${{ matrix.board }} build artifact
uses: actions/[email protected]
with:
name: ${{ matrix.board }}
path: |
bin/*.bin
bin/*.hex
bin/*.tgz
bin/*.zip
# emulator builds
build_emulator:
if: ${{ github.event_name != 'workflow_dispatch' || inputs.enable_emulator }}
runs-on: ubuntu-20.04
strategy:
# devices to build for
matrix: # banglejs, banglejs2
board: [EMSCRIPTEN, EMSCRIPTEN2]
# try and build for all devices even if one fails
fail-fast: false
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: make ${{ matrix.board }}
env:
TRAVIS: 1
RELEASE: 1
BOARD: ${{ matrix.board }}
UPLOADTOKEN: ${{ secrets.UPLOADTOKEN }}
run: |
source ./scripts/provision.sh ${{ matrix.board }}
make
./scripts/ci_upload.sh
- name: Upload ${{ matrix.board }} build artifact
uses: actions/[email protected]
with:
name: ${{ matrix.board }}
path: |
bin/*.js
# Disable doc building for now
# docs:
Expand Down
72 changes: 72 additions & 0 deletions .github/workflows/testFactoryApps.disabled
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
name: Test Factory Apps

on:
push:
branches: [ '*' ]
pull_request:
branches: [ '*' ]

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
inputs:
git-ref:
description: Git Ref (Optional)
required: false

permissions:
contents: read

jobs:
# This workflow contains a single job called "build"
tests:
runs-on: ubuntu-latest
steps:
- name: Checkout Espruino
uses: actions/checkout@v3
with:
submodules: recursive
path: 'Espruino'
ref: ${{ github.event.inputs.git-ref }}

- name: Checkout EspruinoWebIDE
uses: actions/checkout@v3
with:
repository: espruino/EspruinoWebIDE
submodules: recursive
path: 'EspruinoWebIDE'

- name: Setup emsdk
uses: mymindstorm/setup-emsdk@v11
with:
# Make sure to set a version number!
version: 3.1.12
# This is the name of the cache folder.
# The cache folder will be placed in the build directory,
# so make sure it doesn't conflict with anything!
actions-cache-folder: 'emsdk'

- name: Use Node.js
uses: actions/setup-node@v3

- name: Create Emulator
run: |
cd $GITHUB_WORKSPACE/Espruino
make clean
BOARD=EMSCRIPTEN make || exit 1
make clean
BOARD=EMSCRIPTEN2 make || exit 1
cp $GITHUB_WORKSPACE/Espruino/bin/emulator_banglejs*.js $GITHUB_WORKSPACE/EspruinoWebIDE/emu/ -v

- name: Run Tests Bangle.js
run: node $GITHUB_WORKSPACE/Espruino/scripts/factoryTests.js BANGLEJS
id: TestBangle1
continue-on-error: true

- name: Run Tests Bangle.js2
run: node $GITHUB_WORKSPACE/Espruino/scripts/factoryTests.js BANGLEJS2
id: TestBangle2
continue-on-error: true

- name: Fail test
if: (steps.TestBangle1.outcome != 'skipped' && steps.TestBangle1.outcome != 'success') || (steps.TestBangle2.outcome != 'skipped' && steps.TestBangle2.outcome != 'success')
run: exit 1
21 changes: 18 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,10 @@
*.bin
*.uf2
*.pyc
/*.bin.unpadded
/*.zip
/gen/*
/bin/*
/bin_*/*
/obj/*
/.vagrant/*
/boards/*.html
/boards/*.json
Expand All @@ -38,9 +39,11 @@ node_modules
/esp-idf
xtensa-esp32-elf
gcc-arm-none-eabi*
arm-gnu-toolchain*
*.c#
/function_keywords.js
/functions.html
/targetlibs/emscripten/emsdk
/targetlibs/nrf5x_11
/targetlibs/nrf5x_12/examples
/targetlibs/nrf5x_12/documentation/
Expand All @@ -54,7 +57,17 @@ gcc-arm-none-eabi*
/targetlibs/nrf5x_15/modules
/targetlibs/nrf5x_15/config
/targetlibs/nrf5x_15/license.txt
/targetlibs/nrf5x_15_*
/targetlibs/nrf5x_15_3/components
/targetlibs/nrf5x_15_3/example_config
/targetlibs/nrf5x_15_3/examples
/targetlibs/nrf5x_15_3/external
/targetlibs/nrf5x_15_3/external_tools
/targetlibs/nrf5x_15_3/integration
/targetlibs/nrf5x_15_3/modules
/targetlibs/nrf5x_15_3/config
/targetlibs/nrf5x_15_3/documentation
/targetlibs/nrf5x_15_3/license.txt
/targetlibs/nrf5x_15_3/nRF5x_*
/targetlibs/nrf5x_15x
/targetlibs/nrf5x_mesh
/targetlibs/nrf5x_17/components
Expand All @@ -65,6 +78,7 @@ gcc-arm-none-eabi*
/targetlibs/nrf5x_17/config
/targetlibs/nrf5x_17/documentation
/targetlibs/raspberrypi
/js
/.vscode
/CURRENT_BOARD.make
/topreadonly
Expand All @@ -73,3 +87,4 @@ gcc-arm-none-eabi*
*.user
*.jdebug
*.code-workspace
/espruino_embedded.*
4 changes: 2 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Improvements to Documentation are amazingly helpful, and are very rare so hugely

### Functions/Variables

If you want to change something in a [built-in function's documentation](http://www.espruino.com/Reference), look at the heading for the function on that page and there will be a right-arrow (⇒).
If you want to change something in a [built-in function's documentation](http://www.espruino.com/Reference), look at the heading for the function on that page and there will be a right-arrow (⇒).

If you click on that it will bring you to the area of Espruino's source code where the function *and the documentation for it* are stored. You can then edit the documentation in that file (above the function) on GitHub and issue a pull request - it's in Markdown format.

Expand Down Expand Up @@ -56,7 +56,7 @@ Please [see here](http://www.espruino.com/Writing+Modules)
* Ensure that you are not contributing someone else's code, and that you are willing to add your code under Espruino's MPL Licence
* Make sure that what you do doesn't break the Espruino board or the other boards we build for. We can't check all the boards for every commit, so if you break something you'll annoy a whole bunch of people.
* Be aware that Espruino is designed for Microcontrollers - with very low amounts of flash and memory. Both are at a premium so don't statically allocate variables or do other stuff that will use up RAM.
* Don't add a whole bunch of indirection/abstraction for the sake of it - it'll probably just use of more of our precious memory.
* Don't add a whole bunch of indirection/abstraction for the sake of it - it'll probably just use more of our precious memory.
* If you add a new API, try and make it familiar to Arduino/JavaScript users.
* Please [RUN THE TESTS](tests/README.md) before and after your changes to check that there are no regressions
* Finally, please issue us a pull request to [www.github.com/espruino](https://www.github.com/espruino/Espruino) via GitHub. It's way easier for us to incorporate, give credit, and track changes that way.
Expand Down
Loading

0 comments on commit 85d83cd

Please sign in to comment.