sensor: bmi160: move the printing macro to the header

The macro will be used in the upcoming trigger file.

Change-Id: I57a570fde37f31771b3d8bb9c028520fdc41da8f
Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com>
This commit is contained in:
Laurentiu Palcu 2016-04-15 18:26:23 +03:00 committed by Anas Nashif
parent b70278f113
commit 6330388bf5
2 changed files with 6 additions and 7 deletions

View file

@ -27,13 +27,6 @@
#include "sensor_bmi160.h"
#ifndef CONFIG_SENSOR_DEBUG
#define DBG(...) { ; }
#else
#include <misc/printk.h>
#define DBG(...) printk(CONFIG_BMI160_NAME ": " __VA_ARGS__)
#endif /* CONFIG_SENSOR_DEBUG */
struct bmi160_device_data bmi160_data;
static int bmi160_transceive(struct device *dev, uint8_t *tx_buf,

View file

@ -404,4 +404,10 @@ struct bmi160_device_data {
struct bmi160_scale scale;
};
#ifndef CONFIG_SENSOR_DEBUG
#define DBG(...) { ; }
#else
#include <misc/printk.h>
#define DBG(...) printk(CONFIG_BMI160_NAME ": " __VA_ARGS__)
#endif /* CONFIG_SENSOR_DEBUG */
#endif /* _BMI160_H_ */