cancel
Showing results for 
Search instead for 
Did you mean: 

Toggling PA10

allard
Senior

I'm trying to use PA10 to drive a simple LED (custom board), but the I/O doesn't switch at all.

PA10 is not used in any of the device trees.

gpioinfo gpiochip0

reports the I/O as "unused" and "output", but switching the I/O with

gpioset gpiochip0 10=1

doesn't work. The voltage on the pin stays at 1.7V.

PA10 can also function as OTG_FS_ID or OTG_HS_ID, so maybe this causes problems? I do not use USB in my kernel device tree.

5 REPLIES 5
PatrickF
ST Employee

Please check uBoot DT regarding PA10, which might still be activated as OTG_ID pin.

See https://wiki.st.com/stm32mpu/wiki/How_to_configure_U-Boot_for_your_board#USB_OTG_node

Regards.

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
allard
Senior

My u-boot devicetree contains:

&usbotg_hs{
	u-boot,dm-pre-reloc;
 
	/* USER CODE BEGIN usbotg_hs */
	u-boot,force-b-session-valid;
	hnp-srp-disable;
	dr_mode = "peripheral";
	/* USER CODE END usbotg_hs */
};

So, the ID pin should be unused in uBoot?

Are you using the latest Openstlinux-5.4-dunfell-mp1-20-11-12 ?

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.
allard
Senior

I'm at 20-06-24 with DISTRO_VERSION 3.1-snapshot-20210201

OlivierK
ST Employee

​Hi allard (Community Member),

VDD3V3_USBFS is used to supply OTG_VBUS and OTG_ID (PA10) pins. So,

VDD3V3_USBFS must be supplied as well when USB high-speed dual-role-port or USB

high-speed device is used. If not used, should be connected to VDD.

This is an extract of the App note

https://www.st.com/resource/en/application_note/dm00389996-getting-started-with-stm32mp151-stm32mp153-and-stm32mp157-line-hardware-development-stmicroelectronics.pdf

Regards,

Olivier