HAMQTT 0.1.0
ESP-IDF component for integrating devices with Home Assistant over MQTT
Loading...
Searching...
No Matches
HAMQTT_Device_Config Struct Reference

Configuration parameters for a HAMQTT device. More...

#include <hamqtt_device.h>

Public Member Functions

HAMQTT_Device_Config hamqtt_device_config_default (void)
 Returns a default-initialized device configuration.

Public Attributes

char * mqtt_config_topic_prefix
 The prefix for Home Assistant MQTT discovery topics.
char * mqtt_uri
 The URI of the MQTT broker (e.g., "mqtt://broker.hivemq.com:1883").
char * mqtt_username
 The MQTT username.
char * mqtt_password
 The MQTT password.
char * manufacturer
 The manufacturer of the device.
char * model
 The model of the device.
char * serial_number
 The serial number of the device.
char * unique_id
 Unique identifier used for discovery in Home Assistant.
char * sw_version
 The software version of the device.
char * hw_version
 The hardware version of the device.
char * origin_url
 URL to documentation or device homepage.
char * name
 The name of the device shown in Home Assistant.

Detailed Description

Configuration parameters for a HAMQTT device.

Member Function Documentation

◆ hamqtt_device_config_default()

HAMQTT_Device_Config hamqtt_device_config_default ( void )

Returns a default-initialized device configuration.

Caller is still responsible for assigning mqtt_uri and unique_id

Returns
A default-initialized HAMQTT_Device_Config struct.

Member Data Documentation

◆ hw_version

char* HAMQTT_Device_Config::hw_version

The hardware version of the device.

Note
Optional.

◆ manufacturer

char* HAMQTT_Device_Config::manufacturer

The manufacturer of the device.

Note
Optional.

◆ model

char* HAMQTT_Device_Config::model

The model of the device.

Note
Optional.

◆ mqtt_password

char* HAMQTT_Device_Config::mqtt_password

The MQTT password.

Note
Optional.

◆ mqtt_username

char* HAMQTT_Device_Config::mqtt_username

The MQTT username.

Note
Optional.

◆ origin_url

char* HAMQTT_Device_Config::origin_url

URL to documentation or device homepage.

Note
Optional.

◆ serial_number

char* HAMQTT_Device_Config::serial_number

The serial number of the device.

Note
Optional.

◆ sw_version

char* HAMQTT_Device_Config::sw_version

The software version of the device.

Note
Optional.

The documentation for this struct was generated from the following file: