Skip to content

Commit

Permalink
Upgrade libraries & README (#42)
Browse files Browse the repository at this point in the history
### Add
  - Add SparkplugB topic and payload details to README

### Change
  - Bump Revision from v2.0.3 to v2.0.4
  - Change mqtt from 4.2.8 to 4.3.8
  - Change sonarqube-scanner from 2.8.1 to 2.9.1
  - Change sparkplug-client from 3.2.2 to 3.2.4
  - Change winston from 3.3.3 to 3.13.0
 
---------

Co-authored-by: Tom Hollingworth <[email protected]>
  • Loading branch information
tomhollingworth and Tom Hollingworth authored May 13, 2024
1 parent ed9177b commit 5e66ab1
Show file tree
Hide file tree
Showing 7 changed files with 2,057 additions and 1,981 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ LABEL org.opencontainers.image.authors="[email protected]"
LABEL org.opencontainers.image.source="https://github.com/Spruik/PackML-MQTT-Simulator"
LABEL org.opencontainers.image.url="https://spruiktec.com/"
LABEL org.opencontainers.image.vendor="Spruik Technologies LLC"
LABEL org.opencontainers.image.version="2.0.3"
LABEL org.opencontainers.image.version="2.0.4"

WORKDIR /machine

Expand Down
16 changes: 14 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ $ docker run -it -e CLIENT_TYPE=sparkplugb -e SITE=Site -e AREA=Area -e LINE=Lin
2020-06-22T03:13:49.819Z | info: Site/Area/Line/Status/UnitModeCurrent : Production
```

Once up and running, use an Sparkplug B device commands to publish to `Command.Reset` and `Command.Start` metrics to get the simulated machine into the execute state.
Once up and running, use an Sparkplug B device commands to publish to `Command/Reset` and `Command/Start` metrics to get the simulated machine into the execute state. The topic in the above example is: `spBv1.0/Site/DCMD/Area/Line`.

### Node

Expand Down Expand Up @@ -192,7 +192,11 @@ Available Admin Status

## Interfacing via SparkplugB v1.0

Refer to the [Sparkplug B Payload and Topic Payload Definition Specification](https://www.eclipse.org/tahu/spec/Sparkplug%20Topic%20Namespace%20and%20State%20ManagementV2.2-with%20appendix%20B%20format%20-%20Eclipse.pdf).
Refer to the [Sparkplug B Payload and Topic Payload Definition Specification](https://www.eclipse.org/tahu/spec/Sparkplug%20Topic%20Namespace%20and%20State%20ManagementV2.2-with%20appendix%20B%20format%20-%20Eclipse.pdf).

The simulator creates a device and listens to the device commands message (DCMD) topic with metrics representing the available commands without the `<SITE>/<AREA>/<LINE>/` prefix. Consider the command topic `<SITE>/<AREA>/<LINE>/Command/Reset`, when writing as a SparkplugB device command message use the metric name `Command/Reset`. Publishing device command messages are published against `spBv1.0/<SPARKPLUG_GROUP_ID>/DCMD/<SPARKPLUG_EDGE_NODE>/<LINE>` based on site environmental variables.

The simulator will also rebirth when requested at the node level by publishing to `spBv1.0/<SPARKPLUG_GROUP_ID>/NCMD/<SPARKPLUG_EDGE_NODE>` with a metric `Node Control/Rebirth` and a true value.

Below is an example of publishing to Igniition v8.1.5 SCADA with Cirrus Link Modules. The MQTT Engine was configured with the corresponding namespace filter for the simulation environmental variables.

Expand Down Expand Up @@ -295,6 +299,14 @@ For any issue, there are fundamentally three ways an individual can contribute:

## Changelog

- 2.0.4
- Update README
- Update mqtt from 4.2.8 to 4.3.8
- Update sonarqube-scanner from 2.8.1 to 2.9.1
- Update sparkplug-client from 3.2.2 to 3.2.4
- Update winston from 3.3.3 to 3.13.0
- Bump Revision

- 2.0.3
- Update path-parse from 1.0.6 to 1.0.7
- Change README run command env. variable MQTT_HOST to MQTT_URL
Expand Down
2 changes: 1 addition & 1 deletion chart/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ name: packml-sim
description: PackML Machine Simulator
type: application
version: 0.0.2
appVersion: 2.0.3
appVersion: 2.0.4
Loading

0 comments on commit 5e66ab1

Please sign in to comment.