Scripted Vehicle - Custom Metrics
I've got some code I've put aside for supporting creating user metrics that might be required for a duktape implementation of a vehicle.
At the moment it is using an unrestricted namespace, but I'm assuming that forcing 'usr.' prefix would be in line with other custom areas (like shell commands).
Thoughts?
Should I check for "usr." prefix and add one if it doesn't have one? Or just reject it?
//.ichael
Actually, custom namespaces for vehicles follow the scheme of a unique minimum 3 letter make/model abbreviation beginning with an 'x'.
"usr" is the reserved namespace for plugins. While duktape vehicles are a hybrid (being plugins as well), I suggest sticking to the vehicle scheme.
Namespace uniqueness across plugins and native vehicles can of course only be guaranteed for vehicles provided via our managed repository (i.e. passing through our review).
Regarding checking/enforcing the prefix, I'd opt for checking, to keep the full names in standard form everywhere -- easier to find & read & maintain.
Regards, Michael
Am 13.09.26 um 05:45 schrieb Michael Geddes via OvmsDev:
I've got some code I've put aside for supporting creating user metrics that might be required for a duktape implementation of a vehicle.
At the moment it is using an unrestricted namespace, but I'm assuming that forcing 'usr.' prefix would be in line with other custom areas (like shell commands).
Thoughts?
Should I check for "usr." prefix and add one if it doesn't have one? Or just reject it?
//.ichael
OvmsDev mailing list -- ovmsdev@lists.openvehicles.com To unsubscribe send an email to ovmsdev-leave@lists.openvehicles.com
-- Michael Balzer * Am Rahmen 5 * D-58313 Herdecke Fon 02330 9104094 * Handy 0176 20698926
participants (2)
-
Michael Balzer -
Michael Geddes