Can ESP32-C6 operate as FTD (Full Thread Device) and Bluetooth Proxy simultaneously?

I just bought some Level Bolt locks that could be updated to work with Matter but work with Bluetooth currently. I have a bunch of ESP32-C3 I could set up as Bluetooth proxies around the house, but I’d rather have the devices have multiple functions.

So to get started with Matter I just ordered 10 ESP32-C6 units to start my thread network.

I intend to leech power from my wired PIR sensors by means of a buck converter, but I’d like to squeeze as much functionality as possible out of the device.

So, could I make a FTD (Full Thread Device) that reports the status of the PIR sensor and functions as a Bluetooth proxy as well?

What is an FTD?

And in general, you can use your BT Proxies as other things as well. I have lots of BT Proxies spread through the house and they’re all serving other primary purposes with BT Proxy just being a secondary thing that was added.

1 Like

Full thread Device, basically a proxy for thread. What sorts of devices have you built? Are you building your YAML from scratch? Are you adding the proxy code after whatever regular device you have?

Lots of random devices; honestly most of them are pretty simple (at least the ones acting as proxies). BT Proxy is pretty resource intensive, so I wouldn’t be surprised if it doesn’t play well with what you’re trying to do. And yeah, I just add the BT Proxy to my YAML manually, it’s just a few lines.

Best advice is to just try it. Also, add one piece at a time to help narrow down any issues rather than trying to build one giant YAML file from the beginning.

Thanks. I’ll check it out as soon as my buck converters arrive and I’m able to leech from the PIR sensors

I tried adding:

 bluetooth_proxy:
   active: true
 
 esp32_ble_tracker:
   scan_parameters:
     interval: 1100ms
     window: 1100ms
     active: true

to a working OpenThread device, but than OpenThread and BLE are not working.
EDIt: Looking at the post under, I only need to remove the scan_parameters!

I have an H2 being both an FTD and a bluetooth proxy, so I guess a C6 can do it as well.

substitutions:
  device_name: h2-thread-router-02
  friendly_name: H2 Thread router 02

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

esphome:
  name: "${device_name}"
  friendly_name: "${friendly_name}"

esp32:
  board: esp32-h2-devkitm-1
  variant: ESP32H2
  framework:
    type: esp-idf

packages:
  base: !include common/base_thread.yaml

logger:
  baud_rate: 0

binary_sensor:    
  - platform: status
    name: Status

text_sensor:
  - platform: openthread_info
    ip_address:
      name: "Thread IP Address"
    channel:
      name: "Thread Channel"
    role:
      name: "Thread Device Role"
    rloc16:
      name: "Thread RLOC16"
    ext_addr:
      name: "Thread Extended Address"
    eui64:
      name: "Thread EUI64"
    network_name:
      name: "Thread Network Name"
    network_key:
      name: "Thread Network Key"
    pan_id:
      name: "Thread PAN ID"
    ext_pan_id:
      name: "Thread Extended PAN ID"
      
button:
  - platform: restart
    name: "Restart"

sensor:
  - platform: template
    id: esp_memory
    icon: mdi:memory
    name: Free Memory
    lambda: return heap_caps_get_free_size(MALLOC_CAP_INTERNAL) / 1024;
    unit_of_measurement: 'kB'
    state_class: measurement
    entity_category: "diagnostic"
  - platform: uptime
    name: Uptime
    id: sys_uptime

output:
  - platform: gpio
    pin: 13
    id: blue_led

light:
  - platform: binary
    name: "Blue LED"
    output: blue_led

  - platform: esp32_rmt_led_strip
    rgb_order: GRB
    pin: 8
    num_leds: 1
    chipset: ws2812
    name: "RGB LED"

esp32_ble_tracker:

bluetooth_proxy:
  active: true

base_thread.yaml

# Enable logging
logger:

# # Enable Home Assistant API
api:
  homeassistant_services: true
  encryption:
    key: !secret api_key

ota:
  - platform: esphome
    password: !secret ota_password

network:
  enable_ipv6: true
 
openthread:
  tlv: [my TLV]

4 Likes

This looks awesome, it’s a great start for what I want to do. The only unknown is if it could work as a PIR as well and I’d be over the moon. Guess I’ll have to test when the time comes.

A thread ESP behaves exactly the same as a “normal” wifi ESP, so I expect you can do exactly the same. Thread is just the transport protocol.

As a consequence, the ESP won’t be a matter device though. I don’t think matter is possible in ESPHome, yet.

I guess I celebrated too quickly then. Although I don’t have any matter devices yet, I’d like to be futureproofed.

But your device is still Bluetooth proxy over WiFi, right? It’s not “proxying” over Thread, is it?

Yes, it is :slight_smile:

1 Like

Ref: Matter (formerly Project CHIP / Connected Home over IP) Application Layer support in ESPHome? · Issue #1430 · esphome/feature-requests · GitHub