switec.h 452 B

123456789101112131415161718192021
  1. /*
  2. * Definitions to access the Switec driver
  3. */
  4. #ifndef __SWITEC_H__
  5. #define __SWITEC_H__
  6. #include <stdint.h>
  7. #define SWITEC_CHANNEL_COUNT 3
  8. int switec_setup(uint32_t channel, int *pin, int max_deg_per_sec, task_handle_t taskNumber );
  9. int switec_close(uint32_t channel);
  10. int switec_moveto(uint32_t channel, int pos);
  11. int switec_reset(uint32_t channel);
  12. int switec_getpos(uint32_t channel, int32_t *pos, int32_t *dir, int32_t *target);
  13. #endif