[riot-notifications] [RIOT-OS/RIOT] board/nucleo-l412kb (#12144)

マリウス notifications at github.com
Mon Sep 2 12:10:06 CEST 2019


Thanks for the hints! I ran `brew install open-ocd --HEAD` and got what appears to be the latest master (`0819541`). After running it with that version, I got the same issue and there was a warning: `WARNING: interface/stlink-v2-1.cfg is deprecated, please switch to interface/stlink.cfg`. Hence I adjusted [https://github.com/RIOT-OS/RIOT/blob/master/makefiles/tools/openocd-adapters/stlink.inc.mk#L7](https://github.com/RIOT-OS/RIOT/blob/master/makefiles/tools/openocd-adapters/stlink.inc.mk#L7) to `  -c 'source [find interface/stlink.cfg]' \`. The warning disappeared, the issue still remained.

I've then investigated the open-ocd source and digged into `/src/flash/nor/stm32l4x.c`. It doesn't include the correct settings for device_id `0x10006464`, so I added the following lines:

```c
        case 0x464:
                max_flash_size_in_kb = 128;
                break;
```

<img width="670" alt="Screenshot 2019-09-02 at 12 02 24 PM" src="https://user-images.githubusercontent.com/151967/64106939-8f465980-cd79-11e9-815d-532e50c9abfa.png">

Then I basically compiled the code manually using:

```bash
# ./bootstrap nosubmodule
# ./configure --prefix=/usr/local/Cellar/open-ocd/HEAD-0819541 --enable-buspirate --enable-stlink --enable-dummy --enable-jtag_vpi --enable-remote-bitbang
# make install
```

(I used the same prefix as brew did since I have hopes for the open-ocd project to include these changes at some point, which would then overwrite my hack as a brew bottled installation)

Using this updated version I could finally flash the code and test the hello-world example:

<img width="984" alt="Screenshot 2019-09-02 at 12 07 06 PM" src="https://user-images.githubusercontent.com/151967/64107187-34613200-cd7a-11e9-9f4a-a9a1d79da573.png">

So I guess this PR could be tested and merged, if anyone feels like going through this procedure. 🤷‍♂ And no, I haven't opened an issue on open-ocd about this, because, SourceForge.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/RIOT-OS/RIOT/pull/12144#issuecomment-527090161
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20190902/520f6baa/attachment.htm>


More information about the notifications mailing list