Skip to content

Commit

Permalink
Release and Render
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Dec 7, 2024
1 parent 7d121aa commit b3895db
Show file tree
Hide file tree
Showing 8 changed files with 613 additions and 385 deletions.
1 change: 1 addition & 0 deletions file_list.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
software/release/config.py
software/main/main.py
software/networking/networking.py
software/networking/ssp_networking.py
software/libraries/adxl345.py
software/libraries/files.py
software/libraries/icons.py
Expand Down
5 changes: 4 additions & 1 deletion software/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ The repository has the following directory tree.
│ ├── 4sophie.py
│ ├── aioespnow.py
│ ├── am1.py
│ ├── default_main.py
│ ├── extended net code.py
│ ├── hackathon
│ ├── led.py
Expand All @@ -41,6 +42,7 @@ The repository has the following directory tree.
│ ├── networking_old copy.py
│ ├── networking_old.py
│ ├── networkingtest.py
│ ├── pyscript_main.py
│ └── secrets.py
├── libraries
│ ├── README.md
Expand All @@ -65,7 +67,7 @@ The repository has the following directory tree.
│ ├── README.qmd
│ ├── examples
│ ├── networking.py
│ └── networking_commands.py
│ └── ssp_networking.py
└── release
├── README.md
├── README.qmd
Expand All @@ -84,6 +86,7 @@ The repository has the following directory tree.
├── smartlight.py
├── smartmotor.py
├── ssd1306.py
├── ssp_networking.py
└── variableLED.py

A short description of the directories can be found below.
Expand Down
9 changes: 4 additions & 5 deletions software/networking/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,10 @@ The repository has the following directory tree.
├── README.rmarkdown
├── examples
│ ├── codethatfixesUnknownWifiError.py
│ ├── default_main.py
│ ├── example.py
│ ├── long_message_example.py
│ └── pyscript_main.py
│ └── long_message_example.py
├── networking.py
└── networking_commands.py
└── ssp_networking.py

A short description of the directories can be found below.

Expand All @@ -43,4 +41,5 @@ A short description of the directories can be found below.
| examples | This directory hosts example code | Nick |
| examples/example.py | This is some basic example code on how to use my networking library | Nick |
| examples/long_message_example.py | This code showcases the long message capabilities built into my code. By sending multiple messages that are then stitched back together by the recipient the max payload can be increased from 241 bytes to 256 x 238 = 60928 bytes, although in reality the ESP32 boards will start running out of memory with messages above 30 kilobytes. | Nick |
| networking.py | This is the main networking code that builds on ESP-NOW. There are many prepared functionalities (and some more that I am working on), such as long message support, sending of various variable types (bytes, bytearray, dicts, lists, int, float, char, string), as well as different types of messages such as ping, echo and more. There are also various features in place to make the networking more robust. It needs config.py to function. | Nick |
| networking.py | This is the main networking code that builds on ESP-NOW. There are many prepared functionalities (and some more that I am working on), such as long message support, sending of various variable types (bytes, bytearray, dicts, lists, int, float, char, string), as well as different types of messages such as ping, echo and more. There are also various features in place to make the networking more robust. | Nick |
| ssp_networking.py | This is the SSP networking code that builds on the above networking.py. This adds even more functionality on top (many more commands) and customises certain use for the Smart Systems Platform. Needs a config.py to properly work. | Nick |
4 changes: 3 additions & 1 deletion software/release/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ The repository has the following directory tree.
├── smartlight.py
├── smartmotor.py
├── ssd1306.py
├── ssp_networking.py
└── variableLED.py

A short description of the directories can be found below.
Expand All @@ -40,7 +41,8 @@ A short description of the directories can be found below.
|----|----|----|
| release/config.py | Smart Module Configuration File | Nick |
| main/main.py | Smart Module Main.py | Nick |
| networking/networking.py | This is the main networking code that builds on ESP-NOW. There are many prepared functionalities (and some more that I am working on), such as long message support, sending of various variable types (bytes, bytearray, dicts, lists, int, float, char, string), as well as different types of messages such as ping, echo and more. There are also various features in place to make the networking more robust. It needs config.py to function. | Nick |
| networking/networking.py | This is the main networking code that builds on ESP-NOW. There are many prepared functionalities (and some more that I am working on), such as long message support, sending of various variable types (bytes, bytearray, dicts, lists, int, float, char, string), as well as different types of messages such as ping, echo and more. There are also various features in place to make the networking more robust. | Nick |
| networking/ssp_networking.py | This is the ssp networking module. It needs config.py to function. | Nick |
| libraries/adxl345.py | Support for the built in accelerometer https://github.com/DFRobot/micropython-dflib/blob/master/ADXL345/user_lib/ADXL345.py | Milan |
| libraries/files.py | Custom save to file library | Milan |
| libraries/icons.py | Icon support for the smart motor module | Milan |
Expand Down
5 changes: 3 additions & 2 deletions software/release/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
"version": None
}
version = {'adxl345.py': 3,
'ssp_networking.py': 1,
'files.py': 2,
'icons.py': 2,
'prefs.py': 2,
Expand All @@ -14,8 +15,8 @@
'sm3.py': 1,
'sl1.py': 1,
'smartlight.py': 1,
'networking.py': 2,
'main.py': 0,
'networking.py': 3,
'main.py': 1,
'boot.py': 0
}
mysecrets = {"SSID": "Tufts_Robot", "key": ""}
Expand Down
11 changes: 8 additions & 3 deletions software/release/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
sta.active(False)
ap.active(False)

from networking import Networking
from ssp_networking import SSP_Networking

#Network
infmsg = False
Expand All @@ -27,11 +27,12 @@
if configuration == "AM1":
infmsg = True

networking = Networking(infmsg, dbgmsg, errmsg)
networking = SSP_Networking(infmsg, dbgmsg, errmsg)

peer_mac = b'\xff\xff\xff\xff\xff\xff'

import time
global timer

print("{:.3f} Name: {}, ID: {}, Configuration: {}, Sta mac: {}, Ap mac: {}, Version: {}".format(
(time.ticks_ms() - networking.inittime) / 1000,
Expand All @@ -43,6 +44,7 @@
networking.config["version"]
))


def idle():
lastPressed = 0

Expand Down Expand Up @@ -73,7 +75,10 @@ def heartbeat(timer):

def deinit():
networking.cleanup()
timer.deinit()
try:
timer.deinit()
except Exception as e:
print(e)
machine.reset()

def run_config_module(module_name):
Expand Down
Loading

0 comments on commit b3895db

Please sign in to comment.