PyCom Setup: Difference between revisions

From Sensors in Schools
Jump to navigation Jump to search
No edit summary
No edit summary
Line 3: Line 3:
2. Firmware updater
2. Firmware updater
* Expansionboard/Pygate: https://docs.pycom.io/updatefirmware/expansionboard/
* Expansionboard/Pygate: https://docs.pycom.io/updatefirmware/expansionboard/
* LoPy: https://docs.pycom.io/updatefirmware/device/
* LoPy/WiPy: https://docs.pycom.io/updatefirmware/device/


3. Install Atom + Pymakr plugin.
3. Install Atom + Pymakr plugin.
Line 15: Line 15:
* Register new device in TTN (https://www.thethingsnetwork.org)
* Register new device in TTN (https://www.thethingsnetwork.org)
* Use template code from Pycom for the gateway: https://docs.pycom.io/tutorials/expansionboards/pygate/
* Use template code from Pycom for the gateway: https://docs.pycom.io/tutorials/expansionboards/pygate/
Need permission to access serial port!
Need permission to access serial port! Can be an issue on linux if serial won't connect in Atom.
 
Common errors:
AttributeError: 'module' object has no attribute 'callback'
This usually means that WiPy firmware has not been updated.
 
OSError: [Errno 2] ENOENT
Means that the referenced file is not found. Check file path and file name (TTN has a different file name to the code template). Also remove the leading '/' from the flash directory. I'm not sure of the file structure on the LoPy, but it seems that it's not placed in root, and therefore a relative path is needed instead.

Revision as of 07:57, 7 April 2022

1. Board soldering (TODO: Schematic/images)

2. Firmware updater

3. Install Atom + Pymakr plugin. Pymakr and firmware install tools only work on x86 processors, so ARM devices (eg. Raspberry pi) will not work for this step.

  • For Windows, Visual Studio C++ 2019 is required (2022 currently isn't supported): Downloads & Resources
  • For linux: install node v16 (v17 does NOT work currently) and 'make' tools + toolchain.


4. Set up Pygate gateway:

Need permission to access serial port! Can be an issue on linux if serial won't connect in Atom.

Common errors: AttributeError: 'module' object has no attribute 'callback' This usually means that WiPy firmware has not been updated.

OSError: [Errno 2] ENOENT Means that the referenced file is not found. Check file path and file name (TTN has a different file name to the code template). Also remove the leading '/' from the flash directory. I'm not sure of the file structure on the LoPy, but it seems that it's not placed in root, and therefore a relative path is needed instead.