pdcomm_gem_host_constant_request
Function
Sends an Equipment Constant Request (S2F13) or Namelist Request (S2F29) from a Host.
PdcommStatus pdcomm_gem_host_constant_request(PdcommTcpEndpoint *endpoint, uint32_t kind, const PdcommSecsItem *const *ids, size_t count, PdcommTcpToken *out_token)An empty ID list requests every constant. Explicit IDs are copied before the send and keep their order, duplicates, and original item format, which pdcomm_gem_result_constant_value() returns with each value. The IDs count against the Host's max_pending_ids, shared with status, directory, and query requests. For explicit IDs a reply must contain one entry per requested ID, and a namelist reply must also echo the IDs in order; otherwise the result is #PDCOMM_GEM_INVALID_RESPONSE. The reply arrives as #PDCOMM_GEM_RESPONSE with outcome #PDCOMM_GEM_CONSTANT_VALUES_RECEIVED or #PDCOMM_GEM_CONSTANT_METADATA_RECEIVED.
Parameters
| Name | Description |
|---|---|
endpoint | Host endpoint. |
kind | #PDCOMM_GEM_CONSTANT_VALUES or #PDCOMM_GEM_CONSTANT_METADATA. |
ids | Array of count ID items. May be NULL when count is 0. |
count | Number of IDs; 0 requests all constants. |
out_token | Zeroed first; receives the transaction token on success. Must not be NULL. |
Returns
#PDCOMM_OK when the request was queued; #PDCOMM_INVALID_ARGUMENT when endpoint or out_token is NULL, kind is unknown, ids is NULL with a nonzero count, or an ID is NULL or not a valid constant ID; #PDCOMM_LIMIT_EXCEEDED when the IDs exceed max_pending_ids or the Host item limits; #PDCOMM_INVALID_STATE when the endpoint is not a Host or is not Communicating; #PDCOMM_BACKPRESSURE when a TCP event is staged or the pending slots or send queue are full; #PDCOMM_ALLOCATION_FAILED, #PDCOMM_IO_ERROR, or #PDCOMM_POISONED.
Notes
- Successful submission is not a response.