[Ovmsdev] Levels of poller states

Chris Box chris8086 at ee.eclipse1.net
Tue Feb 25 06:17:01 HKT 2025


On 2025-02-24 01:46, Michael Geddes wrote:

> The one that matters most is OvmsPoller::m_poll_state - as that is the 
> one used in processing.  It is possible to set this separately per bus.

That makes sense.

> The one at OvmsPollers level is there if you choose to keep one 
> 'poll-state' and so set the values on all busses together... which is 
> normally the case.  It's mostly there so multiple calls to setting 
> poll-state without actually changing the poll-state will not actually 
> have to queue calls.

And that also makes sense, as a common performance optimisation.

> The one at OvmsVehicle is there because that used to be where it sat.  
> It's still there for reading convenience and for non-blocking access to 
> the value.. but it really should always just be a reference copy of the 
> m_poll_state on OvmsPollers.

I see. Yes, I agree it would be better to remove it as a separate 
variable. I don't plan to work on that myself, but I'll use your 
description in helping to understand the Leaf's state management. Thank 
you.

Chris
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openvehicles.com/pipermail/ovmsdev/attachments/20250224/afbcb8f6/attachment.htm>


More information about the OvmsDev mailing list