dsm-api-v2
Typedefs | Functions
Circuit

This group of API calls addresses functions and properties of the whole circuit attached to the dSM. More...

Typedefs

typedef void(* CircuitCurrentMeterValue_get_request_callback_t )(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)
 Return the current active and reactive power metering values.
typedef void(* CircuitCurrentMeterValue_get_response_callback_t )(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId, uint16_t PowerW, uint16_t PowerQ, uint16_t Phi)
 Return the current active and reactive power metering values.
typedef void(* CircuitEnergyMeterValue_calibration_request_callback_t )(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)
 Read the values necessary for metering calibration.
typedef void(* CircuitEnergyMeterValue_calibration_response_callback_t )(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId, uint16_t Uaverage, uint16_t I14average, uint16_t I180average, uint32_t PActiveLow, uint32_t PActiveHigh)
 Read the values necessary for metering calibration.
typedef void(* CircuitEnergyMeterValue_get_request_callback_t )(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)
 Return the current energy and power metering values.
typedef void(* CircuitEnergyMeterValue_get_response_callback_t )(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId, uint32_t PowerW, uint32_t EnergyWh)
 Return the current energy and power metering values.
typedef void(* CircuitEnergyMeterValue_reset_request_callback_t )(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)
 Return the current energy and power metering values.
typedef void(* CircuitEnergyMeterValue_reset_response_callback_t )(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId, uint32_t PowerW, uint32_t EnergyWh)
 Return the current energy and power metering values.
typedef void(* CircuitEnergyMeterValue_Ws_get_request_callback_t )(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)
 Return the current energy and power metering values.
typedef void(* CircuitEnergyMeterValue_Ws_get_response_callback_t )(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId, uint32_t PowerW, uint32_t EnergyWs)
 Return the current energy and power metering values.
typedef void(* CircuitPingDevices_automatic_request_callback_t )(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId, uint16_t IntervalTime)
 Dynamically change the behavior of the pinging of devices.
typedef void(* CircuitPingDevices_automatic_response_callback_t )(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)
 Dynamically change the behavior of the pinging of devices.
typedef void(* CircuitPingDevices_off_request_callback_t )(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)
 Dynamically change the behavior of the pinging of devices.
typedef void(* CircuitPingDevices_off_response_callback_t )(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)
 Dynamically change the behavior of the pinging of devices.
typedef void(* CircuitPingDevices_one_time_automatic_request_callback_t )(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId, uint16_t OneTimeIntervalTime, uint16_t AutoIntervalTime)
 Dynamically change the behavior of the pinging of devices.
typedef void(* CircuitPingDevices_one_time_automatic_response_callback_t )(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)
 Dynamically change the behavior of the pinging of devices.
typedef void(* CircuitPingDevices_one_time_off_request_callback_t )(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId, uint16_t IntervalTime)
 Dynamically change the behavior of the pinging of devices.
typedef void(* CircuitPingDevices_one_time_off_response_callback_t )(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)
 Dynamically change the behavior of the pinging of devices.

Functions

int CircuitCurrentMeterValue_get (DsmApiHandle_t handle, dsid_t dSMdSID, uint16_t *PowerW, uint16_t *PowerQ, uint16_t *Phi)
 Return the current active and reactive power metering values.
int CircuitEnergyMeterValue_calibration (DsmApiHandle_t handle, dsid_t dSMdSID, uint16_t *Uaverage, uint16_t *I14average, uint16_t *I180average, uint32_t *PActiveLow, uint32_t *PActiveHigh)
 Read the values necessary for metering calibration.
int CircuitEnergyMeterValue_get (DsmApiHandle_t handle, dsid_t dSMdSID, uint32_t *PowerW, uint32_t *EnergyWh)
 Return the current energy and power metering values.
int CircuitEnergyMeterValue_reset (DsmApiHandle_t handle, dsid_t dSMdSID, uint32_t *PowerW, uint32_t *EnergyWh)
 Return the current energy and power metering values.
int CircuitEnergyMeterValue_Ws_get (DsmApiHandle_t handle, dsid_t dSMdSID, uint32_t *PowerW, uint32_t *EnergyWs)
 Return the current energy and power metering values.
int CircuitPingDevices_automatic (DsmApiHandle_t handle, dsid_t dSMdSID, uint16_t IntervalTime)
 Dynamically change the behavior of the pinging of devices.
int CircuitPingDevices_off (DsmApiHandle_t handle, dsid_t dSMdSID)
 Dynamically change the behavior of the pinging of devices.
int CircuitPingDevices_one_time_automatic (DsmApiHandle_t handle, dsid_t dSMdSID, uint16_t OneTimeIntervalTime, uint16_t AutoIntervalTime)
 Dynamically change the behavior of the pinging of devices.
int CircuitPingDevices_one_time_off (DsmApiHandle_t handle, dsid_t dSMdSID, uint16_t IntervalTime)
 Dynamically change the behavior of the pinging of devices.

Detailed Description

This group of API calls addresses functions and properties of the whole circuit attached to the dSM.


Typedef Documentation

typedef void(* CircuitCurrentMeterValue_get_request_callback_t)(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)

Return the current active and reactive power metering values.

Also calculated phase.

Request callback function prototype for call CircuitCurrentMeterValue_get.

To register this callback function, call the DsmApiSetCallback function with MessageType = DS485_CONTAINER_REQUEST, MessageId = CIRCUIT_CURRENT_METER_VALUE and ModifierId = CIRCUIT_CURRENT_METER_VALUE_GET

Parameters:
[in]errorError result of the (potential) previous call.
[in]argUser data
[in]sourceIdSource address of the call
[in]destinationIdDestination address of the call
typedef void(* CircuitCurrentMeterValue_get_response_callback_t)(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId, uint16_t PowerW, uint16_t PowerQ, uint16_t Phi)

Return the current active and reactive power metering values.

Also calculated phase.

Response callback function prototype for call CircuitCurrentMeterValue_get.

To register this callback function, call the DsmApiSetCallback function with MessageType = DS485_CONTAINER_RESPONSE, MessageId = CIRCUIT_CURRENT_METER_VALUE and ModifierId = CIRCUIT_CURRENT_METER_VALUE_GET

Parameters:
[in]errorError result of the (potential) previous call.
[in]argUser data
[in]sourceIdSource address of the call
[in]destinationIdDestination address of the call
[in]PowerWCurrent active power [W].
[in]PowerQCurrent reactive power [var].
[in]PhiPhase [rad] (multiplied with 2^14).
typedef void(* CircuitEnergyMeterValue_calibration_request_callback_t)(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)

Read the values necessary for metering calibration.

Request callback function prototype for call CircuitEnergyMeterValue_calibration.

To register this callback function, call the DsmApiSetCallback function with MessageType = DS485_CONTAINER_REQUEST, MessageId = CIRCUIT_ENERGY_METER_VALUE and ModifierId = CIRCUIT_ENERGY_METER_VALUE_CALIBRATION

Parameters:
[in]errorError result of the (potential) previous call.
[in]argUser data
[in]sourceIdSource address of the call
[in]destinationIdDestination address of the call
typedef void(* CircuitEnergyMeterValue_calibration_response_callback_t)(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId, uint16_t Uaverage, uint16_t I14average, uint16_t I180average, uint32_t PActiveLow, uint32_t PActiveHigh)

Read the values necessary for metering calibration.

Response callback function prototype for call CircuitEnergyMeterValue_calibration.

To register this callback function, call the DsmApiSetCallback function with MessageType = DS485_CONTAINER_RESPONSE, MessageId = CIRCUIT_ENERGY_METER_VALUE and ModifierId = CIRCUIT_ENERGY_METER_VALUE_CALIBRATION

Parameters:
[in]errorError result of the (potential) previous call.
[in]argUser data
[in]sourceIdSource address of the call
[in]destinationIdDestination address of the call
[in]UaverageAverage of all voltage measurements during the last second.
[in]I14averageAverage of all current measurements (low range) during the last second.
[in]I180averageAverage of all current measurements (high range) during the last second.
[in]PActiveLowCalibrated energy measurement of the last second (low range).
[in]PActiveHighCalibrated energy measurement of the last second (high range).
typedef void(* CircuitEnergyMeterValue_get_request_callback_t)(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)

Return the current energy and power metering values.

Request callback function prototype for call CircuitEnergyMeterValue_get.

To register this callback function, call the DsmApiSetCallback function with MessageType = DS485_CONTAINER_REQUEST, MessageId = CIRCUIT_ENERGY_METER_VALUE and ModifierId = CIRCUIT_ENERGY_METER_VALUE_GET

Parameters:
[in]errorError result of the (potential) previous call.
[in]argUser data
[in]sourceIdSource address of the call
[in]destinationIdDestination address of the call
typedef void(* CircuitEnergyMeterValue_get_response_callback_t)(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId, uint32_t PowerW, uint32_t EnergyWh)

Return the current energy and power metering values.

Response callback function prototype for call CircuitEnergyMeterValue_get.

To register this callback function, call the DsmApiSetCallback function with MessageType = DS485_CONTAINER_RESPONSE, MessageId = CIRCUIT_ENERGY_METER_VALUE and ModifierId = CIRCUIT_ENERGY_METER_VALUE_GET

Parameters:
[in]errorError result of the (potential) previous call.
[in]argUser data
[in]sourceIdSource address of the call
[in]destinationIdDestination address of the call
[in]PowerWCurrent power [W].
[in]EnergyWhAccumulated energy [Wh].
typedef void(* CircuitEnergyMeterValue_reset_request_callback_t)(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)

Return the current energy and power metering values.

Reset energy accumulator afterwards.

Request callback function prototype for call CircuitEnergyMeterValue_reset.

To register this callback function, call the DsmApiSetCallback function with MessageType = DS485_CONTAINER_REQUEST, MessageId = CIRCUIT_ENERGY_METER_VALUE and ModifierId = CIRCUIT_ENERGY_METER_VALUE_RESET

Parameters:
[in]errorError result of the (potential) previous call.
[in]argUser data
[in]sourceIdSource address of the call
[in]destinationIdDestination address of the call
typedef void(* CircuitEnergyMeterValue_reset_response_callback_t)(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId, uint32_t PowerW, uint32_t EnergyWh)

Return the current energy and power metering values.

Reset energy accumulator afterwards.

Response callback function prototype for call CircuitEnergyMeterValue_reset.

To register this callback function, call the DsmApiSetCallback function with MessageType = DS485_CONTAINER_RESPONSE, MessageId = CIRCUIT_ENERGY_METER_VALUE and ModifierId = CIRCUIT_ENERGY_METER_VALUE_RESET

Parameters:
[in]errorError result of the (potential) previous call.
[in]argUser data
[in]sourceIdSource address of the call
[in]destinationIdDestination address of the call
[in]PowerWCurrent power [W].
[in]EnergyWhAccumulated energy [Wh].
typedef void(* CircuitEnergyMeterValue_Ws_get_request_callback_t)(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)

Return the current energy and power metering values.

Request callback function prototype for call CircuitEnergyMeterValue_Ws_get.

To register this callback function, call the DsmApiSetCallback function with MessageType = DS485_CONTAINER_REQUEST, MessageId = CIRCUIT_ENERGY_METER_VALUE and ModifierId = CIRCUIT_ENERGY_METER_VALUE_WS_GET

Parameters:
[in]errorError result of the (potential) previous call.
[in]argUser data
[in]sourceIdSource address of the call
[in]destinationIdDestination address of the call
typedef void(* CircuitEnergyMeterValue_Ws_get_response_callback_t)(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId, uint32_t PowerW, uint32_t EnergyWs)

Return the current energy and power metering values.

Response callback function prototype for call CircuitEnergyMeterValue_Ws_get.

To register this callback function, call the DsmApiSetCallback function with MessageType = DS485_CONTAINER_RESPONSE, MessageId = CIRCUIT_ENERGY_METER_VALUE and ModifierId = CIRCUIT_ENERGY_METER_VALUE_WS_GET

Parameters:
[in]errorError result of the (potential) previous call.
[in]argUser data
[in]sourceIdSource address of the call
[in]destinationIdDestination address of the call
[in]PowerWCurrent power [W].
[in]EnergyWsAccumulated energy [Ws].
typedef void(* CircuitPingDevices_automatic_request_callback_t)(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId, uint16_t IntervalTime)

Dynamically change the behavior of the pinging of devices.

Two types of device pinging are supported. One ping round: During the one ping round, every known (both active and inactive) dSD is ping'ed. Upon failure to respond, the same dSD is ping'ed up to two more times before the ping proceeds to the next dSD. Once all known dSDs have been pinged, the one ping round terminates. The time between any two consecutive pings is configurable. Automatic mode: In automatic mode, the dSM repeatedly loops over all known dSDs and pings everyone exactly once per loop. The time between any two consecutive pings in this mode is, again, configurable. In both ping modes, the time between consecutive pings can not be configured to be lower than 3000 ms. Start automatic (continuous) ping rounds.

Request callback function prototype for call CircuitPingDevices_automatic.

To register this callback function, call the DsmApiSetCallback function with MessageType = DS485_CONTAINER_REQUEST, MessageId = CIRCUIT_PING_DEVICES and ModifierId = CIRCUIT_PING_DEVICES_AUTOMATIC

Parameters:
[in]errorError result of the (potential) previous call.
[in]argUser data
[in]sourceIdSource address of the call
[in]destinationIdDestination address of the call
[in]IntervalTimeTime between ping commands [milliseconds]. 0: take default value from config.
typedef void(* CircuitPingDevices_automatic_response_callback_t)(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)

Dynamically change the behavior of the pinging of devices.

Two types of device pinging are supported. One ping round: During the one ping round, every known (both active and inactive) dSD is ping'ed. Upon failure to respond, the same dSD is ping'ed up to two more times before the ping proceeds to the next dSD. Once all known dSDs have been pinged, the one ping round terminates. The time between any two consecutive pings is configurable. Automatic mode: In automatic mode, the dSM repeatedly loops over all known dSDs and pings everyone exactly once per loop. The time between any two consecutive pings in this mode is, again, configurable. In both ping modes, the time between consecutive pings can not be configured to be lower than 3000 ms. Start automatic (continuous) ping rounds.

Response callback function prototype for call CircuitPingDevices_automatic.

To register this callback function, call the DsmApiSetCallback function with MessageType = DS485_CONTAINER_RESPONSE, MessageId = CIRCUIT_PING_DEVICES and ModifierId = CIRCUIT_PING_DEVICES_AUTOMATIC

Parameters:
[in]errorError result of the (potential) previous call.
[in]argUser data
[in]sourceIdSource address of the call
[in]destinationIdDestination address of the call
typedef void(* CircuitPingDevices_off_request_callback_t)(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)

Dynamically change the behavior of the pinging of devices.

Two types of device pinging are supported. One ping round: During the one ping round, every known (both active and inactive) dSD is ping'ed. Upon failure to respond, the same dSD is ping'ed up to two more times before the ping proceeds to the next dSD. Once all known dSDs have been pinged, the one ping round terminates. The time between any two consecutive pings is configurable. Automatic mode: In automatic mode, the dSM repeatedly loops over all known dSDs and pings everyone exactly once per loop. The time between any two consecutive pings in this mode is, again, configurable. In both ping modes, the time between consecutive pings can not be configured to be lower than 3000 ms. Stops any running ping round and disables further pinging.

Request callback function prototype for call CircuitPingDevices_off.

To register this callback function, call the DsmApiSetCallback function with MessageType = DS485_CONTAINER_REQUEST, MessageId = CIRCUIT_PING_DEVICES and ModifierId = CIRCUIT_PING_DEVICES_OFF

Parameters:
[in]errorError result of the (potential) previous call.
[in]argUser data
[in]sourceIdSource address of the call
[in]destinationIdDestination address of the call
typedef void(* CircuitPingDevices_off_response_callback_t)(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)

Dynamically change the behavior of the pinging of devices.

Two types of device pinging are supported. One ping round: During the one ping round, every known (both active and inactive) dSD is ping'ed. Upon failure to respond, the same dSD is ping'ed up to two more times before the ping proceeds to the next dSD. Once all known dSDs have been pinged, the one ping round terminates. The time between any two consecutive pings is configurable. Automatic mode: In automatic mode, the dSM repeatedly loops over all known dSDs and pings everyone exactly once per loop. The time between any two consecutive pings in this mode is, again, configurable. In both ping modes, the time between consecutive pings can not be configured to be lower than 3000 ms. Stops any running ping round and disables further pinging.

Response callback function prototype for call CircuitPingDevices_off.

To register this callback function, call the DsmApiSetCallback function with MessageType = DS485_CONTAINER_RESPONSE, MessageId = CIRCUIT_PING_DEVICES and ModifierId = CIRCUIT_PING_DEVICES_OFF

Parameters:
[in]errorError result of the (potential) previous call.
[in]argUser data
[in]sourceIdSource address of the call
[in]destinationIdDestination address of the call
typedef void(* CircuitPingDevices_one_time_automatic_request_callback_t)(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId, uint16_t OneTimeIntervalTime, uint16_t AutoIntervalTime)

Dynamically change the behavior of the pinging of devices.

Two types of device pinging are supported. One ping round: During the one ping round, every known (both active and inactive) dSD is ping'ed. Upon failure to respond, the same dSD is ping'ed up to two more times before the ping proceeds to the next dSD. Once all known dSDs have been pinged, the one ping round terminates. The time between any two consecutive pings is configurable. Automatic mode: In automatic mode, the dSM repeatedly loops over all known dSDs and pings everyone exactly once per loop. The time between any two consecutive pings in this mode is, again, configurable. In both ping modes, the time between consecutive pings can not be configured to be lower than 3000 ms. Execute one ping round with the given OneTimeIntervalTime and switches to automatic mode afterwards.

Request callback function prototype for call CircuitPingDevices_one_time_automatic.

To register this callback function, call the DsmApiSetCallback function with MessageType = DS485_CONTAINER_REQUEST, MessageId = CIRCUIT_PING_DEVICES and ModifierId = CIRCUIT_PING_DEVICES_ONE_TIME_AUTOMATIC

Parameters:
[in]errorError result of the (potential) previous call.
[in]argUser data
[in]sourceIdSource address of the call
[in]destinationIdDestination address of the call
[in]OneTimeIntervalTimeTime between ping commands [milliseconds] in one-time round. 0: take default value from config.
[in]AutoIntervalTimeTime between ping commands [milliseconds] consecutive automatic rounds. 0: take default value value from config.
typedef void(* CircuitPingDevices_one_time_automatic_response_callback_t)(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)

Dynamically change the behavior of the pinging of devices.

Two types of device pinging are supported. One ping round: During the one ping round, every known (both active and inactive) dSD is ping'ed. Upon failure to respond, the same dSD is ping'ed up to two more times before the ping proceeds to the next dSD. Once all known dSDs have been pinged, the one ping round terminates. The time between any two consecutive pings is configurable. Automatic mode: In automatic mode, the dSM repeatedly loops over all known dSDs and pings everyone exactly once per loop. The time between any two consecutive pings in this mode is, again, configurable. In both ping modes, the time between consecutive pings can not be configured to be lower than 3000 ms. Execute one ping round with the given OneTimeIntervalTime and switches to automatic mode afterwards.

Response callback function prototype for call CircuitPingDevices_one_time_automatic.

To register this callback function, call the DsmApiSetCallback function with MessageType = DS485_CONTAINER_RESPONSE, MessageId = CIRCUIT_PING_DEVICES and ModifierId = CIRCUIT_PING_DEVICES_ONE_TIME_AUTOMATIC

Parameters:
[in]errorError result of the (potential) previous call.
[in]argUser data
[in]sourceIdSource address of the call
[in]destinationIdDestination address of the call
typedef void(* CircuitPingDevices_one_time_off_request_callback_t)(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId, uint16_t IntervalTime)

Dynamically change the behavior of the pinging of devices.

