pulverization
fun pulverization(config: PulverizationScope.() -> Unit): Either<NonEmptyList<ConfigurationError>, PulvreaktConfiguration>
Entrypoint for the pulverization DSL used to configure the pulverization system.
val configurationResult = pulverization {
val device by logicDevice {
withBehaviour<DeviceBehaviour>() requires setOf(embeddedDevice, highCpu)
withSensors<DeviceSensors>() requires embeddedDevice
withCommunication<DeviceCommunication>() requires setOf(embeddedDevice, highCpu)
}
deployment(infrastructure, MqttProtocol()) {
device(device) {
DeviceBehaviour() startsOn server
DeviceSensors() startsOn smartphone
DeviceCommunication() startsOn smartphone
}
}
}
Content copied to clipboard