Shop OBEX P1 Docs P2 Docs Learn Events
SX_Key Debugging Session — Parallax Forums

SX_Key Debugging Session

SamMishalSamMishal Posts: 468
edited 2006-01-05 09:40 in General Discussion
Dear Sirs,

I am using a tutorial program from the the Gunther Book (Programming the Sx).

No problems most of the time and the progra runs OK.

But occasionally when I step through the programme the Debugger dissappears.
This also happens more frequently when I use walk (especially at the faster speeds)

Please note, this is an intermittant problem, it seems to happen only when I step
at a fast rate or when I use walk set at a fast rate (but some times at a slow rate too).

Running the programme works fine.

So it is not a problem with the programme (any way it is a simple one Tut03.src and this happens
with other programmes e.g Tut04 etc. too).
Also since the problem is only occasional, that implies that there is something wrong with the IDE.

Again the problem is:
····· The debugger dissappears on certain occasions after pressing Step a few times at fast rate
······ or when Walk mode is used, but not all the time.

Please let me know if this problem has been encountered before.

I am using Windows ME, Pentium III and SX_Key Rev F software ver 3.1 and the system is Pro Dev system.
I do not have the resonator connected, all switches and fuses are set correctly by the programme.


Thanks in advance

Samuel Mishal
·

Comments

  • SamMishalSamMishal Posts: 468
    edited 2006-01-03 21:53
    Hi all,

    I think I have a solution, Thanks to Gunther's FAQ.
    I set my Com Port FIFO to very low and now I have not been able
    have the problem come back. So this seems to have been the solution.jumpin.gif

    BUT, would it not be better if the·Debugger reported a problem or an error message
    rather than just dissapperaing of the desktop???????

    Thanks Gunther, your book is great and so are your contributions in this forum.
    The FAQ that helped me was :
    SX-Key not found on COMx Error
    Q:
    [font=Arial,Arial color=blue size=2]When I try to program an SX device with the SX-Key, the IDE reports an "SX-Key not found" Error", what is the reason for this? [/font]
    [font=Arial,Arial size=2]The reply to this FAQ had the bit about the FIFO and I thought that sounds like it might be related[/font]
    to my problem. And so I set the FIFo to "low". After this I now can step and walk as fast as I want without
    the Debugger perfoming a vanishing act on me.

    Thanks Gunther.

    To Mr. PJMonty,
    I am wondering what in the programming could cause the debugger window to just vanish
    instead of causing an error message or just hanging even. I am glad it does not hang though!
    Thanks all.

    Samuel Mishal

    [font=Arial,Arial size=2]
    [/font]
  • Guenther DaubachGuenther Daubach Posts: 1,321
    edited 2006-01-03 23:18
    Samuel,

    thanks for you kind words - I'm glad to learn that my writing sometimes really helps out of troubles smile.gif .

    Concerning the disappearing Debugger window: As far as I can remember, former versions of the SX-Key IDE behaved like this when you have set focus (clicked on) another window. Which SK-Key IDE version are you using?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Greetings from Germany,

    G
  • PJMontyPJMonty Posts: 983
    edited 2006-01-04 00:31
    Samuel,

    Not sure what's going on with the disappearing window. You're the first person I am aware of who has reported this problem. Since it seems to have been fixed by the FIFO settings, I'll file it under "mysterious circumstances" for now, but keep my open for it in the future.
      Thanks, PeterM
  • SamMishalSamMishal Posts: 468
    edited 2006-01-04 00:44
    Mr. Gunther,

    I am using the latest and the best (hehehe). Rev. F with 3.1 IDE.
    It is not a problem of loosing focus. It happens while I am stepping or walking, especially if I do it
    at fast rates. When stepping using Alt-S it happens if I press Alt-S rapidly, with the mouse the same.
    Since the FIFO resolves it it sounds to me like a bug with the IDE's serial comms routines.

    But I am racking my tiny brains as to how a comms buffering problem could cause such a thing,
    except it might be a buffer over-under flow and thus writing in un-allowed memory space and this is causing a
    window close. I.E. the same old story when programming using C/C++ where pointers cause
    memory overwrites etc.

    I do not know if the IDE is programmed in C or not, but most other programming languages stop
    this kind of thing.

    Regards

    Samuel
  • PJMontyPJMonty Posts: 983
    edited 2006-01-04 19:41
    Samuel,

    The IDE is written in Delphi, which is object oriented Pascal. I doubt is a buffer over or under flow since that would be more likely to cause an exception to be generated and the entire program to get shut down by Windows. In addition, there are no pointers used in the source code for the communications system in the IDE. You canuse pointers in Delphi, buit there's usually not a pressing reason to do so. I'll see if I can replicate your results here.
      Thanks, PeterM
  • SamMishalSamMishal Posts: 468
    edited 2006-01-05 04:56
    Dear PJMonty,

    Interesting I did not know that Delphi is still being used. I use Borland C++ which has the Delphi windows library.

    I had the serial comms FIFO set at Max when I was having the problem. Setting it at Low has resolved the problem.
    So please note that when you are trying to replicate the problem, also I am using windows me.

    I would be interested in what the problem is. I am still wondering what kind of error would cause
    a window just to vanish. Oh, by the way, some times the whole debugger vanishes and somtimes just the main
    window leaving the control panel there.

    Any way, thanks for a great IDE and the SX_Key is great.
    I have a wish list for the IDE:
  • SamMishalSamMishal Posts: 468
    edited 2006-01-05 05:08
    Sorry I pressed submit before I finished my posting:

    Here is the wish list:

    1-Like in the Stamp editor, can there be a Direcory tree
    2-Can you add a Close-All option to close all open files at once
    3-Can there be a Close button on the Tool Bar to close the current file
    4-Can you add the ability to use a Template file when the editor opens a new file.


    Thanks again for a great product and for the great support and PROFESSIONAL everything..........

    Samuel Mishal
  • PJMontyPJMonty Posts: 983
    edited 2006-01-05 07:51
    Samuel,

    1 - Not familiar with the Stamp editor. Where are you thinking you need a directory tree? When you open files?

    2 - It's already there. Take another look at the "File" menu and you'll see "Close All".

    3 - Right click on the list of open files on the left of screen and there's a menu option to close the current file.

    4 - It does use templates when you open a new file if you have templates in the "Templates" directory and the "Use templates if available" option is checked in the configuration dialog. You can only have one SX/B and one assembly template in the directory and they must have the names "Template.SRC" and "Template.SXB". If you are hoping to have more extensive template capability added, see this thread for more discussion about templates and the concept behind their implementation:

    http://forums.parallax.com/showthread.php?p=560621

    You may have to scroll up to see the start of the thread.
      Thanks, PeterM
  • SamMishalSamMishal Posts: 468
    edited 2006-01-05 09:40
    Dear Peter,

    1 - I am talking about the Basic Stamp Editor (Parallax's)

    ···· I am enclosing an image that shows the IDE there and I have added pointers to the

    ···· kind of thing I am talking about.

    ···· The directory tree even allows you to move/copy/delete files between directories etc.

    ···· i.e. it is a fully functional explorer. This makes it much easier to manage files you are working on

    ··· and tidy up projects, templates, include files etc, etc.

    ··· The Basic Stamp Editor is quite convenient, if you are not familiar with it you should give it

    ··· a run, it is a very very good IDE.

    2 - sad.gif sorry I am getting a new pair of glasses soon!!!!!

    3 -· Yes I saw that but it has to be done like this

    ···· a-click on the file to make it the highlighted one

    ···· b-right click on the file to bring the pop-up menu then choose close

    ··· it would be much more convenient to have an icon on the Toolbar

    4 - shakehead.gif The glasses will help BUT I do not know what to do about the Brain cells (does anyone

    ····· know of a good drug for dying brain cellsdevil.gif )

    Anyway these are all nice "conveniences" to make a great product even greater.

    Regards

    Samuel
    800 x 600 - 163K
Sign In or Register to comment.