Connecting Esp32 to pico

Posted on
  • Hi All,

    I am trying to connect "ESP32 WeMos Lolin32" to the Espruino Pico through SPI2, since I have already used SPI1 pins for other things. this is the code I have written:

    SPI2.setup({mosi:B15, miso:B14, sck: B13});
    var esp32 = require("ESP32").connect(SPI2);

    I'm getting the following error at 2nd line:

    warning: module "esp32" not found uncaught error: sd card must be setup with e.connectsdcard first at line 4 col 28 var esp32 = require("esp32").connect(spi2);

    .
    Please help me resolve this issue. I'm using esp32 to use the bluetooth, any help on using the bluetooth will also be useful.

    Thank You,

  • Hi,

    I'm afraid there's no library for SPI communication with ESP32 built in to Espruino, so the code require("esp32") won't work.

    But, you could still use the SPI2.setup({mosi:B15, miso:B14, sck: B13}); code and then manually send commands with SPI2.send/write - assuming the ESP32 has firmware installed that supports communication via SPI?

    I'm not 100% sure if there is such a firmware... The standard AT command firmware (https://www.espressif.com/en/products/sdĀ­ks/esp-at/overview) would appear to just want to communicate over serial...

  • Post a reply
    • Bold
    • Italics
    • Link
    • Image
    • List
    • Quote
    • code
    • Preview
About

Connecting Esp32 to pico

Posted by Avatar for user151645 @user151645

Actions