Page 12 of 14

Re: Paper Soft type-ins (comments) (ITA/ENG)

Posted: Wed Oct 29, 2014 6:06 am
by highinfidelity
Does it really end so abruptly, at page 11? :?

Re: Paper Soft type-ins (comments) (ITA/ENG)

Posted: Wed Oct 29, 2014 6:43 am
by orion70
Yep, I only had scans of the VIC games, plus the cover and index. Page 11 has the end of the last VIC game, and the beginning of the first C16 listing. Of course, I am only interested in VIC stuff.

NB: Saver71 offered his time in typing the two games in, so we already have a volunteer :D

Re: Sv: Paper Soft type-ins (comments) (ITA/ENG)

Posted: Wed Oct 29, 2014 7:21 am
by joshuadenmark
GO Saver71!

Re: Paper Soft type-ins (comments) (ITA/ENG)

Posted: Wed Oct 29, 2014 8:10 am
by highinfidelity
Oh, I see. :wink:

Would you mind another question? I'm not familiar with this magazine (which, albeit the funny name, I doubt I would have ever bought anyway as a kid: there's not even a B/W screenshot of each game...).

There is a checksum system to debug "on the fly" every line of BASIC right after entering it, line by line. This sounds very convenient but puzzles me. The debugging program is listed among the first pages of the magazine, it is in plain BASIC and I suppose it has to be RUN before typing any of the following programs.

How can it run in background and perform the cheksums, considered that its line numbering overlaps the line numbering of the following programs? Also, how will it survive a NEW statement? Is it perhaps pushed somewhere into a special location of the RAM?

Re: Paper Soft type-ins (comments) (ITA/ENG)

Posted: Wed Oct 29, 2014 8:33 am
by orion70
I can't answer your questions, particularly about the RAM location of the program, but I've used it and can tell you how it works. Each time you type a line in, AFTER you press Return a number appears at the top of the screen. You have to compare it with the number in the paper listing (be aware that spaces and command abbreviations change the checksum!).
It never interferes with the listing itself, nor with the program execution, so it's very useful. It's not affected by a NEW statement either, unless you use RUN/STOP and RESTORE. In fact, you'll see it produces a new number each time you type anything in, including nonsense words.

Try it yourself :wink:

NB: what would you expect, screenshots of the games for a mere mille lire? :)

Re: Paper Soft type-ins (comments) (ITA/ENG)

Posted: Wed Oct 29, 2014 8:48 am
by highinfidelity
orion70 wrote:NB: what would you expect, screenshots of the games for a mere mille lire? :)
Not really! :wink: However I would have been EXTREMELY suspicious towards a type-in listing with no screenshots. I remember spending afternoons at typing in programs that actually came with screenshots, and ending in severe disappointment nonetheless. So I can't figure any reason good enough - back then - to begin a type-in without at least a fuzzy, black & white screenshot to fancy about! :D

Thanks for the details concerning the checksum program. It's comforting to read that you also couldn't grasp its mechanism at first glance! :wink:

Re: Sv: Paper Soft type-ins (comments) (ITA/ENG)

Posted: Wed Oct 29, 2014 9:00 am
by saver71
joshuadenmark wrote:GO Saver71!
Det er godt! Jeg er glad for at hjælpe igen. :mrgreen:

(Jeg boede i København i mere end et år)

Re: Paper Soft type-ins (comments) (ITA/ENG)

Posted: Wed Oct 29, 2014 9:42 am
by Mike
highinfidelity wrote:There is a checksum system to debug "on the fly" every line of BASIC right after entering it, line by line. This sounds very convenient but puzzles me. The debugging program is listed among the first pages of the magazine, it is in plain BASIC and I suppose it has to be RUN before typing any of the following programs.

How can it run in background and perform the cheksums, considered that its line numbering overlaps the line numbering of the following programs? Also, how will it survive a NEW statement? Is it perhaps pushed somewhere into a special location of the RAM?
This is a DATA loader which writes a machine program into a address range, which previously has been locked from use by the BASIC interpreter. Once the code has been put into place and activated, the loader isn't anymore needed and can be removed from memory. The machine program itself is wedged into those routines of the interpreter, which normally perform line input and tokenization (i.e. transforming commands like PRINT, INPUT, etc. into single-byte tokens). From this tokenized line, a checksum is calculated and displayed on screen.

This is very much similar to what was called TSR (terminate-and-stay-resident) programs in DOS times. Other programs, like BASIC extensions or floppy/tape speeders, perform in a similar way: they're loaded and run, 'disappear' (but allocate some memory for themselves) and re-route routines in the BASIC interpreter or KERNAL, so they get executed alongside client programs.

It should be noted though, that even though those checksummers don't interfere with program input (other than there's slightly less space available than without checksum program in action), they should definitely be de-activated before the typed-in program is run. The running program is not necessarily written to run together with the checksummer *): it might require all available memory, may not be content with the memory restricted by the checksummer, and it is also possible that the typed-in program POKEs into the address range occupied by the checksummer (for example, user defined graphics or own machine code) and causes a crash. Best thing would be to save the program on tape or disk, do a power cycle or reset, and then load it again and run it.
orion70 wrote:(be aware that spaces and command abbreviations change the checksum!).
That would actually be a bad checksum algorithm at work. It should be able to cope with abbreviations and extra or missing spaces outside strings, because that usually doesn't change the semantics.

Greetings,

Michael


*): The case would be different for the client program of a BASIC extension. That surely would have been written with the extension in mind. Floppy and tape speeders usually use address ranges outside the 'normal' ranges for most other programs, but one can't guarantee there aren't collisions. For this reason, those utility programs often provide versions residing in different memory ranges.

Re: Sv: Paper Soft type-ins (comments) (ITA/ENG)

Posted: Wed Oct 29, 2014 10:17 am
by joshuadenmark
saver71 wrote:
joshuadenmark wrote:GO Saver71!
Det er godt! Jeg er glad for at hjælpe igen. :mrgreen:

(Jeg boede i København i mere end et år)
Nå ja det er sandt, det er jo internationalt forum :wink:

Jeg værdsætter din indsats, til glæde for os alle her på Denial.

Mit italienske er desværre ikke på højde med dit flotte dansk.

Stort tak skal lyde her fra :D

Re: Paper Soft type-ins (comments) (ITA/ENG)

Posted: Wed Oct 29, 2014 10:26 am
by highinfidelity
Thank you very much for the tech details! I supposed it had to be something like that, although I don't have knowledge enough to understand exactly how it is done...

Re: Paper Soft type-ins (comments) (ITA/ENG)

Posted: Thu Oct 30, 2014 5:04 am
by Mike
highinfidelity wrote:Thank you very much for the tech details! I supposed it had to be something like that, although I don't have knowledge enough to understand exactly how it is done...
That knowledge could be gained by taking some of the available utilities/toolkits as examples and dissecting them in a disassembler, with a ROM listing put aside for cross-reference. And asking detailed questions here in Denial. And actually following up on these discussions, when they're opened.

However, the very concept of a 'third-party' tool running alongside an own program seems to be alien to most fellows here in Denial. Otherwise, there surely would be more uses for wimoos' WimBASIC, Robert's Software Sprite Stack, Kananga's RAM-Disk, and (shameless plug) my MINIGRAFIK suite, etc. ...

Re: Paper Soft type-ins (comments) (ITA/ENG)

Posted: Thu Oct 30, 2014 2:01 pm
by orion70
Mike, I'm sure Highinfidelity really appreciated your intervention as a satisfying explanation of Stop Bug's behaviour - no need to start from this appreciation and blame him for not having done his homework :)

...even if, I agree with you it's a pity those tools aren't used more.

Re: Paper Soft type-ins (comments) (ITA/ENG)

Posted: Thu Oct 30, 2014 3:34 pm
by Mike
No worries. I did not intend to cast blame on highinfidelity - rather I understood his remark, "I don't have knowledge enough to understand exactly how it is done", literally as question about how these tools are supposed to work.

Now in all those years I could not find any good documentation how to write an extension for CBM BASIC. All my knowledge merely came from taking a look at other's code examples, taking a look at the inner workings of the BASIC interpreter and making good guesses how to interface my own code to the interpreter. There is no convention how, for example, the code replacing the $0308 character dispatch routine has to look like; no mention what registers and flags are important. That all needs to be derived from the actions taken by the original routines, carefully modifying them to include the new capabilities.

For example, MINIGRAFIK still doesn't handle the IF .. THEN shortcut of the interpreter: after a THEN, the next command is not called over $0308, rather the interpreter makes a direct, unvectored jump. This is done because THEN also accepts a line number, which is then jumped to if the IF .. THEN clause is true. As MG doesn't honour this shortcut, all MG commands need a colon (':') prefaced directly after THEN, otherwise you get a ?SYNTAX ERROR. At the time I wrote MG, I simply didn't know how to fix that.

That situation was different two years later, when I wrote MAXIGRAFIK. Not only did I include a true tokenizer and lister - a first time for me, even if I blatantly ripped it from the code in Super Expander - but I also got the IF .. THEN shortcut right: commands of MAXIGRAFIK can be placed directly after THEN. That required a redesigned replacement of the character dispatch routine, which now also included a full copy of the IF command to remain in control and do that shortcut by own code.

I still didn't include the shortcut fix into MINIGRAFIK, because that fix requires quite some extra code, and I wanted MINIGRAFIK to remain compact. That odd colon inserted between THEN and @ doesn't do much harm. But it would have looked inelegant with a BASIC extension employing a full tokenizer and lister. ;)

Sorry for derailing the thread.

That being said, if there is some interest to put a BASIC extension into existence, with a few commands or functions felt missing in V2 by some people, I could start a thread in the Programming section explaining how it can be done from scratch.

Re: Paper Soft type-ins (comments) (ITA/ENG)

Posted: Tue Nov 04, 2014 9:31 am
by orion70
Thanks to our friend Saver71, we finally completed another issue of Papersoft, #24 of the second year. You can find two new programs here. GRAZIE :)
Temporarily, I uploaded them in my personal repository, as I cannot enter the proper site anymore, nor I am able to contact Nbla000. Hope he will show up here again.

Re: Paper Soft type-ins (comments) (ITA/ENG)

Posted: Mon Dec 01, 2014 9:11 am
by nbla000
Hi everybody!
Orion70 contacted me to inform about new Papersoft programs !!!

I'm very busy with family and work but I will update the papersoft re-type project pages with these new works !

Thank you for your collaboration, I'm happy to inform you that, I've found the last missing issues of papersoft, I'm waiting for a scanning then I will publish them via ready64.it then we may re-type the last issues.