Hot answers tagged

3

Yes, 1MB is fine for OTA. There are, though, a few caveats when working with OTA that you must observe regardless of the flash size: The maximum OTA program size is less than half the available flash size. Typically it is about 500kB. Two copies need to be stored in flash, plus the partition table and NVRAM. The rest of the flash on larger chips is most ...


3

This is what I was looking for. The development board is not the minimum as @Majenko and @StarCat stated on their comments. This is exactly what I need as I plan to run my project from a battery. Moreover, the development board consumes a lot more energy when in sleep mode. I will even remove the LED that shows on this diagram: So basically use a ...


2

The only two pins that don't glitch or change state during reset and boot are GPIO4 and GPIO5, and neither of them are brought out to the 2x4 header on an ESP-01. https://rabbithole.wwwdotorg.org/2017/03/28/esp8266-gpio.html All of the other pins will make your relay click or chatter. Pick a different module, or try soldering a wire onto GPIO4 or 5. The ...


2

Apparently it's a pretty common issue for people using this board. There are a couple of solutions here that I will try: https://github.com/IOT-MCU/ESP-01S-Relay-v4.0/issues/1 The most non invasive one with Tasmoto firmware didn't work in my case. So I will try another pin and if that fails, bite the bullet and introduce a capacitor.


2

There are programming boards available to which you can plug one of these SOCs into them. There are different boards for different types of ESP SOCs. You can find them at popular Chinese vendors, and probably elsewhere too. They look like this:


2

From your description it sounds like a Watchdog Timer reset. The ESP8266 needs to regularly run internal householding tasks outside of your own code, such as Wifi/network related tasks. It will normally take some processing time for those tasks with every loop() iteration and with every delay() command. If your code is doing things that take longer than ...


2

readStringUntil('\n') //Receiver Mega void setup() { pinMode(LED_BUILTIN, OUTPUT); Serial1.begin(9600); Serial.begin(19200); delay(100); } void loop() { if (Serial1.available()) { String received = ""; received = Serial1.readStringUntil('\n'); Serial.println(received); } } It's about how Serial.readString() works: it ...


2

No memory is allocated for the strings. You should declare your struct like so: struct Departure { char destination[32]; char departure[32]; int deviation; } depart; This assumes the max length for both strings is 31 characters. Then, pass the max size to strlcpy(): strlcpy(dep_arr[i].destination, ResponseData_Metros[i]["Destination"], ...


2

httpClient.getStream() returns an instance of Stream that you can pass to deserializeJson(), like so: deserializeJson(doc, httpClient.getStream()); However, by doing so, you bypass the code in HTTPClient that handles chunked transfer encoding, so you must call httpClient.useHTTP10(true) before calling GET to make sure the server won't return a chunked ...


1

This is a issue raised on github about this: https://github.com/espressif/arduino-esp32/issues/3294 And the issue seems to be that a failed connect prevent the scanning and the solution is: So what i did was when entering the portal: WiFi.mode(WIFI_OFF); // otherwise Wifi.Scannetworks() fails delay(5000); This seems to stop the processes that prevent the ...


1

I ran into this issue with the same setup. This Github issue seems identical to ours, and applying the fix in this comment quickly resolved it for me: https://github.com/espressif/arduino-esp32/issues/5128#issuecomment-851785970. Good luck!


1

Nothing wrong with your code, I've the exact same issue as you have. It bothers me whole week long and fortunately, we (along with my colleague) accidentally figured that was caused by Windows 10, weird right? We don't believe it at very beginning either, but after several back-N-forth testing, it just like that. When we upload exact same code from another ...


1

Everything was correct and my circuit is also good. The only difference i found is to this below line: temp = (analogvalue * 3.3) / 1024.0; Which should be temp = (analogvalue * 1.0) / 1024.0; We are multiplying because we are referencing the voltage from voltage divider circuit as 1 volt. After doing this, i am getting the exact values battery voltage ...


1

I assume you are the one creating the OTA update. If so, then why don't you just include a "signature" in the code that is the architecture, i.e. ESP8266 vs. ESP32 and then check for that in your updater code so that it will not install an update for the wrong CPU.


1

One is a server and the other is a client. The server do not need to know IP of the client, but the client need to know IP address of the server. See more in communication between two Arduino


1

I guess that 1 year later you shouldn't work on this anymore, but for every one that need the grayscale too, here my solution. For reference I've found here that we can set : s->set_special_effect(s, 2); Where 2 is grayscale effect. 0 - No Effect 1 - Negative 2 - Grayscale 3 - Red Tint 4 - Green Tint 5 - Blue Tint 6 - Sepia // Camera init esp_err_t ...


1

I just tried this with my ESP32Cam with no problems. I would check that you are supplying enough power; I've definitely seen the 'Camera capture failed' when I had power issues. Also, I would try a more recent tutorial on the ESP32Cam; the latest Expressif ESP32 Arduino libraries have AI Thinker ESP32Cam as a device choice. I would try the CameraWebServer ...


1

I'm unclear on the distinction being drawn here: the hostname and not mDNS mDNS, like DNS, and hostname lists are all things a "resolver" would use to map a "hostname" to an IP address. If you mean "how do I use DNS instead of mDNS?", you'd need to have your ESP8266 running a DNS server. And for clients to be aware of it you'...


1

For OTA uploads, the size of the compiled (old sketch + new sketch) should not exceed the flash size. Due to this, large sketches (more than 500KB with 1MB flash) cannot be OTA uploaded directly if the sketch size exceeds half of the flash size. However, this restriction can be circumvented by first uploading a sketch only with OTA features as given below: #...


1

You could use wireless. First, use OTA programming (eg Elegant OTA) to burn a basic OTA uploader. Then, in principle, you can then upload any sketch you want so long as it ALWAYS has the basic OTA sketch included within your program.


1

A const parameter to a function doesn't define what can be passed. It is, instead, a "promise" by the function that it will not modify the data you pass it. In C when you pass a "string" (which is actually an array of characters) to a function you don't actually pass the string (as in the content). You really just pass a pointer to the ...


1

I'm a fool, I tried to detect other devices in the setup function before the Wire.begin(PIN_SDA, PIN_SCL, I2C_MASTER); I Found it only because of you. The rubber duck. I started to write the program down to post it here and bingo. That was the reason why the master had the "NACK" answer. The master was not started yet. Thank you


1

You need to set esp 8266 to flash mode. Please connect en PIN to Gnd pin. Then flash again.


1

turns out that it is very simple, I shouldn't put buttonPin[1] a variable for PressNHold, I had to put just1, buttonPin was used already in button_state, also, PressnHold local variables should be declared static to not get a reset after function execution.


1

The Arduino UNO only has one serial port. That is pins 0/1 (RX and TX), which is mapped to the Serial object. Those pins and that object are also used for communication with the PC through the USB connection. That means you can't easily use them for both PC communication and ESP8266 communication. It's possible, but it gets messy. That is why many people ...


Only top voted, non community-wiki answers of a minimum length are eligible