38 # define PDSERV_EXPORT __attribute__((__visibility__("default"))) 40 # define PDSERV_EXPORT 61 #define PDSERV_VERSION(major,minor,patchlevel) \ 62 (((major) << 16) + ((minor) << 8) + (patchlevel)) 63 #define PDSERV_VERSION_CODE \ 65 #define PDSERV_VERSION_MAJOR 3 66 #define PDSERV_VERSION_MINOR 3 67 #define PDSERV_VERSION_PATCH 1 82 #define HAS_VERSION_CODE 163 #define pd_double_T 1 164 #define pd_single_T 2 167 #define pd_uint16_T 5 168 #define pd_sint16_T 6 169 #define pd_uint32_T 7 170 #define pd_sint32_T 8 171 #define pd_uint64_T 9 172 #define pd_sint64_T 10 173 #define pd_boolean_T 11 174 #define pd_schar_T 12 176 #define pd_uchar_T 14 177 #define pd_short_T 15 178 #define pd_ushort_T 16 182 #define pd_ulong_T 20 183 #define pd_longlong_T 21 184 #define pd_ulonglong_T 22 185 #define pd_ssize_T 23 188 #define pd_datatype_end 25 236 struct pdserv* pdserv,
251 struct pdserv* pdserv,
252 void (*fn)(
int lock,
void* priv_data),
266 struct pdserv* pdserv,
282 struct pdtask* pdtask,
283 void (*fn)(
int lock,
void* priv_data),
341 struct pdtask* pdtask,
342 unsigned int decimation,
360 typedef int (*read_signal_t)(
const struct pdvariable *signal,
void *dst,
361 const void *src,
size_t len,
struct timespec* time,
void *priv_data);
363 PDSERV_EXPORT
void pdserv_signal_set_read_cb(
struct pdvariable* signal,
364 read_signal_t read_signal_cb,
void* priv_data
365 ) __attribute__((deprecated(
"use pdserv_signal() instead")));
367 PDSERV_EXPORT
struct pdvariable *pdserv_signal_cb(
struct pdtask* pdtask,
368 unsigned int decimation,
const char *path,
int datatype,
369 const void *addr,
size_t n,
const size_t *dim,
370 read_signal_t read_signal_cb,
void* priv_data
371 ) __attribute__((deprecated(
"use pdserv_signal() instead")));;
402 #define RESET_EVENT 0 403 #define EMERG_EVENT 1 404 #define ALERT_EVENT 2 406 #define ERROR_EVENT 4 408 #define NOTICE_EVENT 6 410 #define DEBUG_EVENT 8 420 struct pdserv* pdserv,
428 struct pdevent* event,
429 const char *
const *text
443 const struct pdevent *event,
455 const struct timespec *t
464 const struct pdevent *event,
466 const struct timespec *t
483 const struct pdevent *event,
484 const unsigned int * level,
498 const struct timespec *t
527 const struct pdvariable *param,
531 struct timespec* time,
550 struct pdserv* pdserv,
576 struct pdvariable *variable,
582 struct pdvariable *variable,
588 struct pdvariable *variable,
600 const struct pdvariable *variable
617 struct pdserv* pdserv
626 struct pdtask* pdtask,
638 struct pdtask* pdtask,
639 const struct timespec *t
int(* gettime_t)(struct timespec *)
Definition: pdserv.h:203
PDSERV_EXPORT const char *const pdserv_version_str
String of pdserv version code "major.minor.patch".
PDSERV_EXPORT void pdserv_compound_add_field(int compound, const char *name, int data_type, size_t offset, size_t ndim, const size_t *dim)
PDSERV_EXPORT void pdserv_event_reset(const struct pdevent *event, size_t element, const struct timespec *t)
PDSERV_EXPORT void pdserv_set_comment(struct pdvariable *variable, const char *comment)
PDSERV_EXPORT void pdserv_event_set_all(const struct pdevent *event, const unsigned int *level, const struct timespec *t)
PDSERV_EXPORT struct pdtask * pdserv_create_task(struct pdserv *pdserv, double tsample, const char *name)
PDSERV_EXPORT void pdserv_config_file(struct pdserv *pdserv, const char *file)
PDSERV_EXPORT struct pdvariable * pdserv_parameter(struct pdserv *pdserv, const char *path, unsigned int mode, int datatype, void *addr, size_t n, const size_t *dim, write_parameter_t write_cb, void *priv_data)
PDSERV_EXPORT void pdserv_update_statistics(struct pdtask *pdtask, double exec_time, double cycle_time, unsigned int overrun)
PDSERV_EXPORT const char *const pdserv_full_version
Full String of pdserv version, generated by git describe.
PDSERV_EXPORT struct pdvariable * pdserv_signal(struct pdtask *pdtask, unsigned int decimation, const char *path, int datatype, const void *addr, size_t n, const size_t *dim)
PDSERV_EXPORT struct pdevent * pdserv_event(struct pdserv *pdserv, const char *path, size_t n)
PDSERV_EXPORT void pdserv_set_signal_readlock_cb(struct pdtask *pdtask, void(*fn)(int lock, void *priv_data), void *priv_data)
int(* write_parameter_t)(const struct pdvariable *param, void *dst, const void *src, size_t len, struct timespec *time, void *priv_data)
Definition: pdserv.h:526
PDSERV_EXPORT int pdserv_create_compound(const char *name, size_t size)
PDSERV_EXPORT struct pdserv * pdserv_create(const char *name, const char *version, gettime_t gettime_cb)
PDSERV_EXPORT void pdserv_event_set_text(struct pdevent *event, const char *const *text)
PDSERV_EXPORT void pdserv_exit(struct pdserv *)
PDSERV_EXPORT int pdserv_prepare(struct pdserv *pdserv)
PDSERV_EXPORT void pdserv_set_unit(struct pdvariable *variable, const char *unit)
PDSERV_EXPORT void pdserv_update(struct pdtask *pdtask, const struct timespec *t)
PDSERV_EXPORT void pdserv_set_parameter_writelock_cb(struct pdserv *pdserv, void(*fn)(int lock, void *priv_data), void *priv_data)
PDSERV_EXPORT void pdserv_set_alias(struct pdvariable *variable, const char *alias)
PDSERV_EXPORT void pdserv_event_set(const struct pdevent *event, size_t element, int priority, const struct timespec *t)
PDSERV_EXPORT const char * pdserv_get_variable_path(const struct pdvariable *variable)