HELIO Messaging API v0
Date
to null
.acknowledgeMessage
receives an argument that is not PLC-conformantIn version 0, the acknowledgeMessage
method defines a parameter named messageId
. However, the actual parameter is not a single id, but a JSON array that includes one messageId
. This appears to cause problems with certain PLCs.
<aside> <img src="/icons/light-bulb_gray.svg" alt="/icons/light-bulb_gray.svg" width="40px" /> Desired Solution
Send only a single messageId
as String variable:
→ acknowledgeMessage(messageId:string)
</aside>
acknowledgedOn
to be nullableMarking a message as incoming/active requires the PLC to set the acknowledgedOn
variable which is of type Date
to Null
. This cannot be achieved on some PLCs.
<aside> <img src="/icons/light-bulb_gray.svg" alt="/icons/light-bulb_gray.svg" width="40px" /> Desired Solution
boolean
property for messages called wasAcknowledged
which has to be set to false if the message is incoming and to true if the message has been acknowledged.Before
interface message {
acknowledgedOn: Date | Null;
arrivedOn: Date;
canAcknowledge: boolean;
...
}
After
interface Message {
// Initial value: false
// Once acknowleged: true
WasAcknowledged: boolean;
// Initial value: Same as ArrivedOn
// Once acknowleged: Date of Acknowledgement
AcknowledgedOn: Date;
ArrivedOn: Date;
CanAcknowledge: boolean;
...
}
</aside>
All methods (e.g. acknowledgeMessage
) or properties (message.id
etc.) of messages are defined in camelCase while PascalCase is the default way to name things – at least in OPC UA. In order to avoid confusion we should follow this way.
<aside> <img src="/icons/light-bulb_gray.svg" alt="/icons/light-bulb_gray.svg" width="40px" /> Desired Solution
Make all methods, properties and parameters pascal case.
</aside>