fix: configure over cmake options
This commit is contained in:
parent
6e3b1d52a4
commit
11f1a79d6a
4 changed files with 24 additions and 13 deletions
include
|
@ -23,13 +23,6 @@
|
|||
*/
|
||||
#define MDB_MAXDBS 8
|
||||
|
||||
/**
|
||||
* @brief Indicates to which level to log
|
||||
*
|
||||
* @see include/log_levels.h
|
||||
*/
|
||||
#define LOG_LEVEL LOG_LEVEL_DEBUG
|
||||
|
||||
/**
|
||||
* @brief How many milli seconds to wait until poll timeout in main loop
|
||||
*/
|
||||
|
@ -37,4 +30,8 @@
|
|||
|
||||
#define PIFACE_GPIO_BASE 200
|
||||
|
||||
#ifndef LOG_LEVEL
|
||||
#define LOG_LEVEL LOG_LEVEL_INFO
|
||||
#endif
|
||||
|
||||
#endif /* CONTROLLER_CONTANTS_H */
|
||||
|
|
|
@ -3,9 +3,13 @@
|
|||
|
||||
#include <logger.h>
|
||||
|
||||
#define LOG_WIRING_DEBUG(x, ...) LOG_DEBUG(x, ##__VA_ARGS__)
|
||||
|
||||
#ifdef WIRING_PI_DEBUG
|
||||
#if WIRING_PI_DEBUG > 1
|
||||
#define LOG_WIRING_DEBUG(x, ...) LOG_DEBUG(x, ##__VA_ARGS__)
|
||||
#else
|
||||
#define LOG_WIRING_DEBUG(x, ...)
|
||||
#endif
|
||||
|
||||
#define wiringPiSetup() LOG_WIRING_DEBUG("wiringPi wiringPiSetup()")
|
||||
#define wiringPiSetupSys() LOG_WIRING_DEBUG("wiringPi wiringPiSetupSys()")
|
||||
#define pinMode(x,y) LOG_WIRING_DEBUG("wiringPi pinMode(%d, %d)", x, y)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue