PTMAP_add_setpoint

This subroutine adds a "Setpoint" request to a Shopping List. Point Management downloads the specified value to the device address designated by the point. The application must have a pointer to a PTM_DATA struct containing the data value. This structure must be allocated by a call to PTM_alloc_ptm_data.

Syntax:

int PTMAP_add_setpoint ( sl_adr, point_adr,

                         point_value,req_adr,

                         retstat )

PTMAP_ADDR  *sl_adr;

PTMAP_ADDR  *point_adr;

PTM_DATA    *point_value;

PTMAP_ADDR  *req_adr;

COR_STATUS  *retstat;

Input Arguments

sl_adr

A Shopping List ID created by a call to PTMAP_add_sl.

point_adr

A Point ID created by a call to PTMAP_add_point.

point_value

A pointer to a PTM_DATA structure containing the point value.

Output Arguments

req_adr

Identifier used to reference this request.

Retstat

Pointer to status structure. The following errors may be returned (see Appendix A for an explanation of this code):

 

PTMAP_ADDR_PTR_NULL

 

PTMAP_SL_ADR_NULL

 

PTMAP_SL_ADDR_NOTF

 

PTMAP_SEQ_NUM_MISMATCH

 

PTMAP_DATA_NULLPTR

 

PTMAP_DATA_TYPE_MISMATCH

 

PTMAP_DATA_LEN_MISMATCH

 

PTMAP_DATA_ELEM_MISMATCH

Return Value

The contents of retstat.status.

More information

Point Management API subroutines.