home *** CD-ROM | disk | FTP | other *** search
/ ARM Club 1 / ARM_CLUB_CD.iso / contents / apps / program / d / debug / !Debug / !Help < prev    next >
Encoding:
Text File  |  1993-03-04  |  2.3 KB  |  73 lines

  1. RISC_OS Debugger
  2.  
  3. Written by Richard H Heywood
  4.  
  5. This program may be distributed freely in the public domain as long as
  6. all the files associated with it are left unaltered. The !run and !boot may
  7. be tweeked for your own systems but all other code, data, copyright messages
  8. and help must be left unaltered.
  9.  
  10. How to use it.
  11.  
  12. Inside the !debug application is a file called debugger. Copy this file into 
  13. the place you keep all your .h files and #include it into any risc_os
  14. application that you are developing. You will be given 2 new functions to 
  15. call.
  16.          debug(line_number, message);
  17.          debug_int(line_number, message, integer);
  18.  
  19.   Line_number is an int between 1 and 6. anything else will be ignored. the
  20. message is a string (eg. "made it to main wimp poll"). Keep these messages
  21. smaller than 45 characters long. If they are longer they will simply be
  22. truncated and you won't be able to read them anyway.
  23.  
  24. Once all the strange bugs have been ironed out, get rid of all the debug()
  25. calls and the #include and send it to the nearest public domain library
  26. (unless you are one of those nasty people that expects money for you 
  27. products!!). Theres no real reason why you should take the debug()s out,
  28. its only that someone else may have !debug running and it would make a mess
  29. of it.
  30.  
  31.  
  32. How it works.
  33.  
  34. There is a system varibale for each line of text plus one to mark if any of
  35. the lines have changed. When a call to debug is made, the appropriate line is
  36. changed and the marker changed. At !debugs next poll, it will notice that
  37. something has changed and update all the lines.
  38. Because of this you can not have two different copies of it running at the 
  39. same time. If you do have two running, only one will get any changes to the
  40. messages (whichever one is polled first!)
  41.  
  42.  
  43. Getting it to work with BASIC wimp progs.
  44.  
  45.  This is no real problem - simply take a look at the two functions inside
  46. 'debugger' and re-write them in basic. They are very simple as all they do is
  47. change 2 system variables. Next bolt the 2 PROCs to the end of you basic 
  48. proggy and call them when needed.
  49.  
  50.  
  51. Hope it helps you out :-)
  52. I needed it when writting it :-( 
  53.  
  54.  
  55. HISTORY
  56.  
  57. Version 1.00
  58.   First implementation
  59.  
  60.  
  61.  
  62.  
  63. Comments, bugs etc to :-
  64.  
  65. Rik
  66. rhh88@uk.ac.soton.ecs        (dies end of July 91)
  67.  
  68. or
  69. Harewood
  70. Harewood Road,
  71. Chalfont St Giles,
  72. Bucks HP8 4UA.
  73.