WIFI LoRa 32(V2) Pinout Diagram questions

Comparing WIFI LoRa 32(V2) Pinout to other controllers and have a few questions that I could not find the answers to.

How many of the input pins support interrupts?

How many of the output capable pins support PWM? Any restricted pins for PWM?

The I2C0 seems to be used internally, does this mean that pins 21(SDA) and 22(SCL) are unavailable?
What pins are required for I2C1 to use?

The I2S pins are not shown on the diagram.
What pins are required for I2S to use?

What is the pin (18x) spacing? Is it 2.54mm?
What is the row (2x) spacing? Is it 9*2.54mm?

1 Like

Hi,

I’ve used this module extensively, let me try to help.

It’s important to know that ESP32 uses a microcontroller which allows for pin multiplexing, which means you can assign different peripherals (like I2C, SPI, PWM, etc) to different pins. This means there aren’t really dedicated pins for the peripherals.

That being said, the ESP32 LoRa module from HelTec includes things like the screen which, in order to use them, are connected to specific pins (GPIO15 and GPIO4)

Looking at the pinout, you see “OLED_SCL” and OLED_SDA" on pins 15 and 4 respectively. To use the screen, you need to have an i2c running on those pins. But you are not limited to using I2C on only those pins, and you can use that bus if you want, as long as you understand that the screen is taking up a specific address on that bus. And you can use those pins for other stuff if you want. Just note that whatever you do with them is connected to the OLED i2c, so you run into issues.

You can run I2C using any available pair of GPIOs which are both inputs and outputs. ESP32 has

There are caveats, however. ESP32s have pins which might be input only, or might be used as part of the programming process.

Likewise, some pins default to certain functionality. For example, RX and TX are, by default, connected to the same UART that the USB port uses.

The best way to answer your question fully is to look at that GPIO from the ESP32 are connected directly to the pins on the HelTec module, and understand how those GPIO work from ESP32 documentation.

To give specifics for your question:

  • any GPIO that is an output can manage a PWM.
  • Not all ESP32 pins are capable of output (specifically 34-39, note the astrisks in the diagram)
  • I2C pins can be set in software
  • ESP32 I2S requires the DACs on GPIO26 and GPIO26

This is all noted in the pinout diagram, but requires decoding against the capabilities of the ESP32 specifically.

Let me know if the above wasn’t clear. If it’s your first time using a chip with IO multiplexing it takes a bit to get used to. In your code you tell the MCU which pins you want the I2C SDA and SCL lines to be, rather than being limited to dedicated pins. However, there are caveats like input only pins. That goes for most of the peripherals. You can reassign them, but not all GPIO are equal.

Thanks; however, I have more questions for I2S:
DAC1 / PIN 26 / GPIO26 shows LoRA_DIO0 as the pin use; can I assume this is not required onboard?
DAC2 / PIN 25 / GPIO25 shows LED as the use; can I assume this is the on-board LED or is this some other LED function?

I’m looking to use I2S on this module as well. Did you have any luck making it go? If so, any pointers or example code that would be helpful? Thanks.

Hi,
Have you found a solution to use I2S on WiFi LoRa V2 board ? I’m also trying to do that, with no luck actually…