Repository: Bluetooth-Devices/oralb-ble (language: python)

Issue:
IO 8 reports as Smart Series 7000
We have an IO 8 but it reports in HA as Smart Series 7000. Most attributes work with some success but I think its not quite right. 

Output from brushing this morning: 

`2022-11-09 06:26:14.716 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] esp32-bluetooth-proxy-c814ac: F8:8A:5E:E1:DB:58 AdvertisementData(local_name='Oral-B Toothbrush', manufacturer_data={220: b'\x061\x19\x08r\x00\x00\x00\x07\x00\x00'}, service_uuids=['0000fe0d-0000-1000-8000-00805f9b34fb'], tx_power=-127, rssi=-96) connectable: True match: set() rssi: -96
2022-11-09 06:26:44.648 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] esp32-bluetooth-proxy-c814ac: F8:8A:5E:E1:DB:58 AdvertisementData(local_name='Oral-B Toothbrush', manufacturer_data={220: b'\x061\x19\x03r\x00\x0f\x00\x01\x00\x00'}, service_uuids=['0000fe0d-0000-1000-8000-00805f9b34fb'], tx_power=-127, rssi=-95) connectable: True match: set() rssi: -95
2022-11-09 06:27:03.151 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] esp32-bluetooth-proxy-c814ac: F8:8A:5E:E1:DB:58 AdvertisementData(local_name='Oral-B Toothbrush', manufacturer_data={220: b'\x061\x19\x03r\x00"\x00\x02\x00\x00'}, service_uuids=['0000fe0d-0000-1000-8000-00805f9b34fb'], tx_power=-127, rssi=-97) connectable: True match: set() rssi: -97
2022-11-09 06:27:03.998 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] esp32-bluetooth-proxy-c814ac: F8:8A:5E:E1:DB:58 AdvertisementData(local_name='Oral-B Toothbrush', manufacturer_data={220: b'\x061\x19\x03r\x00#\x00\x02\x00\x00'}, service_uuids=['0000fe0d-0000-1000-8000-00805f9b34fb'], tx_power=-127, rssi=-97) connectable: True match: set() rssi: -97
2022-11-09 06:27:06.224 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] esp32-bluetooth-proxy-c814ac: F8:8A:5E:E1:DB:58 AdvertisementData(local_name='Oral-B Toothbrush', manufacturer_data={220: b'\x061\x19\x03r\x00%\x00\x02\x00\x00'}, service_uuids=['0000fe0d-0000-1000-8000-00805f9b34fb'], tx_power=-127, rssi=-94) connectable: True match: set() rssi: -94
2022-11-09 06:27:17.698 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] esp32-bluetooth-proxy-c814ac: F8:8A:5E:E1:DB:58 AdvertisementData(local_name='Oral-B Toothbrush', manufacturer_data={220: b'\x061\x19\x03r\x000\x00\x02\x00\x00'}, service_uuids=['0000fe0d-0000-1000-8000-00805f9b34fb'], tx_power=-127, rssi=-93) connectable: True match: set() rssi: -93
2022-11-09 06:27:19.332 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] esp32-bluetooth-proxy-c814ac: F8:8A:5E:E1:DB:58 AdvertisementData(local_name='Oral-B Toothbrush', manufacturer_data={220: b'\x061\x19\x03r\x002\x00\x02\x00\x00'}, service_uuids=['0000fe0d-0000-1000-8000-00805f9b34fb'], tx_power=-127, rssi=-98) connectable: True match: set() rssi: -98
2022-11-09 06:27:24.362 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] esp32-bluetooth-proxy-c814ac: F8:8A:5E:E1:DB:58 AdvertisementData(local_name='Oral-B Toothbrush', manufacturer_data={220: b'\x061\x19\x03r\x007\x00\x02\x00\x00'}, service_uuids=['0000fe0d-0000-1000-8000-00805f9b34fb'], tx_power=-127, rssi=-97) connectable: True match: set() rssi: -97
2022-11-09 06:27:43.190 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] esp32-bluetooth-proxy-c814ac: F8:8A:5E:E1:DB:58 AdvertisementData(local_name='Oral-B Toothbrush', manufacturer_data={220: b'\x061\x19\x03r\x01\x0e\x00\x03\x00\x00'}, service_uuids=['0000fe0d-0000-1000-8000-00805f9b34fb'], tx_power=-127, rssi=-95) connectable: True match: set() rssi: -95
2022-11-09 06:27:44.013 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] esp32-bluetooth-proxy-c814ac: F8:8A:5E:E1:DB:58 AdvertisementData(local_name='Oral-B Toothbrush', manufacturer_data={220: b'\x061\x19\x03r\x01\x0f\x00\x03\x00\x00'}, service_uuids=['0000fe0d-0000-1000-8000-00805f9b34fb'], tx_power=-127, rssi=-93) connectable: True match: set() rssi: -93
2022-11-09 06:27:46.067 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] esp32-bluetooth-proxy-c814ac: F8:8A:5E:E1:DB:58 AdvertisementData(local_name='Oral-B Toothbrush', manufacturer_data={220: b'\x061\x19\x03r\x01\x11\x00\x03\x00\x00'}, service_uuids=['0000fe0d-0000-1000-8000-00805f9b34fb'], tx_power=-127, rssi=-99) connectable: True match: set() rssi: -99
2022-11-09 06:27:48.328 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] esp32-bluetooth-proxy-c814ac: F8:8A:5E:E1:DB:58 AdvertisementData(local_name='Oral-B Toothbrush', manufacturer_data={220: b'\x061\x19\x03r\x01\x13\x00\x03\x00\x00'}, service_uuids=['0000fe0d-0000-1000-8000-00805f9b34fb'], tx_power=-127, rssi=-99) connectable: True match: set() rssi: -99
2022-11-09 06:27:49.127 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] esp32-bluetooth-proxy-c814ac: F8:8A:5E:E1:DB:58 AdvertisementData(local_name='Oral-B Toothbrush', manufacturer_data={220: b'\x061\x19\x03r\x01\x14\x00\x03\x00\x00'}, service_uuids=['0000fe0d-0000-1000-8000-00805f9b34fb'], tx_power=-127, rssi=-96) connectable: True match: set() rssi: -96
2022-11-09 06:28:15.864 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] Oral-B Toothbrush (F8:8A:5E:E1:DB:58): Switching from esp32-bluetooth-proxy-c814ac[True] to esp32-bluetooth-proxy-cb54fc[True] (time elapsed:26.735744516015984 > stale seconds:25.111759460996836)
2022-11-09 06:28:15.865 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] esp32-bluetooth-proxy-cb54fc: F8:8A:5E:E1:DB:58 AdvertisementData(local_name='Oral-B Toothbrush', manufacturer_data={220: b'\x061\x19\x03r\x01/\x00\x04\x00\x00'}, service_uuids=['0000fe0d-0000-1000-8000-00805f9b34fb'], tx_power=-127, rssi=-94) connectable: True match: set() rssi: -94
2022-11-09 06:28:18.624 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] esp32-bluetooth-proxy-cb54fc: F8:8A:5E:E1:DB:58 AdvertisementData(local_name='Oral-B Toothbrush', manufacturer_data={220: b'\x061\x19\x03r\x011\x00\x04\x00\x00'}, service_uuids=['0000fe0d-0000-1000-8000-00805f9b34fb'], tx_power=-127, rssi=-96) connectable: True match: set() rssi: -96
2022-11-09 06:28:18.827 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] esp32-bluetooth-proxy-cb54fc: F8:8A:5E:E1:DB:58 AdvertisementData(local_name='Oral-B Toothbrush', manufacturer_data={220: b'\x061\x19\x03r\x012\x00\x04\x00\x00'}, service_uuids=['0000fe0d-0000-1000-8000-00805f9b34fb'], tx_power=-127, rssi=-98) connectable: True match: set() rssi: -98
2022-11-09 06:28:40.537 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] esp32-bluetooth-proxy-cb54fc: F8:8A:5E:E1:DB:58 AdvertisementData(local_name='Oral-B Toothbrush', manufacturer_data={220: b'\x061\x19\x03r\x02\x0b\x00\x07\x00\x00'}, service_uuids=['0000fe0d-0000-1000-8000-00805f9b34fb'], tx_power=-127, rssi=-98) connectable: True match: set() rssi: -98
2022-11-09 06:29:02.244 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] esp32-bluetooth-proxy-cb54fc: F8:8A:5E:E1:DB:58 AdvertisementData(local_name='Oral-B Toothbrush', manufacturer_data={220: b'\x061\x19\x03r\x02\x1e\x00*\x00\x00'}, service_uuids=['0000fe0d-0000-1000-8000-00805f9b34fb'], tx_power=-127, rssi=-98) connectable: True match: set() rssi: -98
2022-11-09 06:29:40.784 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] esp32-bluetooth-proxy-cb54fc: F8:8A:5E:E1:DB:58 AdvertisementData(local_name='Oral-B Toothbrush', manufacturer_data={220: b'\x061\x19\x02r\x025\x002\x00\x00'}, service_uuids=['0000fe0d-0000-1000-8000-00805f9b34fb'], tx_power=-127, rssi=-99) connectable: True match: set() rssi: -99
2022-11-09 06:29:48.841 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] Oral-B Toothbrush (F8:8A:5E:E1:DB:58): Switching from esp32-bluetooth-proxy-cb54fc[True] to esp32-bluetooth-proxy-c814ac[True] (new rssi:-93 - threshold:5 > old rssi:-99)
2022-11-09 06:29:59.283 DEBUG (MainThread) [homeassistant.components.bluetooth.manager] Oral-B Toothbrush (F8:8A:5E:E1:DB:58): Switching from esp32-bluetooth-proxy-c814ac[True] to esp32-bluetooth-proxy-cb54fc[True] (time elapsed:1.2080062919994816 > stale seconds:1.1120059869717807)`


