From 77cd229a995ee571fa6174e7a1ba5ab21247d062 Mon Sep 17 00:00:00 2001 From: MiraculousConch Date: Fri, 20 Oct 2017 14:33:31 +0800 Subject: [PATCH] =?UTF-8?q?[DeviceDrivers]=E6=B7=BB=E5=8A=A0pin=E5=BC=80?= =?UTF-8?q?=E6=BC=8F=E5=92=8C=E4=B8=8B=E6=8B=89=E8=BE=93=E5=85=A5=E5=AE=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [DeviceDrivers]添加pin开漏和下拉输入宏 --- components/drivers/include/drivers/pin.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/components/drivers/include/drivers/pin.h b/components/drivers/include/drivers/pin.h index a76798e28..051d51a43 100644 --- a/components/drivers/include/drivers/pin.h +++ b/components/drivers/include/drivers/pin.h @@ -20,6 +20,7 @@ * Change Logs: * Date Author Notes * 2015-01-20 Bernard the first version + * 2017-10-20 ZYH add mode open drain and input pull down */ #ifndef PIN_H__ @@ -49,6 +50,8 @@ struct rt_device_pin #define PIN_IRQ_MODE_RISING 0x00 #define PIN_IRQ_MODE_FALLING 0x01 #define PIN_IRQ_MODE_RISING_FALLING 0x02 +#define PIN_MODE_INPUT_PULLDOWN 0x03 +#define PIN_MODE_OUTPUT_OD 0x04 #define PIN_IRQ_DISABLE 0x00 #define PIN_IRQ_ENABLE 0x01 -- GitLab