cancel
Showing results for 
Search instead for 
Did you mean: 

stm32L452CEU6 usb doesnt work with Samsung GalaxyTab A8

anees
Associate II

I have a board design based on stm32L452 , USB gets recognized on a windows PC and I can talk to the device over any software like putty and a Test software sees the com port and can to the device. However in Android (Iam using samsung  GalaxyTab A8), usb is not even recognized. The Tab support OTG mode and I did change default USB mode in the tab (Tried all the combo, file transfer, teethering, media etc). Nothing helps. Any advice is greatly appreciated

 

32 REPLIES 32

We will check that.

How we can enable debug message from USB lib and where we can see these messages?

You need SWO /swd , then if enable the debug msg in Cube setup, see it.

+ in Cube set debug -> 

 

AScha3_0-1715006605639.png

(search/read here in forum, how to do - i wrote it > 2 times. )

If you feel a post has answered your question, please click "Accept as Solution".

I have followed the previous recommendation and enabled debug message in cube ide setup and enabled SWO in debug configuration. But, when I tried to print a sample string "Hello" I got some junk values. Could you please confirm if there is any other configuration?

 

jaindevasy_1-1715085635887.png

 

Just few updates

1) Tried USB mass storage, it came up on windows and mac but not working in Android

2) CDC driver same behavior , works in windows and mac but not in android

3) Use the external clk so crs_sync is no longer used

4) USB D- and D+ are correct. Its just a connector naming issue ( otherwise as u said it wouldnt work in windows or mac)

In all combinations, so far it works in windows/mac but not in android. We are basically stuck with this issue.

Currently looking at pulling log information via SWD, even though message comes out, its all scrambled , why would it be?  clk issue ?

for clarity, we are not setup for 48M for USB from HSE/PLL.

What else we can try? 

1) Try another android tab ? ( we are using galaxy A8 and A2, same behaviour)

2) Heard there is an Android sim software that can run on PC? may be try that and see?

Any other suggestions?

SWO output looks like wrong speed setting.

Did you set the real cpu core clk frequency in debug ?

->

AScha3_0-1715090551878.png

 

+

>for clarity, we are not setup for 48M for USB from HSE/PLL.

eh ? not 48M or just using HSI ?

If you feel a post has answered your question, please click "Accept as Solution".

Core frequency we set to 80MHz, which is the frequency the controller running

for clarity, we are setup for 48M for USB from HSE/PLL. (sorry about typo, it is 48M for USB from HSE/PLL)

Ok, and also correct clock in debug -> swo settings -> 

AScha3_0-1715093445448.png

(here on H563 at 250M )

If you feel a post has answered your question, please click "Accept as Solution".

Below are the settings we done

jaindevasy_2-1715096431473.png