New user here, custom partitions and websockets

All ESP32 boards running MicroPython.
Target audience: MicroPython users with an ESP32 board.
Post Reply
gandalf
Posts: 1
Joined: Tue May 03, 2022 12:05 pm

New user here, custom partitions and websockets

Post by gandalf » Tue May 03, 2022 12:18 pm

Hi guys,
i'm totally new to micropython.

I would like to convert an existing Arduino project for ESP32 to a micropython version.
I was able to customize the partitioning on the arduino project, keeping partitions for OTA and increasing the filesystme size to use with LittleFS (main interface is a vuejs app, i need a lot of space).

I'm at around 900k for the firmware & ota partitions, everything else is SPIFFS.

Any guide on how to make something similiar ? I have the partitions.csv if needed.

Side questions: any example on how to spin up a simple websocket server that receive a json-rpc message and run a VERY VERY VERY long task in background (3-4-5 hours) then reply to the websocket client ? I'm struggling in this from 10 days in C++, maybe in python it's easier. It's simple: vue js conects to the websocket, send a command like {"method": "longOperation"}, the websocket server start the longOperation in background (everything else still run as expected) and when longOperation is done, websocket reply to the previously connected client (if still connected, if not, it doesn't matter)

Post Reply