ha_octopus_intelligent icon indicating copy to clipboard operation
ha_octopus_intelligent copied to clipboard

Turn off delay

Open harleyhousehunt opened this issue 2 years ago • 10 comments

HI, hope someone can help, Integration is working with switch on @ 23:31:01s but does not turn off until 05:31:21s is there something I can do to get the turn off nearer the correct time of 05:30:00?

harleyhousehunt avatar Nov 06 '22 07:11 harleyhousehunt

Hi, I am seeing exactly the same problem with the turn off time. Unfortunately I have seen delays of a little over 5 minutes in recent days using v1.6.0

Brain1000 avatar Jan 21 '23 10:01 Brain1000

Me too - I’m seeing the same issue. Turned off at 5:34:06 seconds this morning for the end of the 5:30 period.

dmelliott20 avatar Feb 02 '23 07:02 dmelliott20

I know Ecoenomy 7 timers stagger their on and off timers so that the grid does not get massive dips and spikes at exactly turn on/off time. Maybe Octopus as doing the same and staggering start and stoptimes to prevent all cars starting and stopping at 23:30 and 05:30 Although im not sure how a smart meter will handle that

bashers222 avatar Feb 24 '23 11:02 bashers222

@harleyhousehunt @Brain1000 @bashers222 I use a template sensor for this, which is always 3 minutes before the end of the next off-peak period. I base my automations off this value. This allows time for things to settle before the end of the off-peak slot (the Tesla Powerwall takes a couple of minutes to stop drawing from the grid sometimes). Here's my sensor:

{{(as_datetime(states('sensor.octopus_intelligent_offpeak_end')) - timedelta(minutes=3))}}

craigrouse avatar Mar 03 '23 12:03 craigrouse

Great idea

On 3 Mar 2023, at 12:14, Craig Rouse @.***> wrote:



@harleyhousehunthttps://github.com/harleyhousehunt @Brain1000https://github.com/Brain1000 @bashers222https://github.com/bashers222 I use a template sensor for this, which is always 3 minutes before the end of the next off-peak period. I base my automations off this value. This allows time for things to settle before the end of the off-peak slot (the Tesla Powerwall takes a couple of minutes to stop drawing from the grid sometimes). Here's my sensor:

{{(as_datetime(states('sensor.octopus_intelligent_offpeak_end')) - timedelta(minutes=3))}}

— Reply to this email directly, view it on GitHubhttps://github.com/megakid/ha_octopus_intelligent/issues/6#issuecomment-1453445413, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ADELRFOJ6AS7QPPJRHZHAHDW2HOCJANCNFSM6AAAAAARYJOAM4. You are receiving this because you commented.Message ID: @.***>

dmelliott20 avatar Mar 03 '23 20:03 dmelliott20

I've adjusted my polling period in the code to 1 minute and it seems better now, it was set to 3 minutes previously. Ideally this would be a config option and not hard-wired.

springfall2008 avatar Mar 24 '23 08:03 springfall2008

Can you point me to where you’ve done that?

On 24 Mar 2023, at 08:15, Trefor Southwell @.***> wrote:



I've adjusted my polling period in the code to 1 minute and it seems better now, it was set to 3 minutes previously. Ideally this would be a config option and not hard-wired.

— Reply to this email directly, view it on GitHubhttps://github.com/megakid/ha_octopus_intelligent/issues/6#issuecomment-1482415076, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ADELRFOAFO6E3JRZOMKQNEDW5VJ2ZANCNFSM6AAAAAARYJOAM4. You are receiving this because you commented.Message ID: @.***>

dmelliott20 avatar Mar 24 '23 08:03 dmelliott20

In octopus_intelligent_system.py (config/custom_components/ocotopus_intelligent):

class OctopusIntelligentSystem(DataUpdateCoordinator): def init(self, hass, *, api_key, account_id, off_peak_start, off_peak_end): super().init( hass, _LOGGER, # Name of the data. For logging purposes. name="Octopus Intelligent", # Polling interval. Will only be polled if there are subscribers. update_interval=timedelta(seconds=120),

springfall2008 avatar Mar 24 '23 08:03 springfall2008

Actually I set it to 2 minutes, I think it was set to 5!

springfall2008 avatar Mar 24 '23 08:03 springfall2008

Given it likely won't update until :30 and :00, could it poll at these times too? Then the polling time doesn't matter for this purpose at least.

Also if using offpeak_end, don't forget to add .astimezone(): {{ as_datetime(states('sensor.octopus_intelligent_offpeak_end')).astimezone() - timedelta(minutes=3) }}

steelixb avatar Jun 07 '23 08:06 steelixb