Jump to content
IGNORED

Logical Line Character limit broken....but how?


Recommended Posts

The attached program has several lines that break the logical line character limit, and seem to have no way of being shortened. Like this one for example:

 

80 S2=PEEK(T3+T):N2=(O2+P2=Q2)+(O2+R2=Q2
)+(O2+S2=Q2)+(P2+R2=Q2)+(P2+S2=Q2)+(R2+S
2=Q2)+(O2+P2+R2=Q2)+(O2+P2+S2=Q2)+(O2+R2
+S2=Q2)+(P2+R2+S2=Q2)+(O2+P2+R2+S2=Q2)

 

Typing this whole thing in gives this error after pressing RETURN:

 

80 ERROR-   S2=PEEK(T3+T):N2=(O2+P2=Q2)+
(O2+R2=Q2)+(O2+S2=Q2)+(P2+R2=Q2)+(P2+S2=
Q2)+(R2+S2=Q2)+(O2+P2+R2=Q2)+(O2+P2+S2=Q
2)+(O2+R2█

 

The error breaks the line off at the line limit. but if you can't type a line that long, then there is something I'm missing here. 

cribbage.bas

Link to comment
Share on other sites

yeah, I did, but giving it those 2 extra on each line only amounts to 6 or 8 extra spots, and that's not much when the line is over 4 full rows long without doing it. 

 

 

EDIT: I was reading Mapping The Atari , and found the BUFCNT address: 

Quote

107       6B        BUFCNT 
Buffer count: the screen editor current logical line size counter. 

Is there another address that keeps track of the max value for the buffer(120), so that maybe this can be manipulated with a POKE and the line can max out at 255 instead?

Edited by TheRaven81
Link to comment
Share on other sites

2 minutes ago, evilmoo said:

Can you "ENTER" it from a file?

I don't know how I would make said file.

 

5 minutes ago, drac030 said:

The logical line limit is not counted in characters, but rather in lines: three lines 80 chars each is 240 characters. This line actually fits in 160:

 

lline.thumb.png.b1262f194fa003b4e47a27e8c7941002.png

ahh I see. Well, I don't have an 80 column editor, I'd have to look into how to get one. 

Link to comment
Share on other sites

1 minute ago, TheRaven81 said:

I don't know how I would make said file.


 

10 OPEN #1,8,0,"D:LONG.TXT"
20 PRINT #1;"80 S2=PEEK(T3+T):N2=(O2+P2=Q2)+(O2+R2=Q2";
30 PRINT #1;")+(O2+S2=Q2)+(P2+R2=Q2)+(P2+S2=Q2)+(R2+S";
40 PRINT #1;"2=Q2)+(O2+P2+R2=Q2)+(O2+P2+S2=Q2)+(O2+R2";
50 PRINT #1;"+S2=Q2)+(P2+R2+S2=Q2)+(O2+P2+R2+S2=Q2)"
60 CLOSE #1

ENTER "D:LONG.TXT"

Like this, possibly? :)

  • Like 1
Link to comment
Share on other sites

1 hour ago, evilmoo said:


 


10 OPEN #1,8,0,"D:LONG.TXT"
20 PRINT #1;"80 S2=PEEK(T3+T):N2=(O2+P2=Q2)+(O2+R2=Q2";
30 PRINT #1;")+(O2+S2=Q2)+(P2+R2=Q2)+(P2+S2=Q2)+(R2+S";
40 PRINT #1;"2=Q2)+(O2+P2+R2=Q2)+(O2+P2+S2=Q2)+(O2+R2";
50 PRINT #1;"+S2=Q2)+(P2+R2+S2=Q2)+(O2+P2+R2+S2=Q2)"
60 CLOSE #1

ENTER "D:LONG.TXT"

Like this, possibly? :)

So I entered that into Altirra to test it out, and it worked :) So I'll have to do this for each line that is too long, I guess? or is there a way to do multiple lines in a single file? TBH I'm not sure how many lines in the program are like this. 

26 minutes ago, David_P said:

If you have SpartaDos X, type CON80 ON

 

 