Two types of device pinging are supported. One ping round: During the one ping round, every known (both active and inactive) dSD is ping'ed. Upon failure to respond, the same dSD is ping'ed up to two more times before the ping proceeds to the next dSD. Once all known dSDs have been pinged, the one ping round terminates. The time between any two consecutive pings is configurable. Automatic mode: In automatic mode, the dSM repeatedly loops over all known dSDs and pings everyone exactly once per loop. The time between any two consecutive pings in this mode is, again, configurable. In both ping modes, the time between consecutive pings can not be configured to be lower than 3000 ms. Execute one ping round.

Request callback function prototype for call CircuitPingDevices_one_time_off.

To register this callback function, call the DsmApiSetCallback function with MessageType = DS485_CONTAINER_REQUEST, MessageId = CIRCUIT_PING_DEVICES and ModifierId = CIRCUIT_PING_DEVICES_ONE_TIME_OFF

Parameters:
[in]errorError result of the (potential) previous call.
[in]argUser data
[in]sourceIdSource address of the call
[in]destinationIdDestination address of the call
[in]IntervalTimeTime between ping commands [milliseconds]. 0: take default value from config.
typedef void(* CircuitPingDevices_one_time_off_response_callback_t)(uint8_t error_code, void *arg, dsid_t sourceId, dsid_t destinationId)

Dynamically change the behavior of the pinging of devices.

Two types of device pinging are supported. One ping round: During the one ping round, every known (both active and inactive) dSD is ping'ed. Upon failure to respond, the same dSD is ping'ed up to two more times before the ping proceeds to the next dSD. Once all known dSDs have been pinged, the one ping round terminates. The time between any two consecutive pings is configurable. Automatic mode: In automatic mode, the dSM repeatedly loops over all known dSDs and pings everyone exactly once per loop. The time between any two consecutive pings in this mode is, again, configurable. In both ping modes, the time between consecutive pings can not be configured to be lower than 3000 ms. Execute one ping round.

Response callback function prototype for call CircuitPingDevices_one_time_off.

To register this callback function, call the DsmApiSetCallback function with MessageType = DS485_CONTAINER_RESPONSE, MessageId = CIRCUIT_PING_DEVICES and ModifierId = CIRCUIT_PING_DEVICES_ONE_TIME_OFF

Parameters:
[in]errorError result of the (potential) previous call.
[in]argUser data
[in]sourceIdSource address of the call
[in]destinationIdDestination address of the call

Function Documentation

int CircuitCurrentMeterValue_get ( DsmApiHandle_t  handle,
dsid_t  dSMdSID,
uint16_t *  PowerW,
uint16_t *  PowerQ,
uint16_t *  Phi 
)

Return the current active and reactive power metering values.

Also calculated phase.

This call has a timeout of 5 seconds.

To receive asynchronous responses to this call (e.g. when addressing broadcast) register the CircuitCurrentMeterValue_get_response_callback_t callback. To receive this request from other bus members register the CircuitCurrentMeterValue_get_request_callback_t callback.

Parameters:
[in]handleHandle to the library instance
[in]dSMdSIDDestination dSM of the call
[out]PowerWCurrent active power [W].
[out]PowerQCurrent reactive power [var].
[out]PhiPhase [rad] (multiplied with 2^14).
Returns:
0: success (return parameters are valid); <0: Library error; >0: dSM error code
int CircuitEnergyMeterValue_calibration ( DsmApiHandle_t  handle,
dsid_t  dSMdSID,
uint16_t *  Uaverage,
uint16_t *  I14average,
uint16_t *  I180average,
uint32_t *  PActiveLow,
uint32_t *  PActiveHigh 
)

Read the values necessary for metering calibration.

This call has a timeout of 5 seconds.

To receive asynchronous responses to this call (e.g. when addressing broadcast) register the CircuitEnergyMeterValue_calibration_response_callback_t callback. To receive this request from other bus members register the CircuitEnergyMeterValue_calibration_request_callback_t callback.

