Re: How can I check the ESP type with code?
Posted: Sat Jul 11, 2020 3:07 pm
2 thoughts.
If you check the flash size in your start up code (ESP.getFlashChipSize()) that should show as 4MByte on ESP-12 modules but I think most ESP-01 only have 1MByte.
If you can spare a pin on the esp-12 variant then you could wire that to 0V. Setting it to Input with internal pull up should then allow you to see that as a 0 on the ESP12 but not on the esp-01
If you check the flash size in your start up code (ESP.getFlashChipSize()) that should show as 4MByte on ESP-12 modules but I think most ESP-01 only have 1MByte.
If you can spare a pin on the esp-12 variant then you could wire that to 0V. Setting it to Input with internal pull up should then allow you to see that as a 0 on the ESP12 but not on the esp-01