Brilliantsmart switch mech no working

Hello. I am new to esphome (and homeassistant for that matter). I have successfully flashed esphome onto some Kogan smart plugs and an Efergy smart plug and they are working fine. I am trying to put ESPHome on a BrilliantSmart switch mech, using the yaml from the Deta two gang switch. but it doesnt work at all. It flahses it fine, and it still turns on with the actual switch and the LED comes on, but via the web interface, nothing happens.

I assume the GPIO pins are wrong. Is there any process to work out the correct GPIO pins apart from trying them all one by one?

Config is

esphome:
  platform: ESP8266
  board: esp01_1m
  name: bathroom_switch
  esp8266_restore_from_flash: true

wifi:
  ssid: xxx
  password: xxxxx
  fast_connect: on
  manual_ip:
    static_ip: 192.168.x.x
    gateway: 192.168.x.x
    subnet: 255.255.255.0

# Enable Web Server (optional)
web_server:
  port: 80
  
api:

ota:

logger:

#################################

status_led:
  pin:
    number: GPIO4
    inverted: True

output:
  - platform: gpio
    pin: GPIO13
    id: relay1

light:
  - platform: binary
    name: "Bathroom Switch"
    output: relay1
    id: light1

# Button
binary_sensor:
  - platform: gpio
    pin:
      number: GPIO16
      mode: INPUT_PULLUP
      inverted: True
    name: "Bathroom Button"
    #toggle relay on push
    on_press:
      - light.toggle: light1

switch:
- platform: restart
  name: "Bathroom REBOOT"

Exactly what device? Brilliantsmart have nodel numbers.

Sorry 21322

Google doesn’t reveal much. It might require some trial and error.

Thanks, yes that is what I found. So can I put firmware on it that exposes all the GPIO pins so I can see their status and turn them on or off via the web interface? Is there a template yaml I can use to do that? My esphome yaml skills are not yet up to writing that

Maybe Tasmota would be a better choice for this trial-and-error process because you can change things fairly quickly. In ESPHome you probably need to try change config, recompile and upload the firmware over and over to find the right configuration.