The data types for the pin & parameter directions were wrong. Signed-off-by: Sebastian Kuzminsky <seb@highlab.com>
68 lines
2.3 KiB
Text
68 lines
2.3 KiB
Text
.TH hal_param_new "3hal" "2006-10-12" "LinuxCNC Documentation" "HAL"
|
|
.SH NAME
|
|
|
|
hal_param_new \- Create a HAL parameter
|
|
|
|
.SH SYNTAX
|
|
|
|
.HP
|
|
int hal_param_bit_new(const char *\fIname\fR, hal_param_dir_t \fIdir\fR, hal_bit_t * \fIdata_addr\fR, int \fIcomp_id\fR)
|
|
|
|
.HP
|
|
int hal_param_float_new(const char *\fIname\fR, hal_param_dir_t \fIdir\fR, hal_float_t * \fIdata_addr\fR, int \fIcomp_id\fR)
|
|
|
|
.HP
|
|
int hal_param_u32_new(const char *\fIname\fR, hal_param_dir_t \fIdir\fR, hal_u32_t * \fIdata_addr\fR, int \fIcomp_id\fR)
|
|
|
|
.HP
|
|
int hal_param_s32_new(const char *\fIname\fR, hal_param_dir_t \fIdir\fR, hal_s32_t * \fIdata_addr\fR, int \fIcomp_id\fR)
|
|
|
|
.HP
|
|
int hal_param_bit_newf(hal_param_dir_t \fIdir\fR, hal_bit_t * \fIdata_addr\fR, int \fIcomp_id\fR, const char *\fIfmt\fR, \fI...\fR)
|
|
|
|
.HP
|
|
int hal_param_float_newf(hal_param_dir_t \fIdir\fR, hal_float_t * \fIdata_addr\fR, int \fIcomp_id\fR, const char *\fIfmt\fR, \fI...\fR)
|
|
|
|
.HP
|
|
int hal_param_u32_newf(hal_param_dir_t \fIdir\fR, hal_u32_t * \fIdata_addr\fR, int \fIcomp_id\fR, const char *\fIfmt\fR, \fI...\fR)
|
|
|
|
.HP
|
|
int hal_param_s32_newf(hal_param_dir_t \fIdir\fR, hal_s32_t * \fIdata_addr\fR, int \fIcomp_id\fR, const char *\fIfmt\fR, \fI...\fR)
|
|
|
|
.HP
|
|
int hal_param_new(const char *\fIname\fR, hal_type_t \fItype\fR, hal_param_dir_t \fIdir\fR, void *\fIdata_addr\fR, int \fIcomp_id\fR)
|
|
|
|
.SH ARGUMENTS
|
|
.TP
|
|
\fIname\fR
|
|
The name to give to the created parameter
|
|
.TP
|
|
\fIdir\fR
|
|
The direction of the parameter, from the viewpoint of the component. It may be
|
|
one of \fBHAL_RO\fR, or \fBHAL_RW\fR A component may assign a value to any
|
|
parameter, but other programs (such as halcmd) may only assign a value to a
|
|
parameter that is \fBHAL_RW\fR.
|
|
.TP
|
|
\fIdata_addr\fR
|
|
The address of the data, which must lie within memory allocated by
|
|
\fBhal_malloc\fR.
|
|
.TP
|
|
\fIcomp_id\fR
|
|
A HAL component identifier returned by an earlier call to \fBhal_init\fR.
|
|
.TP
|
|
\fIfmt,\ ...\fR
|
|
A printf-style format string and arguments
|
|
.TP
|
|
\fItype\fR
|
|
The type of the parameter, as specified in \fBhal_type_t(3hal)\fR.
|
|
|
|
.SH DESCRIPTION
|
|
The \fBhal_param_new\fR family of functions create a new \fIparam\fR object.
|
|
|
|
There are functions for each of the data types that the HAL supports. Pins may
|
|
only be linked to signals of the same type.
|
|
|
|
.SH RETURN VALUE
|
|
Returns a HAL status code.
|
|
.SH SEE ALSO
|
|
\fBhal_type_t(3hal)\fR
|