Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: X_NUCLEO_COMMON ST_INTERFACES
This section groups all the functions concerning data generation. More...
Functions | |
| int32_t | iis2dlpc_power_mode_set (iis2dlpc_ctx_t *ctx, iis2dlpc_mode_t val) |
| Select accelerometer operating modes. | |
| int32_t | iis2dlpc_power_mode_get (iis2dlpc_ctx_t *ctx, iis2dlpc_mode_t *val) |
| Select accelerometer operating modes. | |
| int32_t | iis2dlpc_data_rate_set (iis2dlpc_ctx_t *ctx, iis2dlpc_odr_t val) |
| Accelerometer data rate selection. | |
| int32_t | iis2dlpc_data_rate_get (iis2dlpc_ctx_t *ctx, iis2dlpc_odr_t *val) |
| Accelerometer data rate selection. | |
| int32_t | iis2dlpc_block_data_update_set (iis2dlpc_ctx_t *ctx, uint8_t val) |
| Block data update. | |
| int32_t | iis2dlpc_block_data_update_get (iis2dlpc_ctx_t *ctx, uint8_t *val) |
| Block data update. | |
| int32_t | iis2dlpc_full_scale_set (iis2dlpc_ctx_t *ctx, iis2dlpc_fs_t val) |
| Accelerometer full-scale selection. | |
| int32_t | iis2dlpc_full_scale_get (iis2dlpc_ctx_t *ctx, iis2dlpc_fs_t *val) |
| Accelerometer full-scale selection. | |
| int32_t | iis2dlpc_status_reg_get (iis2dlpc_ctx_t *ctx, iis2dlpc_status_t *val) |
| The STATUS_REG register of the device. | |
| int32_t | iis2dlpc_flag_data_ready_get (iis2dlpc_ctx_t *ctx, uint8_t *val) |
| Accelerometer new data available. | |
| int32_t | iis2dlpc_all_sources_get (iis2dlpc_ctx_t *ctx, iis2dlpc_all_sources_t *val) |
| Read all the interrupt/status flag of the device. | |
| int32_t | iis2dlpc_usr_offset_x_set (iis2dlpc_ctx_t *ctx, uint8_t *buff) |
| Accelerometer X-axis user offset correction expressed in two’s complement, weight depends on bit USR_OFF_W. | |
| int32_t | iis2dlpc_usr_offset_x_get (iis2dlpc_ctx_t *ctx, uint8_t *buff) |
| Accelerometer X-axis user offset correction expressed in two’s complement, weight depends on bit USR_OFF_W. | |
| int32_t | iis2dlpc_usr_offset_y_set (iis2dlpc_ctx_t *ctx, uint8_t *buff) |
| Accelerometer Y-axis user offset correction expressed in two’s complement, weight depends on bit USR_OFF_W. | |
| int32_t | iis2dlpc_usr_offset_y_get (iis2dlpc_ctx_t *ctx, uint8_t *buff) |
| Accelerometer Y-axis user offset correction expressed in two’s complement, weight depends on bit USR_OFF_W. | |
| int32_t | iis2dlpc_usr_offset_z_set (iis2dlpc_ctx_t *ctx, uint8_t *buff) |
| Accelerometer Z-axis user offset correction expressed in two’s complement, weight depends on bit USR_OFF_W. | |
| int32_t | iis2dlpc_usr_offset_z_get (iis2dlpc_ctx_t *ctx, uint8_t *buff) |
| Accelerometer Z-axis user offset correction expressed in two’s complement, weight depends on bit USR_OFF_W. | |
| int32_t | iis2dlpc_offset_weight_set (iis2dlpc_ctx_t *ctx, iis2dlpc_usr_off_w_t val) |
| Weight of XL user offset bits of registers X_OFS_USR, Y_OFS_USR, Z_OFS_USR. | |
| int32_t | iis2dlpc_offset_weight_get (iis2dlpc_ctx_t *ctx, iis2dlpc_usr_off_w_t *val) |
| Weight of XL user offset bits of registers X_OFS_USR, Y_OFS_USR, Z_OFS_USR. | |
Detailed Description
This section groups all the functions concerning data generation.
Function Documentation
| int32_t iis2dlpc_all_sources_get | ( | iis2dlpc_ctx_t * | ctx, |
| iis2dlpc_all_sources_t * | val | ||
| ) |
Read all the interrupt/status flag of the device.
[get]
- Parameters:
-
ctx read / write interface definitions val registers STATUS_DUP, WAKE_UP_SRC, TAP_SRC, SIXD_SRC, ALL_INT_SRC
- Return values:
-
interface status (MANDATORY: return 0 -> no Error)
Definition at line 511 of file iis2dlpc_reg.c.
| int32_t iis2dlpc_block_data_update_get | ( | iis2dlpc_ctx_t * | ctx, |
| uint8_t * | val | ||
| ) |
Block data update.
[get]
- Parameters:
-
ctx read / write interface definitions val change the values of bdu in reg CTRL2
- Return values:
-
interface status (MANDATORY: return 0 -> no Error)
Definition at line 402 of file iis2dlpc_reg.c.
| int32_t iis2dlpc_block_data_update_set | ( | iis2dlpc_ctx_t * | ctx, |
| uint8_t | val | ||
| ) |
Block data update.
[set]
- Parameters:
-
ctx read / write interface definitions val change the values of bdu in reg CTRL2
- Return values:
-
interface status (MANDATORY: return 0 -> no Error)
Definition at line 381 of file iis2dlpc_reg.c.
| int32_t iis2dlpc_data_rate_get | ( | iis2dlpc_ctx_t * | ctx, |
| iis2dlpc_odr_t * | val | ||
| ) |
Accelerometer data rate selection.
[get]
- Parameters:
-
ctx read / write interface definitions val Get the values of odr in reg CTRL1
- Return values:
-
interface status (MANDATORY: return 0 -> no Error)
Definition at line 318 of file iis2dlpc_reg.c.
| int32_t iis2dlpc_data_rate_set | ( | iis2dlpc_ctx_t * | ctx, |
| iis2dlpc_odr_t | val | ||
| ) |
Accelerometer data rate selection.
[set]
- Parameters:
-
ctx read / write interface definitions val change the values of odr in reg CTRL1
- Return values:
-
interface status (MANDATORY: return 0 -> no Error)
Definition at line 287 of file iis2dlpc_reg.c.
| int32_t iis2dlpc_flag_data_ready_get | ( | iis2dlpc_ctx_t * | ctx, |
| uint8_t * | val | ||
| ) |
Accelerometer new data available.
[get]
- Parameters:
-
ctx read / write interface definitions val change the values of drdy in reg STATUS
- Return values:
-
interface status (MANDATORY: return 0 -> no Error)
Definition at line 492 of file iis2dlpc_reg.c.
| int32_t iis2dlpc_full_scale_get | ( | iis2dlpc_ctx_t * | ctx, |
| iis2dlpc_fs_t * | val | ||
| ) |
Accelerometer full-scale selection.
[get]
- Parameters:
-
ctx read / write interface definitions val Get the values of fs in reg CTRL6
- Return values:
-
interface status (MANDATORY: return 0 -> no Error)
Definition at line 442 of file iis2dlpc_reg.c.
| int32_t iis2dlpc_full_scale_set | ( | iis2dlpc_ctx_t * | ctx, |
| iis2dlpc_fs_t | val | ||
| ) |
Accelerometer full-scale selection.
[set]
- Parameters:
-
ctx read / write interface definitions val change the values of fs in reg CTRL6
- Return values:
-
interface status (MANDATORY: return 0 -> no Error)
Definition at line 421 of file iis2dlpc_reg.c.
| int32_t iis2dlpc_offset_weight_get | ( | iis2dlpc_ctx_t * | ctx, |
| iis2dlpc_usr_off_w_t * | val | ||
| ) |
Weight of XL user offset bits of registers X_OFS_USR, Y_OFS_USR, Z_OFS_USR.
[get]
- Parameters:
-
ctx read / write interface definitions val Get the values of usr_off_w in reg CTRL_REG7
- Return values:
-
interface status (MANDATORY: return 0 -> no Error)
Definition at line 654 of file iis2dlpc_reg.c.
| int32_t iis2dlpc_offset_weight_set | ( | iis2dlpc_ctx_t * | ctx, |
| iis2dlpc_usr_off_w_t | val | ||
| ) |
Weight of XL user offset bits of registers X_OFS_USR, Y_OFS_USR, Z_OFS_USR.
[set]
- Parameters:
-
ctx read / write interface definitions val change the values of usr_off_w in reg CTRL_REG7
- Return values:
-
interface status (MANDATORY: return 0 -> no Error)
Definition at line 631 of file iis2dlpc_reg.c.
| int32_t iis2dlpc_power_mode_get | ( | iis2dlpc_ctx_t * | ctx, |
| iis2dlpc_mode_t * | val | ||
| ) |
Select accelerometer operating modes.
[get]
- Parameters:
-
ctx read / write interface definitions val change the values of mode / lp_mode in reg CTRL1 and low_noise in reg CTRL6
- Return values:
-
interface status (MANDATORY: return 0 -> no Error)
Definition at line 205 of file iis2dlpc_reg.c.
| int32_t iis2dlpc_power_mode_set | ( | iis2dlpc_ctx_t * | ctx, |
| iis2dlpc_mode_t | val | ||
| ) |
Select accelerometer operating modes.
[set]
- Parameters:
-
ctx read / write interface definitions val change the values of mode / lp_mode in reg CTRL1 and low_noise in reg CTRL6
- Return values:
-
interface status (MANDATORY: return 0 -> no Error)
Definition at line 172 of file iis2dlpc_reg.c.
| int32_t iis2dlpc_status_reg_get | ( | iis2dlpc_ctx_t * | ctx, |
| iis2dlpc_status_t * | val | ||
| ) |
The STATUS_REG register of the device.
[get]
- Parameters:
-
ctx read / write interface definitions val union of registers from STATUS to
- Return values:
-
interface status (MANDATORY: return 0 -> no Error)
Definition at line 477 of file iis2dlpc_reg.c.
| int32_t iis2dlpc_usr_offset_x_get | ( | iis2dlpc_ctx_t * | ctx, |
| uint8_t * | buff | ||
| ) |
Accelerometer X-axis user offset correction expressed in two’s complement, weight depends on bit USR_OFF_W.
The value must be in the range [-127 127].[get]
- Parameters:
-
ctx read / write interface definitions buff buffer that stores data read
- Return values:
-
interface status (MANDATORY: return 0 -> no Error)
Definition at line 546 of file iis2dlpc_reg.c.
| int32_t iis2dlpc_usr_offset_x_set | ( | iis2dlpc_ctx_t * | ctx, |
| uint8_t * | buff | ||
| ) |
Accelerometer X-axis user offset correction expressed in two’s complement, weight depends on bit USR_OFF_W.
The value must be in the range [-127 127].[set]
- Parameters:
-
ctx read / write interface definitions buff buffer that contains data to write
- Return values:
-
interface status (MANDATORY: return 0 -> no Error)
Definition at line 529 of file iis2dlpc_reg.c.
| int32_t iis2dlpc_usr_offset_y_get | ( | iis2dlpc_ctx_t * | ctx, |
| uint8_t * | buff | ||
| ) |
Accelerometer Y-axis user offset correction expressed in two’s complement, weight depends on bit USR_OFF_W.
The value must be in the range [-127 127].[get]
- Parameters:
-
ctx read / write interface definitions buff buffer that stores data read
- Return values:
-
interface status (MANDATORY: return 0 -> no Error)
Definition at line 580 of file iis2dlpc_reg.c.
| int32_t iis2dlpc_usr_offset_y_set | ( | iis2dlpc_ctx_t * | ctx, |
| uint8_t * | buff | ||
| ) |
Accelerometer Y-axis user offset correction expressed in two’s complement, weight depends on bit USR_OFF_W.
The value must be in the range [-127 127].[set]
- Parameters:
-
ctx read / write interface definitions buff buffer that contains data to write
- Return values:
-
interface status (MANDATORY: return 0 -> no Error)
Definition at line 563 of file iis2dlpc_reg.c.
| int32_t iis2dlpc_usr_offset_z_get | ( | iis2dlpc_ctx_t * | ctx, |
| uint8_t * | buff | ||
| ) |
Accelerometer Z-axis user offset correction expressed in two’s complement, weight depends on bit USR_OFF_W.
The value must be in the range [-127 127].[get]
- Parameters:
-
ctx read / write interface definitions buff buffer that stores data read
- Return values:
-
interface status (MANDATORY: return 0 -> no Error)
Definition at line 614 of file iis2dlpc_reg.c.
| int32_t iis2dlpc_usr_offset_z_set | ( | iis2dlpc_ctx_t * | ctx, |
| uint8_t * | buff | ||
| ) |
Accelerometer Z-axis user offset correction expressed in two’s complement, weight depends on bit USR_OFF_W.
The value must be in the range [-127 127].[set]
- Parameters:
-
ctx read / write interface definitions buff buffer that contains data to write
- Return values:
-
interface status (MANDATORY: return 0 -> no Error)
Definition at line 597 of file iis2dlpc_reg.c.
Generated on Tue Jul 12 2022 14:14:49 by
1.7.2