Closed craig8 closed 2 years ago
See examples at https://github.com/VOLTTRON/volttron-core/tree/main/volttron/services for guide on how to organize the PlatformDriverAgent and drivers as standalone repos.
Below is a UML diagram of the current DriverFramework.
driver_framework_uml__current.txt
Also, below is a more high-level UML of the current DriverFramework:
Since platform.driver is the only agent we will install with a agent vip identity and the rest of the driver specific packages are only libraries that don't get its only agent dir under $VOLTTRON_HOME, I propose the following steps to setup drivers
vctl install volttron-platform-driver --vip-identity=platform.driver --config platform_agent_config.json
vctl install bacnet_proxy_agent (pip install volttron-bacnet-driver)
pip install volttron-modbus-driver
vctl config store platform.driver registry.config /path/to/registry.config --csv
vctl config store platform.driver devices/campus1/building1/bacnet_device1 bacnet_device_config.json
vctl config store platform.driver registry.config /path/to/registry2.config --csv
vctl config store platform.driver devices/campus1/building1/modbus_device1 modbus_device_config.json
All code can be in the same repository - or some combination of drivers in one repo and all unsupported drivers in its own individual repository - as long as we push different wheels - one for base platform.driver (with all the base classes, interfaces etc), and one for each driver type
Possible option -
vctl install <package_name/local whl/local dir> --vip-identity platform.driver --config platform_agent_config.json --dependency volttron-bacnetproxy, volttron-modbus-driver,
For developer working on say, volttron-modbus-driver:
vctl install volttron-platform-driver --vip-identity=platform.driver --config platform_agent_config.json git clone https://github.com/volttron/volttron-modbus-driver make changes to code poetry install (this will generate a whl and install it in your current python environment) vctl config store platform.driver registry.config /path/to/registry2.config --csv vctl config store platform.driver devices/campus1/building1/modbus_device1 modbus_device_config.json vctl start platform.driver
Based on yesterday's meeting with @schandrika and the team, below is a proposed diagram of breaking apart the Driver Framework into modular components:
@bonicim I don't think 2030.5 will be part of driver framework. It's a separate agent.
@bonicim I don't think 2030.5 will be part of driver framework. It's a separate agent.
Ah, ok. I'll pick a different driver to highlight the use of the "Revert" class.
The packages should all be from volttron.drivers That will be the dynamic package that is loaded by the framework.
Completed by #8