@thehighestbit/node-red-contrib-ipc-cfx 1.0.3

A node red node for communicating with AMQP brokers using the IPC-CFX protocol. Uses the official .NET SDK.

npm install @thehighestbit/node-red-contrib-ipc-cfx

node-red-contrib-ipc-cfx

A Node-RED node for interfacing with the official IPC-CFX .NET SDK.

Installation

First make sure the host system has .NET Core 9.x installed. Then simply install this node

npm install @thehighestbit/node-red-contrib-ipc-cfx

Configuration

Configuration node

First configure the endpoint config node, specifying the desired endpoint handle (eg. someManufacturer.someMachine.someSerial) and broker URI (eg. amqp://guest:guest@localhost).

CFX in

Pick the desired endpoint configuration and then specify the desired queues (eg. myQueue) this node should subscribe to. Please note that there can only be a single CFX in node per endpoint configuration. This is because there can only be a single message listener per endpoint and thus all in nodes produce the same messages regardless of what channels they are subscribed to.

CFX out

Pick the desired endpoint configuration and then specify the desired AMQP target that this node should publish its messages to (eg. /exchange/CFXExchange). There can be as many out nodes per endpoint as you wish, since the SDK supports publishing messages on a per channel basis.

Usage

CFX in

This node simply forwards the received CFX envelope inside of the msg.payload field.

CFX out

The node expects the msg.payload to be a JSON object that can be serialized into a valid IPC-CFX message. Additionally, the $type property must also be included, otherwise the serialization will fail. For example:

    {
        "$type": "CFX.ResourcePerformance.ProcessDataRecorded, CFX",
        "ProcessData": {
            "$type": "CFX.Structures.Cleaning.CleaningManagementData, CFX",
            "Readings": [
            {
                "ReadingType": "TemperatureMin",
                "ReadingValue": 345
            }
            ]
        }
    }

The outer type field ("$type": "CFX.ResourcePerformance.ProcessDataRecorded, CFX" in the above example) must always be present. Additionally, if the contained data is ambiguous (like in the above example), the type for that needs to be included as well.

If the message is not valid CFX, an error will be thrown.

Node Info

Version: 1.0.3
Updated 1 week, 2 days ago
License: ISC
Rating: not yet rated

Categories

Actions

Rate:

Downloads

195 in the last week

Nodes

  • ipc-cfx-in
  • ipc-cfx-out
  • ipc-cfx-config

Keywords

  • node-red
  • ipc-cfx
  • CFX
  • .NET
  • SDK

Maintainers