cancel
Showing results for 
Search instead for 
Did you mean: 

STM32L4 default DFU mode verus Standalone

uwe2
Associate II
Posted on August 05, 2015 at 17:25

We used the DFUSE over USB successfully with several L152 designs. The L152 chips don t have a USB boot loader DFU like described in the AN2606 STM32 microcontroller system memory boot mode. (DFU SE via USB) So we download the slightly modified standalone DFU USB loader and everything works perfect with the L152 chips. We hoped to save this work with the L476 chips, cause there the DFU loader is already preprogrammed from factory.

I thought on the L476 devices the DFU over USB is preprogrammed from factory and all we have to do is to have a 32kHz Xtal and have the BOOT0 pin connected to ground (pattern 7). But this doesn t work like expected.

I also found on the Cube, that there is a DFUSE standalone project, which exactly does, what we want.

Can anybody explain, why there is this DFUSE standalone project, if ST already have preprogrammed this code directly at factory ?

Is the factory preprogrammed code more sensitive to 100% correct USB power settings or should it also work with 3.0 Volts ? Further explanation about the intentions of the 2 different DFU loaders would be highly appreciated.

#l476-dfu-factory-preprogrammed-?
29 REPLIES 29
stm32forum
Associate II
Posted on May 03, 2016 at 10:47

I agree with Clive, the board doesn't look routed optimal.

However its hard to say if you don't see the bottom layer etc.

You can try changing the lse driver with the LSEDRV bits in the RCC_BDCR register.

This must be changed before starting the LSE.

To do this all correct I recommend you to read chapter 3.4 (and the rest) of the datasheet I posted above.

Btw If you had read it as you say then you should have notice table 5.

🙂

israel
Associate II
Posted on May 03, 2016 at 15:52

Hi Edje, taks for your help.... all of you,

in fact I already read this document... and many outher... I don't understand somethings and I will read again whith calm.

I read a document that have a table with oscilator recomended by ST and the table has a MC306 6Pf and capacitors... I have a discovery kit too and in discovery use the same xtal and capacitor... so I just copy everything.... I think should work...However I will read this document again, and try undestand better...

I think should have some problem in my route... probably the problem should be this... could you help me ? Atacched the board Top, Botton and TOP AND BOTTON...

Ps: Sorry my english...

________________

Attachments :

01.png : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006I0gE&d=%2Fa%2F0X0000000bcN%2FcyjGIGt0RdcIs_5cFSbd4Cs8RSNIiCnS9urOH2fKTx0&asPdf=false

ALL.png : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006I0g9&d=%2Fa%2F0X0000000bcL%2FZdgi7AH.MO8a5jmpxRpXgdLNh00fPwAZA2HsuwFEkC0&asPdf=false

BOTTON.png : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006I0V5&d=%2Fa%2F0X0000000bcK%2FxAFyrhy04EDMl6oQ3QBqXnxvAqIYCd1SvQj5cOkFwN8&asPdf=false

TOP.png : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006I0fz&d=%2Fa%2F0X0000000bcH%2FIgb9.GjCAbVPMZSTF2SuQld6y8yggLZ1AJRjA93QMx8&asPdf=false
stm32forum
Associate II
Posted on May 03, 2016 at 16:13

Now I'm a bit confused.

Are you using the L4 or the F1.......

israel
Associate II
Posted on May 03, 2016 at 16:44

F1... exatly STM32F100RCT6B..... always ordered in mouser.com

http://www.mouser.com/ProductDetail/STMicroelectronics/STM32F100RCT6B/?qs=sGAEpiMZZMuoKKEcg8mMKD1d%252bdlWpiMrPHYzHQOHgtg%3d

Posted on May 03, 2016 at 17:57

The way the grounds are routed here give me significant pause. Simply being electrically connected is not a sufficient check, you have to consider the current flows, and switching between thick and thin traces is problematic.

Get someone with more PCB/CAD experience to review this.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
israel
Associate II
Posted on May 04, 2016 at 22:28

Hi clive, tks.

I was mesuring some signal here... in osciloscope... and e see something very stranged...

RTC has 3 pin (PC13/TAMPER , PC14/OSC IN and PC15/OSC OUT).

In my board I don't use the TAMPER function, I use the pin PC13 like input to read a buton (pull-down resistor), when I press button the pin is VCC when I release the pin is GND.

Reading the signals I observe that all signal inserted in PC13 is transfer to PC14 and PC15... (osc in , osc out) in first moment I thought should have a short-cut in my board... So I measure everithing and NO... it don't have some short-cut... So I thought, maybe my firmware has something wrong that I can't see.... I burn a firmware that use just the RTC and nothing more.... 

The signal inserted in PC13 continue in PC14 and PC15.... so I erase all memory of chip... no program in chip.... and the signal inserted in PC13 CONTINUE in PC14 and PC15..... 

So I thought ''certainly the chip this damaged'' don't have another explanation... So I get a new board/chip... tha same thing happens in new board/chip

After I tested in more 3 chip... and same thing happens....

I don't know why this happens and I don't know if this have some influence in don't start of xtal...

Somebody know explain this ??

I start to think that there is a spirit around me.... and his mission is don't allow my project works... 

Posted on May 05, 2016 at 00:38

PC13, PC14 and PC15 are all in the low power domain. PC13 has very low current drive capabilities.

What is the circuit, and component values, attached to the pin?

If you disconnect the pin does the crystal start/operate properly?

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
israel
Associate II
Posted on May 05, 2016 at 01:08

Hi Clive, in this case I don't think the pin low power is the problem,

I'm using it like input and the pulldown resistor is 12KOhm

Independent of be low power, what I can't understand is why the signal in PC13 is ''transfer'' to PC14 and PC15... this is question to me? This should not happens...

If I disconnect the pin PC13 the xtal don't start too.... but maybe all xtal here damage because this...  this is my fear... because I have just 5 board here... and all xtal already be weld in the board and test... maybe the signal of PC13 ''transfered'' to PC14 and PC15 has damaged the xtal... 

I don't have more xtal to test with one that never be weld in the board (new)...

If I erase all memory (no program) PC13 should not be transfer to PC14 and PC15... 

Posted on May 05, 2016 at 04:24

I can't explain your situation, are you sure you are measuring against a good ground, and all the VSS pins are solidly grounded, ie no floating nets

The pins are not 5V tolerant, and share a common power rail, so if you get the voltages wrong current will back-feed into those three pins. The oscillator pins have a very small voltage swing, the output doesn't go rail-to-rail.

Unprogrammed these pins should all be inputs.

Step back and try and replicate the behaviour on a Discovery Board

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
israel
Associate II
Posted on May 05, 2016 at 14:17

I measure everything many times in 5 boards... 

I will measure again.... 

When a detect this I would want measure in discovery kit... but I insert 127VAC in kit.... rsrsr... so I can't measure something in discovery... I already ordered a new discovery... I need wait arrive... 

Thank you very much...