OPC UA CAR SERVER with NodeOPCUA

February 16, 2024 · View on GitHub

A simple server that represents a car with the follow structure:

  • Car (obj)
    • Speed (attr)
    • Accelerate (meth)
    • Stop (meth)
    • Engine (obj)
      • Temperature (attr)
      • Oxygen (attr)
      • Pressures (attr)
    • Sensors
      • Any number of user-defined sensors

Car Schema

Install from source

$ git clone "https://github.com/Engineering-Research-and-Development/opc-ua-car-server"
$ cd opc-ua-car-server
$ npm install --unsafe-perm
$ node car.js

Car model behavioural specs

Motion StatusEngineAccelerationOxigenTemperaturePressuresSpeed
StoppedOff00Environmental 20 °C[0,0,0]0
StoppedOn05Tends to 80 °CTends to [100,100,100]0
AcceleratedOn> 0Varies with speed. When the acceleration increases an overshoot is triggered, otherwise if acceleration decreases an undershoot is triggered.Tends to 80 °CTends to [100,100,100]Varies with acceleration
ConstantOn0ConstantTends to 80 °CTends to [100,100,100]Constant
DeceleratedOn< 0Varies with speedTends to 80 °CTends to [100,100,100]Varies with deceleration
In motion (Decelerated)Off00 (Transmission Neutral / Engine Brake)Tends to 20 °CTends to [0,0,0]Tends to 0
From decelerated to constantOff -> On0Follows the current speedTends to 80 °CTends to [100,100,100]Constant