* Fix filesystem mutex handling
This fixes the re-initialization of the filesystem mutex when the dyn storage
module is reinitialized. Using xSemaphoreCreateMutex would cause a memory leak
when the begin function is called multiple times and a semaphore leakage could
be caused by the re-initialization of the global fsMutex variable while the
semaphore is taken.
The fsMutex should not be taken while the logLine function is called as this
would cause a nested take of the fsMutex, which causes a deadlock.
Signed-off-by: Frank Kunz <mailinglists@kunz-im-inter.net>
* Fix hard coded littlefs in json upload
Signed-off-by: Frank Kunz <mailinglists@kunz-im-inter.net>
* Add new AP hardware support OpenEPaperLink_ESP32-PoE-ISO_AP
This is based on Olimex ESP32-PoE-ISO
https://www.olimex.com/Products/IoT/ESP32/ESP32-POE-ISO/open-source-hardware
It has a SD Card slot that is used to store all filesystem data on SD.
Use the prepare_sdcard.sh script to copy all needed data to an empty
SD card that is formatted with FAT filesystem. The AP firmware will format
the SD if an unformatted or from formatted card is used. This can be used
to intially prepare an empty SD card for usage.
For tag communication a ESP32-C6-WROOM-1(U) is used with the following
connection scheme:
ESP32-PoE-ISO | ESP32-C6-WROOM-1
---------------+------------------
GPIO5 | EN
GPIO13 | GPIO9
GPIO36 | GPIO3
GPIO4 | GPIO2
GPIO33 | GPIO24
GPIO32 | GPIO25
| GPIO8 pullup 5.1k
Signed-off-by: Frank Kunz <mailinglists@kunz-im-inter.net>
* Avoid error message log print when parsers.json is missing
Signed-off-by: Frank Kunz <mailinglists@kunz-im-inter.net>
* Workaround for IEEE802.15.4 modem stuck issue
The ESP32-C6 esp-idf based modem firmware can run into a case where it
does not receive data anymore from the tags. This can be detected when
it starts to print
"receive buffer full, drop the current frame"
and does not recover from that. In such a case a modem reset is triggered.
Signed-off-by: Frank Kunz <mailinglists@kunz-im-inter.net>
* Add OpenEPaperLink_ESP32-PoE-ISO_AP to release build
Signed-off-by: Frank Kunz <mailinglists@kunz-im-inter.net>
* Add OpenEPaperLink_ESP32-PoE-ISO_AP to condidional build
Signed-off-by: Frank Kunz <mailinglists@kunz-im-inter.net>
* Add Ethernet support
The ethernet support allows to make the network/internet connection
via LAN cable instead of WiFi. LAN is preferred, if a LAN cable is
connected and a valid IP configuration via DHCP can be obtained, WiFi
is switched off. If the LAN cable is disconnected, a fall back to
WiFi is done.
Use those defines in platform.ini for PHY settings:
ETHERNET_PHY_POWER: IO pin where the PHY can be switched of/on, can be
-1 if not used.
ETHERNET_CLK_MODE: PHY clock mode, see eth_clock_mode_t in ETH.h
ETHERNET_PHY_MDC: PHY MDC pin
ETHERNET_PHY_MDIO: PHY MDIO pin
ETHERNET_PHY_TYPE: PHY type, see eth_phy_type_t in ETH.h
Limitations:
- only DHCP is supported, no static IP configuration for LAN so far.
- If GPIO0 is used for one of the ETHERNET_CLK_MODE modes, then GPIO0
cannot be used to clear the WiFi configuration.
Signed-off-by: Frank Kunz <mailinglists@kunz-im-inter.net>
---------
Signed-off-by: Frank Kunz <mailinglists@kunz-im-inter.net>
Co-authored-by: Frank Kunz <mailinglists@kunz-im-inter.net>
* updated arduinojson to version 7.3.0, enabled comments within json files
* update ESPAsyncWebServer/AsyncTCP to the ESP32Async fork
ESP32Async/ESPAsyncWebServer and ESP32Async/AsyncTCP are much better maintained and it looks like a lot of bugs are fixed compared to the ESPHome version we used before.
* Arduino 3.x compatibility (while maintaining 2.x compatibility)
* add support for lilygo t-panel
add support for lilygo t-panel (the rs485 version with an ESP32-S3 and ESP32-G2)
https://www.lilygo.cc/products/t-panel-s3
* refactor
* moved gfx library to lib2 folder and removed examples
* removed lib2\Arduino_GFX-1.3.7 and switch to moononournation/GFX Library for Arduino@^1.4.9
* added lilygo lib2\Arduino_GFX-1.3.7 back and removed all unused files. went from 166 files to 15 files!
* SubGhz radio fixes.
1. Don't for sending of BLOCK_MAX_PARTS parts for subGhz.
2. Fix CC1101 module detection logic.
3. Mitigate for lost CC1101 interrupts.
* Enabled SubGhz for OpenEPaperLink_Mini_AP_v4.
- adds tag serial debug in webflasher and power up/down buttons
- fixes bug where esp32-s3 connected via usb cdc slows down when no terminal connection is present
- fix: ghost tags reporting a different channel id than the AP are now ignored
- webflasher now ramps up/down power to prevent spikes
- bugfix: C6 doesn't get reset anoymore by the watchdog during flashing
- bugfix: C6 could go in flash mode unintended
- a failed connection during swd write blocks is now reported back instead of silently ignored
- added 4 areas of Sweden to day ahead price content
- new context menu option 'Delete all inactive tags' (only when right clicking on an inactive tag).
- adjusted some timings
- added webinterface for tag flasher
- added tcp transport for communicating with tag flasher (OTG USB also still works)
- added content 'timestamp', makes use of preloaded images and buttons on the 2.9" M3
- webinterface is now aware of C6 and flasher capabilities
- AP can run without ieee801.15.4 radio (i.e. flasher only) by shorting FLASHER_AP_TXD and FLASHER_AP_RXD
- added tcp transport option to OEPL-Flasher.py (serial also still works)
- added new environment OpenEPaperLink_Mini_AP_v4
- lots of finetuning and bug fixes
Pretty complex change here: pending images/commands are now queued.
A command (like LED flasher) will not overwrite a pending image anymore. Also, sending multiple preloaded images is possible.
Also works (at least, as far as I could test) in combination with Multi AP and mirroring tags ('display a copy' content type).
It you want to test this: don't forget to upload the changed files in /www (the pending icon is now displaying the amount of queued messages). Timing improvements will follow later (only one message can be transmitted every checkin. If multiple messages are queued, at this moment, you have to wait until the next checkin which takes 40-60 sec).
This comes also with the advantage of better stability if you upload multiple images to the same tag in succession. Before queuing, if was possible to replace the image between sending the pending message and the image transfer to the tag, causing md5 mismatches and instability.
Solves #47
- changed ESPAsyncWebServer and AsyncTCP (both not properly maintained for more than 5 years) to more recent fork with bugfixes
- fixed concurrency issues in /imgupload. Hurts the upload performance a lot, but probably that's not a real issue. Parallel uploads are now possible (still within the max 5 TCP connection limit)
- Added Signika-SB.ttf and some small bitmap fonts
- Removed calibrib50/60/80/100/120/150 bitmap fonts, as they can be better rendered using truetype. Fallback is in place to auto translate to Signika-SB.ttf with the right size in case it is still used in a json template
- Renamed confusing tag type names to 'M2 + size' and 'M3 + size'. Because the universal firmware, there is no need to tell every subtile type change apart anymore.
- added `textbox` to json templates (https://github.com/jjwbruijn/OpenEPaperLink/wiki/Json-template#paragraph-text)
- redesign of count days/hours
- redesign of RSS feed
- designed Buienradar for more tag sizes
- on a scheduled or user initiated reboot, 'REBOOTING' is sent to the error channel of the websockets just before the connection is dropped
- phased out "hwtype": [] in content_cards.json (new location is in the tagtype json, which contains a list of valid content types)
In case of problems using this commit: keep in mind the heavy caching of the tagtypes in the browser. You might still unknowingly use the old contents.
* New hardware profile: PoE AP
- added harware profiles for C6 firmware in menuconfig
- added free PSRAM stat in webinterface
* fix(fsfree): fixed var type of freesize of FS
* Add formatString convenience function
* Use String& for wsLog, wsErr and wsSerial
* Add tag data parser and parse tag data
* Make logLine use String&
* Fix issue with formatString
* Reuse payloadLength in processTagReturnData
* Fix parsing of unsigned/signed inetegers and cleanup
* Use c++17 standard
* Cleanup logging
To flash the C6, place bootloader.bin, partition-table.bin and OpenEPaperLink_esp32_C6.bin in the file system root.
APconfig -> update -> advanced options -> update ESP32-C6
This should also work with a previous unconfigured C6.
Compatible with Yellow-AP.
- Wifi connection progress is now visible on the TFT
- passthrough serial logging from the C6 to the S3 terminal for easier debugging
- no checks on force_flash and APtag-firmware version when C6 is used