![]() |
Da Vinci Firmware 1
Firmware for the DaVinci-M rocket avionics board.
|
This section group common useful functions. More...

Functions | |
| int32_t | lis2mdl_device_id_get (const stmdev_ctx_t *ctx, uint8_t *buff) |
| DeviceWhoamI.[get]. | |
| int32_t | lis2mdl_reset_set (const stmdev_ctx_t *ctx, uint8_t val) |
| Software reset. Restore the default values in user registers.[set]. | |
| int32_t | lis2mdl_reset_get (const stmdev_ctx_t *ctx, uint8_t *val) |
| Software reset. Restore the default values in user registers.[get]. | |
| int32_t | lis2mdl_boot_set (const stmdev_ctx_t *ctx, uint8_t val) |
| Reboot memory content. Reload the calibration parameters.[set]. | |
| int32_t | lis2mdl_boot_get (const stmdev_ctx_t *ctx, uint8_t *val) |
| Reboot memory content. Reload the calibration parameters.[get]. | |
| int32_t | lis2mdl_self_test_set (const stmdev_ctx_t *ctx, uint8_t val) |
| Selftest.[set]. | |
| int32_t | lis2mdl_self_test_get (const stmdev_ctx_t *ctx, uint8_t *val) |
| Selftest.[get]. | |
| int32_t | lis2mdl_data_format_set (const stmdev_ctx_t *ctx, lis2mdl_ble_t val) |
| Big/Little Endian data selection.[set]. | |
| int32_t | lis2mdl_data_format_get (const stmdev_ctx_t *ctx, lis2mdl_ble_t *val) |
| Big/Little Endian data selection.[get]. | |
| int32_t | lis2mdl_status_get (const stmdev_ctx_t *ctx, lis2mdl_status_reg_t *val) |
| Info about device status.[get]. | |
This section group common useful functions.
| int32_t lis2mdl_boot_get | ( | const stmdev_ctx_t * | ctx, |
| uint8_t * | val | ||
| ) |
Reboot memory content. Reload the calibration parameters.[get].
| ctx | read / write interface definitions.(ptr) |
| val | change the values of reboot in reg CFG_REG_A.(ptr) |
| interface | status.(MANDATORY: return 0 -> no Error) |
Definition at line 843 of file lis2mdl_reg.c.
References LIS2MDL_CFG_REG_A, lis2mdl_read_reg(), and lis2mdl_cfg_reg_a_t::reboot.
Referenced by lis2mdl_init(), and lis2mdl_init_2().


| int32_t lis2mdl_boot_set | ( | const stmdev_ctx_t * | ctx, |
| uint8_t | val | ||
| ) |
Reboot memory content. Reload the calibration parameters.[set].
| ctx | read / write interface definitions.(ptr) |
| val | change the values of reboot in reg CFG_REG_A |
| interface | status.(MANDATORY: return 0 -> no Error) |
Definition at line 819 of file lis2mdl_reg.c.
References LIS2MDL_CFG_REG_A, lis2mdl_read_reg(), lis2mdl_write_reg(), and lis2mdl_cfg_reg_a_t::reboot.
Referenced by lis2mdl_init(), and lis2mdl_init_2().


| int32_t lis2mdl_data_format_get | ( | const stmdev_ctx_t * | ctx, |
| lis2mdl_ble_t * | val | ||
| ) |
Big/Little Endian data selection.[get].
| ctx | read / write interface definitions.(ptr) |
| val | Get the values of ble in reg CFG_REG_C.(ptr) |
| interface | status.(MANDATORY: return 0 -> no Error) |
Definition at line 929 of file lis2mdl_reg.c.
References lis2mdl_cfg_reg_c_t::ble, LIS2MDL_CFG_REG_C, LIS2MDL_LSB_AT_LOW_ADD, LIS2MDL_MSB_AT_LOW_ADD, and lis2mdl_read_reg().

| int32_t lis2mdl_data_format_set | ( | const stmdev_ctx_t * | ctx, |
| lis2mdl_ble_t | val | ||
| ) |
Big/Little Endian data selection.[set].
| ctx | read / write interface definitions.(ptr) |
| val | change the values of ble in reg CFG_REG_C |
| interface | status.(MANDATORY: return 0 -> no Error) |
Definition at line 905 of file lis2mdl_reg.c.
References lis2mdl_cfg_reg_c_t::ble, LIS2MDL_CFG_REG_C, lis2mdl_read_reg(), and lis2mdl_write_reg().

| int32_t lis2mdl_device_id_get | ( | const stmdev_ctx_t * | ctx, |
| uint8_t * | buff | ||
| ) |
DeviceWhoamI.[get].
| ctx | read / write interface definitions.(ptr) |
| buff | that stores data read |
| interface | status.(MANDATORY: return 0 -> no Error) |
Definition at line 759 of file lis2mdl_reg.c.
References lis2mdl_read_reg(), and LIS2MDL_WHO_AM_I.
Referenced by lis2mdl_init(), and lis2mdl_init_2().


| int32_t lis2mdl_reset_get | ( | const stmdev_ctx_t * | ctx, |
| uint8_t * | val | ||
| ) |
Software reset. Restore the default values in user registers.[get].
| ctx | read / write interface definitions.(ptr) |
| val | change the values of soft_rst in reg CFG_REG_A.(ptr) |
| interface | status.(MANDATORY: return 0 -> no Error) |
Definition at line 800 of file lis2mdl_reg.c.
References LIS2MDL_CFG_REG_A, lis2mdl_read_reg(), and lis2mdl_cfg_reg_a_t::soft_rst.
Referenced by lis2mdl_init(), and lis2mdl_init_2().


| int32_t lis2mdl_reset_set | ( | const stmdev_ctx_t * | ctx, |
| uint8_t | val | ||
| ) |
Software reset. Restore the default values in user registers.[set].
| ctx | read / write interface definitions.(ptr) |
| val | change the values of soft_rst in reg CFG_REG_A |
| interface | status.(MANDATORY: return 0 -> no Error) |
Definition at line 776 of file lis2mdl_reg.c.
References LIS2MDL_CFG_REG_A, lis2mdl_read_reg(), lis2mdl_write_reg(), and lis2mdl_cfg_reg_a_t::soft_rst.
Referenced by lis2mdl_init(), and lis2mdl_init_2().


| int32_t lis2mdl_self_test_get | ( | const stmdev_ctx_t * | ctx, |
| uint8_t * | val | ||
| ) |
Selftest.[get].
| ctx | read / write interface definitions.(ptr) |
| val | change the values of self_test in reg CFG_REG_C.(ptr) |
| interface | status.(MANDATORY: return 0 -> no Error) |
Definition at line 886 of file lis2mdl_reg.c.
References LIS2MDL_CFG_REG_C, lis2mdl_read_reg(), and lis2mdl_cfg_reg_c_t::self_test.

| int32_t lis2mdl_self_test_set | ( | const stmdev_ctx_t * | ctx, |
| uint8_t | val | ||
| ) |
Selftest.[set].
| ctx | read / write interface definitions.(ptr) |
| val | change the values of self_test in reg CFG_REG_C |
| interface | status.(MANDATORY: return 0 -> no Error) |
Definition at line 862 of file lis2mdl_reg.c.
References LIS2MDL_CFG_REG_C, lis2mdl_read_reg(), lis2mdl_write_reg(), and lis2mdl_cfg_reg_c_t::self_test.

| int32_t lis2mdl_status_get | ( | const stmdev_ctx_t * | ctx, |
| lis2mdl_status_reg_t * | val | ||
| ) |
Info about device status.[get].
| ctx | read / write interface definitions.(ptr) |
| val | registers STATUS_REG.(ptr) |
| interface | status.(MANDATORY: return 0 -> no Error) |
Definition at line 962 of file lis2mdl_reg.c.
References lis2mdl_read_reg(), and LIS2MDL_STATUS_REG.
