eventUnit.h 499 B

123456789101112131415161718192021
  1. #ifndef __EVENTUNIT_H
  2. #define __EVENTUNIT_H
  3. #include <stdio.h>
  4. #include <stdint.h>
  5. #include <stdbool.h>
  6. typedef struct
  7. {
  8. bool reload; //
  9. uint32_t count; //
  10. uint32_t countSet; //
  11. }eventParams_ts;
  12. void eventDriver(void);
  13. void setEvent(uint16_t mask, bool reload, uint32_t timeOut_ms);
  14. void event_post(uint16_t mask);
  15. void event_clear(uint16_t mask);
  16. uint16_t event_pend(void);
  17. uint16_t getEvent(uint16_t event, uint16_t mask);
  18. #endif