eagle_soc.h 1.4 KB

1234567891011121314151617181920212223242526272829303132
  1. #ifndef _SDK_OVERRIDE_EAGLE_SOC_H_
  2. #define _SDK_OVERRIDE_EAGLE_SOC_H_
  3. #include_next "eagle_soc.h"
  4. #define GPIO_SIGMA_DELTA 0x00000068 //defined in gpio register.xls
  5. #define GPIO_SIGMA_DELTA_SETTING_MASK (0x00000001ff)
  6. #define GPIO_SIGMA_DELTA_ENABLE 1
  7. #define GPIO_SIGMA_DELTA_DISABLE (~GPIO_SIGMA_DELTA_ENABLE)
  8. #define GPIO_SIGMA_DELTA_MSB 16
  9. #define GPIO_SIGMA_DELTA_LSB 16
  10. #define GPIO_SIGMA_DELTA_MASK (0x00000001<<GPIO_SIGMA_DELTA_LSB)
  11. #define GPIO_SIGMA_DELTA_GET(x) (((x) & GPIO_SIGMA_DELTA_MASK) >> GPIO_SIGMA_DELTA_LSB)
  12. #define GPIO_SIGMA_DELTA_SET(x) (((x) << GPIO_SIGMA_DELTA_LSB) & GPIO_SIGMA_DELTA_MASK)
  13. #define GPIO_SIGMA_DELTA_TARGET_MSB 7
  14. #define GPIO_SIGMA_DELTA_TARGET_LSB 0
  15. #define GPIO_SIGMA_DELTA_TARGET_MASK (0x000000FF<<GPIO_SIGMA_DELTA_TARGET_LSB)
  16. #define GPIO_SIGMA_DELTA_TARGET_GET(x) (((x) & GPIO_SIGMA_DELTA_TARGET_MASK) >> GPIO_SIGMA_DELTA_TARGET_LSB)
  17. #define GPIO_SIGMA_DELTA_TARGET_SET(x) (((x) << GPIO_SIGMA_DELTA_TARGET_LSB) & GPIO_SIGMA_DELTA_TARGET_MASK)
  18. #define GPIO_SIGMA_DELTA_PRESCALE_MSB 15
  19. #define GPIO_SIGMA_DELTA_PRESCALE_LSB 8
  20. #define GPIO_SIGMA_DELTA_PRESCALE_MASK (0x000000FF<<GPIO_SIGMA_DELTA_PRESCALE_LSB)
  21. #define GPIO_SIGMA_DELTA_PRESCALE_GET(x) (((x) & GPIO_SIGMA_DELTA_PRESCALE_MASK) >> GPIO_SIGMA_DELTA_PRESCALE_LSB)
  22. #define GPIO_SIGMA_DELTA_PRESCALE_SET(x) (((x) << GPIO_SIGMA_DELTA_PRESCALE_LSB) & GPIO_SIGMA_DELTA_PRESCALE_MASK)
  23. #endif