Re: [Ql-Users] More BASIC Queries

2009-11-14 Thread gdgqler

On 8 Nov 2009, at 09:44, John Gilpin wrote:

 Is there a way of stepping through a BASIC program, line by line, for 
 debugging purposes?  If so how?

The way I debug BASIC programs is to use a routine called Puse, which causes a 
pause.

DEFine PROCedure Puse
 LOcal a$(2)
 OPEN#20,con
 a$=INKEY$(#20,-1)
 CLOSE#20
END DEFine

By placing this inside the program I can see what's happening. For example

2000 Fling: REMark some procedure
2005 Puse:PRINT Line 2000:Puse

allows me to see if I have gone past line 2000. Pressing any key allows the 
program to continue (to the next Puse).

You can add a PRINT facility to Puse by:

 DEFine PROCedure(b$)
.
.
  PRINT#20,b$
.
.
END DEFine

This works well even inside compiled BASIC programs.

George 
___
QL-Users Mailing List
http://www.q-v-d.demon.co.uk/smsqe.htm


Re: [Ql-Users] More BASIC Queries

2009-11-14 Thread Tony Firshman

gdgqler wrote, On 14/11/09 08:15:

On 8 Nov 2009, at 09:44, John Gilpin wrote:

  

Is there a way of stepping through a BASIC program, line by line, for debugging 
purposes?  If so how?



The way I debug BASIC programs is to use a routine called Puse, which causes a 
pause.

DEFine PROCedure Puse
 LOcal a$(2)
 OPEN#20,con
 a$=INKEY$(#20,-1)
 CLOSE#20
END DEFine

By placing this inside the program I can see what's happening. For example

2000 Fling: REMark some procedure
2005 Puse:PRINT Line 2000:Puse

allows me to see if I have gone past line 2000. Pressing any key allows the 
program to continue (to the next Puse).

You can add a PRINT facility to Puse by:

 DEFine PROCedure(b$)
.
.
  PRINT#20,b$
.
.
END DEFine

This works well even inside compiled BASIC programs.
  


... and of course further de-bugging info could be added, like printing 
critical  global variables each time.



Tony

--
QBBS (QL fido BBS 2:257/67) +44(0)1442-828255
  t...@firshman.co.uk http://firshman.co.uk 
Voice: +44(0)1442-828254 Fax: +44(0)1442-828255 Skype: tonyfirshman

   TF Services, 29 Longfield Road, TRING, Herts, HP23 4DG

___
QL-Users Mailing List
http://www.q-v-d.demon.co.uk/smsqe.htm


Re: [Ql-Users] aurora display

2009-11-14 Thread arnold . clarke
 I do not know whether I have Qplane. It was assembled by Qubbesoft in 2003. 
The SGC was plugged into Qubide which was plugged into the backplane. I have 
separated them and and tried them in different positions.
As it is now, when I switch on with a floppy disk in flp1_, it goes through the 
first initionalising stage ignoring the floppy and the F1/F2 selction comes up 
on the screen. I press F1 and it fires up the floppy wich is a Qpac2 floppy. 
I enter load win1_ boot and I can run the boot file from the line after the 
SMSQ installation and everythig seems to be working. 
I did try Aurorql in place of SMSQ but it was the same it stops at the first dot
I have discovered  a reason why my display occasionally used to break up and a 
sharp tap on the case used to cure it, and it seems to be the back plane 
connection  
  
Arnold




From: Tony Firshman t...@firshman.co.uk
To: ql-us...@q-v-d.com
Sent: Friday, 13 November, 2009 23:24:04
Subject: Re: [Ql-Users] aurora display

arnold.cla...@talk21.com wrote, On 13/11/09 19:28:
 Hi,
        I believe my Qubide chips are not working as they should. At first I 
copied my master floppy disk to improve matters and as things didn't improve I 
assumed my master  disk was faulty; but I now realize my master floppy is ok. 
Its the chips.
 Where can I get replacement chips?
 
  

Have you cleaned the chips legs?
You cannot replace them randomly and hope for the best.
If you need qubide checked out, I would recommend sending it to someone who has 
a working qubide. Rich, can you help?

I guess you didn't see see my previous email?  Are you using Qplane?
If so then I found that was unreliable with Qubide.  I had to keep Qubide 
nearest the QL, or even hang SGC on the through connector.
All has been fine (for a decade now) with Mplane.

Tony

-- QBBS (QL fido BBS 2:257/67) +44(0)1442-828255
      t...@firshman.co.uk    http://firshman.co.uk Voice: +44(0)1442-828254 
Fax: +44(0)1442-828255 Skype: tonyfirshman
  TF Services, 29 Longfield Road, TRING, Herts, HP23 4DG

___
QL-Users Mailing List
http://www.q-v-d.demon.co.uk/smsqe.htm



  
___
QL-Users Mailing List
http://www.q-v-d.demon.co.uk/smsqe.htm


Re: [Ql-Users] More BASIC Queries

2009-11-14 Thread Bob Spelten
Op Sat, 14 Nov 2009 09:46:47 +0100 schreef Tony Firshman  
t...@firshman.co.uk:



gdgqler wrote, On 14/11/09 08:15:
The way I debug BASIC programs is to use a routine called Puse, which  
causes a pause.



... and of course further de-bugging info could be added, like printing
critical  global variables each time.

Tony


I combine the two suggestions into one T(est)PAUSE procedure.
Making use of the fact that Qmenu is always present in my QL's.
At various points in the SBasic I put a call like:

 TPAUSE title$,message$

Where title$ identifies the Proc/Fn I'am coming from and message$ can be  
something like: var a$:  a$

...
DEF PROC TPAUSE (t$,m$)
 y%=ITEM_SELECT(t$,m$,'OK')
END DEF

Bob

--
The BSJR QL software site at: http://members.chello.nl/b.spelten/ql/
___
QL-Users Mailing List
http://www.q-v-d.demon.co.uk/smsqe.htm


Re: [Ql-Users] aurora display

2009-11-14 Thread Tony Firshman

arnold.cla...@talk21.com wrote, On 14/11/09 11:59:

 I do not know whether I have Qplane. It was assembled by Qubbesoft in 2003.

The you definitely have Qplane

 The SGC was plugged into Qubide which was plugged into the backplane. I have 
separated them and and tried them in different positions.
As it is now, when I switch on with a floppy disk in flp1_, it goes through the first initionalising stage ignoring the floppy and the F1/F2 selction comes up on the screen. I press F1 and it fires up the floppy wich is a Qpac2 floppy. 
I enter load win1_ boot and I can run the boot file from the line after the SMSQ installation and everythig seems to be working. 
I did try Aurorql in place of SMSQ but it was the same it stops at the first dot
I have discovered  a reason why my display occasionally used to break up and a sharp tap on the case used to cure it, and it seems to be the back plane connection  
  
  

Ah.

Maybe you haven't got the SMSQ line as something like:

IF ver$HBA:code to run smsq:ENDIF

.. and SMSQ is loading repeatedly at every restart.

It sounds from your description above that the qubide is working fine.

Tony



--
QBBS (QL fido BBS 2:257/67) +44(0)1442-828255
  t...@firshman.co.uk http://firshman.co.uk 
Voice: +44(0)1442-828254 Fax: +44(0)1442-828255 Skype: tonyfirshman

   TF Services, 29 Longfield Road, TRING, Herts, HP23 4DG

___
QL-Users Mailing List
http://www.q-v-d.demon.co.uk/smsqe.htm


Re: [Ql-Users] More BASIC Queries

2009-11-14 Thread P Witte

gdgqler wrote:


On 8 Nov 2009, at 09:44, John Gilpin wrote:


Is there a way of stepping through a BASIC program, line by line, for debugging 
purposes?  If so how?


The way I debug BASIC programs is to use a routine called Puse, which causes a 
pause.

DEFine PROCedure Puse
 LOcal a$(2)
 OPEN#20,con
 a$=INKEY$(#20,-1)
 CLOSE#20
END DEFine

By placing this inside the program I can see what's happening. For example

2000 Fling: REMark some procedure
2005 Puse:PRINT Line 2000:Puse

allows me to see if I have gone past line 2000. Pressing any key allows the 
program to continue (to the next Puse).


The way the question was formulated, a line by line stepping through 
a program - specifically, a boot script - was wanted. This hardly adds 
to the responses already given, although its fine if only a few lines 
want monitoring.


To your example I venture to suggest the following improvement:

DEFine PROCedure Puse(l%)
 LOcal c%
 c% = FOPEN('con_')
  PRINT#c%; 'Line'! l%

or

  LIST#c%; l%: rem Unless compiled, of course
  PAUSE#c%; -1
 CLOSE#c%
END DEFine

Call with

2005 Puse 2000


You can add a PRINT facility to Puse by:

 DEFine PROCedure(b$)
.
.
  PRINT#20,b$
.
.
END DEFine

This works well even inside compiled BASIC programs.


Actually,

DEFine PROCedure(b$)

doesnt work at all ;o) Probably just a ruse to see if anyone was 
paying attention.


Per
___
QL-Users Mailing List
http://www.q-v-d.demon.co.uk/smsqe.htm


Re: [Ql-Users] More BASIC Queries

2009-11-14 Thread P Witte

Tony Firshman wrote:


gdgqler wrote, On 14/11/09 08:15:

On 8 Nov 2009, at 09:44, John Gilpin wrote:

 
Is there a way of stepping through a BASIC program, line by line, for 
debugging purposes?  If so how?



The way I debug BASIC programs is to use a routine called Puse, which 
causes a pause.


DEFine PROCedure Puse
 LOcal a$(2)
 OPEN#20,con
 a$=INKEY$(#20,-1)
 CLOSE#20
END DEFine

By placing this inside the program I can see what's happening. For 
example


2000 Fling: REMark some procedure
2005 Puse:PRINT Line 2000:Puse

allows me to see if I have gone past line 2000. Pressing any key 
allows the program to continue (to the next Puse).


You can add a PRINT facility to Puse by:

 DEFine PROCedure(b$)
.
.
  PRINT#20,b$
.
.
END DEFine

This works well even inside compiled BASIC programs.
  


... and of course further de-bugging info could be added, like printing 
critical  global variables each time.


Right you are. I miss Minerva SuperBasic's watch variable facility, eg:

120 WHEN x  10: PRINT X is now too big!
..
130 FOR x = 5 TO 12: PRINT x

will print

5
6
7
8
9
10
X is now too big!
11
X is now too big!
12

Pity it didnt make it into SBasic

Per
___
QL-Users Mailing List
http://www.q-v-d.demon.co.uk/smsqe.htm


[Ql-Users] Web Emulator

2009-11-14 Thread Rich Mellor
Has anyone looked at producing a version of a QL emulator in Java - with 
the popularity of the QL Wiki continually increasing, it is good to see 
it getting high ratings on google when searching for programs.  It is 
also helping to attract more people back to the QL, judging by the sales 
on my website and ebay - I listed a boxed QL on ebay the other day, and 
over 80 people are watching it, with its price currently at over £80 !!


What is really missing from the QL Wiki, is the ability to see what the 
QL Software actually does.


I have tested and got the majority of software working on q-emulator, 
and what we ideally would need would be a link on the page for each 
piece of software to a Java based emulator which would allow you to run 
each item of software, for say, a maximum of 2 minutes at a time, so 
that people could try each title out.


Is there anyone willing and able to write such an emulator ?

--
Rich Mellor
RWAP Services

http://www.rwapsoftware.co.uk
http://www.rwapservices.co.uk

-- Try out our new site: http://sellmyretro.com


___
QL-Users Mailing List
http://www.q-v-d.demon.co.uk/smsqe.htm


Re: [Ql-Users] More BASIC Queries

2009-11-14 Thread David Tubbs

At 08:15 14/11/2009 +, you wrote:
 Is there a way of stepping through a BASIC program, line by line, for 
debugging purposes?  If so how?


Lawrence gave us SSTEP etc, does it work without Minerva ?


___
QL-Users Mailing List
http://www.q-v-d.demon.co.uk/smsqe.htm


Re: [Ql-Users] Web Emulator

2009-11-14 Thread Gerhard Plavec


Has anyone looked at producing a version of a QL emulator in Java - 
with the popularity of the QL Wiki continually increasing, it is good 
to see it getting high ratings on google when searching for programs.  
It is also helping to attract more people back to the QL, judging by 
the sales on my website and ebay - I listed a boxed QL on ebay the 
other day, and over 80 people are watching it, with its price 
currently at over £80 !!


What is really missing from the QL Wiki, is the ability to see what 
the QL Software actually does.


I have tested and got the majority of software working on q-emulator, 
and what we ideally would need would be a link on the page for each 
piece of software to a Java based emulator which would allow you to 
run each item of software, for say, a maximum of 2 minutes at a time, 
so that people could try each title out.


Is there anyone willing and able to write such an emulator ?


You mean something like this
http://www.vavasour.ca/jeff/ts1000/index.html
but for the QL ?
Yeah, would be cool :)

___
QL-Users Mailing List
http://www.q-v-d.demon.co.uk/smsqe.htm