aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal
diff options
context:
space:
mode:
authorMichael Walker <walkerstop@gmail.com>2018-05-01 03:26:28 -0700
committerMichael Walker <walkerstop@gmail.com>2018-05-01 03:26:28 -0700
commit0fbddccd80d3f7f27d2d9286b5e280b53a9e8bd0 (patch)
tree555dd3b1f4cb1a11a1aef96755e26717f7579d88 /os/hal
parent46233064c5527da13c9ea1668a41659a7f8e9a45 (diff)
downloadChibiOS-Contrib-0fbddccd80d3f7f27d2d9286b5e280b53a9e8bd0.tar.gz
ChibiOS-Contrib-0fbddccd80d3f7f27d2d9286b5e280b53a9e8bd0.tar.bz2
ChibiOS-Contrib-0fbddccd80d3f7f27d2d9286b5e280b53a9e8bd0.zip
disable voltage inrush regulator
Diffstat (limited to 'os/hal')
-rw-r--r--os/hal/ports/KINETIS/LLD/hal_usb_lld.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/os/hal/ports/KINETIS/LLD/hal_usb_lld.c b/os/hal/ports/KINETIS/LLD/hal_usb_lld.c
index 77421c8..7b7aa0e 100644
--- a/os/hal/ports/KINETIS/LLD/hal_usb_lld.c
+++ b/os/hal/ports/KINETIS/LLD/hal_usb_lld.c
@@ -461,9 +461,15 @@ void usb_lld_start(USBDriver *usbp) {
_bdt[i].addr=0;
}
+#if defined(MK66F18)
+ /* Disable the USB current limiter */
+ SIM->USBPHYCTL |= SIM_USBPHYCTL_USBDISILIM;
+#endif
+
/* Enable Clock */
#if KINETIS_USB0_IS_USBOTG
SIM->SCGC4 |= SIM_SCGC4_USBOTG;
+
#else /* KINETIS_USB0_IS_USBOTG */
SIM->SCGC4 |= SIM_SCGC4_USBFS;
#endif /* KINETIS_USB0_IS_USBOTG */