From 45e62dbd9e964c74b24f7fcadad9b418f117e008 Mon Sep 17 00:00:00 2001 From: guowenxue <guowenxue@gmail.com> Date: Thu, 27 Jun 2019 15:11:42 +0800 Subject: [PATCH] update mqttd, add hardware configured in configure files --- mqttd/hal/hal.h | 21 +++++++++++++++++---- 1 files changed, 17 insertions(+), 4 deletions(-) diff --git a/mqttd/hal/hal.h b/mqttd/hal/hal.h index 9a1056c..5788ff8 100644 --- a/mqttd/hal/hal.h +++ b/mqttd/hal/hal.h @@ -14,13 +14,26 @@ #ifndef _HAL_H_ #define _HAL_H_ -#include "lylib/logger.h" +#include <wiringPi.h> -#include "led.h" -#include "relay.h" +#include "lylib/logger.h" +#include "etc/conf.h" + #include "ds18b20.h" #include "sht20.h" -int hal_init(void); +#define OFF 0 +#define ON 1 + +/* Three LEDs code */ +enum +{ + LED_R = 0, + LED_G, + LED_B, + LED_MAX, +}; + +int hal_init(hwconf_t *conf); #endif /* ----- #ifndef _HAL_H_ ----- */ -- Gitblit v1.9.1