logo elektroda
logo elektroda
X
logo elektroda

ESP32 control using Raspberry Pi Pico with touchscreen display - sensor management

Michal8883 717 14
ADVERTISEMENT
Treść została przetłumaczona polish » english Zobacz oryginalną wersję tematu
  • #1 20244497
    Michal8883
    Level 5  
    Hello I have an ESP32 which will do the brain of about 10 simple sensors connected by cable. And next to it will be a touchscreen display connected to the Pi PicoW. Now the question is if it is possible to use the pi picoW with the touchscreen to control the esp ie turn the sensors on or off or check if they are active? Is it better to do everything on the same board two pi picoW instead of esp32 and pi picoW.
  • ADVERTISEMENT
  • #2 20245375
    khoam
    Level 42  
    Michal8883 wrote:
    Would it be better to do everything on the same board two pi picoW instead of esp32 and pi picoW.

    Preferably on one ESP32 ;) .
  • #3 20245378
    Michal8883
    Level 5  
    Will I have enough pins for 10 sensors and a touchscreen?
  • #4 20245381
    khoam
    Level 42  
    I believe so. You would have to write specifically what touchscreen and sensors you are referring to.
  • ADVERTISEMENT
  • #6 20245828
    khoam
    Level 42  
    This display is controlled from SPI. You can use the same library TFT_espi to support it, which is suggested for the Pico in the link provided. The display itself is specified as "dedicated" to the RPI, but that's more of a marketing ploy to raise its price ;) Of course it's probably easier to do this with the Pico - it's quite well documented.
    I don't see any obstacle to being able to control this display, reed switch and PIR from the ESP32, as long as you need WiFi.
  • #7 20246135
    Michal8883
    Level 5  
    Esp= A tangle of cables and this pi pico elegantly connects just right, for this I wanted to use a set of pico + screen esp brain operation
  • ADVERTISEMENT
  • #8 20246301
    khoam
    Level 42  
    Communication between ESP32 and Pico is most simply (in software terms) provided over SPI. Unfortunately, once this display is connected to the Pico, you will need to "share" any of the SPI channels on the Pico for transmission with the ESP32.
  • ADVERTISEMENT
  • #9 20246369
    Michal8883
    Level 5  
    And it would be possible over wifi
  • #10 20246422
    khoam
    Level 42  
    It can be done. I think then the ESP32 needs to be set up in AP+STA mode. Then the Pico W can connect directly to the ESP, without going through an external AP router. There would be normal connectivity from the home WiFi network to the ESP.
    This kind of connection requires careful fault diagnostics in the code for ESP and Pico (in case of breakage or errors in WiFi transmission).
  • #11 20246713
    Michal8883
    Level 5  
    Either combine the two pico's together and give up the esp or it is not worth giving up the esp.
  • #12 20246878
    khoam
    Level 42  
    A lot depends on which SDK is/will be more convenient for you. Arduino Core for Pico W does not support AP+STA mode ( Link ).
    A fairly good comparison of the RP2040 and ESP32 chips is here: Link .
  • #13 20246896
    Michal8883
    Level 5  
    No comparison esp better and crushes pi pico.
  • #14 20254109
    Michal8883
    Level 5  
    And what would be the best combination of esp and pico or pico and pico
  • #15 21495491
    mitagimi75
    Level 3  
    You can use a Raspberry Pi Pico W with a touchscreen to control the ESP32, e.g. via Wi-Fi (MQTT, HTTP) or UART. The ESP32 is great for sensors and the Pico W can act as a user interface. If your project is simple, you can use two Pico W, but the ESP32 offers more processing power and better support for wireless communication.

Topic summary

The discussion revolves around using an ESP32 to manage ten sensors while controlling them via a Raspberry Pi PicoW with a touchscreen display. Users debate whether to integrate both functionalities on a single ESP32 or use two PicoW boards. Concerns about pin availability for the sensors and touchscreen are raised, with suggestions that the ESP32 can handle the display and sensors effectively, especially with WiFi capabilities. Communication between the ESP32 and Pico can be achieved via SPI or WiFi, although using the touchscreen with the Pico may require sharing SPI channels. The conversation also touches on the advantages of the ESP32 over the Pico in terms of performance and SDK support.
Summary generated by the language model.
ADVERTISEMENT