Parameters:
[in]handleHandle to the library instance
[in]dSMdSIDDestination dSM of the call
[out]UaverageAverage of all voltage measurements during the last second.
[out]I14averageAverage of all current measurements (low range) during the last second.
[out]I180averageAverage of all current measurements (high range) during the last second.
[out]PActiveLowCalibrated energy measurement of the last second (low range).
[out]PActiveHighCalibrated energy measurement of the last second (high range).
Returns:
0: success (return parameters are valid); <0: Library error; >0: dSM error code
int CircuitEnergyMeterValue_get ( DsmApiHandle_t  handle,
dsid_t  dSMdSID,
uint32_t *  PowerW,
uint32_t *  EnergyWh 
)

Return the current energy and power metering values.

This call has a timeout of 5 seconds.

To receive asynchronous responses to this call (e.g. when addressing broadcast) register the CircuitEnergyMeterValue_get_response_callback_t callback. To receive this request from other bus members register the CircuitEnergyMeterValue_get_request_callback_t callback.

Parameters:
[in]handleHandle to the library instance
[in]dSMdSIDDestination dSM of the call
[out]PowerWCurrent power [W].
[out]EnergyWhAccumulated energy [Wh].
Returns:
0: success (return parameters are valid); <0: Library error; >0: dSM error code
int CircuitEnergyMeterValue_reset ( DsmApiHandle_t  handle,
dsid_t  dSMdSID,
uint32_t *  PowerW,
uint32_t *  EnergyWh 
)

Return the current energy and power metering values.

Reset energy accumulator afterwards.

This call has a timeout of 5 seconds.

To receive asynchronous responses to this call (e.g. when addressing broadcast) register the CircuitEnergyMeterValue_reset_response_callback_t callback. To receive this request from other bus members register the CircuitEnergyMeterValue_reset_request_callback_t callback.

Parameters:
[in]handleHandle to the library instance
[in]dSMdSIDDestination dSM of the call
[out]PowerWCurrent power [W].
[out]EnergyWhAccumulated energy [Wh].
Returns:
0: success (return parameters are valid); <0: Library error; >0: dSM error code
int CircuitEnergyMeterValue_Ws_get ( DsmApiHandle_t  handle,
dsid_t  dSMdSID,
uint32_t *  PowerW,
uint32_t *  EnergyWs 
)

Return the current energy and power metering values.

This call has a timeout of 5 seconds.

To receive asynchronous responses to this call (e.g. when addressing broadcast) register the CircuitEnergyMeterValue_Ws_get_response_callback_t callback. To receive this request from other bus members register the CircuitEnergyMeterValue_Ws_get_request_callback_t callback.

Parameters:
[in]handleHandle to the library instance
[in]dSMdSIDDestination dSM of the call
[out]PowerWCurrent power [W].
[out]EnergyWsAccumulated energy [Ws].
Returns:
0: success (return parameters are valid); <0: Library error; >0: dSM error code
int CircuitPingDevices_automatic ( DsmApiHandle_t  handle,
dsid_t  dSMdSID,
uint16_t  IntervalTime 
)

Dynamically change the behavior of the pinging of devices.

Two types of device pinging are supported. One ping round: During the one ping round, every known (both active and inactive) dSD is ping'ed. Upon failure to respond, the same dSD is ping'ed up to two more times before the ping proceeds to the next dSD. Once all known dSDs have been pinged, the one ping round terminates. The time between any two consecutive pings is configurable. Automatic mode: In automatic mode, the dSM repeatedly loops over all known dSDs and pings everyone exactly once per loop. The time between any two consecutive pings in this mode is, again, configurable. In both ping modes, the time between consecutive pings can not be configured to be lower than 3000 ms. Start automatic (continuous) ping rounds.

This call has a timeout of 5 seconds.

To receive asynchronous responses to this call (e.g. when addressing broadcast) register the CircuitPingDevices_automatic_response_callback_t callback. To receive this request from other bus members register the CircuitPingDevices_automatic_request_callback_t callback.

Parameters:
[in]handleHandle to the library instance
[in]dSMdSIDDestination dSM of the call
[in]IntervalTimeTime between ping commands [milliseconds]. 0: take default value from config.
Returns:
0: success (return parameters are valid); <0: Library error; >0: dSM error code
int CircuitPingDevices_off ( DsmApiHandle_t  handle,
dsid_t  dSMdSID 
)

Dynamically change the behavior of the pinging of devices.

Two types of device pinging are supported. One ping round: During the one ping round, every known (both active and inactive) dSD is ping'ed. Upon failure to respond, the same dSD is ping'ed up to two more times before the ping proceeds to the next dSD. Once all known dSDs have been pinged, the one ping round terminates. The time between any two consecutive pings is configurable. Automatic mode: In automatic mode, the dSM repeatedly loops over all known dSDs and pings everyone exactly once per loop. The time between any two consecutive pings in this mode is, again, configurable. In both ping modes, the time between consecutive pings can not be configured to be lower than 3000 ms. Stops any running ping round and disables further pinging.

This call has a timeout of 5 seconds.

To receive asynchronous responses to this call (e.g. when addressing broadcast) register the CircuitPingDevices_off_response_callback_t callback. To receive this request from other bus members register the CircuitPingDevices_off_request_callback_t callback.

Parameters:
[in]handleHandle to the library instance
[in]dSMdSIDDestination dSM of the call
Returns:
0: success (return parameters are valid); <0: Library error; >0: dSM error code
int CircuitPingDevices_one_time_automatic ( DsmApiHandle_t  handle,
dsid_t  dSMdSID,
uint16_t  OneTimeIntervalTime,
uint16_t  AutoIntervalTime 
)

Dynamically change the behavior of the pinging of devices.

Two types of device pinging are supported. One ping round: During the one ping round, every known (both active and inactive) dSD is ping'ed. Upon failure to respond, the same dSD is ping'ed up to two more times before the ping proceeds to the next dSD. Once all known dSDs have been pinged, the one ping round terminates. The time between any two consecutive pings is configurable. Automatic mode: In automatic mode, the dSM repeatedly loops over all known dSDs and pings everyone exactly once per loop. The time between any two consecutive pings in this mode is, again, configurable. In both ping modes, the time between consecutive pings can not be configured to be lower than 3000 ms. Execute one ping round with the given OneTimeIntervalTime and switches to automatic mode afterwards.

This call has a timeout of 5 seconds.

To receive asynchronous responses to this call (e.g. when addressing broadcast) register the CircuitPingDevices_one_time_automatic_response_callback_t callback. To receive this request from other bus members register the CircuitPingDevices_one_time_automatic_request_callback_t callback.

Parameters:
[in]handleHandle to the library instance
[in]dSMdSIDDestination dSM of the call
[in]OneTimeIntervalTimeTime between ping commands [milliseconds] in one-time round. 0: take default value from config.
[in]AutoIntervalTimeTime between ping commands [milliseconds] consecutive automatic rounds. 0: take default value value from config.
Returns:
0: success (return parameters are valid); <0: Library error; >0: dSM error code
int CircuitPingDevices_one_time_off ( DsmApiHandle_t  handle,
dsid_t  dSMdSID,
uint16_t  IntervalTime 
)

Dynamically change the behavior of the pinging of devices.

Two types of device pinging are supported. One ping round: During the one ping round, every known (both active and inactive) dSD is ping'ed. Upon failure to respond, the same dSD is ping'ed up to two more times before the ping proceeds to the next dSD. Once all known dSDs have been pinged, the one ping round terminates. The time between any two consecutive pings is configurable. Automatic mode: In automatic mode, the dSM repeatedly loops over all known dSDs and pings everyone exactly once per loop. The time between any two consecutive pings in this mode is, again, configurable. In both ping modes, the time between consecutive pings can not be configured to be lower than 3000 ms. Execute one ping round.

This call has a timeout of 5 seconds.

To receive asynchronous responses to this call (e.g. when addressing broadcast) register the CircuitPingDevices_one_time_off_response_callback_t callback. To receive this request from other bus members register the CircuitPingDevices_one_time_off_request_callback_t callback.

Parameters:
[in]handleHandle to the library instance
[in]dSMdSIDDestination dSM of the call
[in]IntervalTimeTime between ping commands [milliseconds]. 0: take default value from config.
Returns:
0: success (return parameters are valid); <0: Library error; >0: dSM error code
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines