xtreme rebel wrote: » Does anyone have the instruction on how to pair the receiver for OilPal with the little box inside the house? My reading on the app has been frozen for a few weeks now.
limnam wrote: » They're attached to this posthttps://www.boards.ie/vbulletin/showpost.php?p=108216535&postcount=16
Looks like Oil Pal no longer works.
Email mentioned some licensing issues on whatever the app was running on
Bit disappointing as it had been working very well for me for years and had no fees.
What are people doing who used oil pal doing? is there a way around this that I could send the data to local webserver?
OR is there other subscription free monitors people recommend ?
I was looking at this for my folks place. Haven't got it yet so not sure how good it is but it says it's subscription free.
https://www.kingspan.com/ie/en/products/tank-monitoring-systems/remote-tank-monitoring/watchman-sensit/
This looks interesting.... keep us posted with how you get on!
Also seems to be an active Home Assistant integration.
https://community.home-assistant.io/t/does-anyone-know-a-way-to-get-kingspan-watchman-sensit-oil-tank-sensor-working-with-ha/411111/12
Do you use home assistant? I have the oil pal connected up to HA, still working fine thankfully. Assuming you can still connect to the apollo unit with an internal IP address it should be possible to set up. See https://www.boards.ie/discussion/comment/121012563#Comment_121012563
Thanks for that, yes I can see the diag page. I don't currently use HA. But this gives me a place to start trying out a few things without buying another sensor.
Cheers for that!
Sorry just installed HA to give this a go.
It states on the card no entity exists sensor.oilpaldata and I can see the sensor is not showing in states under dev tools.
Any idea what's missing?
I've the following in configuration.yml
scrape:
- resource: http://192.168.178.xx/diag.htm
scan_interval: 60
sensor:
- name: OilPalData
platform: scrape
resource: http://192.168.178.xx/diag.htm
select: 'table:nth-of-type(2) td:nth-of-type(5)'
unit_of_measurement: 'Litres'
value_template: >-
{% if value is defined %}
{% set modem_values = value.split(' ') %}
{% set tank_temp = modem_values[1] %}
{% if tank_temp != "Data" %}
{% set tank_depth = modem_values[0] | int %}
{% set tank_dimensions = {
"height": 106,
"width": 67,
"length": 175,
} %}
{% set tank_volume = {
"value": (tank_dimensions.height - tank_depth) * tank_dimensions.length * tank_dimensions.width / 1000,
{{ tank_volume.value | round(0) }}
{% else %}
{% if states('sensor.oilpaldata.state') == "" %}
Waiting for first reading
{{ states('sensor.oilpaldata.state') }}
{% endif %}
No value available
Using this in the card
graph: line
entity: sensor.oilpaldata
hours_to_show: 720
icon: mdi:oil
name: OilPal
type: sensor
unit: Litres
detail: 1
Have you the ip address of your sensor in that config?
Or are you just masking it for the forums sake? There is no need to as it is an internal private address.
The real IP is in the config, but I think for the entity to show up in dev tools it wouldn't matter afaik
I presume you know you need to reload after updating a YAML config?
Yep tried reloading/rebooting HA
I have it in configuration.yml
Should the sensor/scraping go into a seperate sensor.yml or is it ok to be in the main config?
It should be fine in one YAML file.
Have you any errors showing up in the system logs?
looks like issue setting up the scraper
2024-01-18 09:19:11.444 ERROR (MainThread) [homeassistant.components.sensor] Error while setting up scrape platform for sensor
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 360, in _async_setup_platform
await asyncio.shield(task)
File "/usr/src/homeassistant/homeassistant/components/scrape/sensor.py", line 60, in async_setup_platform
coordinator: ScrapeCoordinator = discovery_info["coordinator"]
~~~~~~~~~~~~~~^^^^^^^^^^^^^^^
TypeError: 'NoneType' object is not subscriptable
To me it looks like you probably have some indentation issues, but surprised they are not being reported by HA.
It could just be Boards messing up the format though. There is a code block option that is better for sharing code.
scrape: - resource: http://192.168.178.xx/diag.htm scan_interval: 60 # this is not correct indentation sensor: - name: OilPalData platform: scrape resource: http://192.168.178.xx/diag.htm # this is not correct indentation select: 'table:nth-of-type(2) td:nth-of-type(5)' unit_of_measurement: 'Litres' value_template: >- {% if value is defined %} {% set modem_values = value.split(' ') %} {% set tank_temp = modem_values[1] %} {% if tank_temp != "Data" %} {% set tank_depth = modem_values[0] | int %} {% set tank_dimensions = { "height": 106, "width": 67, "length": 175, } %} {% set tank_volume = { "value": (tank_dimensions.height - tank_depth) * tank_dimensions.length * tank_dimensions.width / 1000, } %} {{ tank_volume.value | round(0) }} {% else %} {% if states('sensor.oilpaldata.state') == "" %} Waiting for first reading {% else %} {{ states('sensor.oilpaldata.state') }} {% endif %} {% endif %} {% else %} No value available {% endif %}
resource and scan interval are between valid indents
You may be better off contacting the Poster from the other thread and ask him to send in a text file.
Edit: maybe worth a look too
https://community.home-assistant.io/t/oilpal-watchman-ultrasonic-oil-tank-level-reading-for-home-assistant/113134
Yeah I had originally thought it was indenting, but any yaml config checker seems to pass and it "works" in the template. e.g. the result seems to be correct when testing in dev tools/templating.
thanks for looking at it. I'll read the thread and hammer away a bit more at it
On the indentation, the two lines marked out of indentation above are out by one space and are failing for me. One space in either direction would make it pass the test for indentation test but would have very different results. So you can have valid indentation but still not be right indentation for your use case.
But like I said that could be just boards reformatting it after you pasted the code. Also likely to have happened with the original poster as they also did not use the code formatting option.
whats the code tags and i'll try post it again ?
It should look more like this.
Everytime a statement is a child of another statement it should step in 2 spaces.
e.g.everytime there is an if statement it should step in 2 spaces.
scrape: - resource: http://192.168.178.60/diag.htm scan_interval: 60 sensor: - name: OilPalData platform: scrape resource: http://192.168.178.xx/diag.htm # this is not correct indentation select: 'table:nth-of-type(2) td:nth-of-type(5)' unit_of_measurement: 'Litres' value_template: >- {% if value is defined %} {% set modem_values = value.split(' ') %} {% set tank_temp = modem_values[1] %} {% if tank_temp != "Data" %} {% set tank_depth = modem_values[0] | int %} {% set tank_dimensions = { "height": 106, "width": 67, "length": 175, } %} {% set tank_volume = { "value": (tank_dimensions.height - tank_depth) * tank_dimensions.length * tank_dimensions.width / 1000, } %} {{ tank_volume.value | round(0) }} {% else %} {% if states('sensor.oilpaldata.state') == "" %} Waiting for first reading {% else %} {{ states('sensor.oilpaldata.state') }} {% endif %} {% endif %} {% else %} No value available {% endif %}
Can't say the above is completely right, I just went through it by eye but I'd say it's closer.
@limnam it's like quoting, just select code block
This is what mine looks like. The file editor in HA shows some detail on the indents which helps
Thanks guys,
This is how it looks currently. This is from emaherx last edit
scrape: - resource: http://192.168.178.60/diag.htm scan_interval: 60 sensor: - name: OilPalData platform: scrape resource: http://192.168.178.60/diag.htm select: 'table:nth-of-type(2) td:nth-of-type(5)' unit_of_measurement: 'Litres' value_template: >- {% if value is defined %} {% set modem_values = value.split(' ') %} {% set tank_temp = modem_values[1] %} {% if tank_temp != "Data" %} {% set tank_depth = modem_values[0] | int %} {% set tank_dimensions = { "height": 106, "width": 67, "length": 175, } %} {% set tank_volume = { "value": (tank_dimensions.height - tank_depth) * tank_dimensions.length * tank_dimensions.width / 1000, } %} {{ tank_volume.value | round(0) }} {% else %} {% if states('sensor.oilpaldata.state') == "" %} Waiting for first reading {% else %} {{ states('sensor.oilpaldata.state') }} {% endif %} {% endif %} {% else %} No value available {% endif %}
I've updated to match tipp's but still seems to be the same issue
Error while setting up scrape platform for sensorTraceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 360, in _async_setup_platform await asyncio.shield(task) File "/usr/src/homeassistant/homeassistant/components/scrape/sensor.py", line 60, in async_setup_platform coordinator: ScrapeCoordinator = discovery_info["coordinator"] ~~~~~~~~~~~~~~^^^^^^^^^^^^^^^ TypeError: 'NoneType' object is not subscriptable
scrape: - resource: http://192.168.178.60/diag.htm sensor: - name: OilPalData select: 'table:nth-of-type(2) td:nth-of-type(5)' unit_of_measurement: 'Litres' value_template: >- {% if value is defined %} {% set modem_values = value.split(' ') %} {% set tank_temp = modem_values[1] %} {% if tank_temp != "Data" %} {% set tank_depth = modem_values[0] | int %} {% set tank_dimensions = { "height": 106, "width": 67, "length": 175, } %} {% set tank_volume = { "value": (tank_dimensions.height - tank_depth) * tank_dimensions.length * tank_dimensions.width / 1000, } %} {{ tank_volume.value | round(0) }} {% else %} {% if states('sensor.oilpaldata.state') == "" %} Waiting for first reading {% else %} {{ states('sensor.oilpaldata.state') }} {% endif %} {% endif %} {% else %} No value available {% endif %} scan_interval: 60
Try going with @tipperary's config completely if it's working.
It looks like very similar but setup for a round tank rather than a square one, but at least if you had it working then you could re-try modding just the calculation.
Your error suggests a function is trying to return a value of 'none' it could be in the recalculation of volume between scraping the page and calculating the result based in litres.
Have you ever used Node-Red, it is usually easier to debug.
Depending how you set up your HA, you may need to install libxml2. See:
Hi folks
Finally got HA to read the OilPal sensor and things are looking good!
Wanted to check if anyone has enhanced it further to display additional information, or some nice looking charts etc.?
I like how c0rnflake uses ApexCharts here but he didn't post the config, although I have just pinged him to see if he could. Curious to see if any of you have done anything interesting.
Thanks!
I've tried his exact config also and get the same error.
Not sure what node-red is, this is my first time trying to use HA