Git Product home page Git Product logo

Comments (79)

MotoMaxis avatar MotoMaxis commented on May 16, 2024 2

Sergio, it looks like you have used the wrong image for recovery the first time around. But don't worry, we'll get you up and running. You just need the correct DFU, FPGA, LOGO, SYS and APP reflashed.

It says hw 2.82 on your PCB and the boot screen says hw 2.60. It means the DFU is wrong too that uses slightly different license check code which explains why your old code didn't work. Now You will need to flash the Unlock app and enter the license to fix the license error after flashing the correct DFU..

Starting with hw 2.81 they have changed the memory layout which means older software can't be used with 2.8x as it will corrupt things.

I happen to have hw 2.82 device and did a rom dump using Wildcat's firmware. My device has the DFU 3.46C, Wildcats custom FPGA with full speed oversampling, and his software v6.5. Yes it's far from stock but it should put things where they belong.

I have included the full dump and the Unlock app. First flash the dump HW_V282_DFU_V346C_WC_V65.zip. Then see if DFU is working and mounts then load the Unlock app. Reboot and try entering the license. (DFU = 3.46C ser: 8726B9A3 lic: 7A9457A7)

Then load the SYS_B164.zip to remove the Unlock app.

After this, your device should be fully working and pass the license check. You can now experiment once again :) As long as nothing overwrites the DFU code you can flash whatever you want (LOGO, FPGA, SYS, APP).

Good luck.

P.S. Sorry I just realized the hex file of the dump I made is wrong (offset) so only use the bin file. Also removed it from this archive.

P.P.S. Just a note about older DFU. It seems to have issues with some computers and operating systems. So you might want to try with different hardware.

from la104.

Sergio- avatar Sergio- commented on May 16, 2024 2

Hi Folks. Thanks for the suggestions.

The command below did the trick on my Linux machine:
sudo mkfs.msdos -s 1 -n DSO203 -f 2 -v -F 12 -S 4096 -r 512 -I /dev/sdb

I believe with that all the functions are back to normal. I didn't start using the device, but I believe it should be fine.

Thanks a lot @MotoMaxis @gabonator @Quas7 for the effort in helping restoring the device. I believe this thread now contains a good knowledge to help others with similar issues. :-)

@gabonator Back to the original theme of this thread... Is there a way to install your version on the v2.82 Hardware? Is there any information I can extract from my device that can help you with that?

Thanks a lot.

from la104.

gabonator avatar gabonator commented on May 16, 2024

Try this firmware:
system_ds203.hex.zip

And copy these files to devices:
ds203apps.zip

If it won't work, please send here screenshot of the root of the device's filesystem

from la104.

Compycompy avatar Compycompy commented on May 16, 2024

