소스 검색

Reduce STM32F4 compile warnings

Scott Lahteine 6 년 전
부모
커밋
606a4362b3
3개의 변경된 파일3개의 추가작업 그리고 1개의 파일을 삭제
  1. 1
    0
      Marlin/src/HAL/HAL_STM32F4/HAL.h
  2. 1
    0
      Marlin/src/HAL/HAL_STM32F4/fastio_STM32F4.h
  3. 1
    1
      Marlin/src/core/macros.h

+ 1
- 0
Marlin/src/HAL/HAL_STM32F4/HAL.h 파일 보기

110
   #define NUM_SERIAL 1
110
   #define NUM_SERIAL 1
111
 #endif
111
 #endif
112
 
112
 
113
+#undef _BV
113
 #define _BV(b) (1 << (b))
114
 #define _BV(b) (1 << (b))
114
 
115
 
115
 /**
116
 /**

+ 1
- 0
Marlin/src/HAL/HAL_STM32F4/fastio_STM32F4.h 파일 보기

29
 #ifndef _FASTIO_STM32F4_H
29
 #ifndef _FASTIO_STM32F4_H
30
 #define _FASTIO_STM32F4_H
30
 #define _FASTIO_STM32F4_H
31
 
31
 
32
+#undef _BV
32
 #define _BV(b) (1 << (b))
33
 #define _BV(b) (1 << (b))
33
 
34
 
34
 #define USEABLE_HARDWARE_PWM(p) true
35
 #define USEABLE_HARDWARE_PWM(p) true

+ 1
- 1
Marlin/src/core/macros.h 파일 보기

57
 #define NANOSECONDS_PER_CYCLE (1000000000.0 / F_CPU)
57
 #define NANOSECONDS_PER_CYCLE (1000000000.0 / F_CPU)
58
 
58
 
59
 // Remove compiler warning on an unused variable
59
 // Remove compiler warning on an unused variable
60
-#define UNUSED(x) (void) (x)
60
+#define UNUSED(x) ((void)(x))
61
 
61
 
62
 // Macros to make a string from a macro
62
 // Macros to make a string from a macro
63
 #define STRINGIFY_(M) #M
63
 #define STRINGIFY_(M) #M

Loading…
취소
저장