Atmega328p xplained mini board: uploading success, can't debug

Thank you very much @maxgerhardt
I try both -1 and -2:

[env:ATmega328P]
platform = atmelavr
board = ATmega328P
framework = arduino

;for upload
upload_protocol = custom
upload_flags =
    -C
    $PROJECT_PACKAGES_DIR/tool-avrdude/avrdude.conf
    -p
    atmega328p
    -Pusb
    -c
    xplainedmini
    -e
upload_command = avrdude $UPLOAD_FLAGS -U flash:w:$SOURCE:i

;for debug
debug_port = :2331
debug_load_cmds = 
debug_load_mode = manual
debug_tool = custom
debug_init_cmds =
  target remote $DEBUG_PORT
  file "$PROG_PATH"
  load C:\Users\wgt\Documents\PlatformIO\Projects\test_medbg\.pio\build\ATmega328P\firmware.elf
debug_server = 
  avarice
  -1 ;or -2
  --jtag
  COM10 
  --ignore-intr 
  :2331

An error occured:

Reading symbols from c:\Users\wgt\Documents\PlatformIO\Projects\test_medbg\.pio\build\ATmega328P\firmware.elf...
done.
PlatformIO Unified Debugger -> https://bit.ly/pio-debug
PlatformIO: debug_tool = custom
PlatformIO: Initializing remote target...
.pioinit:12: Error in sourced command file:
:2331: ϵͳ��ͼ���������ϲ����ϲ��������ϵ�Ŀ¼��

The target mcu is atmega328p, and the debug protocol supported by it is debugWIRE, does it need to switch between ISP and debugWIRE mode?

And the “2331” of “debug_port = :2331” has special meaning? Can I change it to some other numbers?

Best regards.