Hi gab,
I tried to flash clean with the RS232 port, all was smooth, I copied the sys_b164.hex and all started correctly.
I loaded the system_ds203.hex, it was accepted. Turned off, then on asking for shell.elf (which at this point is fine).
I copied the ds203apps (uncompressed), turned off then on but still asking for shell.elf :-(
On the device directory I have the seven elf files, CALIB.DAT and CONFIG.DAT
Thanks for the help

from la104.

gabonator avatar gabonator commented on May 16, 2024

I just tried the files I provided and with the same result as in your case. For some strange reason, the filesystem gets corrupted when I copied all the files at once. After reconnecting I saw only empty root folder. But when I copied only the shell.elf to the disk, it worked. And then when the shell was loaded I copied remaining elf files. So please try to delete all *.elf files you copied before and copy only "shell.elf". Or try copying the file until the device will find it, possibly device format could help (dont forget to backup your CALIB.DAT and CONFIG.DAT)

from la104.

Compycompy avatar Compycompy commented on May 16, 2024

Unfortunately no luck always missing shell.elf (tried to format both quick and standard). I tried either pressing f1 directly after copying or doing power cycle (several times).
I will try with another PC/OS maybe it helps.
Thank you!

from la104.

gabonator avatar gabonator commented on May 16, 2024

Just out of curiosity, please drop here screenshot of the disk root and hex view of the shell.elf

from la104.

Compycompy avatar Compycompy commented on May 16, 2024

Hi,
this is the shell.elf hex view and the folder.
image

image

thank you!

from la104.

gabonator avatar gabonator commented on May 16, 2024

try running "fsutil fsinfo sectorInfo e:" and "fsutil fsinfo ntfsinfo e:", this should show us how the disk is formatted, the disk should have 4096 sectors and every sector should have 512 bytes, on OSX:

$ sudo diskutil info /dev/disk2                                      ↑
   Device Identifier:         disk2
   Device Node:               /dev/disk2
   Whole:                     Yes
   Part of Whole:             disk2
   Device / Media Name:       Flash Disk

   Volume Name:               DS203
   Mounted:                   No

   Content (IOContent):       None
   File System Personality:   MS-DOS FAT12
   Type (Bundle):             msdos
   Name (User Visible):       MS-DOS (FAT12)

   OS Can Be Installed:       No
   Media Type:                Generic
   Protocol:                  USB
   SMART Status:              Not Supported
   Volume UUID:               FC397130-DDE8-3700-94A9-F8B250F2079E

   Disk Size:                 2.1 MB (2097152 Bytes) (exactly 4096 512-Byte-Units)
   Device Block Size:         512 Bytes

   Volume Total Space:        0 B (0 Bytes) (exactly 0 512-Byte-Units)
   Volume Free Space:         0 B (0 Bytes) (exactly 0 512-Byte-Units)

   Read-Only Media:           No
   Read-Only Volume:          Not applicable (not mounted)

   Device Location:           External
   Removable Media:           Removable
   Media Removal:             Software-Activated

   Solid State:               Info not available
   Virtual:                   No

from la104.

Compycompy avatar Compycompy commented on May 16, 2024

Hello gab,
my disk size is 8mb not 2, could that be a problem?
I try to run the command later today from linux.
thank you

from la104.

gabonator avatar gabonator commented on May 16, 2024

Yes that is a problem, the disk parameters are hard coded in the firmware. I do not own DS203 with 8MB disk, but if you can tell me what is the sector size and how many sectors are in that disk, I can prepare a build for you (and for others who own this newer version of DSO203), on linux try this command "fdisk -l"

from la104.

Compycompy avatar Compycompy commented on May 16, 2024

From what I can see from windows it is exactly 8.388.608 byte with 4096 byte/sector and 2048 total sectors.
I can look with the command under linux if needed.

from la104.

gabonator avatar gabonator commented on May 16, 2024

Try this
system_ds203hd.hex.zip
ds203apps.zip

from la104.

Compycompy avatar Compycompy commented on May 16, 2024

Copied in DFU mode the new system, now it goes directly in file manager mode.
Reboot and in normal mode I copied the shell.elf
Reboot and goes into file manager, if I choose the shell.elf some text appears quickly at the bottom (cannot see what is coming up) and then goes back to the file manager like if nothing happened.
I copied all the other elf files, they all work with the exception of miniosc.elf which gives an hardware error.

image

from la104.

gabonator avatar gabonator commented on May 16, 2024

Try one of these, maybe it will work. Their (minidso's) bios use different memory layout, because it needs bigger buffer for the filesystem (4k vs. 512), so I tried to build the app for different memory locations:
Archive.zip

from la104.

Compycompy avatar Compycompy commented on May 16, 2024

No luck always hardware fault :-(
Btw I noticed that since I flashed the new system file it quickly says at boot FPGA configuration error, but then it continues without problems.

from la104.

gabonator avatar gabonator commented on May 16, 2024

Without having access to your device it is very difficult to fix this issue. And when it says that there is problem with FPGA, then also the oscilloscope functions wont work even when the application was running.

from la104.

Compycompy avatar Compycompy commented on May 16, 2024

Ok thanks a lot anyway. The FPGA error has been resolved with the recovery with serial. Do you know if I can copy the old version of your system on the 8m version? (the GAB_N1.hex, N2, N3 and N4)

from la104.

acidg avatar acidg commented on May 16, 2024

I did quite the same as @Compycompy and ended up with the FPGA configuration error and corrupted logo. I have HW version 2.72. Any chance to get this working or revert to the old version?

First try:

Next try:

  • Flashed system_ds203hd.hex from above in DFU mode
  • Rebooted normally (without holding F1-button)
  • Copied shell.elf from ds203apps.zip above
  • Copied webosc.elf from ds203apps.zip

Starting webosc using the file manager didn't work with Chrome and https://l.valky.eu/webusbds203v2. So I tried with PulseView and selecting "Openbench ...(ols)" as input and got this error:
IMG20201113182912

Trying to revert:
I tried to flash a lot of different firmwares, including the old https://github.com/gabonator/DS203 GAB_N1.hex and GAB_O1.hex and the latest original firmware from http://minidso.com/forum.php?mod=viewthread&tid=666&extra=page%3D1
This resulted in the FPGA configuration error.

//edit:
tried one more time to flash GAB_N1.hex and was successful 🙂 Still would be interested in trying the new version though!

from la104.

acidg avatar acidg commented on May 16, 2024

@Compycompy can you tell me how you did the recovery with serial? Where did you get the binaries for the FPGA?

from la104.

gabonator avatar gabonator commented on May 16, 2024

Hello guys, do any of you have working 8MB device with original fw? Could you please share flash image of your device? I am trying to put together all flash images for recovery purposes. Thank you! (fyi: @nutz88)

from la104.

Sergio- avatar Sergio- commented on May 16, 2024

Hi.
I wish I saw this earlier. I had a DSO203 8Mb working until few minutes ago. I tried to updated the firmware and now I'm stuck on the "Image 'shell.elf' not found" message. :-(

from la104.

acidg avatar acidg commented on May 16, 2024

You can find the original fw for HW version <= 2.72 here: http://jpa.kapsi.fi/dsoquad/ as DS203.V2.72.zip

from la104.

Sergio- avatar Sergio- commented on May 16, 2024

Forgot to mention: My Hardware version is 2.82, Sys ver 1.64.
Is there firmware out there I can use to put the device back to work? I tried putting the GAB_N1.hex into the DFU disk, but only got the ERR file back. I'm using Ubuntu 20.04 as Environment.
Thank you.

from la104.

acidg avatar acidg commented on May 16, 2024

You can find Firmware 2.81 with FPGA binaries for HW version >= 2.82 here: http://minidso.com/forum.php?mod=viewthread&tid=666&extra=page%3D1
I repacked the files for you: DS203_2.81_HW2.82.zip

from la104.

Sergio- avatar Sergio- commented on May 16, 2024

You can find Firmware 2.81 with FPGA binaries for HW version >= 2.82 here: http://minidso.com/forum.php?mod=viewthread&tid=666&extra=page%3D1
I repacked the files for you: DS203_2.81_HW2.82.zip

Hello @acidg Thanks so much for putting this together. Really appreciate it.
All went well, except the last file (PA1_V113.hex). I tried putting it in several times, it always return as ERR. I even tried the dfuload method, but I was not able to put the device back to work. It always returns the "FPGA configuration error" message.
Do you guys think this is permanent damaged or do we still have ways to recover it?
Thank you.
image
By the way, I'm adding a dmesg portion of when the device is connected, to the PC, if that helps somehow....
image

from la104.

Sergio- avatar Sergio- commented on May 16, 2024

Ok thanks a lot anyway. The FPGA error has been resolved with the recovery with serial. Do you know if I can copy the old version of your system on the 8m version? (the GAB_N1.hex, N2, N3 and N4)

Hi @Compycompy Could you please point us or share how to proceed with the serial recovery to fix the FPGA issue? Thank you.

from la104.

gabonator avatar gabonator commented on May 16, 2024

@Sergio- it is nearly impossible to brick the device, DS203 can be recovered using the internal uart connection: https://github.com/gabonator/LA104/tree/master/tools/stm32flash
You will need uart converter (3.3V) for this

from la104.

Sergio- avatar Sergio- commented on May 16, 2024

@Sergio- it is nearly impossible to brick the device, DS203 can be recovered using the internal uart connection: https://github.com/gabonator/LA104/tree/master/tools/stm32flash
You will need uart converter (3.3V) for this

Hi @gabonator! First of all, thanks for the reply.
It's a good relief to know that the device can be restored. I believe it's just a matter to find the correct firmware combination now. :-)

I'll explain below what I did to recover from UART, hoping that others can user the information too.
Before starting, I took a picture of my device first screen, where it shows the license (I'm not sure if that's useful or not).
I compiled a Linux version of the stm32flash utility (download from sources, build it replace the bin at the same location I had the one from your repository).
I removed the cover and battery of the DSO203, and soldered some wires on the BOOT0 and UART ports (I didn't have any pin bars available) :-)
image
image
I connected the RX, TX and GND pins into USB to Serial adapter (3.3V) and to enter the Bootloader mode, just jumped the B0 with VCC, then powered on the device (the screen was just white at this point).
Then I run:
sudo ./stm32flash -w ./ds203_2mb_full/dso_quad_bootloader_flash_modified.bin /dev/ttyUSB0
and got this output

stm32flash 0.5

http://stm32flash.sourceforge.net/

Using Parser : Raw BINARY
Interface serial_posix: 57600 8E1
Version      : 0x22
Option 1     : 0x00
Option 2     : 0x00
Device ID    : 0x0414 (STM32F10xxx High-density)
- RAM        : 64KiB  (512b reserved by bootloader)
- Flash      : 512KiB (size first sector: 2x2048)
- Option RAM : 16b
- System RAM : 2KiB
Write to memory
Erasing memory
Wrote address 0x08040000 (100.00%) Done.

I then disconnected the B0 from VCC, powered off the device and on again.
I got an Invalid License screen:
image
Even inputting the number I recorder earlier, it didn't work. Anyway, you can press the top keys to move to the next steps.
Once the main application is loaded. I noticed something strange: The 2 channels (CHA, CHB) are not displaying. Not sure how to solve that.
image

The other issue is that, when booting pressing F1, the DFU disk is not being mounted anymore. The logs shows the message below:

106093.808621] usb 1-3: new full-speed USB device number 61 using xhci_hcd
[106093.957735] usb 1-3: New USB device found, idVendor=0483, idProduct=5720, bcdDevice= 2.00
[106093.957738] usb 1-3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[106093.957740] usb 1-3: Product: STM32 Mass Storage
[106093.957743] usb 1-3: Manufacturer: STMicroelectronics
[106093.957744] usb 1-3: SerialNumber: 6ÿÛMW60 cQ
[106093.958882] usb-storage 1-3:1.0: USB Mass Storage device detected
[106093.959063] scsi host2: usb-storage 1-3:1.0
[106094.973067] scsi 2:0:0:0: Direct-Access     Mini_DSO Flash Disk            PQ: 0 ANSI: 2
[106094.973316] sd 2:0:0:0: Attached scsi generic sg1 type 0
[106094.973576] sd 2:0:0:0: [sdb] 4096 512-byte logical blocks: (2.10 MB/2.00 MiB)
[106094.973720] sd 2:0:0:0: [sdb] Write Protect is off
[106094.973724] sd 2:0:0:0: [sdb] Mode Sense: 03 00 00 00
[106094.973865] sd 2:0:0:0: [sdb] No Caching mode page found
[106094.973869] sd 2:0:0:0: [sdb] Assuming drive cache: write through
[106095.045694] sd 2:0:0:0: [sdb] Attached SCSI removable disk
[106095.988819] sd 2:0:0:0: [sdb] tag#0 FAILED Result: hostbyte=DID_ERROR driverbyte=DRIVER_OK
[106095.988823] sd 2:0:0:0: [sdb] tag#0 CDB: Read(10) 28 00 00 00 0d 58 00 00 08 00
[106095.988827] blk_update_request: I/O error, dev sdb, sector 3416 op 0x0:(READ) flags 0x80700 phys_seg 1 prio class 0
[106095.988832] usb 1-3: USB disconnect, device number 61
[106095.988895] blk_update_request: I/O error, dev sdb, sector 3416 op 0x0:(READ) flags 0x0 phys_seg 1 prio class 0
[106095.988898] Buffer I/O error on dev sdb, logical block 427, async page read
[106096.888682] usb 1-3: new full-speed USB device number 62 using xhci_hcd
[106097.037671] usb 1-3: New USB device found, idVendor=0483, idProduct=5720, bcdDevice= 2.00
[106097.037673] usb 1-3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[106097.037674] usb 1-3: Product: STM32 Mass Storage
[106097.037675] usb 1-3: Manufacturer: STMicroelectronics
[106097.037676] usb 1-3: SerialNumber: 6ÿÛMW60 cQ
[106097.038736] usb-storage 1-3:1.0: USB Mass Storage device detected
[106097.038840] scsi host2: usb-storage 1-3:1.0
[106098.045137] scsi 2:0:0:0: Direct-Access     Vertual  DFU Disk              PQ: 0 ANSI: 2
[106098.045408] sd 2:0:0:0: Attached scsi generic sg1 type 0
[106098.046502] sd 2:0:0:0: [sdb] 1024 512-byte logical blocks: (524 kB/512 KiB)
[106098.046644] sd 2:0:0:0: [sdb] Write Protect is off
[106098.046647] sd 2:0:0:0: [sdb] Mode Sense: 03 00 00 00
[106098.046789] sd 2:0:0:0: [sdb] No Caching mode page found
[106098.046793] sd 2:0:0:0: [sdb] Assuming drive cache: write through
[106098.088458] sd 2:0:0:0: [sdb] Attached SCSI removable disk

To summarize: The device now boots up, but it seems it's not working as intended still.
I'm looking for any advice on how to proceed from here.
Thanks a lot.

from la104.

gabonator avatar gabonator commented on May 16, 2024

@Sergio- During powerup, what does it say about FPGA configuration? When you connect CH1 to signal generator, does it show any signal?

If you are using FW from jpa, he made there a little hack that skips license verification, with original fw it wouldn't let you go further.

If you are having problems with DFU drive, you can try uploading new firmwares (HEX files) through this utility https://github.com/gabonator/LA104/tree/master/tools/dfuload

It seems you just need to find the right fw for your device. Or maybe just fpga image. Maybe we could ask guys here for a help: Anyone here with working DS203 V2.82 8MB and willing to share its flash dump with us?

from la104.

Sergio- avatar Sergio- commented on May 16, 2024

@Sergio- During powerup, what does it say about FPGA configuration? When you connect CH1 to signal generator, does it show any signal?

If you are using FW from jpa, he made there a little hack that skips license verification, with original fw it wouldn't let you go further.

If you are having problems with DFU drive, you can try uploading new firmwares (HEX files) through this utility https://github.com/gabonator/LA104/tree/master/tools/dfuload

It seems you just need to find the right fw for your device. Or maybe just fpga image. Maybe we could ask guys here for a help: Anyone here with working DS203 V2.82 8MB and willing to share its flash dump with us?

Hi @gabonator Thanks for the reply!
1 - No it doesn't show any FPGA error now. It jumps directly to that license screen where it shows 0000000.I even recorded it in slow motion to make sure I'm losing any quick message. It jumps directly to the license screen.
2 - Connecting CHA or CHB to a generator doesn't show up anything, changing the channel parameters have not effect.
3 - FW from jpa? I'm loaded via USART the one that one you here on the repository (dso_quad_bootloader_flash_modified.bin) is there any other one that I should consider? I found this repository (http://jpa.kapsi.fi/dsoquad/) but, as I don't have the DFU disk mounting anymore, I don't know how I can load these...
4 - I tried the dfuload method. It seems to work sometimes, but I'm not 100% sure as I cannot read the output file response (ERR, RDY, etc). I tried loading a couple of files, event a FPGA firmware available on the repository here (https://github.com/gabonator/LA104/tree/master/tools/fpga/ds203_8mb_hwV272-V261FPGA), but, still not luck. Devices boots up on the license screen, i press f1 twice to skip it, it load the oscilloscope app, but CHA and CHB doesn't show up. DFU disk is also not mounted when boot holding F1.

from la104.

gabonator avatar gabonator commented on May 16, 2024

@Sergio-
then it explains everything - the dso_quad_bootloader_flash_modified.bin is from jpa (http://jpa.kapsi.fi/dsoquad/) and the "modified" means, he skipped the license verification. The problem is, this flash dump is for 2MB device. So that is probably the reason why you are unable to mount it. Just continue try to find proper fw, and if you won't find anything, I will try to ask the guys at miniware if they can help. But I am not giving much hope they will be able to help us

from la104.

Sergio- avatar Sergio- commented on May 16, 2024

@gabonator Thanks. I"ll continue searching.
Let's hope someone with a working 8mb version can post the flash dump here.
Thanks a lot.

from la104.

acidg avatar acidg commented on May 16, 2024

[106098.046502] sd 2:0:0:0: [sdb] 1024 512-byte logical blocks: (524 kB/512 KiB)
[106098.046644] sd 2:0:0:0: [sdb] Write Protect is off
[106098.046647] sd 2:0:0:0: [sdb] Mode Sense: 03 00 00 00
[106098.046789] sd 2:0:0:0: [sdb] No Caching mode page found
[106098.046793] sd 2:0:0:0: [sdb] Assuming drive cache: write through
[106098.088458] sd 2:0:0:0: [sdb] Attached SCSI removable disk

As far as I see from this log, your DFU device is there, it's just not mounted automatically. Try to mount the device manually: sudo mount -o rw /dev/sdb /media/USB. You should be able to copy the firmware files there. You will have to unmount and mount the device again to see the .RDY and .ERR files.

from la104.

Sergio- avatar Sergio- commented on May 16, 2024

[106098.046502] sd 2:0:0:0: [sdb] 1024 512-byte logical blocks: (524 kB/512 KiB)
[106098.046644] sd 2:0:0:0: [sdb] Write Protect is off
[106098.046647] sd 2:0:0:0: [sdb] Mode Sense: 03 00 00 00
[106098.046789] sd 2:0:0:0: [sdb] No Caching mode page found
[106098.046793] sd 2:0:0:0: [sdb] Assuming drive cache: write through
[106098.088458] sd 2:0:0:0: [sdb] Attached SCSI removable disk

As far as I see from this log, your DFU device is there, it's just not mounted automatically. Try to mount the device manually: sudo mount -o rw /dev/sdb /media/USB. You should be able to copy the firmware files there. You will have to unmount and mount the device again to see the .RDY and .ERR files.
Hi @acidg Thanks for the suggestion!
I tried that, althought I can mount the device, it only return "write error" when I try to saving something on it. Even the dfuload utility returns only writing errors...

from la104.

Sergio- avatar Sergio- commented on May 16, 2024

I was able to make a little progress. I found the attached file on the minidso Chinese forum, it contains the DFU 3.45C for the Hw v2.81. I flashed this file using the stm32flash and it helped a little.
After flashing and rebooting, I got this screen:
image
Then, It moves to this one:
image
and finally:
image

Booting the device holding F1, shows this screen:
image
And it mounts the DFU drive on my Linux machine.

But, not everything is Ok yet... When I try to do any operation with the virtual DFU disk, it always return as ERR. If I drag a file and drop on the disk, it immediately disconnects and, upon returning, it contains the file with extension .ERR.
I also tried transferring the files using the 'dfuload' utility. I umount (sudo umount /dev/sdb) then transfer the file, the drive disconnects and, when connecting it always have the A.ERR file in it.

I'm clueless how to move on from here. I want to install a decent firmware like the one from this repo, but, transferring the file via DFU vitual disk or dfuload is not working. I tried upgrading the APP and SYS via same method, but got the same result (ERR). I even tried the Wildcat 6.x method with the HEX files split in BIN. As soon as I save the first ADR file, the drive disconnects (expected), but returns with a ERR file instead of a SET.

Another thing: The attached file also contain the DFU 3.40C. I tried loading it with stm32flash the same way I did with the 3.45 but it always stopped at 40%, no error message, nothing. just stopped at 40%...

Any ideas/suggestions are appreciated.

dso_hw281_dfu_pack.zip

Thank you.

from la104.

Sergio- avatar Sergio- commented on May 16, 2024

Sergio, it looks like you have used the wrong image for recovery the first time around. But don't worry, we'll get you up and running. You just need the correct DFU, FPGA, LOGO, SYS and APP reflashed.
...

Hello @MotoMaxis
First of all, thanks for such a detailed response and Thanks for the commitment in helping. I really appreciate it and I'm sure others will find it useful too.
I flashed the HW_V282_DFU_V346C_WC_V65.BIN using the stm32flash utility. It worked fine and when rebooted, I entered the DFU mode and transferred the UNLOCK.hex (via dfuload).

Upon rebooting, the screen to enter the new license showed up, I input the license and pressed Key2. This is what showed up:
image

I turned the device Off and On again, then this screen comes up:
image

Then the screen to enter the license comes up again.
image

I tried entering and saving the license a couple of times, it always display "Licence written Ok", but comes up back to "License Error" -> "License Unlock" screen.

I re-flashed the DFU and repeated all the steps few times.. No luck...

Any suggestions is appreciated.

Thank you.

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

Edit:
Wrong. Must load SYS_B164.zip to replace Unlock.

Not:
Once it accepts the License, reboot into DFU and load WC65app1.hex next, only after this do a normal boot.
The Unlock is actually an app only for entering the License at times when the device was wiped. It must be replace by an app such us WC6.5.

from la104.

Sergio- avatar Sergio- commented on May 16, 2024

Hi @MotoMaxis Thanks for the quick reply.
I tried that and I'm still with no luck.
I recorded the video below trying to capture all the details I'm doing expecting that something wrong can be identified and pointed to me so I can fix it.
Feel free to skip the obvious sequential parts.
https://drive.google.com/file/d/12sNB2ID2U8ckqJI-EkF01A1hJnLruxs4/view?usp=sharing
I appreciate all the help.
Thank you.

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

Screenshot_5

Hi, from the video it looks like its showing wrong License Code. Not sure why. Maybe the Unlock app is at fault. Try another Unlock app attached.
DS203.Unlock.V0.21.hex.zip

Now DFU says 3.46C so my dump was written correctly. I noticed you get many ERR when copying hex to disk. This is because of usb timing and issues with DFU. I don't know of any solution except to try different Linux/Windows OS. Perhaps minidso have newer DFU than 3.46C that is more compatible. I will look for it.

I will have some time tomorrow to convert hex to bin so you can try load the ADR and Bin files. Or better yet, if possible use stmflash tool to directly write to a certain address such as 0x08004000. This seems to work best for you.

We need to resolve the license error. I am wondering if the area where license is stored got corrupt somehow and the Unlock is not fully clearing it before a new code is saved.

Last resort would be to patch the license check.

from la104.

Sergio- avatar Sergio- commented on May 16, 2024

Cool @MotoMaxis
Yes. I tried the new Unlock, but the behavior remained the same as the one in the video.
I'm not that familiar with the conversion of the HEX to BIN and how to place it in the right address, but It seems a good approach, provided we have the address/location and the proper file.
Is there anything I can do that will help in this process?
Thank you!

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

Finally had time put together the recovery package.
The memory layout looks like this.

Only DS203 Hardware Ver 2.81 and 2.82
08000000 - DFU
08004000 - SYS / Unlock
0800C000 - APP
0805C800 - FPGA
0807D800 - LOGO

The device must have all 5 sections inplace to function properly. On Power on, operation starts at DFU, then jump to SYS then to APP. Once you use Unlock, you must write back the SYS which I included in SYS folder.,

I have included the latest stock DFU3.46C,SYS1.64,APP1.13 dump in IMAGE folder in hex and bin. Use UART to write it to device. I also included Wildcat 6.5 app to try.
RECOVERY281282.zip
Update. Here is new Wildcat 6.5 as of 12-24-20
Wildcat6.5_122420.zip

Note Using these full images or DFU will require to use Unlock to reenter your License code.

Since DFU is so unreliable for you I suggest you use stm32flash utility. I believe you can "stm32flash -w filename -v -S 0x4000 ..." to write SYS as an example as it lives at 08004000. This way you can write what you need to the section you want.

If you want, you can also copy .ADR files in DFU mode for sys, app, fpga and logo. It should say .SET then copy the .bin. This is more reliable way then .hex in DFU.

Best regards.

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

Hey Sergio. Something looked familiar in your video, it is my License code. I traced it down to a address part of the DFU. Knowing this, I have redone the bin files with your License code. Attached are:

  • SergioDS203_P-D346CS164A113stock.bin - full image latest factory fw
  • Sergio_HW_V282_DFU_V346C_WC_V65.BIN - full image Wildcat 6.5 fw https://github.com/MotoMaxis/DS203-DSOQuad
  • SergioDS203.DFU.V346C.bin - only DFU 3.46C

With these files you should not get the license error.
SergioDS203.zip

from la104.

Sergio- avatar Sergio- commented on May 16, 2024

Hi MotoMaxis. Thank you very much about all the effort on solving this. Really appreciate it.
I'm happy to report that flashing Sergio_HW_V282_DFU_V346C_WC_V65.BIN solved most of the issues. Not license or FPGA errors. APP seems to be working OK.
Except for a little thing: It seems I"m not able to save a configuration file. When I try the "Save File"000.CFG it flashes ERR. That's it.
I"m not sure if there's anything I can do to format the DFU or other storage it that exists.
I also noticed that, when mounted, the serial number is kind of scrambled.
The Disk size is ~2Mb (instead of the 8Mb). I'm wondering if there's a way to force format it somehow.
image

Apart from that, all seems fine.
Thanks again for all the help!
image

PS: If you can just give some tips about the tools/utilities used to do all the conversion, find the serial, etc, or how to get started with this type of skills... I believe it will be beneficial as a learning resource.

Thanks a lot!

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

Great news!

I think you can use gparted or fdisk or built in tool. https://vitux.com/how-to-format-a-usb-drive-in-ubuntu/

Try to remove 2mb partition first then recreate it. Then format.

from la104.

Sergio- avatar Sergio- commented on May 16, 2024

@MotoMaxis When you mount the DFU disk, does it show up as 2 or 8Mb?
Mine shows DFU as ~2M and the "normal" startup as ~8M.
What are the filesystem to which the normal disk should be formatted to?
Thank you.

from la104.

Sergio- avatar Sergio- commented on May 16, 2024

I tried with different partition types (FAT12, FAT16, FAT32, NTFS, etc).

Although I can read and write data using the drive mounted on the PC, in none of those the Option of "Save File" worked on the application.

Here's the details of the current format I stick with.

Any suggestion on how to fix the save configuration file is appreciated!

Thank you.

focal@ES1:~$ sudo fdisk /dev/sdb

Welcome to fdisk (util-linux 2.34).
Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.

Command (m for help): i
Selected partition 1
         Device: /dev/sdb1
          Start: 256
            End: 2047
        Sectors: 1792
      Cylinders: 113
           Size: 7M
             Id: 1
           Type: FAT12
    Start-C/H/S: 16/0/1
      End-C/H/S: 127/0/16

Command (m for help): 

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

After formating, is the disks serial number readable now?

This applies to Wildcat 6.5 firmware...
After format and restart, I get the Configuration file not found error. I do the option Save 000.cfg (Press and Hold button 3, release and press again). This will create serialnumber.wpt file. This is the default config device loads on start.. When I tried saving to 001.cfg, I get ERR. You need to copy default .wpt to CONF001.cfg manually, then you can save to it and load it. I think this is unfinished part of firmware. Maybe someone can fix it on https://github.com/MotoMaxis/DS203-DSOQuad

The other Save BUF, DAT, CSV, ROM show OK. You have to remount to see new files.

Here is how my 8MB storage disk look.


DISKPART> list volume

  Volume ###  Ltr  Label        Fs     Type        Size     Status     Info
  ----------  ---  -----------  -----  ----------  -------  ---------  --------
  Volume 5     I   DS203        FAT    Removable      8 MB  Healthy

DISKPART> FILESYSTEMS

Current File System

  Type                 : FAT
  Allocation Unit Size : 4096
  Flags : 00000000

I:\>dir
 Volume in drive I is DS203
 Volume Serial Number is DC3B-1D3B

from la104.

Sergio- avatar Sergio- commented on May 16, 2024

Hi MotoMaxis
So close, yet so far. :-)
The disk seems to be working ok on the PC, I can save store/retrieve files, read and write it without issues.

image

The Problem seems to be something on the firmware not able to access the filesystem correctly, I tried the Button 3 method. It doesn't save anything on the Disk (always shows ERR). I also tried saving CSV, ROM and some other format, always ERR, umounting/mounting disk again always show it as empty.

On the Linux log, I still see the serial number like this:

image

This is the result of fdisk -l:

focal@ES1:/media/focal/28F4-0161$ sudo fdisk -l /dev/sdc
Disk /dev/sdc: 8 MiB, 8388608 bytes, 2048 sectors
Disk model: Flash Disk      
Units: sectors of 1 * 4096 = 4096 bytes
Sector size (logical/physical): 4096 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: dos
Disk identifier: 0xaa68d4b6

Device     Boot Start   End Sectors Size Id Type
/dev/sdc1         256  2047    1792   7M  1 FAT12
focal@ES1:/media/focal/28F4-0161$ 

All my investigation points to some disconnect between the firmware and the filesystem, but I can't comment much further as I'm not familiar with the ST's and the firmware architecture.

I"m ready to try whatever you guys think it's a good idea.

Thank you.

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

I suggest you try the SergioDS203_P-D346CS164A113P10F26A(27AB).bin image. That is factory code. See if Saving files works. Try to delete 8MB partition and create a new one. I am wondering if the 8MB flash memory is corrupt. Or if its info somewhere inside the STM.

The Wildcat firmware checks for a string 8MB Internal in order to decide to use 4096/sec for 8MB or 512/sec for 2MB. Maybe it defaults to 512 for you.

from la104.

Sergio- avatar Sergio- commented on May 16, 2024

Hi MotoMaxis. I did as you suggested. I flashed the SergioDS203_P-D346CS164A113P10F26A(27AB).bin and flashed the FPGA, SYS, APP, etc, all using the st32flash. All ok. Removed the partition and create it again. Rebooted, but unfortunately, the firmware still not able to create the files on the disk (when hitting the Save Param for example, it shows up the message "Load File Fail").

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

I am thinking perhaps linux is formating the flash in a different way. I can dump the flash memory into a bin and if you know a way to write it to yours, we can try that. Or you should find a Windows machine and format it there.

from la104.

Quas7 avatar Quas7 commented on May 16, 2024

not sure, if this is worth anything but seems related and maybe it gets you a tiny bit closer: #26
You would have do adapt the command a bit for the 8MB, I guess.

from la104.

gabonator avatar gabonator commented on May 16, 2024

I am using this command to format LA104 fs, and the DS203 8MB has the same sector size, so maybe it will help:

sudo newfs_msdos -F 12 -v la104 -O "MSDOS5.0" -S 4096 /dev/disk2

-F 12 (fat12)
-v la104 (volume label)
-O "MSDOS5.0" (oem name, otherwise it will use BSD, but the device does not care anyway)
-S 4096 (sector size)

edit: @Quas7 shows in his post how to format on ubuntu if newfs_msdos is not available, so just ignore my message

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

@sergio, Finally words of success. I am glad to have been able to participate.

@gabonator I am also interested in beta testing your firmware on my DS203 HW2.83 8MB flash.

The DFU V3.46C stores the License code of a device at 0xFC to 0xFF in reverse (Little Endian) format. You can use a hex editor to enter your own code. A stock DFU has FFFFFFFF in said location. As far as I know, the only known way to flash DFU is by UART.

WARNING
If you decide to flash a stock or another device's full dump bin, you will lose your License code. As mentioned above the code is part of DFU.
Sergio's example DFU = 3.46C ser: 8726B9A3 lic: 7A9457A7
Screenshot_3

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

Hi Sergio and anyone else, could you test this Wildcat V6.5 modified firmware on a 2.81 or 2.82 device?

Make sure there are no CONF00x.CFG files on 8MB drive. We are testing new file creation.
Then try to Save CFG (press&hold button 3) then choose 001 to 009 (left wheel) and press button 3, do you get OK now?

WC6.5testapp1.zip

Thank you.

from la104.

Sergio- avatar Sergio- commented on May 16, 2024

Hi @MotoMaxis Yes. It worked.
I also must say that, the WildCat 6.5 you had prepared for me before, also worked after I formatted the disk with mkfs.msdos.
Have a nice day!

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

Actually the before version only works for default 000.cfg. But fails for others unless conf001.cfg to 009 already exist. The test version has a minor update to automatically create new files for 001 to 009.

Edit:
I also found another bug. If you try to Load CFG with the filemager with no .cfg files, it will show None but still lets you load it. Then if go to Save CFG instead of CONF you see weird characters.

Uploaded both fixes to https://github.com/MotoMaxis/DS203-DSOQuad as well as compiled hex.

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

Also trying to run webosc on my DS203 hw2.83 8mb.

Windows 7 can't find the driver.
Screenshot_4

from la104.

gabonator avatar gabonator commented on May 16, 2024

@MotoMaxis it is mentioned in the project readme: https://github.com/gabonator/LA104/blob/master/system/apps_featured/69_webusbosc/readme.md

On windows machine you will need to generate "winusb" driver. And this tool does it for you: https://zadig.akeo.ie/

from la104.

Sergio- avatar Sergio- commented on May 16, 2024

Uploaded both fixes to https://github.com/MotoMaxis/DS203-DSOQuad as well as compiled hex.

@MotoMaxis What's the link to the compiled Hex files?

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

@gabonator

Thank you for the tip.

While testing yesterday I noticed one issue. After flashing the system_ds203hd.hex and trying all the elf files I flashed back the Wildcat6.5 expecting it to work but it was stuck on FPGA error. Flashing the FPGA fixed the error. So it seems it got corrupted somehow. The area in question is 0805C800 - FPGA - 0807D7FF. You main app loads to 0800C000 - 08012740.

@sergio
Im 6.5 folder https://github.com/MotoMaxis/DS203-DSOQuad/blob/master/WildcatV6.5/app1.hex
or
WC6.5_122420_app1.zip

from la104.

gabonator avatar gabonator commented on May 16, 2024

@MotoMaxis
Interesting, here is a list of used ram/rom range for each app and I cannot find any that would overlap the fpga code:

100i2ct.elf   ram: 20004800-20004928   1K, rom: 0801ed00-0801f6bc   3K, entry: 0801ed00 
101radio.elf  ram: 20004800-20004bc8   1K, rom: 0801ed00-0801f669   3K, entry: 0801ed00 
102oled.elf   ram: 20004800-20006f64  10K, rom: 0801ed00-08020dd4   9K, entry: 0801ed00 
103servo.elf  ram: 20004800-20005adc   5K, rom: 0801ed00-08023510  19K, entry: 0801ed00 
104avris.elf  ram: 20004800-200055b8   4K, rom: 08064300-08066dd0  11K, entry: 08064300 
105avrfl.elf  ram: 20005000-20006470   6K, rom: 08020400-08022b90  10K, entry: 08020400 
106mpr12.elf  ram: 20004800-20004938   1K, rom: 0801ed00-0801f694   3K, entry: 0801ed00 
107schem.elf  ram: 20004800-20005024   3K, rom: 0801ed00-08021490  10K, entry: 0801ed00 
108si11.elf   ram: 20004800-20004930   1K, rom: 0801ed00-0801fe78   5K, entry: 0801ed00 
10i2c.elf     ram: 20005000-20005508   2K, rom: 08018000-0801b604  14K, entry: 08018000 
11i2c.elf     ram: 20005088-200050c0   1K, rom: 08018000-08018ce4   4K, entry: 08018000 
12uart.elf    ram: 20005088-200050b8   1K, rom: 08018000-08018238   1K, entry: 08018000 
13mp3.elf     ram: 20005000-20005450   2K, rom: 08020000-08022810  11K, entry: 08020000 
14apds1.elf   ram: 200050a0-20005198   1K, rom: 08018000-08019490   6K, entry: 08018000 
14apds2.elf   ram: 200050a0-20005194   1K, rom: 08018000-08019474   6K, entry: 08018000 
15chards.elf  ram: 20007000-200071c4   1K, rom: 08020000-08020f84   4K, entry: 08020000 
15charla.elf  ram: 20007000-200071c4   1K, rom: 08020000-08020f84   4K, entry: 08020000 
16cc1101.elf  ram: 20004088-200040b8   1K, rom: 08020000-0802197c   7K, entry: 08020000 
17analys.elf  ram: 20002700-20007d38  22K, rom: 08040000-08048588  34K, entry: 08040000 
18onew.elf    ram: 20006090-2000613c   1K, rom: 0801a000-0801bafc   7K, entry: 0801a000 
19rtc.elf     ram: 20006000-20006140   1K, rom: 0801a000-0801baf8   7K, entry: 0801a000 
1noimp.elf    ram: 20004000-20004000   0K, rom: 08020000-08020134   1K, entry: 08020000 
20uplay.elf   ram: 20004088-200040c0   1K, rom: 08020000-0802063c   2K, entry: 08020000 
21mplay2.elf  ram: 20005000-20006144   5K, rom: 08020000-080224f8  10K, entry: 08020000 
21mplayd.elf  ram: 20005000-20006144   5K, rom: 08020000-08022508  10K, entry: 08020000 
21mplayl.elf  ram: 20005000-2000614c   5K, rom: 08020000-08022518  10K, entry: 08020000 
22seqen.elf   ram: 20005000-200054cc   2K, rom: 08020000-080226a8  10K, entry: 08020000 
23screen.elf  ram: 20009f8c-20009fd0   1K, rom: 0802f000-0802f62c   2K, entry: 0802f000 
24ncdc.elf    ram: 2000a000-2000aa18   3K, rom: 08020000-08020b00   3K, entry: 08020000 
25hid.elf     ram: 20005000-20005330   1K, rom: 08020000-08020c50   4K, entry: 08020000 
26midi.elf    ram: 20005000-200054ec   2K, rom: 08020000-08020e3c   4K, entry: 08020000 
27irsend.elf  ram: 20005000-20005194   1K, rom: 08020000-08021a98   7K, entry: 08020000 
28shell.elf   ram: 20004800-20007908  13K, rom: 0801f000-08022bfc  15K, entry: 0801f000 
29fileman_ds203.elf ram: 20005200-20005c8c   3K, rom: 08019000-0801af90   8K, entry: 08019000 
29fileman_ds213.elf ram: 20004800-2000528c   3K, rom: 08013e00-08015e30   9K, entry: 08013e00 
29fileman_la104.elf ram: 20004800-2000528c   3K, rom: 08013e00-08015e30   9K, entry: 08013e00 
2import.elf   ram: 20006088-200060a0   1K, rom: 08020000-080201ec   1K, entry: 08020000 
30dcf77.elf   ram: 20004800-20004a44   1K, rom: 08014000-080156a0   6K, entry: 08014000 
31testg.elf   ram: 20009f90-20009fbc   1K, rom: 0802f000-0802f234   1K, entry: 0802f000 
32graph.elf   ram: 20007000-20007988   3K, rom: 08020000-08023f00  16K, entry: 08020000 
32sump.elf    ram: 20005000-200066b0   6K, rom: 08020000-08020ee0   4K, entry: 08020000 
33temper.elf  ram: 20005000-200070f4   9K, rom: 08020200-080230a8  12K, entry: 08020200 
34scope.elf   ram: 20007000-20008058   5K, rom: 08020000-08021c28   8K, entry: 08020000 
35view13.elf  ram: 20004888-200058d0   5K, rom: 08040000-08041438   6K, entry: 08040000 
35viewds.elf  ram: 20004888-20004ad0   1K, rom: 08040000-08041438   6K, entry: 08040000 
35viewla.elf  ram: 20004888-200058d0   5K, rom: 08040000-08041438   6K, entry: 08040000 
36espwww.elf  ram: 20004800-20004b30   1K, rom: 0801a000-0801bbb0   7K, entry: 0801a000 
37icscan.elf  ram: 20004888-20004960   1K, rom: 0801a000-0801acdc   4K, entry: 0801a000 
38oregon.elf  ram: 20004800-20004dac   2K, rom: 0801a000-0801b2fc   5K, entry: 0801a000 
39lcd.elf     ram: 20007088-2000709c   1K, rom: 08020000-080218bc   7K, entry: 08020000 
3gui.elf      ram: 20007088-200070a8   1K, rom: 08020000-080208dc   3K, entry: 08020000 
40anal.elf    ram: 20007000-200070c8   1K, rom: 08020000-08020204   1K, entry: 08020000 
41alche.elf   ram: 20004400-20005af4   6K, rom: 0801ee00-0802aabc  48K, entry: 0801ee00 
43dump.elf    ram: 20004888-200048ac   1K, rom: 0801a000-0801a50c   2K, entry: 0801a000 
44fault.elf   ram: 20004888-20004898   1K, rom: 0801a000-0801a1bc   1K, entry: 0801a000 
45simcom.elf  ram: 20004800-20004fbc   2K, rom: 0801ed00-08021780  11K, entry: 0801ed00 
46consol.elf  ram: 20004800-200048f8   1K, rom: 0801ee00-0801f254   2K, entry: 0801ee00 
48scroll.elf  ram: 20004800-20007ae8  13K, rom: 0801ee00-0801fbe4   4K, entry: 0801ee00 
49gpio.elf    ram: 20004800-20005094   3K, rom: 0801ed00-08023a74  20K, entry: 0801ed00 
4snake.elf    ram: 20007000-20007278   1K, rom: 08020000-080214a0   6K, entry: 08020000 
50mpr121.elf  ram: 20005000-2000512c   1K, rom: 08018000-08018c68   4K, entry: 08018000 
51osc.elf     ram: 20005000-20007914  11K, rom: 08020000-0802478c  18K, entry: 08020000 
52osc213.elf  ram: 20005000-20007904  11K, rom: 08020000-08024980  19K, entry: 08020000 
52uart.elf    ram: 20005000-200050e4   1K, rom: 08018000-08018708   2K, entry: 08018000 
53fpga1.elf   ram: 20004800-20004f54   2K, rom: ffffffff-00000000   1K, entry: 20004800 
54shell.elf   ram: 20005000-2000550c   2K, rom: 08014000-08016f00  12K, entry: 08014000 
55gosc.elf    ram: 20002b00-20008fac  26K, rom: 08013100-08023860  66K, entry: 08013100 
56ds1307.elf  ram: 20005000-20005108   1K, rom: 08018000-08018610   2K, entry: 08018000 
57ds3231.elf  ram: 20005000-20005108   1K, rom: 08018000-08018620   2K, entry: 08018000 
58gmin03.elf  ram: 20005000-2000a7a8  22K, rom: 08012c00-0801bf70  37K, entry: 08012c00 
58gmin13.elf  ram: 20002800-20007fa4  22K, rom: 08013100-0801c420  37K, entry: 08013100 
59memtst.elf  ram: 20005000-20006930   7K, rom: 08024000-0802525c   5K, entry: 08024000 
60gagen0.elf  ram: 20005000-20005f8c   4K, rom: 08017000-0801dc48  28K, entry: 08017000 
60gagen1.elf  ram: 20005000-20005f8c   4K, rom: 08017000-0801dc48  28K, entry: 08017000 
61devin.elf   ram: 20004800-200058ec   5K, rom: 0801ed00-0801fab4   4K, entry: 0801ed00 
62memvw.elf   ram: 20005000-200052f8   1K, rom: 0801c000-0801cebc   4K, entry: 0801c000 
63ws_104.elf  ram: 20004800-20005544   4K, rom: 08064000-080670d4  13K, entry: 08064000 
63ws_203.elf  ram: 20004800-20005548   4K, rom: 08064000-0806729c  13K, entry: 08064000 
63ws_213.elf  ram: 20004800-20005548   4K, rom: 08064000-0806729c  13K, entry: 08064000 
64remote.elf  ram: 20005000-200060b4   5K, rom: 08020000-08023459  14K, entry: 08020000 
66webusb.elf  ram: 20005000-200055f0   2K, rom: 08020000-08021648   6K, entry: 08020000 
67-6wusb.elf  ram: 20005000-200053dc   1K, rom: 08020000-080219e0   7K, entry: 08020000 
68webdrw.elf  ram: 20004800-20005510   4K, rom: 08064800-080675c8  12K, entry: 08064800 
69webos0.elf  ram: 20005200-20006c84   7K, rom: 08064100-08067c54  15K, entry: 08064100 
69webos1.elf  ram: 20005200-20006e44   8K, rom: 08064100-08067c80  15K, entry: 08064100 
70webana.elf  ram: 20004800-20005634   4K, rom: 08064800-080684bc  16K, entry: 08064800 
70wildca.elf  ram: 20004300-2000b998  30K, rom: 08040000-0805ad60 108K, entry: 08040000 
71strm.elf    ram: 20004800-2000591c   5K, rom: 0801ed00-08020cac   8K, entry: 0801ed00 
72uartm.elf   ram: 20004800-20004a68   1K, rom: 0801ed00-08020d70   9K, entry: 0801ed00 
73invt.elf    ram: 20004800-2000496c   1K, rom: 0801ed00-0801fd8c   5K, entry: 0801ed00 
74invt.elf    ram: 20004800-200050d0   3K, rom: 0801ee00-08022368  14K, entry: 0801ee00 
75invtem.elf  ram: 20004800-20004988   1K, rom: 0801ed00-08020154   6K, entry: 0801ed00 
76sender.elf  ram: 20004400-2000598c   6K, rom: 08014400-080187a4  17K, entry: 08014400 
77dma.elf     ram: 20004450-20004e44   3K, rom: 08014500-08014b90   2K, entry: 08014500 
78ugen.elf    ram: 200044d8-20004504   1K, rom: 08014500-08014700   1K, entry: 08014500 
79ccosc.elf   ram: 20005200-200072bc   9K, rom: 08064300-08069c50  23K, entry: 08064300 
7pwm.elf      ram: 20007088-200070bc   1K, rom: 08020000-08020bd0   3K, entry: 08020000 
80rftool.elf  ram: 20004800-20007b18  13K, rom: 08040300-08049bcc  39K, entry: 08040300 
81image.elf   ram: 20005000-20006a7c   7K, rom: 0801f000-08020b90   7K, entry: 0801f000 
82sanal.elf   ram: 20005000-20005948   3K, rom: 0801f400-08021488   9K, entry: 0801f400 
84maxdis.elf  ram: 20004800-20004908   1K, rom: 0801ed00-0801f398   2K, entry: 0801ed00 
85eetest.elf  ram: 20004800-20004b68   1K, rom: 0801ed00-08020a3c   8K, entry: 0801ed00 
86keyb.elf    ram: 20004800-20004aec   1K, rom: 0801ed00-0801f3b4   2K, entry: 0801ed00 
87mlx906.elf  ram: 20004800-2000491c   1K, rom: 0801ed00-08020214   6K, entry: 0801ed00 
88eink.elf    ram: 20004800-20004d20   2K, rom: 0801ed00-0802344c  18K, entry: 0801ed00 
89fancy.elf   ram: 20004800-2000729c  11K, rom: 0801ed00-0802133c  10K, entry: 0801ed00 
8ds.elf       ram: 20007088-200070bc   1K, rom: 08020000-08021050   5K, entry: 08020000 
90eink.elf    ram: 20004800-20005d18   6K, rom: 08040300-08042e44  11K, entry: 08040300 
91mfrc.elf    ram: 20004800-20004910   1K, rom: 0801ed00-0801f2b4   2K, entry: 0801ed00 
92bmp180.elf  ram: 20004800-20004d68   2K, rom: 0801ed00-08021ce8  12K, entry: 0801ed00 
93mfrc.elf    ram: 20004800-20006518   8K, rom: 0801f000-080242a4  21K, entry: 0801f000 
95sht20.elf   ram: 20004800-2000491c   1K, rom: 0801ef00-0801ffe0   5K, entry: 0801ef00 
96tm1637.elf  ram: 20004800-20004908   1K, rom: 0801ef00-0801fa70   3K, entry: 0801ef00 
97backl.elf   ram: 20004800-200049fc   1K, rom: 0801ef00-0801f45c   2K, entry: 0801ef00 
99cube03.elf  ram: 20005000-20007548  10K, rom: 08020200-08022580   9K, entry: 08020200 
99cube04.elf  ram: 20005000-20007548  10K, rom: 08020200-08022580   9K, entry: 08020200 
99cube13.elf  ram: 20005000-20007548  10K, rom: 08020200-08022580   9K, entry: 08020200 
9dht.elf      ram: 20007088-200070bc   1K, rom: 08020000-08020cc4   4K, entry: 08020000 

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

@gabonator

What about these? They fit in 0805C800 - FPGA - 0807D7FF 135K

104avris.elf  ram: 20004800-200055b8   4K, rom: 08064300-08066dd0  11K, entry: 08064300 
63ws_104.elf  ram: 20004800-20005544   4K, rom: 08064000-080670d4  13K, entry: 08064000 
63ws_203.elf  ram: 20004800-20005548   4K, rom: 08064000-0806729c  13K, entry: 08064000 
63ws_213.elf  ram: 20004800-20005548   4K, rom: 08064000-0806729c  13K, entry: 08064000 
68webdrw.elf  ram: 20004800-20005510   4K, rom: 08064800-080675c8  12K, entry: 08064800 
69webos0.elf  ram: 20005200-20006c84   7K, rom: 08064100-08067c54  15K, entry: 08064100 
69webos1.elf  ram: 20005200-20006e44   8K, rom: 08064100-08067c80  15K, entry: 08064100 
70webana.elf  ram: 20004800-20005634   4K, rom: 08064800-080684bc  16K, entry: 08064800 
79ccosc.elf   ram: 20005200-200072bc   9K, rom: 08064300-08069c50  23K, entry: 08064300 

Only DS203 Hardware Ver 2.81 and 2.82 8MB flash
08000000 - DFU 16K
08004000 - SYS 32K
0800C000 - APP 349K
0805C800 - FPGA 135K
0807D800 - LOGO 10K

Perhaps these elfs can be moved to
Available space that starts at 08080000.

from la104.

gabonator avatar gabonator commented on May 16, 2024

Aaah, I see now. I put wrong addresses in the script which checks the collision. Yes, they can be moved. Or in better, I will make separate builds for ds213 hd, sice at those addresses it was tested on ds203/ds213.
In the flashing code I have some strange bug which sometimes fails. And the only thing I can do is moving a little bit the ROM code in the linker script - that's the reason why is every app at different memory location.

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

Sorry, I was wrong in saying that available space starts at 08080000. That is actually the end of the eeprom on a 512KB chip.

We can possibly use 1.9KB after the LOGO at 0807F880 to 0807FFF . About 11.7KB after SYS at 08009190 to 0800BFFF. And all of 329.7KB of APP space from 0800C000 to 0805C7FF. As far as I know, thats it.

Happy New Year everyone.

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

So I've relocated WebOsc to 08023000 to not corrupt the FPGA at 0805C800 on DS203 2.82 8MB. Now flashing back WC6.5 works.

Anyways, after opening the site, it shows DS203 paired but stuck saying Connecting... Now not sure whats wrong.

If anyone want to try, DFU copy the system. Restart normally nd copy 2 elf files. Restart the run webosc. Fyi, I had to format 8MB before files showed up.
ds203hd8mb.zip

from la104.

gabonator avatar gabonator commented on May 16, 2024

Happy New Year everyone! I hope all of you and your families are safe and healthy.

@MotoMaxis, what does chrome say in the debug console? When you try to connect (through the webosc html interface), does it show the DS203 in list of available devices? I dont know if it is the same in windows, but the firmware just uses a regular CDC (serial link) usb. So you can open the port as serial port and then communicate with it. And you can easily verify if it is communicating by sending

"OSC::Ready();\n"

and it should reply

"{ret:0}"

Do you have memory layouts also for other DSxxx devices? I would like to put together this information from each device to improve the app placement. Ideal case would be achieved when no application would be overlapping any other, so you can switch between them even without flashing the eeprom.

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

Happy New 2021 Year everyone.

@gabonator, Thank you for the tip. Originally I installed WebUSB driver using zadig-2.5.exe but now installed CDCSerial and see Com34 in device manager. I no longer get the popup when plugging in the DSO.
Screenshot_6

Here is what chrome says.
Screenshot_7

So next I used HyperTerminal to connect to that port. As soon as I press a key, it Hard Faults. Happens with stock and relocated webosc.
Screenshot_8

I do not have info about other devices. But do own DS201, DS202 and DS203.

Thank you for your hard work.

Update:
Some info from disassembler. Here is Unstripped elf.
weboscunstripped.zip

I don't understand why failing at 080233A8. A Push command. Maybe stack overflow?
Screenshot_10

Segmentation from elf
Screenshot_11

from la104.

gabonator avatar gabonator commented on May 16, 2024

GetRpcAddress is called when a line was received over serial link (line ended with \n). After typing a single letter, it should not call this function. I looked at the disassembly and got different one. Mine says 080233A8 is in _ZN4BIOS3LOW8SetParamEii after relocating ROM begin to 0x08023000 (compiling with gcc-arm-none-eabi-9-2020-q2-update on osx)

In the build folder, there is also assembly listing file, just for such cases when we need to trace the error. It could be caused by stack size. Hard to tell, you can try changing the stack size here, if it helps:

system/os_host/app_ds203.ld:

/* Define memory regions. */
MEMORY
{
  rom (rx) : ORIGIN = 0x0800C000, LENGTH = 32K
  ram (rwx) : ORIGIN = 0x20003000, LENGTH = 34K
}

_estack = ORIGIN(ram)+LENGTH(ram)-0x100;

Reading the documentation about HFSR/CFSR (https://www.keil.com/appnotes/files/apnt209.pdf), it says this:
image

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

I came across a nice small FLDump utility by bobtidey that lets you make a full image dump of your DSO. I modified it to dump 512KB instead of 256KB. You simply copy FL_DUMP4.HEX or (FL_DUMP4.ADR then FL_DUMP4.BIN) to device.

Reboot with Button 4 pressed. When it's done you should see FLASH.BIN on the drive.

credits: bobtidey
FlDumpHD.zip

from la104.

szmolnar avatar szmolnar commented on May 16, 2024

Hi!

Have you got this fw running on DS203 2.82 hw?
Me too I was facing the same issue, whatever I did I'm just getting missing shell.elf, so I went back to MotoMaxis fw, which runs ok.

In spite the fact that I could not use our fw. I'm still interested in an potion how I could use it on my device. I need a solution to be able to make long time aquisitions, and I hope taht I will be able to do that with your fw or at least that It I will be able to write an app to to that.

Another question would be if it is possible to run four fw. in slot 3 or 4?
Slots 3,4 are open in w6.5, so theoretically I could be possible to run both fw. on this device.

Thanks!

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

Hi,

I was not able to make webosc.elf to work on DS203 2.82 hw. Always get HARDFAULT. I tried moving it to different area but it didn't help. We are waiting for gabonator to look into it.

On a side note, Wildcat fw has the Chart mode with extended time base of 100mS/div to 10min/div and the ability to Auto save to .csv until memory full. Check out -CHART MODE: in https://github.com/MotoMaxis/DS203-DSOQuad/blob/master/WildcatV6.5/User%20Guide%20V5.6-6.5.pdf

I am not sure if we can squeeze both firmwares on same device. It will require recompiling Wildcat to shift it to unused areas. But gabonator is one to know the answer.

from la104.

szmolnar avatar szmolnar commented on May 16, 2024

On a side note, Wildcat fw has the Chart mode with extended time base of 100mS/div to 10min/div and the ability to Auto save to .csv until memory full. Check out -CHART MODE: in https://github.com/MotoMaxis/DS203-DSOQuad/blob/master/WildcatV6.5/User%20Guide%20V5.6-6.5.pdf

Oh, thanks for that!
I totally missed that somehow. What is the longest period we can capture in practice?

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

On screen with meters off we see 13 divisions so that's 130 minutes. But if you enable auto log to .csv files then its until the flash drive becomes full.

I think its over 6 full days on a 8MB device. Each file has 4094 samples that are about 100KB in size.

from la104.

szmolnar avatar szmolnar commented on May 16, 2024

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

Oh 24 hours is easy to do.
It will depend on how fast you tell it to acquire a reading. The fastest time in Chart mode is 100ms/div and slowest is 10min/div which is a range of 13sec to about 20 hours to fill in the buffer. This will use up about 100KB of space. So I think you could max our in 20 minutes with fastest speed to something like 60 days with slowest speed. .

Chart mode works only in Full size buffer mode orange with scrolling rectangle at the bottom. . Which is 13 divisions times about 10 screens. That's about 4094 samples I think.

from la104.

szmolnar avatar szmolnar commented on May 16, 2024

from la104.

MotoMaxis avatar MotoMaxis commented on May 16, 2024

Once the screen fills up it will start scrolling through 10 more screens then loop back to the beginning. .

from la104.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.