From 6fc7b7627313d2850895237d30c9e0ae2ee70ab3 Mon Sep 17 00:00:00 2001 From: Vegard Storheil Eriksen Date: Sun, 22 Jan 2012 10:55:51 +0100 Subject: Enable pullup on DP. --- main.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/main.cpp b/main.cpp index 2898f2b..2fafeb6 100644 --- a/main.cpp +++ b/main.cpp @@ -42,9 +42,12 @@ int main() { led_red.on(); led_blue.off(); + usb_vbus.set_mode(Pin::Input); usb_dm.set_mode(Pin::AF); + usb_dm.set_pull(Pin::PullNone); usb_dm.set_af(10); usb_dp.set_mode(Pin::AF); + usb_dp.set_pull(Pin::PullUp); usb_dp.set_af(10); RCC.enable(RCC.OTGFS); -- cgit v1.2.3