One of the concepts in Plain and BSA is that you develop distributed system, not a single application or device. Meaning that state diagrams and logic can relate to a list of modules that are located either on HMI, on some server or a device distributed in a network. Both PLD and UML State Diagrams support this.
To enable this we will need to maintain a list of modules. A module is a functional module where you decide where you want this located by simply selecting platform from a list. This also means that you with a single click can move modules between platforms. Obviously we also need a definition of Nodes so we can describe the system we develop and a target platform selection – the later is static, build-in for now. It get a bit complicated, but the concept will save a big bulk of development hours by reducing complexity for the developer.
And here comes the trick called RPC (Remote Procedure Call). If PLD make a function call that call will need to adapt to wherever the module is local or on a remote node. If a function is local you simply make a standard local call, but if a function is remote it needs to convert into a message that is sent and wait for response (or timeout). The developer need to be aware of this, so function calls needs to be enabled for RPC as they are called.
Module is the key here because this also means that the repository needs to be structured around modules as the root component – something that goes hand in hand with how Plain is designed and works well for all other target languages.
Another level that is BSA specific is that we need to be able to load multiple projects. This will enable BSA to copy modules between projects or use library projects. Now this creates a new requirement as we need to keep track of dependencies between projects.
Going back to the discussion wherever I should use WPF or QML I think the discussion above tells it all. I have only worked a few days in WPF and are straight back into BSA functionality rather than HMI “How To”. Integration between XAML and C# is much easier to deal with than fighting the complexity of QML. That said I still miss some of the good things about QML so it is not a black/white discussion!