ESPHome Bed Occupancy Sensor Setup Guide

Hello everyone! I’m new to ESP devices and I’m trying to set up a bed occupancy sensor using an ESP32. I came across a great guide by Home Automation Guy, which walks through creating a sensor using pressure mats. However, I’m running into some issues with the pin layout on my ESP32. The guide uses a different model, and I’m not sure which pins to use for my setup. I’ve attached a picture of my ESP32 for reference.

I also found some sample code for the binary_sensor platform, but I’m not sure if it will work with my device. I’ve tried adjusting the pin number, but I’m concerned about compatibility. Does anyone have experience with ESP32 bed occupancy sensors? Any advice on pin selection or code modifications would be greatly appreciated!

Looking forward to hearing from you all. Thanks in advance!

Best regards,
Marc