No description
Find a file
Scott Shawcroft e463b130cb
Merge pull request #20 from stellaw1/master
Update README for android
2020-08-21 10:52:59 -07:00
__tests__ Initial Glider commit 2019-09-19 17:56:12 -07:00
android completes reading from file instead of over ble 2020-08-07 00:52:49 -04:00
ios fixes bundle identifier 2020-08-08 00:41:16 -04:00
pyright@cdb883014b Finish updates, reworking ble init and start function and if support. 2019-09-25 18:08:22 -07:00
template Initial Glider commit 2019-09-19 17:56:12 -07:00
.buckconfig Initial Glider commit 2019-09-19 17:56:12 -07:00
.eslintrc.js Initial Glider commit 2019-09-19 17:56:12 -07:00
.flowconfig Initial Glider commit 2019-09-19 17:56:12 -07:00
.gitattributes Initial Glider commit 2019-09-19 17:56:12 -07:00
.gitignore More android tweaks 2019-09-24 00:11:24 -07:00
.gitmodules Add pyright submodule 2019-09-19 17:58:49 -07:00
.prettierrc.js Initial Glider commit 2019-09-19 17:56:12 -07:00
.watchmanconfig Initial Glider commit 2019-09-19 17:56:12 -07:00
App.js resolve conflicts 2020-08-18 14:56:25 -07:00
app.json Initial Glider commit 2019-09-19 17:56:12 -07:00
babel.config.js pyright dependencies are ok 2019-09-19 20:59:24 -07:00
code-editor.js Merge pull request #16 from kpolnitz/add-boolean-button 2020-08-14 10:24:45 -07:00
CODE_OF_CONDUCT.md Initial Glider commit 2019-09-19 17:56:12 -07:00
draggable-view.js connect searchbar to CodeEditor 2020-07-30 11:07:37 -07:00
index.js sets ble as default reading method 2020-08-07 00:59:26 -04:00
LICENSE Initial Glider commit 2019-09-19 17:56:12 -07:00
logo.png Add logo to readme 2019-09-26 10:18:20 -07:00
metro.config.js initial reading test 2020-08-06 22:49:05 -04:00
old-app.js Initial Glider commit 2019-09-19 17:56:12 -07:00
package-lock.json resolve conflicts 2020-08-18 14:56:25 -07:00
package.json resolve conflicts 2020-08-18 14:56:25 -07:00
README.md added note about code stubbing libraries manual linking 2020-08-21 00:06:59 -07:00
status.js Initial Glider commit 2019-09-19 17:56:12 -07:00
stubbed.py adds reading from files 2020-08-07 00:11:08 -04:00
StubbedApp.js completes reading from file instead of over ble 2020-08-07 00:52:49 -04:00
template.config.js Initial Glider commit 2019-09-19 17:56:12 -07:00
yarn.lock Bump lodash from 4.17.15 to 4.17.19 2020-07-18 07:59:01 +00:00

Glider word logo

Glider is a portable mobile app aimed at making wireless editing of Python code really easy and fun.

Installation

git clone --recursive https://github.com/adafruit/glider.git

If pyright fails to install, run:

cd glider
rm -rf pyright
git clone https://github.com/adafruit/pyright

In the glider folder, run:

npm install

NOTE: Android requires manual installation/ linking of the libraries:

iOS

From the /ios folder, run:

pod install

Open XCode and run on your device, it should ask for bluetooth permissions once loaded. Additionaly, the bundle identifiers may need to be changed for the code signing to work.

Android

  1. Build the gradle project by opening glider/android folder in Android Studio. Gradle should automatically start building and notify you when project is built via logs or Build tab.
  2. If the debug.keystore file does not exist already in glider/android/app, then copy it from glider/node_modules/react-native/template/android/app or search for where this file exists in your glider folder and paste it to glider/android/app.
  3. Connect your android device to your computer. NOTE: app must be run on physical device (not an Android Simulator) due to bluetooth limitations.
  4. In VS Code, run:
npx react-native run-android

Adafruit board

Ensure your board is running a BLE-allowed version of Circuit Python to allow your board to connect to glider.

To revert back to version of Circuit Python with BLE enabled:

git clone https://github.com/adafruit/circuitpython.git
cd circuitpython
git checkout aca53aa1a2c21ff46b609cfc270134ee6ee024f2

Then rebuild Circuit Python onto your board following these directions, replacing the last step with BLE flag:

cd ports/{insert_board_type_folder}
make BOARD={insert_board_name} CIRCUITPY_BLE_FILE_SERVICE = 1

Then run your build following these directions and ensure code.py is actively running code to allow BLE detection. (Eg, this led sample code).

Optional: To check whether BLE-allowed version of Circuit Python was installed correctly or not, download the Adafruit Bluefruit LE Connect app and check that your board is detected.

Upon refresh of glider app, your board should be automatically detected and connected. NOTE: may need to refresh glider more than once or may need to click reset button on board

Usage

Glider can run using code from either your BLE enabled CircuitPython device, or from a local file.

To allow it to run on your CircuitPython device, you must first build CircuitPython using this commit (run git checkout followed by this hash): aca53aa1a2c21ff46b609cfc270134ee6ee024f2 Use the instructions from here to build the code and upload it to your device.

To test code from your local machine, put your code in stubbed.py and change the false value to true from this line in index.js:

const readFromFile = false;

🔖 License

This project is MIT licensed.