I don't. I only have DOS 2.5, and DOS 3.

Edited by TheRaven81
Link to comment
Share on other sites

13 minutes ago, TheRaven81 said:

So I entered that into Altirra to test it out, and it worked :) So I'll have to do this for each line that is too long, I guess? or is there a way to do multiple lines in a single file? TBH I'm not sure how many lines in the program are like this. 

I'm glad it worked.  That's the least worst solution I can come up with on short notice.

Link to comment
Share on other sites

Hi!

6 hours ago, TheRaven81 said:

The attached program has several lines that break the logical line character limit, and seem to have no way of being shortened. Like this one for example:

 

80 S2=PEEK(T3+T):N2=(O2+P2=Q2)+(O2+R2=Q2
)+(O2+S2=Q2)+(P2+R2=Q2)+(P2+S2=Q2)+(R2+S
2=Q2)+(O2+P2+R2=Q2)+(O2+P2+S2=Q2)+(O2+R2
+S2=Q2)+(P2+R2+S2=Q2)+(O2+P2+R2+S2=Q2)

 

Typing this whole thing in gives this error after pressing RETURN:

 

80 ERROR-   S2=PEEK(T3+T):N2=(O2+P2=Q2)+
(O2+R2=Q2)+(O2+S2=Q2)+(P2+R2=Q2)+(P2+S2=
Q2)+(R2+S2=Q2)+(O2+P2+R2=Q2)+(O2+P2+S2=Q
2)+(O2+R2█

 

The error breaks the line off at the line limit. but if you can't type a line that long, then there is something I'm missing here. 

cribbage.bas 23.09 kB · 1 download

The problem is that you are not typing the original program, you are typing some "reconstruction" of the original, with larger variable names.

 

This is the same, but typeable in the normal Atari:

cribbage.thumb.png.09da958cb6b030f6a2515ea0b76aedbb.png

 

Have Fun!

 

 

 

 

cribbage.bas cribbage.lst

  • Like 2
Link to comment
Share on other sites

6 hours ago, dmsc said:

Hi!

The problem is that you are not typing the original program, you are typing some "reconstruction" of the original, with larger variable names.

 

This is the same, but typeable in the normal Atari:

cribbage.thumb.png.09da958cb6b030f6a2515ea0b76aedbb.png

 

Have Fun!

 

 

 

 

cribbage.bas 22.96 kB · 1 download cribbage.lst 22.3 kB · 1 download

Where/how did you get this?

Link to comment
Share on other sites

Atari Program Exchange Repository, APX, easy search... on the internet... archive.org ....  etc etc etc...

 

for example....

 

https://archive.org/search.php?query=atari cribbage

 

yeah some different cribbage and books et al....

Edited by _The Doctor__
Link to comment
Share on other sites

Bad practice to do Basic programs intended as type-ins that exceed the 120 characters.

But as discussed in threads relating to the 10-liner comp it can be good practice.

Basic imposes a 256 limit on an overall line size entered for incorporation to a program -can be met by using a different device such as "D:"

It also imposes a 255 byte limit (?) on actual line length once tokenized (rarely would you come near that)

 

2 relatively painless workarounds:

- split the line into 2, though for a type-in relies on the program having left unused numbers.

- type the line into a text editor then ENTER it from an emulated H: device using Atascii translation.

 

Link to comment
Share on other sites

11 hours ago, dmsc said:

The problem is that you are not typing the original program, you are typing some "reconstruction" of the original, with larger variable names.

@TheRaven81: The APX release does have a protection against LISTing. The BASIC variable name table has been destroyed.

 

Version 2.0 of CRIBBAGE.BAS which can be found on ANTIC's release does not have this kind of protection. I uploaded the ATR to your other Cribbage-related thread.

The program looks a lot different, but I believe that these lines are at least similar to what you are looking at:

grafik.thumb.png.f20ee01e510b82da8b45d50d73cfe8d1.png

As you can see, there all variable names are only one character long (beside the fact that the line has been broken into several lines).

CRIBBAGE.BAS

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...