Fixed conflicting macro name

This commit is contained in:
jgromes 2021-03-02 11:19:04 +01:00
parent ef7a8b6e0f
commit 1bceb90d42

View file

@ -1,4 +1,4 @@
#ifndef _RADIOLIB_BUILD_OPTIONS_H #if !defined(_RADIOLIB_BUILD_OPTIONS_H)
#define _RADIOLIB_BUILD_OPTIONS_H #define _RADIOLIB_BUILD_OPTIONS_H
#if ARDUINO >= 100 #if ARDUINO >= 100
@ -391,7 +391,7 @@
* possibly leading to bricked module and/or program crashing. * possibly leading to bricked module and/or program crashing.
* Note: Enabled by default. * Note: Enabled by default.
*/ */
#define RADIOLIB_CHECK_RANGE #define RADIOLIB_CHECK_PARAMS
/* /*
* Uncomment to enable god mode - all methods and member variables in all classes will be made public, thus making them accessible from Arduino code. * Uncomment to enable god mode - all methods and member variables in all classes will be made public, thus making them accessible from Arduino code.
@ -424,7 +424,7 @@
/*! /*!
\brief Macro to check variable is within constraints - this is commonly used to check parameter ranges. Requires RADIOLIB_CHECK_RANGE to be enabled \brief Macro to check variable is within constraints - this is commonly used to check parameter ranges. Requires RADIOLIB_CHECK_RANGE to be enabled
*/ */
#if defined(RADIOLIB_CHECK_RANGE) #if defined(RADIOLIB_CHECK_PARAMS)
#define RADIOLIB_CHECK_RANGE(VAR, MIN, MAX, ERR) { if(!(((VAR) >= (MIN)) && ((VAR) <= (MAX)))) { return(ERR); } } #define RADIOLIB_CHECK_RANGE(VAR, MIN, MAX, ERR) { if(!(((VAR) >= (MIN)) && ((VAR) <= (MAX)))) { return(ERR); } }
#else #else
#define RADIOLIB_CHECK_RANGE(VAR, MIN, MAX, ERR) {} #define RADIOLIB_CHECK_RANGE(VAR, MIN, MAX, ERR) {}