diff options
author | Giovanni Di Sirio <gdisirio@gmail.com> | 2018-12-01 19:30:36 +0000 |
---|---|---|
committer | Giovanni Di Sirio <gdisirio@gmail.com> | 2018-12-01 19:30:36 +0000 |
commit | 179aa7224e72affbf92c2fc4b1f08fee13c92427 (patch) | |
tree | 163b44bb75b7cb1118940a77013af5aba5a76f47 /os | |
parent | 37a5f0bc07554548ca516f6d46af9a69b24bed16 (diff) | |
download | ChibiOS-179aa7224e72affbf92c2fc4b1f08fee13c92427.tar.gz ChibiOS-179aa7224e72affbf92c2fc4b1f08fee13c92427.tar.bz2 ChibiOS-179aa7224e72affbf92c2fc4b1f08fee13c92427.zip |
USB tested on L4+.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@12447 110e8d01-0319-4d1e-a829-52ad28d1bb01
Diffstat (limited to 'os')
-rw-r--r-- | os/hal/boards/ST_NUCLEO144_L496ZG/board.h | 6 | ||||
-rw-r--r-- | os/hal/boards/ST_NUCLEO144_L496ZG/cfg/board.chcfg | 4 | ||||
-rw-r--r-- | os/hal/boards/ST_NUCLEO144_L4R5ZI/board.h | 6 | ||||
-rw-r--r-- | os/hal/boards/ST_NUCLEO144_L4R5ZI/cfg/board.chcfg | 6 | ||||
-rw-r--r-- | os/hal/ports/STM32/LLD/OTGv1/hal_usb_lld.h | 2 |
5 files changed, 12 insertions, 12 deletions
diff --git a/os/hal/boards/ST_NUCLEO144_L496ZG/board.h b/os/hal/boards/ST_NUCLEO144_L496ZG/board.h index f9a381983..294d81b0a 100644 --- a/os/hal/boards/ST_NUCLEO144_L496ZG/board.h +++ b/os/hal/boards/ST_NUCLEO144_L496ZG/board.h @@ -298,7 +298,7 @@ * PA6 - PIN6 (analog).
* PA7 - PIN7 (analog).
* PA8 - USB_SOF (alternate 10).
- * PA9 - USB_VBUS (input pullup).
+ * PA9 - USB_VBUS (analog).
* PA10 - USB_ID (alternate 10).
* PA11 - USB_DM (alternate 10).
* PA12 - USB_DP (alternate 10).
@@ -315,7 +315,7 @@ PIN_MODE_ANALOG(GPIOA_PIN6) | \
PIN_MODE_ANALOG(GPIOA_PIN7) | \
PIN_MODE_ALTERNATE(GPIOA_USB_SOF) | \
- PIN_MODE_INPUT(GPIOA_USB_VBUS) | \
+ PIN_MODE_ANALOG(GPIOA_USB_VBUS) | \
PIN_MODE_ALTERNATE(GPIOA_USB_ID) | \
PIN_MODE_ALTERNATE(GPIOA_USB_DM) | \
PIN_MODE_ALTERNATE(GPIOA_USB_DP) | \
@@ -363,7 +363,7 @@ PIN_PUPDR_FLOATING(GPIOA_PIN6) | \
PIN_PUPDR_FLOATING(GPIOA_PIN7) | \
PIN_PUPDR_FLOATING(GPIOA_USB_SOF) | \
- PIN_PUPDR_PULLUP(GPIOA_USB_VBUS) | \
+ PIN_PUPDR_FLOATING(GPIOA_USB_VBUS) | \
PIN_PUPDR_FLOATING(GPIOA_USB_ID) | \
PIN_PUPDR_FLOATING(GPIOA_USB_DM) | \
PIN_PUPDR_FLOATING(GPIOA_USB_DP) | \
diff --git a/os/hal/boards/ST_NUCLEO144_L496ZG/cfg/board.chcfg b/os/hal/boards/ST_NUCLEO144_L496ZG/cfg/board.chcfg index fa064dee7..5eaf00890 100644 --- a/os/hal/boards/ST_NUCLEO144_L496ZG/cfg/board.chcfg +++ b/os/hal/boards/ST_NUCLEO144_L496ZG/cfg/board.chcfg @@ -45,8 +45,8 @@ PinLock="Disabled" Alternate="10" ID="USB_SOF" Resistor="Floating"
Mode="Alternate" Level="Low" />
<pin9 Type="PushPull" Speed="Minimum" AnalogSwitch="Disabled"
- PinLock="Disabled" Alternate="0" ID="USB_VBUS" Resistor="PullUp"
- Mode="Input" Level="Low" />
+ PinLock="Disabled" Alternate="0" ID="USB_VBUS" Resistor="Floating"
+ Mode="Analog" Level="Low" />
<pin10 Type="PushPull" Speed="Maximum" AnalogSwitch="Disabled"
PinLock="Disabled" Alternate="10" ID="USB_ID" Resistor="Floating"
Mode="Alternate" Level="Low" />
diff --git a/os/hal/boards/ST_NUCLEO144_L4R5ZI/board.h b/os/hal/boards/ST_NUCLEO144_L4R5ZI/board.h index 464399327..b4cca1eba 100644 --- a/os/hal/boards/ST_NUCLEO144_L4R5ZI/board.h +++ b/os/hal/boards/ST_NUCLEO144_L4R5ZI/board.h @@ -298,7 +298,7 @@ * PA6 - PIN6 (analog).
* PA7 - PIN7 (analog).
* PA8 - USB_SOF (alternate 10).
- * PA9 - USB_VBUS (input pullup).
+ * PA9 - USB_VBUS (analog).
* PA10 - USB_ID (alternate 10).
* PA11 - USB_DM (alternate 10).
* PA12 - USB_DP (alternate 10).
@@ -315,7 +315,7 @@ PIN_MODE_ANALOG(GPIOA_PIN6) | \
PIN_MODE_ANALOG(GPIOA_PIN7) | \
PIN_MODE_ALTERNATE(GPIOA_USB_SOF) | \
- PIN_MODE_INPUT(GPIOA_USB_VBUS) | \
+ PIN_MODE_ANALOG(GPIOA_USB_VBUS) | \
PIN_MODE_ALTERNATE(GPIOA_USB_ID) | \
PIN_MODE_ALTERNATE(GPIOA_USB_DM) | \
PIN_MODE_ALTERNATE(GPIOA_USB_DP) | \
@@ -363,7 +363,7 @@ PIN_PUPDR_FLOATING(GPIOA_PIN6) | \
PIN_PUPDR_FLOATING(GPIOA_PIN7) | \
PIN_PUPDR_FLOATING(GPIOA_USB_SOF) | \
- PIN_PUPDR_PULLUP(GPIOA_USB_VBUS) | \
+ PIN_PUPDR_FLOATING(GPIOA_USB_VBUS) | \
PIN_PUPDR_FLOATING(GPIOA_USB_ID) | \
PIN_PUPDR_FLOATING(GPIOA_USB_DM) | \
PIN_PUPDR_FLOATING(GPIOA_USB_DP) | \
diff --git a/os/hal/boards/ST_NUCLEO144_L4R5ZI/cfg/board.chcfg b/os/hal/boards/ST_NUCLEO144_L4R5ZI/cfg/board.chcfg index 2c506d1e5..ca5ad6a81 100644 --- a/os/hal/boards/ST_NUCLEO144_L4R5ZI/cfg/board.chcfg +++ b/os/hal/boards/ST_NUCLEO144_L4R5ZI/cfg/board.chcfg @@ -119,8 +119,8 @@ PinLock="Disabled"
Alternate="0"
ID="USB_VBUS"
- Resistor="PullUp"
- Mode="Input"
+ Resistor="Floating"
+ Mode="Analog"
Level="Low" />
<pin10
Type="PushPull"
@@ -141,7 +141,7 @@ ID="USB_DM"
Resistor="Floating"
Mode="Alternate"
- Level="Low" />
+ Level="Low" ></pin11>
<pin12
Type="PushPull"
Speed="Maximum"
diff --git a/os/hal/ports/STM32/LLD/OTGv1/hal_usb_lld.h b/os/hal/ports/STM32/LLD/OTGv1/hal_usb_lld.h index addfd9858..31cb87a58 100644 --- a/os/hal/ports/STM32/LLD/OTGv1/hal_usb_lld.h +++ b/os/hal/ports/STM32/LLD/OTGv1/hal_usb_lld.h @@ -239,7 +239,7 @@ #define STM32_USBCLK STM32_PLL48CLK
#elif defined(STM32F10X_CL)
#define STM32_USBCLK STM32_OTGFSCLK
-#elif defined(STM32L4XX)
+#elif defined(STM32L4XX) || defined(STM32L4XXP)
#define STM32_USBCLK STM32_48CLK
#elif defined(STM32H7XX)
/* Defines directly STM32_USBCLK.*/
|