No project description provided
Project description
MSF Cli
For use in creating and managing a project using the micropython-sniffs-framework: https://github.com/surdouski/micropython-sniffs-framework.
Installation
pipx install msf-cli
Usage
Note: docker must be installed and on path for broker commands.
msf new <path> # creates new msf project at <path>
msf broker up --port=1883 # starts a local MQTT broker for testing (--port is optional, default is 1883)
msf broker down # stops the local MQTT broker
$ msf new path
Creates a new project at <path>. This is a convenience utility to set up your project so that it's easy to begin
development. However, it does also include some of the things you do require, such as the .config/mqtt_as.json
file with some defaults (although at minimum you need to update the "server" value). It also installs the framework and
it's required dependencies.
An example of what the directory looks like after being run:
After updating the json, you can uncomment
out the code in main.py related to the device and settings setup to test that everything is working. A simple way to
do this is to navigate to the project path, do mpbridge dev a0, wait for everything to load then press <Enter> once,
then press <ctrl+d> to do a soft restart on the device so that it runs main.py.
$ msf broker up
This command is meant for testing on your local network. If you already have a broker set up elsewhere that you want to use, use that instead.
This command runs a eclipse-mosquitto:1.6 container with some defaults. Can optionally add --port to specify
a different port on your local machine you want to access it through.
This command also outputs your IP and port you can connect to it through on your local network.
msf broker up
# output: Local MQTT broker started at 192.168.x.x:1883.
$ msf broker down
Stops and removes the broker.
Tests (Development)
Will eventually put up a test harness for this and add it to workflows. Today, however, is not that day.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file msf_cli-0.2.0.tar.gz.
File metadata
- Download URL: msf_cli-0.2.0.tar.gz
- Upload date:
- Size: 6.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.3 CPython/3.10.10 Linux/5.4.0-193-generic
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3cf8523f119283596234711c992183abb24187410874ebafbeee1160cabd1c9e
|
|
| MD5 |
661848421d290cd5bb78cfc342c15f6e
|
|
| BLAKE2b-256 |
b583a1eb7d808b2b049abf20363711bf523e5c417ae88838120c12c6f6e93a47
|
File details
Details for the file msf_cli-0.2.0-py3-none-any.whl.
File metadata
- Download URL: msf_cli-0.2.0-py3-none-any.whl
- Upload date:
- Size: 7.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.3 CPython/3.10.10 Linux/5.4.0-193-generic
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
adc82a307a8adcbfe715bb9f6421738582ae854e044a5c415fef7df53d77527a
|
|
| MD5 |
8b6835936b244fa75d5eb23dcb10c72a
|
|
| BLAKE2b-256 |
6ac19703a6809daa8c58ea8a8e59942496b8955269be12cce03e8ad5d9c257d0
|