This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm that you accept these cookies being set.

BACnet address mapping
#4
Hello Admin,

I have to read 173 Analog Inputs (energy monitoring) from a BACnet server and I am looking to do it with a scheduled script that runs every 15'. 
I tested this and got a nice table in the log. 
Code:
    require('bacnet')
    device, objects = bacnet.scandevice(1)
 
    log(objects)

Trigger HVAC BACnet Polling (32/0/1) 08.05.2024 13:53:13
* table:
[1]
  * table:
  ["present-value"]
    * string: 59932.000000
  ["id"]
    * number: 1
  ["out-of-service"]
    * bool: false
  ["overridden"]
    * bool: false
  ["identifier"]
    * number: 118
  ["description"]
    * string: Mtr - Watervoeding ZKW 15F.. - Cumulated volume
  ["type"]
    * string: analog input
  ["name"]
    * string: B_02'S_EBHVAC'Plt'MtrWa(14)'CumVlm
  ["fault"]
    * bool: false
  ["in-alarm"]
    * bool: false
[2]
  * table:
  ["present-value"]
    * string: 5490.000000
  ["id"]
    * number: 2
  ["out-of-service"]
    * bool: false
  ["overridden"]
    * bool: false
  ["identifier"]
    * number: 119
  ["description"]
    * string: Mtr - Voeding verzacht labowater - Cumulated volume
  ["type"]
    * string: analog input
  ["name"]
    * string: B_02'S_EBHVAC'Plt'MtrWa(20)'CumVlm
  ["fault"]
    * bool: false
  ["in-alarm"]
    * bool: false


What I want to achieve is to access only the analog input objects and write the value to a knx group address.
  • Could you provide a nice example of how can I access only the objects with ["type"] analog input and get then the ["present-value"] and write it to the knx bus on the object with the same name as the ["description"] filed?
  • Is there a way to use this nice table data and create automatically all KNX objects based on the  ["description"] so copy the string and set as name to the knx object? In most cases Units are kWh and l (liters) but I have also °C (temperature) which I would like to recieve as 2byte float in the KNX.

Regards
Reply


Messages In This Thread
BACnet address mapping - by Osvaldas - 12.12.2023, 10:40
RE: BACnet address mapping - by admin - 12.12.2023, 10:57
RE: BACnet address mapping - by Osvaldas - 20.12.2023, 14:19
RE: BACnet address mapping - by manos@dynamitec - 08.05.2024, 12:55
RE: BACnet address mapping - by Daniel - 08.05.2024, 13:08
RE: BACnet address mapping - by admin - 08.05.2024, 13:50

Forum Jump: