Skip to content

Commit

Permalink
Remove Underscore from Macro Names
Browse files Browse the repository at this point in the history
  • Loading branch information
iabdalkader committed Jan 22, 2014
1 parent 28b23f0 commit 630d8ff
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 30 deletions.
6 changes: 3 additions & 3 deletions stm/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -803,7 +803,7 @@ int main(void) {
rt_store_attr(m, MP_QSTR_switch, (mp_obj_t)&pyb_switch_obj);
rt_store_attr(m, MP_QSTR_servo, rt_make_function_n(2, pyb_servo_set));
rt_store_attr(m, MP_QSTR_pwm, rt_make_function_n(2, pyb_pwm_set));
#if __HAVE_MMA7660
#if HAVE_MMA7660
rt_store_attr(m, MP_QSTR_accel, (mp_obj_t)&pyb_mma_read_obj);
rt_store_attr(m, MP_QSTR_mma_read, (mp_obj_t)&pyb_mma_read_all_obj);
rt_store_attr(m, MP_QSTR_mma_mode, (mp_obj_t)&pyb_mma_write_mode_obj);
Expand Down Expand Up @@ -923,7 +923,7 @@ int main(void) {
//pyb_usbh_init();

if (first_soft_reset) {
#if __HAVE_MMA7660
#if HAVE_MMA7660
// MMA: init and reset address to zero
mma_init();
#endif
Expand Down Expand Up @@ -954,7 +954,7 @@ int main(void) {
}


#if __HAVE_MMA7660
#if HAVE_MMA7660
// HID example
if (0) {
uint8_t data[4];
Expand Down
54 changes: 27 additions & 27 deletions stm/mpconfigport.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,15 +28,15 @@ machine_float_t machine_sqrt(machine_float_t x);
//#define STM32F4DISC

#if defined (PYBOARD)
#define __HAVE_SWITCH (1)
#define __HAVE_SDCARD (1)
#define __HAVE_MMA7660 (1)
#define __HAVE_LIS3DSH (0)
#define __ENABLE_RNG (1)
#define __ENABLE_RTC (1)
#define __ENABLE_TIMER (1)
#define __ENABLE_SERVO (1)
#define __ENABLE_AUDIO (0)
#define HAVE_SWITCH (1)
#define HAVE_SDCARD (1)
#define HAVE_MMA7660 (1)
#define HAVE_LIS3DSH (0)
#define ENABLE_RNG (1)
#define ENABLE_RTC (1)
#define ENABLE_TIMER (1)
#define ENABLE_SERVO (1)
#define ENABLE_AUDIO (0)

#define USRSW_PORT (GPIOA)
#define USRSW_PIN (GPIO_Pin_13)
Expand All @@ -47,15 +47,15 @@ machine_float_t machine_sqrt(machine_float_t x);
#define USRSW_EXTI_IRQN (EXTI15_10_IRQn)
#define USRSW_EXTI_EDGE (EXTI_Trigger_Rising)
#elif defined (PYBOARD4)
#define __HAVE_SWITCH (1)
#define __HAVE_SDCARD (1)
#define __HAVE_MMA7660 (1)
#define __HAVE_LIS3DSH (0)
#define __ENABLE_RNG (1)
#define __ENABLE_RTC (1)
#define __ENABLE_TIMER (1)
#define __ENABLE_SERVO (1)
#define __ENABLE_AUDIO (0)
#define HAVE_SWITCH (1)
#define HAVE_SDCARD (1)
#define HAVE_MMA7660 (1)
#define HAVE_LIS3DSH (0)
#define ENABLE_RNG (1)
#define ENABLE_RTC (1)
#define ENABLE_TIMER (1)
#define ENABLE_SERVO (1)
#define ENABLE_AUDIO (0)

#define USRSW_PORT (GPIOB)
#define USRSW_PIN (GPIO_Pin_3)
Expand All @@ -66,15 +66,15 @@ machine_float_t machine_sqrt(machine_float_t x);
#define USRSW_EXTI_IRQN (EXTI15_10_IRQn)
#define USRSW_EXTI_EDGE (EXTI_Trigger_Rising)
#elif defined (STM32F4DISC)
#define __HAVE_SWITCH (1)
#define __HAVE_SDCARD (0)
#define __HAVE_MMA7660 (0)
#define __HAVE_LIS3DSH (1)
#define __ENABLE_RNG (1)
#define __ENABLE_RTC (1)
#define __ENABLE_TIMER (1)
#define __ENABLE_SERVO (0)
#define __ENABLE_AUDIO (0)
#define HAVE_SWITCH (1)
#define HAVE_SDCARD (0)
#define HAVE_MMA7660 (0)
#define HAVE_LIS3DSH (1)
#define ENABLE_RNG (1)
#define ENABLE_RTC (1)
#define ENABLE_TIMER (1)
#define ENABLE_SERVO (0)
#define ENABLE_AUDIO (0)

#define USRSW_PORT (GPIOA)
#define USRSW_PIN (GPIO_Pin_0)
Expand Down

0 comments on commit 630d8ff

Please sign in to comment.