jlamendo/ha-sensor.owlet

Sensor not registering any values

Closed this issue · 15 comments

The owlet base picked up properly because the sensor ends with the matching serial number that the app has so I know my main config is correct but I added the template section to get the sensors and they register nothing. Any advice?

Well, I might've just figured it out but I'll have to wait until tonight to test it. I didn't notice the [YOUR_SMART_SOCK_SERIAL_NUMBER] section of each sensor. I pasted in the serial number that was appended to the end of the main hub sensor upon creation and restarted. Should I leave the brackets? I deleted them.

Nope it didn’t pick up. None of the sensors have the serial numbered appended at the end of the name like the hub does. Is that part of the problem somehow?

friendly bump:
Any help would be SUPER appreciated. I’ve got a high risk newborn and I think this would make me feel so much better to tie in these metrics with my lights and speakers. I’m getting the base station to register with the serial number automatically appended to the end of the entityID so that MUST mean the login process is working, right? It’s just the other sensors that won’t return any data. Should I delete everything and start from the beginning but have the serial number already appended to my other sensors? I’d like to run the base python api login in a terminal window to see if that works but I’m not sure how to do that. Any other ways to debug what’s going on that y’all could point me to? Thanks in advance.

And just to be sure that my config for integration is okay, this is my setup:

configuration.yaml:

sensor: !include sensors.yaml
secrets: !include secrets.yaml

sensors.yaml:

####### Owlet SmartSock Integration by jlamendo

  • platform: owlet
    username: !secret owlet_username
    password: !secret owlet_password
    region: "world"
    ####### Owlet attributes test:
  • platform: template
    sensors:
    owlet_heart_rate:
    friendly_name: "Owlet Heart Rate"
    unit_of_measurement: 'bpm'
    value_template: "{{ state_attr('sensor. owlet_smart_sock_ac000w016550878', 'heart_rate') }}"
    ######## Owlet SmartSock Sensors
  • platform: template
    sensors:
    owlet_heart_rate:
    value_template: "{{states.sensor.owlet_smart_sock_ac000w016550878.attributes.heart_rate}}"
    unit_of_measurement: BPM
    owlet_spo2:
    value_template: "{{states.sensor.owlet_smart_sock_ac000w016550878.attributes.oxygen_saturation}}"
    unit_of_measurement: SPO2
    owlet_movement:
    value_template: "{{states.sensor.owlet_smart_sock_ac000w016550878.attributes.movement}}"
    unit_of_measurement: "%"
    owlet_battery:
    value_template: "{{states.sensor.owlet_smart_sock_ac000w016550878.attributes.battery}}"
    unit_of_measurement: "%"
    owlet_rssi:
    value_template: "{{states.sensor.owlet_smart_sock_ac000w016550878.attributes.ble_rssi}}"
    unit_of_measurement: dBm
    owlet_monitoring_status:
    value_template: "{{(states.sensor.owlet_smart_sock_ac000w016550878.attributes.active) and (states.sensor.owlet_smart_sock_ac000w016550878.state == 'Connected')}}"
    unit_of_measurement: boolean
    owlet_connection:
    value_template: "{{states.sensor.owlet_smart_sock_ac000w016550878.state}}"
    unit_of_measurement: boolean
    owlet_tachycardia_alert:
    value_template: "{{states.sensor.owlet_smart_sock_ac000w016550878.attributes.HIGH_HR_ALRT}}"
    unit_of_measurement: boolean
    owlet_bradycardia_alert:
    value_template: "{{states.sensor.owlet_smart_sock_ac000w016550878.attributes.LOW_HR_ALRT}}"
    unit_of_measurement: boolean
    owlet_hypoxia_alert:
    value_template: "{{states.sensor.owlet_smart_sock_ac000w016550878.attributes.LOW_OX_ALRT}}"
    unit_of_measurement: boolean
    owlet_lobatt_alert:
    value_template: "{{states.sensor.owlet_smart_sock_ac000w016550878.attributes.LOW_BATT_ALRT}}"
    unit_of_measurement: boolean
    owlet_read_integrity_alert:
    value_template: "{{states.sensor.owlet_smart_sock_ac000w016550878.attributes.LOW_INTEG_READ}}"
    unit_of_measurement: boolean

The "### Owlet Attributes Test" section was just another failed attempt and creating a sensor a different failed way that I found in some forum but I really don't know enough about coding to know if I have anything wrong. I found another older owlet integration by CAB426 where the login info was placed in the actual configuration.yaml file and I guess it wasn't a sensor. I have all my setup in the sensors.yaml file including the login info. He also had an additional field of "name" to fill in but this one rejects my setup if I add that field. Should I be setting all this up as sensors even including the integration itself and should I give it a "name" field? Also, should I load the integration initially without all of the attribute sensors and then restart with the sensors added after it discovers the base? Should I be manually appending the serial number in each of the sensor attribute fields the way I have? Should I use [brackets] around them like in the example? I assumed I delete those brackets. Sorry for the long question here guys. Any help appreciated. I know its a lack of knowledge of my part but I'm learning a lot about HA with this.

Check out issue #13, I think that you are describing the same issue. This is fixed in the version in my repo. I have suggested that this is brought into the main repo through pull #14, but it has yet to be accepted.

@RampantRedsFan @jacobwtyler
not sure where to ask this question, but you two would likely know since you are still using this... does SPO2 still work via HA?

I can confirm that SpO2 works with sock v3 using the fork in my repo as of 12 hours ago (have not tried since last night my time).
On Thu, May 12, 2022 at 7:13 PM opie546 @.> wrote: @RampantRedsFan https://github.com/RampantRedsFan @jacobwtyler https://github.com/jacobwtyler not sure where to ask this question, but you two would likely know since you are still using this... does SPO2 still work via HA? — Reply to this email directly, view it on GitHub <#15 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACVK3Z4AE2FUFVUAT2OUHXTVJWGA7ANCNFSM5T7N46YA . You are receiving this because you were mentioned.Message ID: @.>
-- Sent from my mobile

awesome! does it work with their app? I thought they were getting rid of that feature

thanks, I am confused because I thought that the v3 is what they are selling right now... when did you buy yours / was it listed as the dream sock?

thanks for that clarification, a US based search makes it more confusing since there is an ad that calls it "All New Owlet Dream Sock - Owlet Smart Sock 3"

This should be fixed in the latest version of the integration

Did anyone buy an Owlet Dream Sock and test it? (I don't understand if Dream Sock = v3)

cvocvo commented

Did anyone buy an Owlet Dream Sock and test it? (I don't understand if Dream Sock = v3)

It does seem to authenticate and pull data for Owlet Dream Sock; not sure if it's actually working though:
#20 (comment)

Edit: it is and does work on the Owlet Dream Sock. It just only shows data when the sock is off of the base station.