FB debugger : 2.96 32/64 BIT ..... (2020/02/17)

User projects written in or related to FreeBASIC.
D.J.Peters
Posts: 8189
Joined: May 28, 2005 3:28
Contact:

Re: FB debugger : 2.80 BETA 1 (january 13th, 2014)

Postby D.J.Peters » Jan 15, 2014 0:15

SARG wrote:About your request, how do you think to do if the array is very big
may be a scrollbar
SARG wrote:About your request, how do you think if/or multi dim ?
may be some more scrollbars. (not a joke)
I'm personally would use FLTK for such and other own special widgets.

Joshy
VANYA
Posts: 1411
Joined: Oct 24, 2010 15:16
Location: Ярославль
Contact:

Re: FB debugger : 2.80 BETA 1 (january 13th, 2014)

Postby VANYA » Jan 15, 2014 4:49

Hi SARG!

Here's how to do in the IDE Purebasic:

Image

This drawing was made from the debugger Insinght:

Image
SARG
Posts: 1162
Joined: May 27, 2005 7:15
Location: FRANCE

Re: FB debugger : 2.80 BETA 1 (january 13th, 2014)

Postby SARG » Jan 16, 2014 0:31

Hi all,

@D.J.Peters
I was thinking that 100000 elements or more could take a long time to manage.
Anyway thanks for the suggestion.

@VANYA
a first attempt a bit limited http://users.freebasic-portal.de/sarg/FBdebugger.bas
Only the arrays with basic type are displayed, max 100 elements. I will quickly add arrays of udt, arrays in udt and upgrade this limit.
I believe that 1000 elements in the listview should be enough by giving the possibility to move inside the array.
By the way I found a bug in the index selection.....fixed in this version.

Image
VANYA
Posts: 1411
Joined: Oct 24, 2010 15:16
Location: Ярославль
Contact:

Re: FB debugger : 2.80 BETA 1 (january 13th, 2014)

Postby VANYA » Jan 16, 2014 3:30

Hi SARG!

Thank you for responding to my request!

It would be nice to make two amendments:

1) need a button to update the cell array in ListView (Display), but not close the window "Index Selection".
2) cell array in ListView are beyond the upper limit

Image
SARG
Posts: 1162
Joined: May 27, 2005 7:15
Location: FRANCE

Re: FB debugger : 2.80 BETA 1 (january 13th, 2014)

Postby SARG » Jan 16, 2014 8:55

Hi,

VANYA wrote:1) need a button to update the cell array in ListView (Display), but not close the window "Index Selection".
2) cell array in ListView are beyond the upper limit


These features were planned : I just have adapted a few the existing code to show quickly what could be done.
Still a bit of work to do, let me the time :-)
SARG
Posts: 1162
Joined: May 27, 2005 7:15
Location: FRANCE

Re: FB debugger : 2.80 BETA 1 (january 13th, 2014)

Postby SARG » Jan 16, 2014 21:52

Hi all,

A more polished version : http://users.freebasic-portal.de/sarg/FBdebugger.bas

Select the indexes then click on the button "update" to display up to 100 elements. This limit can easily be changed.
For now only basic types are allowed but more complex cases could be added.

Code: Select all

Type tudt
   dim As Integer xxx(3,5)
   Dim As UShort yyy
End Type

Dim As tudt udt(2,3,4)
udt(1,2,3).xxx(2,2)=127

In the above example it's possible to list the different values of xxx.
Select indexes for udt (here 1, 2, 3) and apply, then select indexes for xxx (here 2) you see all the values for udt(1,2,3).xxx(2, 0 TO 5). Set the second index at 2 to display a list beginning at 2 instead 0.

But it is not (currently) possible to list the different values of yyy.
However I'm thinking about that. All opinions, ideas and weird cases are welcome.
VANYA
Posts: 1411
Joined: Oct 24, 2010 15:16
Location: Ярославль
Contact:

Re: FB debugger : 2.80 BETA 1 (january 13th, 2014)

Postby VANYA » Jan 17, 2014 3:56

SARG wrote:

Code: Select all

Type tudt
   dim As Integer xxx(3,5)
   Dim As UShort yyy
End Type

Dim As tudt udt(2,3,4)
udt(1,2,3).xxx(2,2)=127



Hi SARG!

Net arrays (without UDT) work perfectly. Wow!

SARG wrote:

Code: Select all

Type tudt
   dim As Integer xxx(3,5)
   Dim As UShort yyy
End Type

Dim As tudt udt(2,3,4)
udt(1,2,3).xxx(2,2)=127


I understand , debugger (today) not displays the values ​​for this code? We will wait for updates. Thank you SARG!
SARG
Posts: 1162
Joined: May 27, 2005 7:15
Location: FRANCE

Re: FB debugger : 2.80 BETA 1 (january 13th, 2014)

Postby SARG » Jan 18, 2014 0:44

VANYA wrote:I understand , debugger (today) not displays the values ​​for this code

Not exactly, previously only the values for direct arrays could be listed. But it was not possible to list the same simple data fields inside an array of udt.
Now the new beta (V4) allows that feature, see the screenshot below. http://users.freebasic-portal.de/sarg/FBdebugger.bas

To come, I'll add buttons to move inside the array : +/- 1 element and +/- 1 block (up to 100 elements).

Image
VANYA
Posts: 1411
Joined: Oct 24, 2010 15:16
Location: Ярославль
Contact:

Re: FB debugger : 2.80 BETA 1 (january 13th, 2014)

Postby VANYA » Jan 18, 2014 3:25

Hi SARG!

I do not know , why did not show this code in the debugger:

Code: Select all

Type tudt
     As Integer xxx(3,5)
     As UShort yyy
End Type

