There should be an option to disable or enable a configured device source in the config JSON file. If it's not explicitly enabled or disabled it's always implicitly enabled. When a device source is disabled, it should not be loaded. If the config JSON is updated it should trigger a reload of the device sources and deactivate/activate the ones that were active/inactive before the change of the config has happened.
Like this:
"deviceSources": {
"b6a0f45e-c3d0-4dca-ab81-7daac0764291": {
"id": "b6a0f45e-c3d0-4dca-ab81-7daac0764291",
"type": "slvCtrlPlusSerial",
"enabled": false,
"config": {
}
},
Also devices should be disable-able. If the config JSON is updated it should trigger a check of the devices and deactivate/activate the ones that were active/inactive before the change of the config has happened.
If a new device is detected by a device provider, it should be checked if it's enabled (or enabled is missing, in that case it's implicitly true) and if it's not enabled, it should not be initiated and ignored. If there is a device config change and suddenly a device is enabled that was disabled before, it should be checked if it's connected and be initiated.
Like this:
"knownDevices": {
"ceea37f1-419a-44f4-973c-b51502aa4176": {
"id": "ceea37f1-419a-44f4-973c-b51502aa4176",
"name": "Random Generator",
"type": "randomGenerator",
"source": "virtual",
"enabled": false,
"config": {
"min": 1,
"max": 100
}
},
}
There should be an option to disable or enable a configured device source in the config JSON file. If it's not explicitly enabled or disabled it's always implicitly enabled. When a device source is disabled, it should not be loaded. If the config JSON is updated it should trigger a reload of the device sources and deactivate/activate the ones that were active/inactive before the change of the config has happened.
Like this:
Also devices should be disable-able. If the config JSON is updated it should trigger a check of the devices and deactivate/activate the ones that were active/inactive before the change of the config has happened.
If a new device is detected by a device provider, it should be checked if it's enabled (or enabled is missing, in that case it's implicitly true) and if it's not enabled, it should not be initiated and ignored. If there is a device config change and suddenly a device is enabled that was disabled before, it should be checked if it's connected and be initiated.
Like this: