Home - aeristhings/aeris-modsdk-py GitHub Wiki
aerismodsdk python package wiki
This package is intended to provide both an SDK and CLI for common radio modules. The package is particularly useful for exploring eDRX and PSM. There are also some special commands for when the module is attached to a pi and that pi gpio ports are used for control of the module.
This is not production code. There is no formal support provided by Aeris for this SDK.
Installation
OS environments successfully tested so far:
- Raspberry pi
OS environments known to fail:
- macOS
Python environments tested so far:
- Python 3.7.5 / pip 19.3.1
Installation / upgrade:
A step by step series of examples that tell you how to get a development env running
Step 1: Clone the source to your local machine
$ git clone https://github.com/aeristhings/aeris-modsdk-py.git
Step 2: Install dependencies
$ cd aeris-modsdk-py
$ poetry install
Step 3: Verify development environment working
$ poetry run aeriscli
Usage information
The --help option can be used at any level to get more information about usage
$ cd ~/aeris-modsdk-py
$ poetry run aeriscli --help
Usage: aeriscli [OPTIONS] COMMAND [ARGS]...
Options:
-v, --verbose Verbose output
-cfg, --config-file TEXT Path to config file.
--help Show this message and exit.
Commands:
config Set up the configuration for using this tool
edrx eDRX commands
fw firmware commands
http HTTP commands
info Module information
interactive Interactive mode
modem Modem information
network Network commands
packet Packet commands
pi pi commands
psm PSM commands
reset Reset module
udp UDP commands
Configuration command
For nearly all commands, you will need to configure the sdk with information about your modems.
You must configure the tool for other sdk commands to work properly. The configuration will be stored locally.
$ poetry run aeriscli config --help
Usage: aeriscli config [OPTIONS]
Set up the configuration for using this tool
Options:
--modemmfg [ublox|quectel|telit]
Modem manufacturer.
--comport [ACM0|S0|S1|USB0|USB1|USB2|USB3|USB4]
Modem COM port.
--apn TEXT APN to use
--help Show this message and exit.
Interactive command
Used to open up interactive AT command shell with the configured modem
$ poetry run aeriscli interactive
Enter AT command or type exit
>>
Info command
Used to gather basic information about the radio module
$ poetry run aeriscli info
{'imsi': '311882995001347', 'maker': 'QUECTEL', 'model': 'BG95-M3', 'imei': '864475040480534', 'rev': 'BG95M3LAR02A03'}