This library is optimized by Cesanta for lower memory usage.
It also includes support for ATECC508 crypto chip.
Optimized version of mbedTLS
License: Other
Starting from few weeks ago, all my Mongoose OS based IoT devices fail connecting to the local Mosquitto MQTT broker. Everything worked fine since a couple of weeks ago.
This is my WEMOS D1 Mini board yml
configuration:
config_schema:
- ["mqtt.enable", true]
- ["mqtt.user", "<my_username>"]
- ["mqtt.pass", "<my_password>"]
- ["mqtt.server", "<my_loacal_IP_address>:8883"]
- ["mqtt.ssl_ca_cert", "ca.pem"]
This is the error log of my WEMOS D1 Mini board:
[Sep 15 08:54:05.996] mgos_mqtt_conn.c:471 MQTT0 connecting to 192.168.1.254:8883
[Sep 15 08:54:06.020] mongoose.c:4912 0x3fff1574 is a fatal alert message (msg 40)
[Sep 15 08:54:06.025] mongoose.c:4912 0x3fff1574 mbedtls_ssl_handle_message_type() returned -30592 (-0x7780)
[Sep 15 08:54:06.034] mongoose.c:4912 0x3fff1574 mbedtls_ssl_read_record() returned -30592 (-0x7780)
[Sep 15 08:54:06.040] mongoose.c:5088 0x3fff1574 mbedTLS error: -0x7780
[Sep 15 08:54:06.050] mgos_mqtt_conn.c:229 MQTT0 TCP connect error (-3)
[Sep 15 08:54:06.050] mgos_mqtt_conn.c:256 MQTT0 Disconnect
This is the error log of my local Mosquitto MQTT broker:
1631689879: New connection from 192.168.1.15 on port 8883.
1631689879: OpenSSL Error[0]: error:1417A0C1:SSL routines:tls_post_process_client_hello:no shared cipher
1631689879: Socket error on client <unknown>, disconnecting.
When I try to build firmware, it dies, saying this library contains neither sources nor prebuilt binaries.
Error: /private/tmp/mos-20191105-57219-1rk8su4/mos-adcad3f2ca90789fc5426dc8c6302383effaa415/src/cesanta.com/go/src/github.com/mongoose-os/mos/mos/manifest_parser/manifest_parser.go:353: neither sources nor prebuilt binary exists for the lib "mbedtls" (or, if a library doesn't have any code by design, its mos.yml shouldn't contain "sources"). Fetch error was: [failed to download libmbedtls-eps8266.a: mongoose-os-libs/mbedtls: no asset libmbedtls-eps8266.a found in release 2.16.0: file does not exist]
/private/tmp/mos-20191105-57219-1rk8su4/mos-adcad3f2ca90789fc5426dc8c6302383effaa415/src/cesanta.com/go/src/github.com/mongoose-os/mos/mos/build_local.go:142:
/private/tmp/mos-20191105-57219-1rk8su4/mos-adcad3f2ca90789fc5426dc8c6302383effaa415/src/cesanta.com/go/src/github.com/mongoose-os/mos/mos/build.go:220:
/private/tmp/mos-20191105-57219-1rk8su4/mos-adcad3f2ca90789fc5426dc8c6302383effaa415/src/cesanta.com/go/src/github.com/mongoose-os/mos/mos/build.go:163:
/private/tmp/mos-20191105-57219-1rk8su4/mos-adcad3f2ca90789fc5426dc8c6302383effaa415/src/cesanta.com/go/src/github.com/mongoose-os/mos/mos/main.go:196: build failed
It would be very helpful to be able to enable mbedtls_platform_set_calloc_free
by setting CONFIG_MBEDTLS_PLATFORM_MEMORY=y
in build vars, to align with this commit of the main mbedtls library in ESP-IDF.
This would allow us to specify that mbedtls should use SPIRAM rather than internal RAM, as described in this post:
espressif/esp-idf#2184
mbedtls has this feature. I guess it would be trivial (I might be wrong) to port to this.
I'm trying to use mbedtls with mongoose OS compiled with different cflags for the mbedtls library.
However, the library sources ("mbedtls/library") and the "src" directory referenced in the mos.yml file are not present in this repo. I tried copying the "library" directory from ARMmbed/mbedtls version 2.16.0, but it seems like there are changes to the header files which makes the sources incompatible with the headers in this repo.
Can you provide instructions on how to compile this library from sources instead of using the pre-compiled version?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.