apache / mynewt-core

An OS to build, deploy and securely manage billions of devices
https://mynewt.apache.org/
Apache License 2.0
813 stars 365 forks source link

flash_test: Show printable characters along when read #3267

Closed kasjer closed 1 week ago

kasjer commented 1 week ago

So far flash read displayed data in hexadecimal format only. Now additional ascii values are shown for printable characters, which is common practice

Old format:

compat> flash 0 read 0x1d110100 0x20
Read 0x1d110100 + 32
  0x1d110100: 0x09 0x0f 0x00 0x6c 0x6f 0x67 0x2d 0x73
  0x1d110108: 0x74 0x6f 0x72 0x61 0x67 0x65 0x20 0xff

New format:

compat> flash 0 read 0x1d110100 0x20
Read 0x1d110100 + 32
  0x1d110100: 0x09 0x0f 0x00 0x6c 0x6f 0x67 0x2d 0x73  ...log-s
  0x1d110108: 0x74 0x6f 0x72 0x61 0x67 0x65 0x20 0xff  torage .