soburi / zephyr_porting_gd32v

https://soburi.github.io/zephyr_porting_gd32v/
7 stars 0 forks source link

Programming with usb and dfu-util #2

Closed Martoni closed 3 years ago

Martoni commented 3 years ago

Hello, I'm trying to flash longan nano zephyr sample/basic/blinky example with the USB interface without success.

I used this dfu-util version. With the following command :

$ dfu-util -d 28e9:0189 -a 0 --dfuse-address 0x08000000:leave -D build/zephyr/zephyr.bin 
dfu-util 0.9

Copyright 2005-2009 Weston Schmidt, Harald Welte and OpenMoko Inc.
Copyright 2010-2016 Tormod Volden and Stefan Schmidt
This program is Free Software and has ABSOLUTELY NO WARRANTY
Please report bugs to http://sourceforge.net/p/dfu-util/tickets/

dfu-util: Invalid DFU suffix signature
dfu-util: A valid DFU suffix will be required in a future dfu-util release!!!
Opening DFU capable USB device...
ID 28e9:0189
Run-time device DFU version 011a
Claiming USB DFU Interface...
Setting Alternate Setting #0 ...
Determining device status: state = dfuIDLE, status = 0
dfuIDLE, continuing
DFU mode device DFU version 011a
Device returned transfer size 2048
GD32 flash memory access detected
Device model: GD32VF103CB
Memory segment (0x08000000 - 0801ffff)(rew)
Erase size 1024, page count 128
Downloading to address = 0x08000000, size = 23728
Download    [=========================] 100%        23728 bytes
Download done.
File downloaded successfully
dfu-util: Error during download get_status

Have you tryied to use dfu mode with usb ?

soburi commented 3 years ago

The file that is distributed by sipeed is worked with this commandline.

dfu-util -d,28e9:0189 -s 0x8000000 -a 0 -D ../build_hello_world/zephyr/zephyr.bin

http://dl.sipeed.com/fileList/LONGAN/platformio/dl-packages/tool-gd32vflash-v0.1.0-linux.tar.gz

Martoni commented 3 years ago

Thanks,

That download binary without error. I don't have the blinking led yet but it downloads \o/