-
-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Characteristic to offer configuration #25
Comments
I hope these will be typical UUIDs? Device Information: This list is fully processed in all typical Xiaomi thermometers and with custom firmware, except for the atc1441 option. https://github.com/pvvx/ATC_MiThermometer#control-function-id-when-connected - The link points to a short description of the service UUID with a specific command format that is different for each device, and not to standard UUIDs. |
It looks like they use the official descriptions. I still have to check the UUIDs, as they don’t give them in this document. They refer to the core Bluetooth specs, will look into that later, but I assume that these will correspond to the ones Xiaomi and you have used. Makes sense to use the same. From the Device Information service documentation 3 Service Characteristics The Device Information Service may expose one or more of the characteristics shown in Table 3.1. It is possible that none of the characteristics below are included. Unless otherwise specified, only one instance of each characteristic shall be present.
Table 3.1: Device Information Service characteristics |
There may be difficulties here.
I do not know such a UUID characteristic.
|
I don’t think we need the device class, as this is already defined in the different object_ids. Data interval isn’t needed either, one of the latest HA versions has now implemented a dynamic time before it becomes unavailable, based on the interval it received the last x advertisements. |
BLE_UUID_SCAN_PARAMETERS_SERVICE 0x1813 So far I have not seen implementations with UUID_SCAN_PARAMETERS. |
Due to incorrect encoding in BTHome v2, it cannot be supported in ESPHome and other implementations on small SoCs. Requires version 3. |
What do you mean with “incorrect encoding in BTHome V2”? Can you explain what is wrong (and how to fix)? |
There is no way to identify the size of variables without special tables. When adding a new ID, a mandatory firmware update is required. An example of such a variable is the time in the device. Many SoCs do not have a dedicated clock crystal, and the timing drifts. A third party program can match the counter and decide to synchronize if the drift is large. There is no need to display the time counter in the user interface. There may also be other variables that are only needed for transfer between devices. The current v2 format requires that you ask for permission to enter them and wait to be entered into the HA. How will the parsing of two messages received during the same ad event but from different sources - from the scan request and from the main frame - behave now? ->Will be combined into one promotional event or ? advertisements with multiple measurements of the same type What do you think of the Advertising ID in Extended Advertising? Advertising identifier - advertising package number. BT5.3 introduced "AdvDataInfo", the equivalent of "package ID" in BTHome. "Package ID" becomes redundant. |
Just thinking, but if we add a time object id to BTHome, and we don't want to use it in Home Assistant, we should just make HA to skip the object id, and continue with the next. This should be possible, as we know the data length, also in V2.
Yes, but at the moment, we don't have any text objects, both not in V1 as well as not in V2. Yes, of course V1 is able to just use a if obj_meas_type in VARIABLE_LENGTH_SENSORS:
obj_data_length = obj_data_start[0]
else:
obj_data_length = MEAS_TYPES[obj_meas_type].data_length
Good question. But I was thinking that the characteristics should only contain specific data for configuration, e.g. device information. A next step could be sensor data as well, but that is probably for BTHome V3 or V4.
Again, good questions (and suggestions). This is something for the future to figure out. |
Issue moved from home-assistant/bthome.io#11. Issue originally created by @balloob
Some data we want the receiver to know but it never changes. It would be nice if we could offer a read-only characteristic for receivers to fetch this. It could contain:
Device classInterval that data is send (for unavailable tracking)The flow would be:
Example is the pvvx ATC firmware, that also holds device info and keys, that can be read after connecting to the device
https://github.com/pvvx/ATC_MiThermometer#control-function-id-when-connected
The text was updated successfully, but these errors were encountered: