Commit 6289312a authored by Micha Mueller's avatar Micha Mueller
Browse files

Update README.md: Add section for BACnet plugin

parent 73c03d02
......@@ -391,6 +391,81 @@ Explanation of the values specific for the PDU plugin:
| request | Define the request to be sent to the host via HTTPS as a string. One should put the request in quotation marks (' " ') to enable the use of whitespaces within the request. Special characters (like usage of ' " ' within the request) should be escaped (' " ' --> ' \" '; ' \ ' --> ' \\\\ '; newline --> ' \n '; ...).
| path | Define a dot-separated path to the value to be read in the XML file. One can specify attribute values a node has to fulfil in brackets after the node. Even multiple (comma-separated) attributes can be given, however no whitespaces should be used (!) as they will not be filtered and could therefore be treat as part of the attributes name.
## BACnet
The BACnet plugin enables dcdbpusher to communicate and request data from devices which communicate via the BACnet protocol. A so called "read property" request is sent by the plugin to the BACnet devices as configured in the config file. The response value is then stored in the database. Usually one is only interested in collecting the current reading of a BACnet device (property PROP_PRESENT_VALUE, ID 85). However, also reading of other properties is supported.
> NOTE     On startup BACnet plugin does no device discovery. Instead it relies on the user providing an address_cache file with addresses of all required BACnet devices. One can generate such a address-file for example by using the bacwi demo tool provided by the BACnet-Stack.
### config file format
The config file for the BACnet plugin should fulfill the following scheme:
```
global {
mqttPrefix /FF112233445566778899FFFF
interface eth0
port 22222
apdu_timeout 200
apdu_retries 1
}
templates {
property def0 {
id 85
interval 1000
minValues 3
}
property def1 {
...
}
}
devices {
device dev1 {
instance 1234
mqttPart FF
object o1 {
type 8
instance 1234
mqttPart FF
property test1 {
default def0
id 85
mqttsuffix 0000
}
property smth {
...
}
}
object o2 {
...
}
}
device jklo {
...
}
}
```
Explanation of the values specific for the BACnet plugin:
| Value | Explanation |
|:----- |:----------- |
| interface | Network interface (IPv4) which to use by the plugin to send its "Read Property" requests.
| port | Port to use on the interface
| apdu_timeout | Value of µ-seconds before sending a request times out.
| apdu_retries | How often should sending a request be retried.
| templates | One can define template properties in this section for convenience.
| devices | Starts the part in the config file where the actual BACnet devices are configured. A BACnet device consists of multiple nested parts: device > objects > properties.
| mqttPart | One can define a partial MQTT topic on each nesting level (device, object), which will be appended to the MQTT prefix. Together with the mqttsuffix of a property this will make up the whole MQTT topic of a property (aka sensor). MQTT topic = mqttPrefix + mqttPart (device) + mqttPart (object) + mqttsuffix.
| instance (device) | Instance of the BACnet-device.
| type | Type of the object within the device.
| instance (object) | Instance of the object within the device.
| id | ID of the property to be read from the BACnet device-object. Assignment of numbers to properties is done according to the enum as defined in `bacenum.h`.
#### TODOS
* perhaps xml-file example for pdu
* ipmi, snmp, more about mqtt-topic
\ No newline at end of file
* snmp, more about mqtt-topic
\ No newline at end of file
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment