|
hal_init − Sets up HAL and RTAPI |
|
int hal_init(const char *modname) |
|
modname |
|
The name of this hal module |
|
hal_init sets up HAL and RTAPI. It must be called by any module that intends to use the API, before any other RTAPI calls. modname can optionally point to a string that identifies the module. The string will be truncated at RTAPI_NAME_LEN characters. If modname is NULL, the system will assign a name. |
|
Call only from within user or init/cleanup code, not from relatime tasks. |
|
On success, returns a positive integer module ID, which is used for subsequent calls to hal and rtapi APIs. On failure, returns a HAL error code. |