Skip to content

[minichlink] Incorrect log #588

Open
@BogdanTheGeek

Description

@BogdanTheGeek

minichlink reports "Image written" regardless of weather it actually flashed any device. It also returns code 0. I think it should return a non zero error code like ENOENT.
This is the log with no mcu attached to the programmer.

riscv64-unknown-elf-gcc -o bootloader.elf  bootloader.c ../rv003usb/rv003usb.S  -g -Os -flto -ffunction-sections -fdata-sections -fmessage-length=0 -msmall-data-limit=8 -march=rv32ec -mabi=ilp32e -DCH32V003 -static-libgcc -I/usr/include/newlib -I../ch32v003fun/ch32fun/../extralibs -I../ch32v003fun/ch32fun -nostdlib -I. -Wall -I. -I../lib -DUSE_TINY_BOOT -I../rv003usb -Wl,--print-memory-usage -Wl,-Map=bootloader.map -L../ch32v003fun/ch32fun/../misc -lgcc -lgcc -T ch32v003fun-usb-bootloader.ld -Wl,--gc-sections
Memory region         Used Size  Region Size  %age Used
           FLASH:        1868 B       1916 B     97.49%
          SECRET:           4 B          4 B    100.00%
             RAM:          96 B         2 KB      4.69%
riscv64-unknown-elf-objdump -S bootloader.elf > bootloader.lst
riscv64-unknown-elf-objcopy  -O binary bootloader.elf bootloader.bin
riscv64-unknown-elf-objcopy -O ihex bootloader.elf bootloader.hex
make -C ../ch32v003fun/ch32fun/../minichlink all
make[1]: Nothing to be done for `all'.
../ch32v003fun/ch32fun/../minichlink/minichlink -a -w bootloader.bin bootloader -B
Found WCH Link
WCH Programmer is LinkE version 2.8
Already Connected
Full Chip Type Reply: [4] 81-55-01-01-00-00-00-00-00
Unknown chip fallback
No detected chip.
Setup success
Interface Setup
Writing image
Chip Type: 000
Unknown chip type.  Report as bug with picture of chip.
Vendored: 00000000
marchid : 00000000
HARTINFO: 00000000

Image written.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions