bma253(179).h 769 B

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. /**
  2. * @brief : this
  3. * @file : bma253.h
  4. * @version : v0.0.1
  5. * @author : gang.cheng
  6. * @date : 2017-06-01
  7. * change logs :
  8. * Date Version Author Note
  9. * 2017-06-01 v0.0.1 gang.cheng first version
  10. */
  11. #ifndef __BMA_253_H__
  12. #define __BMA_253_H__
  13. #include "bma253_defs.h"
  14. #include "common/lib/lib.h"
  15. #define WATERMARK_COUNT (25u)
  16. typedef enum
  17. {
  18. BMA253_GET_FRAME_COUNT,
  19. BMA253_CLR_FRAME_COUNT,
  20. BMA253_GET_TEMPERATURE,
  21. } BMA253_CMD_E;
  22. typedef struct _bma253_context
  23. {
  24. uint8_t i2c_addr;
  25. // use the fifo
  26. bool_t use_fifo;
  27. // accelerationg scaling
  28. fp32_t acc_scale;
  29. } bma253_context_t;
  30. void bma253_device_init(void);
  31. #define ACC_SENSOR_NAME "BMA253"
  32. #endif