Dim As tudt udt(2,3,4)
udt(1,2,3).xxx(2,2)=127
udt(1,2,3).yyy = 568
udt(0,0,0).yyy = 345
udt(0,0,1).yyy = 999
udt(1,1,1).yyy = 888
udt(2,2,2).yyy = 777

? udt(1,2,3).xxx(2,2)
? udt(1,2,3).yyy
sleep


All lines except udt(0,0,0).yyy not show

Image

Video:
http://video.yandex.ru/users/freebasic/view/1/

And this code works fine (the debugger shows all cells):

Code: Select all

Type Q
   i As Integer
   u(5) As Integer
   P(5,7) As Integer
End Type

Dim shared As Q a(300,300)

For i As Integer = 0 To 300
   For j As Integer = 0 To 300
      a(i,j).i = Rnd*100
      a(i,j).u(3) = Rnd*100
      a(i,j).P(1,1) = Rnd*100
   Next
Next


Compilier 0.90.0
SARG
Posts: 1162
Joined: May 27, 2005 7:15
Location: FRANCE

Re: FB debugger : 2.80 BETA 1 (january 13th, 2014)

Postby SARG » Jan 18, 2014 10:54

Hi VANYA,

At the beginning I was not able to reproduce the error and I didn't understand. Happily you gave this information :
VANYA wrote:Compilier 0.90.0


In fbc 0.91 dkl has fixed a bug : the lenght of udt is now correct (debugging data). As I'm using this version I have removed for fbdebugger 2.80 the workaround used previously.....

The better to do is to download the recent-git-build provided by MOD :
http://www.freebasic.net/forum/viewtopic.php?f=17&t=19095&p=194420#p194305
Or If you dont want to upgrade fbc I could give you few lines of code to be added to solve this issue.
VANYA
Posts: 1411
Joined: Oct 24, 2010 15:16
Location: Ярославль
Contact:

Re: FB debugger : 2.80 BETA 1 (january 13th, 2014)

Postby VANYA » Jan 18, 2014 13:30

SARG wrote:The better to do is to download the recent-git-build provided by MOD :
http://www.freebasic.net/forum/viewtopic.php?f=17&t=19095&p=194420#p194305


I downloaded the latest beta version and will test the debugger on it. SARG Thanks for the clarification.
SARG
Posts: 1162
Joined: May 27, 2005 7:15
Location: FRANCE

Re: FB debugger : 2.80 BETA 1 (january 13th, 2014)

Postby SARG » Jan 18, 2014 21:41

Hi again,

An other version to play with indexes : Fbdebugger 2.80 beta 5

The window is a bit larger to show big var names.

The listview display is also larger and list up to 20 lines at the same time. The maximum of lines inside the listview is given by a const KBLOCKIDX, defined by default 100. Change it if you want.

4 new buttons (line+, line-, block+, block-) allow to change the current index by adding or subtracting 1 or a block (100), if possible.

Finally by clicking on a line, the index of the line becomes the current index. Don't forget to apply if needed....

Image
VANYA
Posts: 1411
Joined: Oct 24, 2010 15:16
Location: Ярославль
Contact:

Re: FB debugger : 2.80 BETA 1 (january 13th, 2014)

Postby VANYA » Jan 19, 2014 5:56

Tried FbDebugger on to version 0.91, everything works fine. Now it is very conveniently implemented viewing arrays. Thanks SARG for innovations.
be_design
Posts: 11
Joined: Mar 04, 2014 21:09
Location: Stockholm, Europe

Re: FB debugger : 2.80 BETA 1 (january 13th, 2014)

Postby be_design » Mar 16, 2014 23:03

Hi SARG and all !

All new to FB, just tried fbdebugger 2.80_b6
and noticed some minor details -

After defining CSED_FB.EXE as an editor it refused to
stay registered (in the .ini-file)

I made a patch for it to be 'file name Case agnostic" and at some other
relevant places within the ini_read() procedure

Also future proofing by a less specific check of compiler name (c.exe)

And an addition for faster scanning of the ini-file (well, practically un-noticeable)

And some patches to enable re-enabling of some warnings/hints about file exceptions
- have tested with the different combinations of file conditions - all (should) work OK

My comments in the source is prefixed by (BE)
_________

Menu fields DBG and CMPL are not stored, due to the current beta state I assume.


I will send the complete procedure ini_read() source to SARG
My comments are prefixed by (BE)


I'm impressed by the FBdebugger, will be using it!

/be_design
SARG
Posts: 1162
Joined: May 27, 2005 7:15
Location: FRANCE

Re: FB debugger : 2.80 BETA 1 (january 13th, 2014)

Postby SARG » Mar 23, 2014 22:58

Hi be_design,

My reply not as quickly that said in my email.... Thanks again for your comments.

- some of yours modifications added. For example use of lcase.

- 'Continue do' not added. It seems not usefull as when a test is true the other ones are not executed (if elseif..).
- 'fbc.exe' kept as compiler. fbdebugger is too close to fbc : it would be difficult to use it with an other compiler.
- 'messages for fbc/ide fields not filled' not added. As written in my email, users not using them should not get the warning message each time they start fbdebugger.

- Parameters for execution of debuggees, DBG = cmdexe(), are saved and restored.

- Parameters for compilation, CMPL, are now saved BUT there is only one set : not one dedicated for each debuggee. This could be easily change.

I upload a new beta version also without all its own debugging statements. Fbdebugger 2.80 beta 7

A screenshot of my current work on a fbdebugger written with (almost) no Windows API. The goal is a tools for both Windows and Linux. I'll try also to integrate a light editor and a GUI designer. For now there are different buttons, tooltips, contextual menus, scrolling bars, message boxes, tabs, treeviews. Any help is welcome. :-)
Image.

Return to “Projects”

Who is online

Users browsing this forum: No registered users and 12 guests