Advertisement
wandrake

Untitled

Dec 8th, 2014
453
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.98 KB | None | 0 0
  1. main.c:
  2. =============================================================================
  3. palSetPadMode(IOPORTA, 27, PAL_MODE_OUTPUT_PUSHPULL);
  4.  
  5. pal.h:
  6. =============================================================================
  7. #if !defined(pal_lld_setpadmode) || defined(__DOXYGEN__)
  8. #define palSetPadMode(port, pad, mode)                                      \
  9.   palSetGroupMode(port, PAL_PORT_BIT(pad), 0, mode)
  10. #else
  11. #define palSetPadMode(port, pad, mode) pal_lld_setpadmode(port, pad, mode)
  12. #endif
  13.  
  14. #if !defined(pal_lld_setgroupmode) || defined(__DOXYGEN__)
  15. #define palSetGroupMode(port, mask, offset, mode)
  16. #else
  17. #define palSetGroupMode(port, mask, offset, mode)                           \
  18.   pal_lld_setgroupmode(port, mask, offset, mode)
  19. #endif
  20.  
  21. pal_lld.h:
  22. =============================================================================
  23. /*
  24. #define pal_lld_setgroupmode(port, mask, offset, mode)                      \
  25.   _pal_lld_setgroupmode(port, mask << offset, mode)
  26. */
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement