Programming the STM32L152C8u6
You can use it as a programmer debugger. You just need to remove ST-LINK jumpers and use SWD connector to connect your micro.


You need to configure in the Cube (or bare register) SWD debug mode



And then connect GND to GND, SWCLK to PA14 and SWDIO to PA13 pin and NRST to NRST.