Custom STM32F103C8T6

If you made your own board, post here, unless you built a Maple or Maple mini clone etc
User avatar
Slammer
Posts: 251
Joined: Tue Mar 01, 2016 10:35 pm
Location: Athens, Greece

Re: Custom STM32F103C8T6

Post by Slammer » Mon Jun 06, 2016 8:45 pm

No remove of resistors, no break of board.
Just remove the two jumpers on CN2 (see photo). The only problem I had with Nucleo-STLInk is that RESET pin is required for reseting the target system (or you have to reset manually by button or other way) . Note that VCC cannot power the target board from ST-Link (unlike the cheap ST-Link Dongles), is only for sensing the target voltage, but in Nucleo-STLink is NOT used. Note the TX & RX at CN3, these signals go to USB-CDC.
Attachments
nucleo.jpeg
nucleo.jpeg (44.67 KiB) Viewed 659 times
Last edited by Slammer on Mon Jun 06, 2016 8:54 pm, edited 1 time in total.

randybb
Posts: 11
Joined: Fri Sep 11, 2015 5:26 pm
Location: Slovakia

Re: Custom STM32F103C8T6

Post by randybb » Mon Jun 06, 2016 8:48 pm

But these jumpers are for SWD interface only. In case you want to use serial interface as well, then you need to remove mentioned 0 ohm resistors.

User avatar
Slammer
Posts: 251
Joined: Tue Mar 01, 2016 10:35 pm
Location: Athens, Greece

Re: Custom STM32F103C8T6

Post by Slammer » Mon Jun 06, 2016 8:57 pm

Yes! correct! Serial is available either by removing of SB14/SB15, either by breaking the ST-Link from the board.
The price of the board is so low and I think it is possible for someone to buy it, just for the ST-Link part (and keep the rest as a bonus).

User avatar
Rick Kimball
Posts: 1038
Joined: Tue Apr 28, 2015 1:26 am
Location: Eastern NC, US
Contact:

Re: Custom STM32F103C8T6

Post by Rick Kimball » Mon Jun 06, 2016 9:14 pm

randybb wrote:But these jumpers are for SWD interface only. In case you want to use serial interface as well, then you need to remove mentioned 0 ohm resistors.
I just pull the power jumper to the target chip and it won't read or write on the serial pins. Oh and I use the power there to power the target off board chip
-rick

User avatar
Vassilis
Posts: 320
Joined: Thu May 21, 2015 6:42 am
Location: Thessaloniki, Greece
Contact:

Re: Custom STM32F103C8T6

Post by Vassilis » Tue Jun 07, 2016 6:27 am

Rick Kimball wrote:
randybb wrote:But these jumpers are for SWD interface only. In case you want to use serial interface as well, then you need to remove mentioned 0 ohm resistors.
I just pull the power jumper to the target chip and it won't read or write on the serial pins. Oh and I use the power there to power the target off board chip
Nice tip Rick!

User avatar
Slammer
Posts: 251
Joined: Tue Mar 01, 2016 10:35 pm
Location: Athens, Greece

Re: Custom STM32F103C8T6

Post by Slammer » Tue Jun 07, 2016 1:41 pm

Rick Kimball wrote:I just pull the power jumper to the target chip and it won't read or write on the serial pins. Oh and I use the power there to power the target off board chip
:D Very Nice! Is this trick safe? The pins of MCU will have power while the MCU itself no, can this cause a damage?

User avatar
Rick Kimball
Posts: 1038
Joined: Tue Apr 28, 2015 1:26 am
Location: Eastern NC, US
Contact:

Re: Custom STM32F103C8T6

Post by Rick Kimball » Tue Jun 07, 2016 3:49 pm

I haven't seen any issues from doing this. However, it doesn't mean your results will be the same
-rick

testato
Posts: 39
Joined: Sun Aug 14, 2016 7:44 am

Re: Custom STM32F103C8T6

Post by testato » Mon Sep 26, 2016 12:47 pm

Slammer wrote:No remove of resistors, no break of board.
Just remove the two jumpers on CN2 (see photo). The only problem I had with Nucleo-STLInk is that RESET pin is required for reseting the target system (or you have to reset manually by button or other way) . Note that VCC cannot power the target board from ST-Link (unlike the cheap ST-Link Dongles), is only for sensing the target voltage, but in Nucleo-STLink is NOT used. Note the TX & RX at CN3, these signals go to USB-CDC.
Witch MCU model is there on Nucleo StLink ?
We may open the STdongle and if it is the same maybe is possible copy the fw from the STnucleo to the STdongle ?

A second question: is it possible use mass storage upload by the Bluepill onboard USB instead of the STLInk ?
The datasheet tell that the F103 have the mass storage profile

User avatar
RogerClark
Posts: 7157
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: Custom STM32F103C8T6

Post by RogerClark » Mon Sep 26, 2016 9:13 pm

The STLink firmware is read protected, but I have seen copies of it in some Russian sites, as someone figured out who to hack the Windows program that does the firmware upgrade, and extracted the unencrypted binary from Windows memory.

Re:Usb mass storage

The STM32F103 does not have any built in USB profiles, ( unlike the F4).
You can write code so that its any form of USB device you want, but you have run code in the MCU to do this.

If you feel like writing a mass storage bootloader, please go ahead, but remember you wont be able to use the HAL or CMSIS etc as the code needs to be ultra small ( less then 0x2000 to be comparable with the existing DFU bootloader)

User avatar
Slammer
Posts: 251
Joined: Tue Mar 01, 2016 10:35 pm
Location: Athens, Greece

Re: Custom STM32F103C8T6

Post by Slammer » Mon Sep 26, 2016 9:43 pm

The hacked firmware is for STLink/V2 not for V2.1
V2.1 adds some very important features like mass storage upload and USB/Serial passthrough, as I understand nobody has cloned the V2.1 (this is included on all Nucleo boards) as all Chinese clones support V2 operations.
If we compare the code size of BlackMagic (which is also a debuger/serial passtrough device), I dont think that would be possible to include this functionality in the code memory of a typical F103C8 as bootloader (and to have spare memory for a real application)
Last edited by Slammer on Mon Sep 26, 2016 10:08 pm, edited 1 time in total.

Post Reply