Go Down

Topic: ESP32 board selection and graphics LCD error (Read 52 times) previous topic - next topic

trm33

Oct 19, 2019, 11:44 am Last Edit: Oct 19, 2019, 11:50 am by trm33 Reason: attachments
I have esp32 module pic attached https://www.amazon.ca/Development-Wireless-Module-Bluetooth-Arduino/dp/B07HG5XHLB

i am facing 2 problems
1. when i select board "ESP32 Dev Module from arduino IDE" and upload simple program "AnalogReadSerial" from examples, program successfully burned but module resets continuously and it shows in serial terminal

but when i select "ESP32 pico kit" from arduino baords same program "AnalogReadSerial" works perfectly


2. I want to use graphics LCD 12864zw in SPI Mode with ESP32  pic attached http://www.bajdi.com/cheap-128x64-graphic-lcd-12864zw/

the code i m using is given below

Code: [Select]
  #include "U8glib.h"
// display constructor for u8g library - this one depends on your type of display
//  U8GLIB_ST7920_128X64 u8g(13, 11, 12, U8G_PIN_NONE);
// ESP32 pin 18,18,21
U8GLIB_ST7920_128X64 u8g(21, 19, 18, U8G_PIN_NONE);

//U8GLIB_ST7920_128X64 u8g(E, RW, RS, U8G_PIN_NONE);

void setup() {  

  Serial.begin(9600);                     // start serial port
  

  // Select font =================================================================
  
  //u8g.setFont(u8g_font_unifont);
   u8g.setFont(u8g_font_courB10);
   //u8g.setFont(u8g_font_7x14B);
  //u8g.setFont(u8g_font_8x13);

  u8g.setColorIndex(1);                   // Instructs the display to draw with a pixel on.
}

void loop() {  
  u8g.firstPage();
  do {  
    draw();
  } while( u8g.nextPage() );
 
}
  
void draw(){


   u8g.drawFrame(0,0,128,22);            // upper frame col/row
   u8g.drawFrame(0,33,128,31);           // lower frame
  u8g.drawStr( 15, 10, "Temperature");       // do this for temperature
    
}

 this program works perfectly with arduino nano but when i use it with ESP32 module it shows the error

Sketch too big; see http://www.arduino.cc/en/Guide/Troubleshooting#size for tips on reducing it.

Error compiling for board ESP32 Dev Module.


anyone has idea about these two probelms

septillion

1) Can you give me a hint where I find the 'AnalogReadSerial' example? And what do you mean by "and it shows in serial terminal"?

And yeah, you might need to play around with which board you select. Especially when you select the Dev Module which gives you ALL the individual settings.

2) The error is pretty obvious... And I think it's because U8glib isn't made for the ESP32. Heck, Oli even tells you it's a good idea to switch to u8g2, the successor of U8glib. Might be worth giving that a try :)

Also note, that display is 5V, the ESP32 is 3,3V, so you probably need to add a level shifter in between.
Use fricking code tags!!!!
I want x => I would like x, I need help => I would like help, Need fast => Go and pay someone to do the job...

NEW Library to make fading leds a piece of cake
https://github.com/septillion-git/FadeLed

trm33

1) Can you give me a hint where I find the 'AnalogReadSerial' example? And what do you mean by "and it shows in serial terminal"?

And yeah, you might need to play around with which board you select. Especially when you select the Dev Module which gives you ALL the individual settings.

2) The error is pretty obvious... And I think it's because U8glib isn't made for the ESP32. Heck, Oli even tells you it's a good idea to switch to u8g2, the successor of U8glib. Might be worth giving that a try :)

Also note, that display is 5V, the ESP32 is 3,3V, so you probably need to add a level shifter in between.
AnalogReadSerial example  availabe in arduino software examples/basic/AnalogReadSerial

ESP8266 and ESP32 if program is successfully burned but the code is not 100% comaptible with modules or the user has not selected suitable baord for the code then these both ESP modules resets/reboots itself and generates error code in serial terminal at baud rate 115200.


Go Up