ATmega328P debugging, avr-stub doesn't halt

Hello,
I would like to debug my Arduino UNO (ATmega328P) using avr-stub (Without Arduino framework). If I create a project using the Arduino Framework, it works without any problems. However, I would like to do without the use of the Arduino Framework.
My configuration is as follows:
platformio.ini:

[env:ATmega328P]
platform = atmelavr
board = ATmega328P
board_build.mcu = atmega328p
board_build.f_cpu = 16000000L
upload_protocol = arduino

debug_init_break = tbreak main
debug_tool = avr-stub
debug_port = \.\COM16
lib_deps = jdolinay/avr-debugger @ ~1.4

I can successfully execute the following code:

#include “avr8-stub.h”
#include “app_api.h”
#include <avr/io.h>
#include <util/delay.h>

int main(void) {
debug_init();

DDRB |= (1 << DDB5);

breakpoint();

while(1)
{
PORTB |= (1 << PB5);
_delay_ms(500);
PORTB = 0;
_delay_ms(500);
}

return 1;
}
However, I am not able to halt the CPU even if I manually call the breakpoint() function. It is neither paused in the main(), nor can I pause by pressing the pause button

still interested in solving the problem