Skip to content

write-mem seems not to be working? #44

Description

@thirstyone

something strange is going on.
the first time I did wlink dump 0x08003fc0 64 i got:

23:56:02 [INFO] WCH-Link v2.11 (WCH-LinkE-CH32V305)
23:56:02 [INFO] Attached chip: CH32V003 [CH32V003J4M6] (ChipID: 0x00330500)
23:56:02 [INFO] Read memory from 0x08003fc0 to 0x08004000
Length: 64 (0x40) bytes | printable whitespace ascii_other non_ascii
08003fc0:   ff ff ff ff  ff ff ff ff  ff ff ff ff  ff ff ff ff   ××××××××××××××××
08003fd0:   ff ff ff ff  ff ff ff ff  ff ff ff ff  ff ff ff ff   ××××××××××××××××
08003fe0:   ff ff ff ff  ff ff ff ff  ff ff ff ff  ff ff ff ff   ××××××××××××××××
08003ff0:   ff ff ff ff  ff ff ff ff  ff ff ff ff  ff ff ff ff   ××××××××××××××××

Then immediately I did it the second time: wlink dump 0x08003fc0 64
I got:

23:56:05 [INFO] WCH-Link v2.11 (WCH-LinkE-CH32V305)
23:56:05 [INFO] Attached chip: CH32V003 (ChipID: 0x73655207)
23:56:05 [INFO] Read memory from 0x08003fc0 to 0x08004000
Length: 64 (0x40) bytes | printable whitespace ascii_other non_ascii
08003fc0:   ff ff ff ff  ff ff ff ff  ff ff ff ff  ff ff ff ff   ××××××××××××××××
08003fd0:   ff ff ff ff  ff ff ff ff  ff ff ff ff  ff ff ff ff   ××××××××××××××××
08003fe0:   ff ff ff ff  ff ff ff ff  ff ff ff ff  ff ff ff ff   ××××××××××××××××
08003ff0:   ff ff ff ff  ff ff ff ff  ff ff ff ff  ff ff ff ff   ××××××××××××××××

See the changes in chip id?
then I did wlink write-mem 0x08003fc0 0:
23:57:28 [INFO] WCH-Link v2.11 (WCH-LinkE-CH32V305) 23:57:28 [INFO] Attached chip: CH32V003 (ChipID: 0xffffffff) 23:57:28 [INFO] Write memory 0x00000000 to 0x08003fc0
Then I rechecked it with wlink dump 0x08003fc0 64 and got:

23:57:34 [INFO] WCH-Link v2.11 (WCH-LinkE-CH32V305)
23:57:34 [INFO] Attached chip: CH32V003 (ChipID: 0x74617405)
23:57:34 [INFO] Read memory from 0x08003fc0 to 0x08004000
Length: 64 (0x40) bytes | printable whitespace ascii_other non_ascii
08003fc0:   ff ff ff ff  ff ff ff ff  ff ff ff ff  ff ff ff ff   ××××××××××××××××
08003fd0:   ff ff ff ff  ff ff ff ff  ff ff ff ff  ff ff ff ff   ××××××××××××××××
08003fe0:   ff ff ff ff  ff ff ff ff  ff ff ff ff  ff ff ff ff   ××××××××××××××××
08003ff0:   ff ff ff ff  ff ff ff ff  ff ff ff ff  ff ff ff ff   ××××××××××××××××

So, I tried once again: wlink write-mem 0x08003fc0 10 and got

23:58:29 [INFO] WCH-Link v2.11 (WCH-LinkE-CH32V305)
23:58:30 [INFO] Attached chip: CH32V003 (ChipID: 0xffffffff)
23:58:30 [INFO] Write memory 0x0000000a to 0x08003fc0

After checking with wlink dump 0x08003fc0 64 I got:

23:58:37 [INFO] WCH-Link v2.11 (WCH-LinkE-CH32V305)
23:58:37 [INFO] Attached chip: CH32V003 (ChipID: 0x0000000a)
23:58:37 [INFO] Read memory from 0x08003fc0 to 0x08004000
Length: 64 (0x40) bytes | printable whitespace ascii_other non_ascii
08003fc0:   ff ff ff ff  ff ff ff ff  ff ff ff ff  ff ff ff ff   ××××××××××××××××
08003fd0:   ff ff ff ff  ff ff ff ff  ff ff ff ff  ff ff ff ff   ××××××××××××××××
08003fe0:   ff ff ff ff  ff ff ff ff  ff ff ff ff  ff ff ff ff   ××××××××××××××××
08003ff0:   ff ff ff ff  ff ff ff ff  ff ff ff ff  ff ff ff ff   ××××××××××××××××

What is going on with chip-id? am I doing something wrong?

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions