Revision 3106e8cc modules/NUCLEO-F401RE/module.h

View differences:

modules/NUCLEO-F401RE/module.h
91 91
/**
92 92
 * @brief   Event flag to be set on a USER_BUTTON interrupt.
93 93
 */
94
#define MODULE_OS_IOEVENTFLAGS_USERBUTTON       AOS_IOEVENT_FLAG(GPIOC_BUTTON)
94
#define MODULE_OS_IOEVENTFLAGS_USERBUTTON       AOS_IOEVENT_FLAG(PAL_PAD(LINE_BUTTON))
95 95

  
96 96
#if (AMIROOS_CFG_SHELL_ENABLE == true) || (AMIROOS_CFG_TESTS_ENABLE == true) || defined(__DOXYGEN__)
97 97
/**
......
106 106
 */
107 107
#define MODULE_INIT_INTERRUPTS() {                                            \
108 108
  /* user button */                                                           \
109
  palSetPadCallback(moduleGpioUserButton.gpio->port, moduleGpioUserButton.gpio->pad, _intCallback, &moduleGpioUserButton.gpio->pad);  \
110
  palEnablePadEvent(moduleGpioUserButton.gpio->port, moduleGpioUserButton.gpio->pad, APAL2CH_EDGE(moduleGpioUserButton.meta.edge));   \
109
  palSetLineCallback(moduleGpioUserButton.gpio->line, aosSysGetStdIntCallback(), &moduleGpioUserButton.gpio->line); \
110
  palEnableLineEvent(moduleGpioUserButton.gpio->line, APAL2CH_EDGE(moduleGpioUserButton.meta.edge));                \
111 111
}
112 112

  
113 113
/**

Also available in: Unified diff