Search found 10 matches

by AndreaS73
Mon Sep 09, 2024 3:03 pm
Forum: General Discussion
Topic: How many register a Modbus TCP master can read from ESP32
Replies: 1
Views: 542

How many register a Modbus TCP master can read from ESP32

Using the official TCP Modbus https://docs.espressif.com/projects/esp-modbus/en/latest/esp32/overview_messaging_and_mapping.html as Modbus slave, I wonder how many input registers the master can read with a single operation from ESP32. Is it like the standard? So 256 bytes, and counting for headers/...
by AndreaS73
Mon Aug 26, 2024 12:50 pm
Forum: ESP-IDF
Topic: Checking Wifi NVS data
Replies: 3
Views: 6137

Re: Checking Wifi NVS data

One could also check for WIFI_INIT_CONFIG_MAGIC - that seems to be its purpose Where did you find the magic member for struct wifi_config_t? I cannot find it in the latest stable (5.3): typedef union { wifi_ap_config_t ap; /**< configuration of AP */ wifi_sta_config_t sta; /**< configuration of STA...
by AndreaS73
Wed Jul 31, 2024 4:04 pm
Forum: ESP-IDF
Topic: mbc_slave_get_param_info does not catch different addresses
Replies: 1
Views: 570

Re: mbc_slave_get_param_info does not catch different addresses

After digging it out, it seems the problem is: mb_event_group_t event = mbc_slave_check_event(MB_WRITE_MASK); that does not filter out the readings. For example, my client reads every 1000 ms and sometimes writes a holding register. But `event` has the following value 0x83, hence both reading and wr...
by AndreaS73
Wed Jul 31, 2024 3:37 pm
Forum: ESP-IDF
Topic: mbc_slave_get_param_info does not catch different addresses
Replies: 1
Views: 570

mbc_slave_get_param_info does not catch different addresses

ESP32-S3, here my code derived from the slave example: #include "modbus.h" #include <mbcontroller.h> #include "../resources/modbus_params.h" #include "../utils/settings.h" #include <esp_err.h> #include <esp_log.h> #include <esp_system.h> #include <esp_wifi.h> #include <esp_event.h> #include <esp_log...
by AndreaS73
Wed Jul 31, 2024 7:11 am
Forum: ESP-IDF
Topic: WiFi always fails and then connects
Replies: 3
Views: 826

Re: WiFi always fails and then connects

My solution: Upon receiving a WiFi disconnect event, start a timer to trigger a (new) connection attempt after a little while. Yeah, I'm doing the same, but it's an ugly workaround! I'd like to understand why it fails and how to fix it. I have other ESP32 boards, programmed using the Arduino framew...
by AndreaS73
Tue Jul 30, 2024 6:32 am
Forum: ESP-IDF
Topic: WiFi always fails and then connects
Replies: 3
Views: 826

WiFi always fails and then connects

I wrote this code (derived from the examples) for ESP32-S3: #include "task_wifi.h" #include <esp_log.h> #include <esp_system.h> #include <sdkconfig.h> #include <lwip/netdb.h> #include <string.h> #define WIFI_SSID "<ssid>" #define WIFI_PASSWORD "<password>" #define WIFI_DELAY_RETRY 10 #define EXAMPLE...
by AndreaS73
Tue Jul 23, 2024 10:42 am
Forum: General Discussion
Topic: Example to handle MIFARE Ultralight (NTAG215)
Replies: 0
Views: 388

Example to handle MIFARE Ultralight (NTAG215)

When I was working with Arduino framework I used the well known https://github.com/miguelbalboa/rfid library. Is there a native ESP-IDF library for the common RC522 modules? Specifically I have some XFW-ETLIVE MINI RFID-RC522 modules and I want to read/write from MIFARE Ultralight cards (or as secon...
by AndreaS73
Tue Jul 02, 2024 1:59 pm
Forum: General Discussion
Topic: Does usb_serial_jtag_driver_install() disable stdout?
Replies: 0
Views: 840

Does usb_serial_jtag_driver_install() disable stdout?

I created a task for processing incoming data on the JTAG/USB serial line: void Serial_Task(void *arg) { usb_serial_jtag_driver_config_t usb_serial_jtag_config = { .rx_buffer_size = BUFFER_SIZE, .tx_buffer_size = BUFFER_SIZE, }; ESP_ERROR_CHECK(usb_serial_jtag_driver_install(&usb_serial_jtag_config)...
by AndreaS73
Mon Mar 11, 2024 7:37 am
Forum: General Discussion
Topic: OTA with browser instead of server
Replies: 2
Views: 487

Re: OTA with browser instead of server

Thanks, I'll give it a try.
by AndreaS73
Sun Mar 10, 2024 12:59 pm
Forum: General Discussion
Topic: OTA with browser instead of server
Replies: 2
Views: 487

OTA with browser instead of server

If I'm not wrong, all the OTA examples require a server where store the firmware to be downloaded into the target.
Is there an example that shows how to upload the file using a browser? Like the common OTA libraries do for Arduino - example ElegantOTA.