ST-link clone by baite

rreignier
Posts: 17
Joined: Tue Feb 16, 2016 8:52 pm
Location: Toulon, France

Re: ST-link clone by baite

Post by rreignier » Thu Feb 16, 2017 1:52 am

RogerClark wrote: They only used F103C8 (64k) in their F103 version and only the F103CB version (128k) supports the UART in the STLink software as I think the UART version of the STLInk is just a little to big to fit in 64k. This is because the STLink has its own bootloader system, but the bootloader is quite large (possibly 20k I can't remember the precise details)
Ok, thanks for the clarification.
One more reason to use the BMP firmware instead ;)

mvcorrea
Posts: 3
Joined: Wed Dec 28, 2016 4:37 pm

Re: ST-link clone by baite

Post by mvcorrea » Wed Mar 29, 2017 6:05 am

hi there,

finished flashing a baite st-link clone into a BMP!
I am having a problem when trying to find connected targets!
bmp connected directly in a macbook usb port (target "bluepill" powered by the bmp)
any help is always welcomed :)

Code: Select all

% arm-none-eabi-gdb blink_v0.elf
GNU gdb (GNU Tools for ARM Embedded Processors) 7.6.0.20140731-cvs
Copyright (C) 2013 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "--host=x86_64-apple-darwin10 --target=arm-none-eabi".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /Users/mvcorrea/Private/vscode/ARMDEV_v0/projects/blink_v0/build/blink_v0.elf...done.
(gdb) target extended-remote /dev/cu.usbmodemE1C59EA1
Remote debugging using /dev/cu.usbmodemE1C59EA1
(gdb) monitor version
Black Magic Probe
Copyright (C) 2015  Black Sphere Technologies Ltd.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>

(gdb) mon tpwr enable
(gdb) monitor jtag_scan
Target voltage: 2.4V
JTAG device scan failed!
(gdb) monitor swdp_scan
Target voltage: 2.2V
SW-DP scan failed!
(gdb)
Target voltage: 2.3V
SW-DP scan failed!
(gdb)

mvcorrea
Posts: 3
Joined: Wed Dec 28, 2016 4:37 pm

Re: ST-link clone by baite

Post by mvcorrea » Thu Mar 30, 2017 3:21 am

I was forgetting, the baite st-link pcb changed from aliexpress pictures (they add the swd connectors)
Attachments
Screen Shot 2017-03-30 at 04.15.23.jpg
Screen Shot 2017-03-30 at 04.15.23.jpg (204.76 KiB) Viewed 499 times

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

Re: ST-link clone by baite

Post by RogerClark » Sat Jun 03, 2017 12:51 am

Thanks

My older variants only have the pads on the bottom which connect to PA9 and PA10 to reflash via Serial

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

Re: ST-link clone by baite

Post by RogerClark » Wed Jun 07, 2017 7:32 am

mvcorrea wrote:I was forgetting, the baite st-link pcb changed from aliexpress pictures (they add the swd connectors)
Did you get your Baite STLink to work as a BMP ?

I think I've finally managed to get mine to work, but the Serial UART behaves a bit strangely.

If I connect the TX and RX together, it does not work as serial loopback, however if I connect to an external USB to Serial adaptor, it sends and receives OK.


Also...

What MCU do they now use. Mine are old ones where they initially used a STM32F103C8, but from what I've heard the newer versions use the cheaper F101C8, as they don't need the additional hardware features in the F103C8

aster
Posts: 103
Joined: Thu Mar 30, 2017 2:41 pm
Location: bella italy
Contact:

Re: ST-link clone by baite

Post by aster » Thu Jun 08, 2017 2:13 pm

hello i confirm that now they use the stm32f101, not sure if it still possible to flash it with the BMP software

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

Re: ST-link clone by baite

Post by RogerClark » Thu Jun 08, 2017 10:04 pm

aster wrote:hello i confirm that now they use the stm32f101, not sure if it still possible to flash it with the BMP software
Thanks

The BMP appears to load Ok onto a different stlink which uses the f101, so I suspect it may still run ok on the new Baite version. Though I may order one of the new Baite versions, to make sure.

I have been looking at whether the BMP could be made to work on one of those STLink dongles in a rectangular metal tube, and I think it may be possible, but the BMP code would need a lot of modification as the UART Tx and Rx would need to be on different UART devices.

So I think the core part of STM version, would need to be updated to have a tx dev and rx device

devan
Posts: 50
Joined: Sat May 14, 2016 1:45 am

Re: ST-link clone by baite

Post by devan » Thu Jun 08, 2017 10:45 pm

RogerClark wrote:I have been looking at whether the BMP could be made to work on one of those STLink dongles in a rectangular metal tube, and I think it may be possible, but the BMP code would need a lot of modification as the UART Tx and Rx would need to be on different UART devices.

So I think the core part of STM version, would need to be updated to have a tx dev and rx device
It's definitely viable, as I mentioned off-hand once. I have some CDC-ACM test firmware that I run on metal STLink dongles (because when you work on debugger firmware as a hobby, debug dongles become your most available dev boards). It's pretty straightforward to configure USART1 as TX-only and USART3 as RX-only - it's mostly a bunch of extra config code, as you mentioned.

Here's a link to the code, if you're curious:
https://github.com/devanlai/termlink/bl ... sole.c#L65

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

Re: ST-link clone by baite

Post by RogerClark » Thu Jun 08, 2017 11:22 pm

Thanks @devan

It think it depends on the wiring of the dongle(s) which seems to vary

I'm trying to find a definitive schematic for one of the STLink's in the rectangular metal tube.

Imageg

It could be that RST is SWIM_RST, in which case its not a problem because UART can be on PB6 and PB7, but if RST means T_NRST that appears to be on another pin

The other problem seems to be the pullup and series resistors, as it prevents serial loopback working.

zmemw16
Posts: 1449
Joined: Wed Jul 08, 2015 2:09 pm
Location: St Annes, Lancs,UK

Re: ST-link clone by baite

Post by zmemw16 » Thu Jun 08, 2017 11:40 pm

one thing that's caught me, usually when i'm trying a different st-link is that the sequence of the sw-dat, sw-clk and ground pins in the 10 way connector changes.
so that's at least 2 types, so 4 if they've done the same using 101's :(
stephen

Post Reply