title: How do I use "ST-link GDB server"
body: <p>I installed the ST-Link GDB server from the ST webpage (link)</p>
  <p>ST created <em>&quot;ST-Link Server&quot;</em> (<a href="https://www.st.com/en/development-tools/st-link-server.html" rel="nofollow noreferrer">link</a>) which bridges the architecture gap and enables us to comfortably monitor and debug the <em>&quot;running binary&quot;</em> (<code>arm</code> architecture) on our workstation PC (<code>x86</code> or <code>x86_64</code> architercture) using the <em>&quot;GDB&quot;</em> debugger.</p>
  <p>To install the <em>&quot;ST-Link Server&quot;</em> I first download it's <code>.zip</code> file that I can get on the bottom of the page that i linked in the previous paragraph:</p>
  <p><a href="https://i.stack.imgur.com/NPSRG.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/NPSRG.png" alt="enter image description here" /></a></p>
  <p>Then I uncompress it and run the <code>.msi</code> file that can be found in the compressed file structure. Note that installation wizard will install a command line tool <code>stlinkserver.exe</code> inside the folder:</p>
  <pre><code>/mnt/c/Program\ Files\ \(x86\)/STMicroelectronics/stlink_server/
  </code></pre>
  <p>So I move inside and prompt for help:</p>
  <pre><code>ziga@EN3310278:~$ cd /mnt/c/Program\ Files\ \(x86\)/STMicroelectronics/stlink_server/
  ziga@EN3310278:stlink_server$ ./stlinkserver.exe --help
  stlink-server
  --help       | -h       display this help
  --version    | -v       display STLinkserver version
  --port       | -p       set tcp listening port
  --debug      | -d       set debug level &lt;0-5&gt; (incremental, 0: Error, 1:Info, 2:Warning, 3:STlink, 4:Debug, 5:Usb)
  --auto-exit  | -a       exit() when there is no more client
  --log_output | -l       redirect log output to file &lt;name&gt;
  </code></pre>
  <p>There are very little parameters listed! Weird... Also useless... This seemed weird to me so I investigated further.</p>
  <p><em>&quot;ST-Link Server&quot;</em> has a nice documentation <em>&quot;UM2576&quot;</em> (<a href="https://www.st.com/resource/en/user_manual/um2576-stm32cubeide-stlink-gdb-server-stmicroelectronics.pdf" rel="nofollow noreferrer">link</a>). But in the documentation there are more parameters listed than <code>stlinkserver.exe</code> returns to us.</p>
  <p>At this point I was so confused that I tried executing one parameter i.e. <code>-g</code> listed in the <em>&quot;UM2576&quot;</em> and application really failed to recognize the parameter:</p>
  <pre><code>ziga@EN3310278:stlink_server$ ./stlinkserver.exe -g
  stlinkserver.exe: unknown option -- g
  Info : default port : 7184
  Info : 127.0.0.1:7184
  Info : ctrl_handler 0
  Ctrl-C event
  </code></pre>
  <p>What is going on with ST? Why doesn't the <em>&quot;ST-Link GDB server&quot;</em> work? How do you use it? I am really confused... And most importantly... I can not connect to my board?</p>
  <p>Should I just throw in the towel and use J-Link or OpenOCD???</p>