Discussion / hints:
Thanks for the `AdvertisementData`
@bdraco if you need any more logging to be done for different features, just tag me, this was just from a standard clean, so aware there are menu options etc to go through and maybe config for the pressure?
It was using the mapping for Smart Series instead of IO Series so it should just work with the right mapping now

Fix patch:
diff --git a/src/oralb_ble/parser.py b/src/oralb_ble/parser.py
index ab19ea7..8b70d79 100644
--- a/src/oralb_ble/parser.py
+++ b/src/oralb_ble/parser.py
@@ -41,7 +41,7 @@ class Models(Enum):
     TriumphV2 = auto()
     IOSeries8 = auto()
     IOSeries9 = auto()
-    IOSeries78 = auto()
+    IOSeries67 = auto()
     IOSeries4 = auto()
     SmartSeries4000 = auto()
     SmartSeries6000 = auto()
@@ -80,6 +80,7 @@ class ModelDescription:
     3: "whiten",
     4: "intense",
     5: "super sensitive",
+    6: "tongue cleaning",
     8: "settings",
 }
 
@@ -87,8 +88,8 @@ class ModelDescription:
 DEVICE_TYPES = {
     Models.Pro6000: ModelDescription("Pro 6000", SMART_SERIES_MODES),
     Models.TriumphV2: ModelDescription("Triumph V2", SMART_SERIES_MODES),
-    Models.IOSeries78: ModelDescription(
-        device_type="IO Series 7/8",
+    Models.IOSeries67: ModelDescription(
+        device_type="IO Series 6/7",
         modes=IO_SERIES_MODES,
     ),
     Models.IOSeries8: ModelDescription(
@@ -165,7 +166,7 @@ class ModelDescription:
 
 
 BYTES_TO_MODEL = {
-    b"\x062k": Models.IOSeries78,
+    b"\x062k": Models.IOSeries67,
     b"\x074\x0c": Models.IOSeries4,
     b"\x03V\x04": Models.SmartSeries4000,
     b"\x04'\r": Models.SmartSeries6000,


Test patch:
diff --git a/tests/test_parser.py b/tests/test_parser.py
index c4eae4b..fb1c875 100644
--- a/tests/test_parser.py
+++ b/tests/test_parser.py
@@ -53,6 +53,15 @@
     service_data={},
     source="local",
 )
+ORALB_IO_SERIES_6 = BluetoothServiceInfo(
+    name="78:DB:2F:C2:48:BE",
+    address="78:DB:2F:C2:48:BE",
+    rssi=-63,
+    manufacturer_data={220: b"\x062k\x02r\x00\x00\x01\x01\x00\x04"},
+    service_uuids=[],
+    service_data={},
+    source="local",
+)
 ORALB_IO_SERIES_7 = BluetoothServiceInfo(
     name="78:DB:2F:C2:48:BE",
     address="78:DB:2F:C2:48:BE",
@@ -111,7 +120,7 @@
 ORALB_4000_SERIES = BluetoothServiceInfo(
     address="78:DB:2F:C2:48:BE",
     rssi=-63,
-    name="9000",
+    name="4000",
     manufacturer_data={220: b"\x03V\x04\x030\x00\x00\x01\x01\x00\x04"},
     service_uuids=[],
     service_data={},
@@ -190,6 +199,43 @@
     source="local",
 )
 
+ORALB_IO_SERIES_6_DAILY_CLEAN = BluetoothServiceInfo(
+    address="78:DB:2F:C2:48:BE",
+    rssi=-63,
+    name="Oral-B Toothbrush",
+    manufacturer_data={220: b"\x062k\x02r\x00\x00\x00\x01\x00\x04"},
+    service_uuids=[],
+    service_data={},
+    source="local",
+)
+ORALB_IO_SERIES_6_SENSITIVE = BluetoothServiceInfo(
+    address="78:DB:2F:C2:48:BE",
+    rssi=-63,
+    name="Oral-B Toothbrush",
+    manufacturer_data={220: b"\x062k\x02r\x00\x00\x01\x01\x00\x04"},
+    service_uuids=[],
+    service_data={},
+    source="local",
+)
+ORALB_IO_SERIES_6_GUM_CARE = BluetoothServiceInfo(
+    address="78:DB:2F:C2:48:BE",
+    rssi=-63,
+    name="Oral-B Toothbrush",
+    manufacturer_data={220: b"\x062k\x02r\x00\x00\x02\x01\x00\x04"},
+    service_uuids=[],
+    service_data={},
+    source="local",
+)
+ORALB_IO_SERIES_6_WHITEN = BluetoothServiceInfo(
+    address="78:DB:2F:C2:48:BE",
+    rssi=-63,
+    name="Oral-B Toothbrush",
+    manufacturer_data={220: b"\x062k\x02r\x00\x00\x03\x01\x00\x04"},
+    service_uuids=[],
+    service_data={},
+    source="local",
+)
+
 
 def test_can_create():
     OralBBluetoothDeviceData()
@@ -655,16 +701,591 @@ def test_dataset_4():
     )
 
 
+def test_io_series_6():
+    parser = OralBBluetoothDeviceData()
+    service_info = ORALB_IO_SERIES_6
+    result = parser.update(service_info)
+    assert result == SensorUpdate(
+        title="IO Series 6/7 48BE",
+        devices={
+            None: SensorDeviceInfo(
+                name="IO Series 6/7 48BE",
+                model="IO Series 6/7",
+                manufacturer="Oral-B",
+                sw_version=None,
+                hw_version=None,
+            )
+        },
+        entity_descriptions={
+            DeviceKey(key="number_of_sectors", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="number_of_sectors", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="sector_timer", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="sector_timer", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="signal_strength", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="signal_strength", device_id=None),
+                device_class=SensorDeviceClass.SIGNAL_STRENGTH,
+                native_unit_of_measurement=Units.SIGNAL_STRENGTH_DECIBELS_MILLIWATT,
+            ),
+            DeviceKey(key="sector", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="sector", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="toothbrush_state", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="toothbrush_state", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="mode", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="mode", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="pressure", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="pressure", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="time", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="time", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+        },
+        entity_values={
+            DeviceKey(key="number_of_sectors", device_id=None): SensorValue(
+                device_key=DeviceKey(key="number_of_sectors", device_id=None),
+                name="Number " "of " "sectors",
+                native_value=4,
+            ),
+            DeviceKey(key="sector_timer", device_id=None): SensorValue(
+                device_key=DeviceKey(key="sector_timer", device_id=None),
+                name="Sector " "Timer",
+                native_value=0,
+            ),
+            DeviceKey(key="signal_strength", device_id=None): SensorValue(
+                device_key=DeviceKey(key="signal_strength", device_id=None),
+                name="Signal " "Strength",
+                native_value=-63,
+            ),
+            DeviceKey(key="sector", device_id=None): SensorValue(
+                device_key=DeviceKey(key="sector", device_id=None),
+                name="Sector",
+                native_value="sector " "1",
+            ),
+            DeviceKey(key="toothbrush_state", device_id=None): SensorValue(
+                device_key=DeviceKey(key="toothbrush_state", device_id=None),
+                name="Toothbrush " "State",
+                native_value="idle",
+            ),
+            DeviceKey(key="mode", device_id=None): SensorValue(
+                device_key=DeviceKey(key="mode", device_id=None),
+                name="Mode",
+                native_value="sensitive",
+            ),
+            DeviceKey(key="pressure", device_id=None): SensorValue(
+                device_key=DeviceKey(key="pressure", device_id=None),
+                name="Pressure",
+                native_value="normal",
+            ),
+            DeviceKey(key="time", device_id=None): SensorValue(
+                device_key=DeviceKey(key="time", device_id=None),
+                name="Time",
+                native_value=0,
+            ),
+        },
+        binary_entity_descriptions={
+            DeviceKey(key="brushing", device_id=None): BinarySensorDescription(
+                device_key=DeviceKey(key="brushing", device_id=None), device_class=None
+            )
+        },
+        binary_entity_values={
+            DeviceKey(key="brushing", device_id=None): BinarySensorValue(
+                device_key=DeviceKey(key="brushing", device_id=None),
+                name="Brushing",
+                native_value=False,
+            )
+        },
+        events={},
+    )
+
+
+def test_io_series_6_daily_clean_mode():
+    parser = OralBBluetoothDeviceData()
+    service_info = ORALB_IO_SERIES_6_DAILY_CLEAN
+    result = parser.update(service_info)
+    assert result == SensorUpdate(
+        title="IO Series 6/7 48BE",
+        devices={
+            None: SensorDeviceInfo(
+                name="IO Series 6/7 48BE",
+                model="IO Series 6/7",
+                manufacturer="Oral-B",
+                sw_version=None,
+                hw_version=None,
+            )
+        },
+        entity_descriptions={
+            DeviceKey(key="number_of_sectors", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="number_of_sectors", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="sector_timer", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="sector_timer", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="signal_strength", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="signal_strength", device_id=None),
+                device_class=SensorDeviceClass.SIGNAL_STRENGTH,
+                native_unit_of_measurement=Units.SIGNAL_STRENGTH_DECIBELS_MILLIWATT,
+            ),
+            DeviceKey(key="sector", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="sector", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="toothbrush_state", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="toothbrush_state", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="mode", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="mode", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="pressure", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="pressure", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="time", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="time", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+        },
+        entity_values={
+            DeviceKey(key="number_of_sectors", device_id=None): SensorValue(
+                device_key=DeviceKey(key="number_of_sectors", device_id=None),
+                name="Number " "of " "sectors",
+                native_value=4,
+            ),
+            DeviceKey(key="sector_timer", device_id=None): SensorValue(
+                device_key=DeviceKey(key="sector_timer", device_id=None),
+                name="Sector " "Timer",
+                native_value=0,
+            ),
+            DeviceKey(key="signal_strength", device_id=None): SensorValue(
+                device_key=DeviceKey(key="signal_strength", device_id=None),
+                name="Signal " "Strength",
+                native_value=-63,
+            ),
+            DeviceKey(key="sector", device_id=None): SensorValue(
+                device_key=DeviceKey(key="sector", device_id=None),
+                name="Sector",
+                native_value="sector " "1",
+            ),
+            DeviceKey(key="toothbrush_state", device_id=None): SensorValue(
+                device_key=DeviceKey(key="toothbrush_state", device_id=None),
+                name="Toothbrush " "State",
+                native_value="idle",
+            ),
+            DeviceKey(key="mode", device_id=None): SensorValue(
+                device_key=DeviceKey(key="mode", device_id=None),
+                name="Mode",
+                native_value="daily clean",
+            ),
+            DeviceKey(key="pressure", device_id=None): SensorValue(
+                device_key=DeviceKey(key="pressure", device_id=None),
+                name="Pressure",
+                native_value="normal",
+            ),
+            DeviceKey(key="time", device_id=None): SensorValue(
+                device_key=DeviceKey(key="time", device_id=None),
+                name="Time",
+                native_value=0,
+            ),
+        },
+        binary_entity_descriptions={
+            DeviceKey(key="brushing", device_id=None): BinarySensorDescription(
+                device_key=DeviceKey(key="brushing", device_id=None), device_class=None
+            )
+        },
+        binary_entity_values={
+            DeviceKey(key="brushing", device_id=None): BinarySensorValue(
+                device_key=DeviceKey(key="brushing", device_id=None),
+                name="Brushing",
+                native_value=False,
+            )
+        },
+        events={},
+    )
+
+
+def test_io_series_6_sensitive_mode():
+    parser = OralBBluetoothDeviceData()
+    service_info = ORALB_IO_SERIES_6_SENSITIVE
+    result = parser.update(service_info)
+    assert result == SensorUpdate(
+        title="IO Series 6/7 48BE",
+        devices={
+            None: SensorDeviceInfo(
+                name="IO Series 6/7 48BE",
+                model="IO Series 6/7",
+                manufacturer="Oral-B",
+                sw_version=None,
+                hw_version=None,
+            )
+        },
+        entity_descriptions={
+            DeviceKey(key="number_of_sectors", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="number_of_sectors", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="sector_timer", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="sector_timer", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="signal_strength", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="signal_strength", device_id=None),
+                device_class=SensorDeviceClass.SIGNAL_STRENGTH,
+                native_unit_of_measurement=Units.SIGNAL_STRENGTH_DECIBELS_MILLIWATT,
+            ),
+            DeviceKey(key="sector", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="sector", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="toothbrush_state", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="toothbrush_state", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="mode", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="mode", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="pressure", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="pressure", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="time", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="time", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+        },
+        entity_values={
+            DeviceKey(key="number_of_sectors", device_id=None): SensorValue(
+                device_key=DeviceKey(key="number_of_sectors", device_id=None),
+                name="Number " "of " "sectors",
+                native_value=4,
+            ),
+            DeviceKey(key="sector_timer", device_id=None): SensorValue(
+                device_key=DeviceKey(key="sector_timer", device_id=None),
+                name="Sector " "Timer",
+                native_value=0,
+            ),
+            DeviceKey(key="signal_strength", device_id=None): SensorValue(
+                device_key=DeviceKey(key="signal_strength", device_id=None),
+                name="Signal " "Strength",
+                native_value=-63,
+            ),
+            DeviceKey(key="sector", device_id=None): SensorValue(
+                device_key=DeviceKey(key="sector", device_id=None),
+                name="Sector",
+                native_value="sector " "1",
+            ),
+            DeviceKey(key="toothbrush_state", device_id=None): SensorValue(
+                device_key=DeviceKey(key="toothbrush_state", device_id=None),
+                name="Toothbrush " "State",
+                native_value="idle",
+            ),
+            DeviceKey(key="mode", device_id=None): SensorValue(
+                device_key=DeviceKey(key="mode", device_id=None),
+                name="Mode",
+                native_value="sensitive",
+            ),
+            DeviceKey(key="pressure", device_id=None): SensorValue(
+                device_key=DeviceKey(key="pressure", device_id=None),
+                name="Pressure",
+                native_value="normal",
+            ),
+            DeviceKey(key="time", device_id=None): SensorValue(
+                device_key=DeviceKey(key="time", device_id=None),
+                name="Time",
+                native_value=0,
+            ),
+        },
+        binary_entity_descriptions={
+            DeviceKey(key="brushing", device_id=None): BinarySensorDescription(
+                device_key=DeviceKey(key="brushing", device_id=None), device_class=None
+            )
+        },
+        binary_entity_values={
+            DeviceKey(key="brushing", device_id=None): BinarySensorValue(
+                device_key=DeviceKey(key="brushing", device_id=None),
+                name="Brushing",
+                native_value=False,
+            )
+        },
+        events={},
+    )
+
+
+def test_io_series_6_gum_care_mode():
+    parser = OralBBluetoothDeviceData()
+    service_info = ORALB_IO_SERIES_6_GUM_CARE
+    result = parser.update(service_info)
+    assert result == SensorUpdate(
+        title="IO Series 6/7 48BE",
+        devices={
+            None: SensorDeviceInfo(
+                name="IO Series 6/7 48BE",
+                model="IO Series 6/7",
+                manufacturer="Oral-B",
+                sw_version=None,
+                hw_version=None,
+            )
+        },
+        entity_descriptions={
+            DeviceKey(key="number_of_sectors", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="number_of_sectors", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="sector_timer", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="sector_timer", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="signal_strength", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="signal_strength", device_id=None),
+                device_class=SensorDeviceClass.SIGNAL_STRENGTH,
+                native_unit_of_measurement=Units.SIGNAL_STRENGTH_DECIBELS_MILLIWATT,
+            ),
+            DeviceKey(key="sector", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="sector", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="toothbrush_state", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="toothbrush_state", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="mode", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="mode", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="pressure", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="pressure", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="time", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="time", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+        },
+        entity_values={
+            DeviceKey(key="number_of_sectors", device_id=None): SensorValue(
+                device_key=DeviceKey(key="number_of_sectors", device_id=None),
+                name="Number " "of " "sectors",
+                native_value=4,
+            ),
+            DeviceKey(key="sector_timer", device_id=None): SensorValue(
+                device_key=DeviceKey(key="sector_timer", device_id=None),
+                name="Sector " "Timer",
+                native_value=0,
+            ),
+            DeviceKey(key="signal_strength", device_id=None): SensorValue(
+                device_key=DeviceKey(key="signal_strength", device_id=None),
+                name="Signal " "Strength",
+                native_value=-63,
+            ),
+            DeviceKey(key="sector", device_id=None): SensorValue(
+                device_key=DeviceKey(key="sector", device_id=None),
+                name="Sector",
+                native_value="sector " "1",
+            ),
+            DeviceKey(key="toothbrush_state", device_id=None): SensorValue(
+                device_key=DeviceKey(key="toothbrush_state", device_id=None),
+                name="Toothbrush " "State",
+                native_value="idle",
+            ),
+            DeviceKey(key="mode", device_id=None): SensorValue(
+                device_key=DeviceKey(key="mode", device_id=None),
+                name="Mode",
+                native_value="gum care",
+            ),
+            DeviceKey(key="pressure", device_id=None): SensorValue(
+                device_key=DeviceKey(key="pressure", device_id=None),
+                name="Pressure",
+                native_value="normal",
+            ),
+            DeviceKey(key="time", device_id=None): SensorValue(
+                device_key=DeviceKey(key="time", device_id=None),
+                name="Time",
+                native_value=0,
+            ),
+        },
+        binary_entity_descriptions={
+            DeviceKey(key="brushing", device_id=None): BinarySensorDescription(
+                device_key=DeviceKey(key="brushing", device_id=None), device_class=None
+            )
+        },
+        binary_entity_values={
+            DeviceKey(key="brushing", device_id=None): BinarySensorValue(
+                device_key=DeviceKey(key="brushing", device_id=None),
+                name="Brushing",
+                native_value=False,
+            )
+        },
+        events={},
+    )
+
+
+def test_io_series_6_whiten_mode():
+    parser = OralBBluetoothDeviceData()
+    service_info = ORALB_IO_SERIES_6_WHITEN
+    result = parser.update(service_info)
+    assert result == SensorUpdate(
+        title="IO Series 6/7 48BE",
+        devices={
+            None: SensorDeviceInfo(
+                name="IO Series 6/7 48BE",
+                model="IO Series 6/7",
+                manufacturer="Oral-B",
+                sw_version=None,
+                hw_version=None,
+            )
+        },
+        entity_descriptions={
+            DeviceKey(key="number_of_sectors", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="number_of_sectors", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="sector_timer", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="sector_timer", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="signal_strength", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="signal_strength", device_id=None),
+                device_class=SensorDeviceClass.SIGNAL_STRENGTH,
+                native_unit_of_measurement=Units.SIGNAL_STRENGTH_DECIBELS_MILLIWATT,
+            ),
+            DeviceKey(key="sector", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="sector", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="toothbrush_state", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="toothbrush_state", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="mode", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="mode", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="pressure", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="pressure", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+            DeviceKey(key="time", device_id=None): SensorDescription(
+                device_key=DeviceKey(key="time", device_id=None),
+                device_class=None,
+                native_unit_of_measurement=None,
+            ),
+        },
+        entity_values={
+            DeviceKey(key="number_of_sectors", device_id=None): SensorValue(
+                device_key=DeviceKey(key="number_of_sectors", device_id=None),
+                name="Number " "of " "sectors",
+                native_value=4,
+            ),
+            DeviceKey(key="sector_timer", device_id=None): SensorValue(
+                device_key=DeviceKey(key="sector_timer", device_id=None),
+                name="Sector " "Timer",
+                native_value=0,
+            ),
+            DeviceKey(key="signal_strength", device_id=None): SensorValue(
+                device_key=DeviceKey(key="signal_strength", device_id=None),
+                name="Signal " "Strength",
+                native_value=-63,
+            ),
+            DeviceKey(key="sector", device_id=None): SensorValue(
+                device_key=DeviceKey(key="sector", device_id=None),
+                name="Sector",
+                native_value="sector " "1",
+            ),
+            DeviceKey(key="toothbrush_state", device_id=None): SensorValue(
+                device_key=DeviceKey(key="toothbrush_state", device_id=None),
+                name="Toothbrush " "State",
+                native_value="idle",
+            ),
+            DeviceKey(key="mode", device_id=None): SensorValue(
+                device_key=DeviceKey(key="mode", device_id=None),
+                name="Mode",
+                native_value="whiten",
+            ),
+            DeviceKey(key="pressure", device_id=None): SensorValue(
+                device_key=DeviceKey(key="pressure", device_id=None),
+                name="Pressure",
+                native_value="normal",
+            ),
+            DeviceKey(key="time", device_id=None): SensorValue(
+                device_key=DeviceKey(key="time", device_id=None),
+                name="Time",
+                native_value=0,
+            ),
+        },
+        binary_entity_descriptions={
+            DeviceKey(key="brushing", device_id=None): BinarySensorDescription(
+                device_key=DeviceKey(key="brushing", device_id=None), device_class=None
+            )
+        },
+        binary_entity_values={
+            DeviceKey(key="brushing", device_id=None): BinarySensorValue(
+                device_key=DeviceKey(key="brushing", device_id=None),
+                name="Brushing",
+                native_value=False,
+            )
+        },
+        events={},
+    )
+
+
 def test_io_series_7():
     parser = OralBBluetoothDeviceData()
     service_info = ORALB_IO_SERIES_7
     result = parser.update(service_info)
     assert result == SensorUpdate(
-        title="IO Series 7/8 48BE",
+        title="IO Series 6/7 48BE",
         devices={
             None: SensorDeviceInfo(
-                name="IO Series 7/8 48BE",
-                model="IO Series 7/8",
+                name="IO Series 6/7 48BE",
+                model="IO Series 6/7",
                 manufacturer="Oral-B",
                 sw_version=None,
                 hw_version=None,