Sunday , 18 April 2021
iten

Issues with ST-Link


Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #3169
    tlamb96
    Participant

    I bought your book and love it but I ran into some issues. The book uses the STM32 Nucleo board but I have an STM32F4 Discovery board. Everything has been working unit I needed to use the ST-Link connection. I have tried following your book on both Windows and Linux and I kept getting stuck there. I have tried the ST supported ST-Link, QSTLink, and two well known Git repos. Can you please help me get the ST-Link to work with the STM32F4 Discovery on either Windows or Linux (preferably Linux)?

    Best,

    Ty

    #3172
    Carmine Noviello
    Keymaster

    Hi,
    Unfortunately I don’t have an STM32F4-Discovery to do tests. It sounds strange that QTStlink doesn’t recognize your board, since it is the most widespread development kit from ST. However, if you can also work in Windows, I suggest to use the official ST-LINK Utility from ST. Moreover, check if the ST-LINK firmware of your board is updated to the latest one (2.27.x).

    Finally, Chapter 5 shows how to configure OpenOCD to flash and debug STM32 microcontrollers using the ST-LINK debugger. I strongly suggest to use that way.

    #3316
    pedro
    Participant

    Hi

    Sorry, I have seen this post this morning…

    -Download stlink-master.zip from https://github.com/texane/stlink to ~/STM32Toolchain
    -unzip it
    -Dependencies in my system (kubuntu) autoconf automake automake1.4 m4 autotools-dev libusb-1.0-0 libusb-1.0-0-dev

    – $ cd ~/STM32Toolchain/stlink-master
    – $ ./autogen.sh
    – $ ./configure
    – $ make
    – $ sudo make install

    -Copy 49-stlinkv2.rules to /etc/udev/rules.d

    In Eclipse
    – Run->External Tools->External Tools configuration
    New Icon (as described in the book for openOCD
    Main tab
    Name st-linkv2
    Locations /usr/local/bin/st-flash
    Working Directory ${project_loc}/Release
    Arguments write ${project_name}.bin 0x8000000
    Click on Apply
    Click on Run

    Remember to set the output file format to Raw Binary
    -Project->Properties
    C/C++ Build-> Settings
    Tool Settings, Cross ARM GNU Create Flash Image-> General
    Output file Format (-O) Raw binary
    Click Apply and OK

    Regards,
    Pedro.


Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.