Category Archives: Engineering

Cannot Flash Wemos ESP32 D1 Mini

I have just had an issue where I couldn’t flash my ESP32 Wemos D1 mini, It was giving me the following error:

Failed to connect to ESP32 invalid head of packet 0x65

which I believe is similar to other similar errors like:

Invalid head of packetĀ (‘S’)

Invalid head of packet (‘w’)

Invalid head of packetĀ (‘p’)

There were a number of different suggestions online including:

  • Try lowing the Baud rate
  • Try pressing the reset button on start
  • Try pressing the boot button (there isn’t one on the Wemos D1 Mini)

However, the one thing which worked for me to was short IO0 to GND while Arduino flasher was trying to connect to the board. That allowed it to programme.

FIXED: Arduino IDE High CPU Usage

I’ve been using the Arduino IDE for some project development recently, and finding that I’m getting very high CPU usage from Java to the point that it’s slowing my machine down, and then Arduino IDE becomes unresponsive. I couldn’t find any info on any of the forums related to this, but from my own research I believe I have found the problem.

It seems that my problem comes after a long time connected to the Serial Monitor and receiving data from the Arduino. It then gets worse and worse until things start getting unresponsive. The solution for me appears to be to basically just close the Serial Monitor, and reopen it. this can sometimes take a long time, and has caused Arduino to become unresponsive before, causing it to crash and restart. However, this appears to have been the only time I have seen this problem online.

How to: Honda Civic Type R EP3 Anti Roll Bar Bush Change

I had to change the anti roll bar bushes on my Civic EP3. I was getting a knocking noise, and upon investigation it turned out that they were really loose, and you could basically move the anti roll bar by hand. I got the parts from Eurocarparts (probably not the best quality – would suggest a better Motorfactors), and they were easy to change within 5 minutes with just a 14mm socket!

Check out the video below

Arduino Vidor CAN bus support

Arduino have just announced a bunch of new boards, including one with an on board FPGA chip (plus a SAMD21 Cortex-M0+, plus an ESP32 WiFi and Bluetooth Module). A Field Programmable Gate Array (FPGA) chip is possibly the most impressive piece of electronics going. They are essentially a way of creating entirely custom digital electronic circuits (resistors and transistors) all inside a tiny chip, and completely reprogrammable – genius!

See more about the Arduino Vidor CAN bus support after the break.

Continue reading

ESP8266 Arduino `.text’ will not fit in region `iram1_0_seg’ Error

I’ve been writing some software for a Wifi based CAN data logger for the ESP8266 in the Arduino platform, and have been getting a bit of a strange error. It appeared to be related to using the std::string functions in my code – and although I have used this in other sketches without issue, I suddenly received the following error as soon as I simply declared a std::string variable:

c:/users/scott/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9-2/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/bin/ld.exe: C:\Users\Scott\AppData\Local\Temp\build525647f6f8500d071cfab5cccf314276.tmp/ESPCANLogger.ino.elf section `.text' will not fit in region `iram1_0_seg'

collect2.exe: error: ld returned 1 exit status

See how to fix it after the break.

Continue reading

ILI9341 and XPT2046 TFT display on ESP8266

For my own future reference more than anything else, to get the ILI9341 (either Adafruit or otherwise) working on the ESP8266 using the Arduino development environment isn’t completely straightforward. I knew I had this working previously, but couldn’t find the info again, so am copying it here.

See the details after the break.

Continue reading