DSO Quad Logic analyzer application

--DSO203

Moderators: violet, jessie, jpa

steve1712
Pre-kindergarten
Pre-kindergarten
Posts: 9
Joined: Tue Feb 25, 2014 3:42 pm

Re: DSO Quad Logic analyzer application

Post by steve1712 » Tue Feb 25, 2014 3:43 pm

Hello,
has anyone tried the LogicAnalyzer on DSO Quad HW2.72 ??

thx

jon.woods
Pre-kindergarten
Pre-kindergarten
Posts: 6
Joined: Fri Mar 28, 2014 7:18 pm

Re: DSO Quad Logic analyzer application

Post by jon.woods » Thu Apr 03, 2014 3:00 am

Yes. It loads and seems to run but crashes if you try and save anything.

Hopefully the author will release an update :)

robert.skup
Pre-kindergarten
Pre-kindergarten
Posts: 2
Joined: Tue Jun 17, 2014 2:52 pm

Re: DSO Quad Logic analyzer application

Post by robert.skup » Tue Jun 17, 2014 4:21 pm

Hello,

The reason causing problems with HW 2.72 is increase flash memory up to 8MB. This change caused a change the FAT sector size of 512 to 4096 bytes.
The read/write BIOS functions read/write one full sector, so buffer used in application must have a size of one FAT sector.
In logic analyzer application in file ds203_io.c buffer is declared:

Code: Select all

// Err.. something somewhere is writing past SecBuff, and I'm quite sure it is
// not my code. Allocating a bit more than 512 bytes for that purpose.
static u8 SecBuff[600];
For the application to work correctly with the new HW is a need to change the buffer size to the new sector size and correct fixed size of 512 in the functions _fputc() and _fclose() to the actual system sector size.
Logic analyzer after that change correctly saves both types of files :D

But ... after this change, we have another problem :( - in the current version we have ~4 KB for captured data. When the FAT I/O buffer will be increased, then we lose the additional RAM space and for data capture will be less than 500 bytes.
Which means that the application requires a thorough rebuild :cry:

--
Best regards,
Robert

jpa
Elementary-2
Elementary-2
Posts: 215
Joined: Wed Nov 02, 2011 4:06 am
Are you a staff member of seeedstudio?: no
Which products/projects are your favorite?: DSO Quad

Re: DSO Quad Logic analyzer application

Post by jpa » Tue Jun 17, 2014 11:48 pm

robert.skup wrote: But ... after this change, we have another problem :( - in the current version we have ~4 KB for captured data. When the FAT I/O buffer will be increased, then we lose the additional RAM space and for data capture will be less than 500 bytes.
Which means that the application requires a thorough rebuild :cry:
Actually, the default space for signal capture stuff is 25kB in dsosignalstream.hh. The 4kB is just for malloc().. 500 bytes is probably a little bit too little for that though.

(I'll tell you a secret: there is 16 kB extra ram on DSO Quad. Maybe use that?)

But anyway, better to use AlterBIOS like QuadPawn does.

Btw, if you want long captures, use vcd capture application in QuadPawn. It captures at 72 MSps to flash drive.

robert.skup
Pre-kindergarten
Pre-kindergarten
Posts: 2
Joined: Tue Jun 17, 2014 2:52 pm

Re: DSO Quad Logic analyzer application

Post by robert.skup » Sun Jun 22, 2014 8:34 am

Hi,

Thanks for the information.
Decrease signal capture buffer in dsosignalstream.hh solved problem with RAM memory for malloc :D

ALTERBIOS (binary version 0.4) incorrecty works on HW 2.72. After AlterBIOS hex file is loaded, flash disk is not properly accessible (already at start we have information: "AlterBIOS 0.4: FatFS fail"). In sources I saw that AlterBIOS is built using SYS_B152.HEX. HW 2.72 must have loaded new SYS version min. 1.60 (on MiniDSO.com site I found latest version SYS_B161.hex). I think that's why the last version AlterBIOS 0.4 doesn't work properly with HW 2.72.

Are you planning to develop Logic Analyzer application yet? GUI created by you to display captured signals is really awesome, but of course it still needs a little fine-tuning (already by yourself I made some changes and corrections :) ).


I also have an additional question: Do you know why HEX of your applications (AlterBIOS and PAWN) have problems with normal loading to the device? The disk is removed before the operating system finishes copying file and we get message copy file error. But ... loaded applications seems to be working correctly.

--
Best regards,
Robert

bobtidey
Elementary-1
Elementary-1
Posts: 174
Joined: Sun May 13, 2012 9:39 am
Are you a staff member of seeedstudio?: no
Which products/projects are your favorite?: DSO Quad

Re: DSO Quad Logic analyzer application

Post by bobtidey » Mon Jun 23, 2014 11:35 pm

I think the problem loading the Hex is down to a problem with the basic Hex loader which doesn't seem to like short or overlapping hex records. The build for Alterbios and Pawn seem to prodcue a couple of instances of these probably as segment changes are made. My theory is that the buffer used to hold the hex data is not cleared out properly prior to each record but I have never managed to find the source for the base DFU to verify and or correct any problems in this area. I have successfully loaded problematic Hex files by manually combining the couple of short records that can occur in Pawn / Alterbios. I would not rely on apps where it doesn't complete loading successfully as part of the file near the end may not have flashed properly.

On the version of which SYS is used the main difference between the one for the 2.72 and earlier versions is the support for 8MB flash, but ALTERBIOS replaces these routines anyway so it should not matter which you start from.

Post Reply