[Ovmsdev] Addition to OVMS Developer Guide
Michael Balzer
dexter at expeedo.de
Sun Jan 3 21:21:54 HKT 2021
Steve,
Am 02.01.21 um 07:20 schrieb Stephen Casner:
>> I wasn't aware of the tab completion on "event raise"... I normally use the
>> command to raise custom events only. I'll fix that.
> Are those custom events not registered? RegisterEvent() adds events
> to m_map which makes them available for tab completion.
I've pushed the fix, but think it's still wrong to use the callback
registration map to validate events without filtering out "*". While you
technically may send "*" as an event, it isn't meant to be used that
way, just gets added to the map because of the "any event" listeners.
Regarding your question: custom events normally will not have a
registered listener on the module. Event scripts do not register a
native callback, the same applies to Javascript event subscriptions and
events transported via the network to clients (e.g. web plugins or an
MQTT listener). These are the main applications for custom events.
Regards,
Michael
--
Michael Balzer * Helkenberger Weg 9 * D-58256 Ennepetal
Fon 02333 / 833 5735 * Handy 0176 / 206 989 26
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature
Type: application/pgp-signature
Size: 203 bytes
Desc: OpenPGP digital signature
URL: <http://lists.openvehicles.com/pipermail/ovmsdev/attachments/20210103/e76105e5/attachment.sig>
More information about the OvmsDev
mailing list