Giter Site home page Giter Site logo

Comments (3)

jeanthom avatar jeanthom commented on June 5, 2024

from dirtyjtag.

metalstarlight avatar metalstarlight commented on June 5, 2024

Thanks, Jead.
I should say there is same problem with HID bootloader (https://github.com/Serasidis/STM32_HID_Bootloader).
Here is a log. Building from the source (last update on Dec 14, 2022):

  st-flash write dirtyjtag.bluepill.noloader.bin 0x8000000
  st-flash 1.7.0
  2023-01-17T02:00:32 INFO common.c: F1xx Medium-density: 20 KiB SRAM, 128 KiB flash in at least 1 KiB pages.
  file dirtyjtag.bluepill.noloader.bin md5 checksum: 3a94dd19ada294cd9b8399b599487f3, stlink checksum: 0x000dc45b
  2023-01-17T02:00:32 INFO common.c: Attempting to write 9232 (0x2410) bytes to stm32 address: 134217728 (0x8000000)
  2023-01-17T02:00:32 INFO common.c: Flash page at addr: 0x08000000 erased
  2023-01-17T02:00:32 INFO common.c: Flash page at addr: 0x08000400 erased
  2023-01-17T02:00:32 INFO common.c: Flash page at addr: 0x08000800 erased
  2023-01-17T02:00:32 INFO common.c: Flash page at addr: 0x08000c00 erased
  2023-01-17T02:00:32 INFO common.c: Flash page at addr: 0x08001000 erased
  2023-01-17T02:00:32 INFO common.c: Flash page at addr: 0x08001400 erased
  2023-01-17T02:00:32 INFO common.c: Flash page at addr: 0x08001800 erased
  2023-01-17T02:00:32 INFO common.c: Flash page at addr: 0x08001c00 erased
  2023-01-17T02:00:32 INFO common.c: Flash page at addr: 0x08002000 erased
  2023-01-17T02:00:32 INFO common.c: Flash page at addr: 0x08002400 erased
  2023-01-17T02:00:32 INFO common.c: Finished erasing 10 pages of 1024 (0x400) bytes
  2023-01-17T02:00:32 INFO common.c: Starting Flash write for VL/F0/F3/F1_XL
  2023-01-17T02:00:32 INFO flash_loader.c: Successfully loaded flash loader in sram
  2023-01-17T02:00:32 INFO flash_loader.c: Clear DFSR
   10/ 10 pages written
  2023-01-17T02:00:32 INFO common.c: Starting verification of write complete
  :~/DirtyJTAG/src$ md5sum dirtyjtag.bluepill.noloader.bin 
  3a94dd19ad0a294cd9b8399b599487f3  dirtyjtag.bluepill.noloader.bin

So, there is some warnings during compilation process.

Using pre-compilated release Version 2.0:

$ st-flash write dirtyjtag.bluepill.noloader.bin 0x8000000
st-flash 1.7.0
2023-01-17T02:13:37 INFO common.c: F1xx Medium-density: 20 KiB SRAM, 128 KiB flash in at least 1 KiB pages.
file dirtyjtag.bluepill.noloader.bin md5 checksum: dc87643c89d1b379476ddda919fbc853, stlink checksum: 0x000db627
2023-01-17T02:13:37 INFO common.c: Attempting to write 9224 (0x2408) bytes to stm32 address: 134217728 (0x8000000)
2023-01-17T02:13:37 INFO common.c: Flash page at addr: 0x08000000 erased
2023-01-17T02:13:37 INFO common.c: Flash page at addr: 0x08000400 erased
2023-01-17T02:13:37 INFO common.c: Flash page at addr: 0x08000800 erased
2023-01-17T02:13:37 INFO common.c: Flash page at addr: 0x08000c00 erased
2023-01-17T02:13:37 INFO common.c: Flash page at addr: 0x08001000 erased
2023-01-17T02:13:37 INFO common.c: Flash page at addr: 0x08001400 erased
2023-01-17T02:13:37 INFO common.c: Flash page at addr: 0x08001800 erased
2023-01-17T02:13:37 INFO common.c: Flash page at addr: 0x08001c00 erased
2023-01-17T02:13:37 INFO common.c: Flash page at addr: 0x08002000 erased
2023-01-17T02:13:37 INFO common.c: Flash page at addr: 0x08002400 erased
2023-01-17T02:13:37 INFO common.c: Finished erasing 10 pages of 1024 (0x400) bytes
2023-01-17T02:13:37 INFO common.c: Starting Flash write for VL/F0/F3/F1_XL
2023-01-17T02:13:37 INFO flash_loader.c: Successfully loaded flash loader in sram
2023-01-17T02:13:37 INFO flash_loader.c: Clear DFSR
2023-01-17T02:13:37 INFO flash_loader.c: Clear CFSR
2023-01-17T02:13:37 INFO flash_loader.c: Clear HFSR
 10/ 10 pages written
2023-01-17T02:13:37 INFO common.c: Starting verification of write complete
2023-01-17T02:13:37 INFO common.c: Flash written and verified! jolly good!

Here is an output from "BluePill Diagnostic tool" (https://mecrisp-stellaris-folkdoc.sourceforge.io/bluepill-diagnostics-v1.6.html) :

===========================================
Bluepill Diagnostics V1.640 - GPL3 Licensed
===========================================
h - test second Half of the 128KB flash declared for this chip
f - how much Flash is declared in the Flash Size Register ?
d - Print DBGMCU_IDCODE
a - STM32F103C8T6 Authenticity test, don't use with SWD/JTAG.
j - Jdec manufacturer id
e - Extra menu
q - Quit menu, enter the Forth command line
m - Main menu


Please wait, testing Flash ......


131072 flash is declared in the Flash size register at 0x1FFFF7E0


DBGMCU_IDCODE [@ 0xE0042000] = 0x20036410


STM32F103C8 authentication FAILED one or more tests:
----------------------------------------------------
FAIL - Declared flash not 65536
FAIL - DBGMCU_IDCODE is readable with no SWD/Jtag connected
PASS - Second 64KB flash block verified
PASS - JDEC manufacturer id IS STMicroelectronics


Jdec Continuation Code: 0x00
Jdec Identity Code: 0x20
JDEC manufacturer id: STMicroelectronics


----------
Extra Menu
----------
f - view First  64kb flash memory block: 0x00000 - 0x10000
s - view Second 64kb flash memory block: 0x10000 - 0x1FFFF
i - unique device Id
n - unique derived serial Number
a - fAQ
u - Usb faq
c - Credits
q - Quit back to main menu
m - Extra menu


UNIQUE DEVICE ID:
-----------------
BITS-95:64 | 0x41373931 | A791
BITS-63:32 | 0x31333915 | 139.
BITS-31:0  | 0x002D003F | .-.?


Unique Serial Number = 0x7029001B

from dirtyjtag.

jeanthom avatar jeanthom commented on June 5, 2024

Thanks for your report. It appears that you have an undocumented counterfeit STM32. I found a user on the net facing similar issues with their STM32 board: qmk/qmk_firmware#17605

Unfortunately I don't know where to investigate, and I can't justify spending a lot of time fixing buggy STM32 clones. If you ever find relevant resources about STM32 clones, or have a patch I could integrate, feel free to reach out.

from dirtyjtag.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.