Hi Alexey
You are right - mapping Modbus to XPCA doesn't make sense. XPCA should really live at a higher level, exposing resources like boilers, switches, etc - not at the lower machine-to-machine level.
The idea with HAL is to allow for auto-discovery of resources as hypermedia / HATEOS resources. I.e. you can examine the links available via an xpca endpoint to reach other resources. In this sense it's more meaningful to compare xpca resources with the notion of 'nodes' in an OPC UA model.
Where XPCA differs from OPC UA is that it is effectively schema-less. I think I need to focus on the value-proposition of XPCA (a simple, lightweight alternative to OPC UA) and forget about low-level stuff. Obviously there needs to be a mapping from Modbus and similar protocols, but that would be the purpose of an XPCA server - effectively hiding all the low-level interaction and presenting a more refined model to be consumed by SCADA interfaces. I think I was looking at
I need to find a "classic" application to model in XPCA and prove the overall concept. I've found a lot of examples for OPC use the same typical boiler / flow control / etc model. I'm not where this comes from, but it seems like a good place to start. Example:
If anyone can think of a better "classic" example to use I'd be interested in knowing more.
On the issue of Thrift vs. Protocol Buffers, in general the latency in HTTP shouldn't be an problem for HMI type applications. If we're using JSON or XML the overhead would be similar to or perhaps less than an OPC UA XML packet. But OPC UA does have a binary format for places where you need higher performance - and I guess I was getting ahead of myself.
In any case, thinking about all this has made me think about other important stuff. This is the first time I've mentioned XPCA being schema-less - because it's the first time I've really thought about it. While I'm not sure that is super important, it raises some possible design issues going forward. For instance, if we say that schema-less models is a design constraint then it rules out both Protocol Buffers and Thrift as a binary format (both are schema-oriented protocols) but it does allow for something like BSON - at the cost of efficiency over the wire.
Whatever the case, I'm still getting way ahead of myself. The next goal should be to create an example project that presents how XPCA should work. The boiler one makes sense, but if there is a better example... It'll make me have to address how XPCA will handle different scenarios, so maybe if we can cover two or three different applications it can help present the case for XPCA better. As a side note, I'm not too keen to compare XPCA to OPC UA too much. I think they serve different purposes. But if there are common models that can be presented side-by-side (like the boiler example) then it will help to demonstrate where XPCA is a better fit and where it isn't.
Cheers
Tom