* \return The larger of the two input parameters
*/
#if !defined(MAX) || defined(__DOXYGEN__)
- #define MAX(x, y) ((x > y) ? x : y)
+ #define MAX(x, y) (((x) > (y)) ? (x) : (y))
#endif
/** Convenience macro to determine the smaller of two values.
* \return The smaller of the two input parameters
*/
#if !defined(MIN) || defined(__DOXYGEN__)
- #define MIN(x, y) ((x < y) ? x : y)
+ #define MIN(x, y) (((x) < (y)) ? (x) : (y))
#endif
#if !defined(STRINGIFY) || defined(__DOXYGEN__)
*
* \param[in] Milliseconds Number of milliseconds to delay
*/
- static inline void Delay_MS(uint8_t Milliseconds) ATTR_ALWAYS_INLINE;
- static inline void Delay_MS(uint8_t Milliseconds)
+ static inline void Delay_MS(uint16_t Milliseconds) ATTR_ALWAYS_INLINE;
+ static inline void Delay_MS(uint16_t Milliseconds)
{
#if (ARCH == ARCH_AVR8)
if (GCC_IS_COMPILE_CONST(Milliseconds))