Updated BASIC Editor

bbc/electron apps, languages, utils, educational progs, demos + more
User avatar
daveejhitchins
Posts: 6842
Joined: Wed Jun 13, 2012 6:23 pm
Location: Newton Aycliffe, County Durham
Contact:

Re: Updated BASIC Editor

Post by daveejhitchins »

Coeus wrote:
Fri Oct 22, 2021 2:43 pm
tom_seddon wrote:
Fri Sep 21, 2018 7:27 pm
I was completely wrong about this, and it actually looks like it's a bit complicated :( - the ROMs do in fact communicate, there's a bunch of new code to handle it, and all the editor error messages appear to have moved into the utils half to make space for the extra stuff. So I'm not going to do this in the end, as I don't use the PRES utils myself.
I obviously missed this when reading the thread. It's a pity it's that complicated. What I was hoping we might find is that the editor was self contained in the lower ROM of the PRES pair, and thus able to be stand-alone, and that there was a mechanism by which this lower ROM would offer commands to the upper ROM (if present) if they weren't built in, i.e. if they weren't implemented in the lower ROM.

I am certainly intrigued, now.
IIRC we licenced two ROM images - that of the BASIC Editor and the separate Utils ROM. We then outsourced the work of putting it together into one PLD ROM - also making changes to support the Electron, our main aim. I can send you what I've found so far?

Again IIRC Altra "claimed" that they wrote both ROMs and they included that in the agreement/Licence. We were given the source for both!

The licence specified that it could only be sold for the Electron. However, later on we were verbally given the OK for all machines as people were just buying anyway!

Dave H.
Coeus
Posts: 2411
Joined: Mon Jul 25, 2016 12:05 pm
Contact:

Re: Updated BASIC Editor

Post by Coeus »

daveejhitchins wrote:
Fri Oct 22, 2021 5:14 pm
The licence specified that it could only be sold for the Electron. However, later on we were verbally given the OK for all machines as people were just buying anyway!
That makes perfect sense. If Acornsoft were, quite legitimately, selling a very similar editor, based on the same code but without the utilities, for the BBC Micro then they would not want their sales affected by an improved version from which they did not take a cut. Until their sales dropped off anyway as people discovered the Electron version worked on the BBC micro too. So that suggests there was a formal licensing arrangement between Acornsoft and Altra.
daveejhitchins wrote:
Fri Oct 22, 2021 7:15 am
Any code that JGH has is 'exactly' the same code that P.R.E.S./ACP sold on behalf of Baildon Electronics....
Was the PLD just for the Electron version, then? The version on mdfs.net has the bank switching code using the standard ROMSEL between a pair of adjacent ROMs and the service routine in the upper ROM is just an 'RTS', delegating all service operations to the lower ROM which is not what he described previously as an explanation as to why the lower ROM seemed to be able to work stand-aline while the upper one crashed after trying to switch to the lower one so possibly he was talking about the ELectron ROM images.

The interface between the two ROMs seem more complicated than it needs to be. JGH found the code that runs from &A00 but when I looked at the execution of the 'utils' command. before it gets as far as executing the bank switching code it:
  • Tweaked the horizontal timing on the CRTC.
  • Inserted *BUTIL into the keyboard buffer with the relevant OSBYTE.
  • Started BASIC.
BASIC passed *BUTIL to OSCLI and it was then recognised by the service code in the lower ROM, initiating the bank switch.
daveejhitchins wrote:
Fri Oct 22, 2021 5:14 pm
I can send you what I've found so far?
Do you have anything you have not posted? I have downloaded the previous ZIP, which does not contain the code for the lower ROM and I could not even find what the subdirectory for the 2nd SSD of source files was supposed to be. !MAKEROM (once renamed) worked fine without any of those files.
User avatar
daveejhitchins
Posts: 6842
Joined: Wed Jun 13, 2012 6:23 pm
Location: Newton Aycliffe, County Durham
Contact:

Re: Updated BASIC Editor

Post by daveejhitchins »

That makes perfect sense. If Acornsoft were, quite legitimately, selling a very similar editor, based on the same code but without the utilities, for the BBC Micro then they would not want their sales affected by an improved version from which they did not take a cut. Until their sales dropped off anyway as people discovered the Electron version worked on the BBC micro too. So that suggests there was a formal licensing arrangement between Acornsoft and Altra.
I'm still not sure where Acorn figures in all this? No conversations or documents , from Altra, ever mentioned Acorn! I would have thought that if Acorn were involved there would have been a legal requirement to mention it?

Was the PLD just for the Electron version, then? The version on mdfs.net has the bank switching code using the standard ROMSEL between a pair of adjacent ROMs and the service routine in the upper ROM is just an 'RTS', delegating all service operations to the lower ROM which is not what he described previously as an explanation as to why the lower ROM seemed to be able to work stand-aline while the upper one crashed after trying to switch to the lower one so possibly he was talking about the ELectron ROM images.
The PLD version worked(s) on all machines - there was also a cartridge version that had IIRC (again!) a spare ROM socket for the user. This is the thread where JGH found the switching code. There was/is only one ROM pair. Currently I have the Master and Electron new PLD ROM working. Just swap the unit between machines. There is a minor hardware option as there is a change needed if you want to use a second "User' ROM e.g. in a Master or and Electron, with an AP6, using a socket that has pin 1 connected to A14. This is working fine on the Master, however, I have a puzzle with the Electron/AP6 version that I working on. The ABE ROM code is identical, though!

The interface between the two ROMs seem more complicated than it needs to be. JGH found the code that runs from &A00 but when I looked at the execution of the 'utils' command. before it gets as far as executing the bank switching code it:
  • Tweaked the horizontal timing on the CRTC.
  • Inserted *BUTIL into the keyboard buffer with the relevant OSBYTE.
  • Started BASIC.

BASIC passed *BUTIL to OSCLI and it was then recognised by the service code in the lower ROM, initiating the bank switch.

I've not looked at any of the code, so can't comment here. There is a comment, from the outsourcing programmer (Chris Gibson) to the effect that it was way too easy to defeat the switching code and would do something to obfuscate it a little better - so this is possibly what you are seeing?

This is what I think is the last correspondence from Chris:
Hello Dave!


Here is the (hopefully) final version of the Basic Editor Plus. The files on
this disk called ROMIMAGE1 and ROMIMAGE2 are identical copies of the full
32K image for blowing.


The changes since the last version I sent you are as follows :

1) The OSWORD call to interface with AFM has been incorporated. I've allowed
two options from AFM, Load and Append.

This is one that I haven't tested but would find useful!

2) As part of doing 1), Alan Glover remarked to me that he would find it
useful if I removed a 'purge keyboard buffer' call that the Editor
makes before issuing a user-entered * command from our command screen.
Amongst other things, this now makes it possible to assign a string like

*BE|MM 3|M

to a function key, and for it to work properly from within the Editor as
well as from BASIC.

3) Our hardware-switching code which we download to &A00 now restores the
previous contents after it's done its stuff, and no longer interferes
with anything else.

4) As requested, *BMENU has been changed to *BUTIL. The minimum abbreviation
for this is now *BUT. (as *BU. is interpreted by the MOS as *BUILD). The
*HELP BE text reflects this change.

5) Having done so much testing to make sure the hardware-switching worked OK,
we nearly forgot the reason why you invented it in the first place! Just out
of curiosity, I loaded the 16K Editor half of the package into sideways RAM
on my Master, and pressed Ctrl-Break to initialise it. *ROMS told me it was
there, and *BE brought it up, with full editing capability!

I've now fixed things so that if people rip off the code from the EPROM and
try running it in 16K halves from sideways RAM as I did, they can still get
the Editor command screen up, and issue all the commands (except UTILS!),
but they won't be able to do any full-screen editing. Pressing Escape, or
issuing commands like TOP, END, FIND, etc., will just be ignored, and they
will remain on the command screen.

In fact, a really persistent hacker could discover five consecutive bytes
that could be replaced by NOP instructions to defeat the protection, but
that part of the program is pretty well buried.

I hope that's it, since I've very nearly run out of bytes on the Editor half
of the package. Good luck with it, and let me know when and to whom you're
sending a review copy.



Merry Christmas!



Chris Gibson
Do you have anything you have not posted? I have downloaded the previous ZIP, which does not contain the code for the lower ROM and I could not even find what the subdirectory for the 2nd SSD of source files was supposed to be. !MAKEROM (once renamed) worked fine without any of those files.
If I do find anything new I will, of course post it in the original thread (link above).

If I sound a little 'blank' on the software details (?) it's due to me not having the software expertise to fully understand it! We were so busy at the time, hence the outsourcing . . .

I've attached what I think is all I have found so far. I've also attached an .hfe file which I'm struggling to open! The HxC Floppy Emulator won't open it (?) but Clock Signal will - but doesn't manage a save! Included are a few other Altra related files . . . There maybe some duplication!

This is the start of a wish list:
ABE Editor: (if anything else can be fitted?)
(1) Ability to enter ABE with Parameters (a) to determine which screen mode to use - If not used default would be 6 or 7, as current. (b) TBA
(2) To use Name of file, for saving, if it entered on first line of BASIC (I believe there’s a ‘standard’ for this <#name>??
(3) When editing – it would be a good feature if you could follow a jump or procedure – possibly by holding down a key combination – and returning, in the case of a procedure.
(4) Key mapping could be improved for the Electron.
(5) Remember current line number (even after renumber??) and any procedural jumps, after visiting UTILS.
(6) Would be really useful if it worked with the TUBE

ABE Utilities: (if anything else can be fitted?)
(1) Remember screen mode used in the editor - currently it returns to the editor in default screen mode - as a language it should be able to use a common workspace?
(2) Remember the File Name used in the editor - currently doesn’t. When in the editor you can use the UPDATE command, it remembering the file name used when loading the file. If you go the the Utilities and then return to the editor, this information is lost along with (1) screen mode.
(3) Pack to have an option to remove extra colons ’:’
(4) Pack to have option to remove blank lines
(5) Highlighting of search parameter, during the search, doesn’t work in BeebEM – Needs further investigation!
(6) When searching add ability to distinguish between: e.g. ENTRIES% and NENTRIES%
(7) Maybe a ‘feature’ (?) Using Pack, in the UTILS, I've had 'LANGUAGES' and 'UTILITIES' treated as variables e.g. they were shortened! Even though they were in a DATA statement. Changing to 'Utilities' worked!
(8) Doesn’t seem to work if Page is ‘not standard’ – more info required to better explain this.
(9) Ability to cut-and-past.
(10) Add some features from JGH’s Basutils on mdfs.net – to be further described.
Dave H.

ABE.zip
(475.96 KiB) Downloaded 18 times
Coeus
Posts: 2411
Joined: Mon Jul 25, 2016 12:05 pm
Contact:

Re: Updated BASIC Editor

Post by Coeus »

Dave,

I have download the newer ABE.zip from your post. In a very quick look I found that:
  • The ElkBE-sourceFiles-59.adf file does not contain anything useful. The file extension suggests it should be an image of an ADFS disc but all it actually contains is many blocks of 00 (hex) followed by a few blocks of the letter Z (5A hex) so no sign of a filesystem structure and nothing useful can be extracted from it.
  • I had not more luck with the HFE support in B-Em reading Altera BE Commands Text_adl.hfe than you did with whatever you used. I may look into using Beebjit as I believe it has very good HFE support but that means working out how to get ADFS running under Beebjit as I assume it is an ADFS disc by the adl in the filename.
I still need to go through the other files in more detail.
daveejhitchins wrote:
Sat Oct 23, 2021 10:32 am
I'm still not sure where Acorn figures in all this? No conversations or documents , from Altra, ever mentioned Acorn! I would have thought that if Acorn were involved there would have been a legal requirement to mention it?
The relevance of Acorn here is that the first ROM of the pair in both the P.R.E.S. and BE products has much in common with a BASIC editor that Acorn were marketing and which Tom has already disassembled and has been enhancing. Here is a part of the front cover of the manual that came with the Acorn version, which clearly has Acornsoft branding:
be1.png
I posted further up the thread that I had downloaded a pair of ROM images from mdfs.net, which you believed to be the P.R.E.S version, and when I traced the language entry of the lower (editor) ROM of that pair it looked remarkably similar to the code in Tom's GitHub, which originated from disassembling the Acorn version. However the files on mdfs.net cannot be the version from any PLD ROM as they work quite satisfactorily, including going into the utilities menu which involves swapping ROMs, running in sideways RAM as the code to swap between the ROM uses normal ROMSEL rather than writing to the end of the paged ROM areas as you were previously discussing with respect to the PLD.

So I looked back over the P.R.E.S. thread and downloaded the file BE 90 BASIC EDITOR AND TOOLKIT 1VO -256.BIN.zip. That is a single file for loading into a 27256 but looking at the start of the higher ROM i.e. 4000 (hex) bytes in, we have this:

Code: Select all

00004000 - 4C 36 B9 4C 7D B9 C2 24 01 42 41 53 49 43 20 45 L6.L}..$.BASIC E
00004010 - 64 69 74 6F 72 20 26 20 54 6F 6F 6C 6B 69 74 20 ditor & Toolkit 
00004020 - 56 31 2E 30 00 28 43 29 31 39 39 30 20 42 2E 45 V1.0.(C)1990 B.E
00004030 - 2E 00 48 8A 48 98 48 BA BD 03 01 C9 04 F0 14 C9 ..H.H.H.........
compare with the same block from the higher ROM of the files from mdfs.net:

Code: Select all

00000000 - 4C 36 B9 60 7D B9 C2 24 01 42 41 53 49 43 20 45 L6.`}..$.BASIC E
00000010 - 64 69 74 6F 72 20 26 20 54 6F 6F 6C 6B 69 74 20 ditor & Toolkit 
00000020 - 31 2E 30 30 00 28 43 29 31 39 39 30 20 42 2E 45 1.00.(C)1990 B.E
00000030 - 2E 00 48 8A 48 98 48 BA BD 03 01 C9 04 F0 14 C9 ..H.H.H.........
and the only difference is that someone has patched in a &60 (RTS) instruction for the service routine. Even the address that would have been jumped to still remains so, to me, that means the JGH (mdfs.net) versions have been patched to run without the PLD and elsewhere that will have included patching the actual ROM switch. The copyright message also says B.E. not P.R.E.S. in both.

If I make that same change myself to the upper ROM in BE 90 BASIC EDITOR AND TOOLKIT 1VO -256.BIN and then trace the language entry I get:

Code: Select all

8000: 4C 52 8E    JMP 8E52    >s
8E52: C9 01       CMP #01     >s
8E54: F0 01       BEQ 8E57    >s
8E57: 20 0A 8F    JSR 8F0A    >n
8E5A: 20 51 A8    JSR A851    >n
8E5D: 20 CE AD    JSR ADCE    >n
8E60: 20 C1 9D    JSR 9DC1    >n
8E63: A2 05       LDX #05     >s
8E65: 86 61       STX 61      >s
8E67: A2 00       LDX #00     >s
8E69: A9 D2       LDA #D2     >s
8E6B: 20 DF AF    JSR AFDF    >n
8E6E: A2 60       LDX #60     >s
8E70: 86 31       STX 31      >s
8E72: A2 00       LDX #00     >s
8E74: 86 3C       STX 3C      >s
8E76: 86 62       STX 62      >s
8E78: E8          INX         >s
8E79: 86 3D       STX 3D      >s
8E7B: A9 E4       LDA #E4     >s
8E7D: 20 DF AF    JSR AFDF    >n
8E80: 20 C9 AF    JSR AFC9    >n
8E83: A9 87       LDA #87     >s
8E85: 20 F4 FF    JSR FFF4    >n
i.e. exactly the same as in my previous post about the similarity to the version in Tom's GitHub.

So this has turned out to be a bit long-winded but it seems plain to me that Acornsoft's "The Basic Editor" and the editor ROM in the P.R.E.S and B.E. Advanced Basic Editors were substantially the same and certainly had a common ancestor.

That means there has to have been some licensing from a common originator or some outright plagiarism going on.

But, importantly to the discussion of future enhancements, it brings into question whether it is worth attempting to make improvements to the version of this ROM in the B.E. product independent of the work Tom has been doing based on the Acornsoft version as Tom already has a disassembly. Tom's version could almost certainly work with a companion ROM containing the utilities and producing versions that use normal sideways ROM/RAM switching vs. using the PLD to switch between two halves of a larger ROM is a very small amount of work.

On preventing an image from the PLD ROM being useful in sideways RAM, the message you quoted seems to related to just using the editor part rather than the ROM switching but in the light of "obsfuscation", perhaps the meddling with the CRTC is to try to get the TV/monitor to lose sync for a frame or too to prevent an eagle eyed user from seeing what was being entered into the keyboard buffer.
Coeus
Posts: 2411
Joined: Mon Jul 25, 2016 12:05 pm
Contact:

Re: Updated BASIC Editor

Post by Coeus »

For comparison, here are the help screens of three versions of the editor. First the Acornsoft one, vs. 1.32, the last published:
as132_help.png
Then the Basildon Electronics version:
be_help.png
so this gained two more commands, utils and update.

and finally, Tom's updated one (based on the Acorn):
tom_136.png
(ignore the file name it is 1.45).

So this gained ichange, ifind, qichange, zsave, zrun compared to the Acorn version.
User avatar
hoglet
Posts: 10710
Joined: Sat Oct 13, 2012 7:21 pm
Location: Bristol
Contact:

Re: Updated BASIC Editor

Post by hoglet »

The Acornsoft Basic Editor manual (1985) states it was written by Pete Morris and Chris Gibson:
https://raw.githack.com/tom-seddon/basi ... Manual.pdf

The PRES Basic Editor manual (1989) doesn't state the authors, but bears a remarable similarity to the Acornsoft one:
download/file.php?id=15498

Altra Basic Ed (1984) seems to pre-date both of these:
http://www.computinghistory.org.uk/det/ ... 0Basic-Ed/

Dave's source file seem to mention (C) IJW

The Altra Probe ROM is also (C) IJW

The Altra Enigma Disk Image is (C) MDY and IJW, and the manual includes:
M. Yell and I. Wilson 1984
Altra Roms
209 North Street,
Leeds 7. ©.
So it looks like the original work was done by Altra, and that Acornsoft either just OEMed/rebranded this legally, or copied it illegally (which I doubt) or wrote their version from scratch.

All very strange....

Dave

Edit: Oh, and there is also Altra Editor (1985, Andrew Lord):
http://www.computinghistory.org.uk/det/ ... %20Editor/

Edit 2: The README files in Dave's archive come from Chris Gibson
User avatar
daveejhitchins
Posts: 6842
Joined: Wed Jun 13, 2012 6:23 pm
Location: Newton Aycliffe, County Durham
Contact:

Re: Updated BASIC Editor

Post by daveejhitchins »

Thanks for that (^^^), Dave . . . You beat me to it - I was putting together something similar. I haven't found any magazine articles for Altra, though - yet! If anyone has seen any it would be good to see when they first started advertising the BASIC-ED

Anyway, I'd just love to see an updated version of both the BASIC Editor and the BASIC Utilities - however, it's accomplished. I use it for all my software writing and feel improvements would be beneficial. I've not tried Tom's version - so I'll correct that today.

On the availability of the ABE PLD ROM - It's now all working. PCBs are arriving by the 26-10 - so I'll try and get the User guide sorted by then. But any users will be able to download the .pdf version! I'll start a new thread for this.

Dave H.
User avatar
hoglet
Posts: 10710
Joined: Sat Oct 13, 2012 7:21 pm
Location: Bristol
Contact:

Re: Updated BASIC Editor

Post by hoglet »

daveejhitchins wrote:
Sun Oct 24, 2021 9:59 am
Thanks for that (^^^), Dave . . . You beat me to it - I was putting together something similar. I haven't found any magazine articles for Altra, though - yet! If anyone has seen any it would be good to see when they first started advertising the BASIC-ED
Dave, I'm interested in your recollections of Chris Gibson, and exactly what he did. I found it interesting that he was listed by Acornsoft as one of the main authors, but also (independently I think) was used by you as a contract programmer four years later. Do I have that right?

Dave
User avatar
daveejhitchins
Posts: 6842
Joined: Wed Jun 13, 2012 6:23 pm
Location: Newton Aycliffe, County Durham
Contact:

Re: Updated BASIC Editor

Post by daveejhitchins »

hoglet wrote:
Sun Oct 24, 2021 10:05 am
daveejhitchins wrote:
Sun Oct 24, 2021 9:59 am
Thanks for that (^^^), Dave . . . You beat me to it - I was putting together something similar. I haven't found any magazine articles for Altra, though - yet! If anyone has seen any it would be good to see when they first started advertising the BASIC-ED
Dave, I'm interested in your recollections of Chris Gibson, and exactly what he did. I found it interesting that he was listed by Acornsoft as one of the main authors, but also (independently I think) was used by you as a contract programmer four years later. Do I have that right?

Dave
I don't remember how we came into contact with Chris. Most probably, through Rob Northern (?) but it could have been, less likely, Alan glover.

Chris took the source code, we'd been given by Altra, and a list of requirements we were looking for - disappeared for a while and then came up with something for us to test. As I mentioned ^^^ were were super busy at the time so he was a Godsend! Testing didn't reveal many issues and I think there were only a few iterations.

The one thing I regret is the way we agreed to pay for the work. Not having a great deal of liquid cash we settled on a royalty. And, regrettably, the sales weren't that great - Probably due to it being late in the life of the Acorn 8 bit series. It's one of those things that prays on your mind!!

I can't remember if we knew he had co-written the Acorn User Guide. We only ever met on the 'phone.

Dave H.
Coeus
Posts: 2411
Joined: Mon Jul 25, 2016 12:05 pm
Contact:

Re: Updated BASIC Editor

Post by Coeus »

hoglet wrote:
Sat Oct 23, 2021 8:47 pm
So it looks like the original work was done by Altra, and that Acornsoft either just OEMed/rebranded this legally, or copied it illegally (which I doubt) or wrote their version from scratch.
I think we can rule out having written it from scratch because the code in the two versions is too similar for that to be the case. It would also not be the first time the Acornsoft languages team went outside of Acorn for a product: some of the language implementations come from people who were active in the language concerned. One example is John Richards (RCP) for BCPL who was the brother of Martin Richards, the BCPL inventor and who (John) specialised in microprocessor implementations of BCPL having done a CP/M version too. Then there was Richard de Grandis Harrison who wrote the Acornsoft FORTH implementation and was chairman of a UK FORTH special interest group.

On the Altra Basic Ed which may be the common ancestor, it is a pity we don't have a ROM image as I very much suspect this will look quite similar to the ones we have already seen. I had never heard of it so maybe it was the classic case that some companies are well able to come up with a good product but lack the skill, or maybe the budget, to market it sucessfully.
daveejhitchins wrote:
Sun Oct 24, 2021 10:53 am
The one thing I regret is the way we agreed to pay for the work. Not having a great deal of liquid cash we settled on a royalty. And, regrettably, the sales weren't that great - Probably due to it being late in the life of the Acorn 8 bit series. It's one of those things that prays on your mind!!
I assume you mean you regret how you agreed to be paid, i.e. you signed a royalty deal with the people who would have been marketing the product?

Also interesting to hear of work being done with only the telephone and correspondence and no actual meetings.

Thinking back to my comments on using Tom's version for the lower ROM to make up a working pair, there are some things I may have overlooked. One is that I believe you looking for a version that works on the Electron, for which there are presumably some specific changes: these can be found by disassembling the BE version of the ROM. The other is that the compromises may be different for a one ROM vs. two ROM version. Tom specifically wanted a one ROM version and therefore has chosen to remove text in order to make room for code resulting in a version that does not look as neat but has more features. With the luxury of two ROMs it may be possible to have both.

I have started to look at the BE version but I don't think I have, so far, found anything that isn't already known from Tom's work.
User avatar
SKS1
Posts: 47
Joined: Sat Sep 19, 2020 12:04 am
Location: Highland Perthshire
Contact:

Re: Updated BASIC Editor

Post by SKS1 »

Coeus wrote:
Sun Oct 24, 2021 4:15 pm
hoglet wrote:
Sat Oct 23, 2021 8:47 pm
So it looks like the original work was done by Altra, and that Acornsoft either just OEMed/rebranded this legally, or copied it illegally (which I doubt) or wrote their version from scratch.
I think we can rule out having written it from scratch because the code in the two versions is too similar for that to be the case. It would also not be the first time the Acornsoft languages team went outside of Acorn for a product: some of the language implementations come from people who were active in the language concerned. One example is John Richards (RCP) for BCPL who was the brother of Martin Richards, the BCPL inventor and who (John) specialised in microprocessor implementations of BCPL having done a CP/M version too. Then there was Richard de Grandis Harrison who wrote the Acornsoft FORTH implementation and was chairman of a UK FORTH special interest group.
As I recall Acornsoft didn't go looking for one, but that Pete and Chris just contacted us (in late 1984?), offered to demonstrate and we were really taken with the BASIC Editor.
Miserable old curmudgeon who still likes a bit of an ARM wrestle now and then. ARMX6, SA Risc PC, A540
tom_seddon
Posts: 495
Joined: Tue Aug 30, 2005 12:42 am
Contact:

Re: Updated BASIC Editor

Post by tom_seddon »

Coeus wrote:
Sat Oct 23, 2021 7:04 pm
and finally, Tom's updated one (based on the Acorn):
So this gained ichange, ifind, qichange, zsave, zrun compared to the Acorn version.
There's a full list of the other changes here: https://github.com/tom-seddon/basic_edi ... ocs/doc.md

A couple of the keys changed, and there are some new * commands too. Not mentioned there is that there's some minor optimizations that make the editing experience a bit nippier - from memory, it was originally using some overly-generic routines for clearing buffers and the like, and I replaced them with little inline loops.
Coeus wrote:
Sun Oct 24, 2021 4:15 pm
Thinking back to my comments on using Tom's version for the lower ROM to make up a working pair, there are some things I may have overlooked. One is that I believe you looking for a version that works on the Electron, for which there are presumably some specific changes: these can be found by disassembling the BE version of the ROM. The other is that the compromises may be different for a one ROM vs. two ROM version. Tom specifically wanted a one ROM version and therefore has chosen to remove text in order to make room for code resulting in a version that does not look as neat but has more features. With the luxury of two ROMs it may be possible to have both.
My updated BASIC editor has an Electron version, thanks to Mince. I don't know how similar (or not) it might be to the PRES version... I don't have an Electron.

Regarding the scruffier-looking help and lack of command prompt HUD in my version, this is indeed partly due to space being a bit tight. I suspect it could actually all be made to fit, just, but space was looking rather tight at some point so I did a general code size pass. I think this was when the fancy help went away, and I vaguely recall making the HUD text a bit shorter as well.

The other reason is that I couldn't figure out how to detect shadow RAM status, which is something the editor needs to know about if it's going to change modes itself. So what I did was just make the editor never change mode... mostly fine, but text window software scrolling isn't very nice in the 20K modes. So the HUD got canned, meaning it can use full-screen hardware scrolling. All I ever really cared about myself was how much RAM was free, so I added that to the prompt. (And, as a bonus, I think this also freed up a bit more space.)

(I have an open issue related to the mode change thing: https://github.com/tom-seddon/basic_editor/issues/19 - as I've ended up finding it a bit annoying that the editor doesn't change out of mode 2/5. The bug description describes my current plan. I'm not averse to the idea of reinstating a mode 7/135 command prompt with HUD, but my guess is that it would eat up a lot of the 200-odd bytes that are currently available. But it's also possible that a further code size pass would reveal some dead weight...)

--Tom
Coeus
Posts: 2411
Joined: Mon Jul 25, 2016 12:05 pm
Contact:

Re: Updated BASIC Editor

Post by Coeus »

tom_seddon wrote:
Sun Oct 24, 2021 8:46 pm
Regarding the scruffier-looking help and lack of command prompt HUD in my version, this is indeed partly due to space being a bit tight. I suspect it could actually all be made to fit, just, but space was looking rather tight at some point so I did a general code size pass. I think this was when the fancy help went away, and I vaguely recall making the HUD text a bit shorter as well.
With the help text, I did wonder if some very simple compression would help and was thinking, for example, of having a code that stood for two spaces, i.e. something very simple indeed as it needs to save more bytes than it costs to implement. That could also be used for formatting in a HUD screen, if desired.
tom_seddon wrote:
Sun Oct 24, 2021 8:46 pm
The other reason is that I couldn't figure out how to detect shadow RAM status, which is something the editor needs to know about if it's going to change modes itself. So what I did was just make the editor never change mode... mostly fine, but text window software scrolling isn't very nice in the 20K modes. So the HUD got canned, meaning it can use full-screen hardware scrolling. All I ever really cared about myself was how much RAM was free, so I added that to the prompt. (And, as a bonus, I think this also freed up a bit more space.)
I think the OSBYTE to ask what HIMEM will be in any given mode is all you need. If I do:

Code: Select all

*SHADOW 1
MODE 3
*BE
on a Master, the HUD screen shows 12286 bytes free. If I do:

Code: Select all

*SHADOW 0
MODE 3
*BE
the HUD shows 28670 bytes free. This is in the Acornsoft 1.32 version which is, AFAIK naive about the Master so I think that mean the OSBYTE that asks the OS what HIMEM would be in a given mode takes into account whether shadow screen memory would be used for the mode concerned. I'll run a definite test and post back.
tom_seddon
Posts: 495
Joined: Tue Aug 30, 2005 12:42 am
Contact:

Re: Updated BASIC Editor

Post by tom_seddon »

Coeus wrote:
Sun Oct 24, 2021 9:04 pm
I think the OSBYTE to ask what HIMEM will be in any given mode is all you need. If I do:

Code: Select all

*SHADOW 1
MODE 3
*BE
on a Master, the HUD screen shows 12286 bytes free. If I do:

Code: Select all

*SHADOW 0
MODE 3
*BE
the HUD shows 28670 bytes free. This is in the Acornsoft 1.32 version which is, AFAIK naive about the Master so I think that mean the OSBYTE that asks the OS what HIMEM would be in a given mode takes into account whether shadow screen memory would be used for the mode concerned. I'll run a definite test and post back.
I don't use *SHADOW personally - I leave it at the default setting, and select mode 128+ if I want shadow memory. From memory, the original basic editor would get it wrong in that case, because querying the current mode only gives you a value from 0 to 7.

--Tom
Coeus
Posts: 2411
Joined: Mon Jul 25, 2016 12:05 pm
Contact:

Re: Updated BASIC Editor

Post by Coeus »

As promised, test program:

Code: Select all

   10*SHADOW 1
   20PROChimem("Off", 3)
   30PROChimem("Off", 131)
   40*SHADOW 0
   50PROChimem("On", 3)
   60PROChimem("On", 131)
   70END
   80DEFPROChimem(O$,M%)
   90A%=&85
  100X%=M%
  110R%=USR&FFF4
  120H%=(R%DIV256)AND&FFFF
  130PRINT"HIMEM for mode ";M%;", SHADOW ";O$;" is ";~H%
  140ENDPROC
result:
ss.png
Coeus
Posts: 2411
Joined: Mon Jul 25, 2016 12:05 pm
Contact:

Re: Updated BASIC Editor

Post by Coeus »

tom_seddon wrote:
Sun Oct 24, 2021 9:17 pm
I don't use *SHADOW personally - I leave it at the default setting, and select mode 128+ if I want shadow memory. From memory, the original basic editor would get it wrong in that case, because querying the current mode only gives you a value from 0 to 7.
I usually do the same, but was forced to try *SHADOW when working with the original editor because it won't allow mode numbers outside the range 0-7. On querying the current mode, here is a modified test program and results:

Code: Select all

   10*SHADOW 1
   20MODE3
   30PROChimem("Off", 3)
   40MODE131
   50PROChimem("Off", 131)
   60*SHADOW 0
   70PROChimem("On", 3)
   80MODE3
   90PROChimem("On", 131)
  100MODE131
  110END
  120DEFPROChimem(O$,M%)
  130A%=&84
  140X%=M%
  150R%=USR&FFF4
  160H%=(R%DIV256)AND&FFFF
  170PRINT"HIMEM for mode ";M%;", SHADOW ";O$;" is ";~H%
  180G%=GET
  190ENDPROC
This gives exactly the same results as the previous version.
Coeus
Posts: 2411
Joined: Mon Jul 25, 2016 12:05 pm
Contact:

Re: Updated BASIC Editor

Post by Coeus »

Coeus wrote:
Sat Oct 23, 2021 5:46 pm
[*]I had no more luck with the HFE support in B-Em reading Altera BE Commands Text_adl.hfe than you did with whatever you used. I may look into using Beebjit as I believe it has very good HFE support but that means working out how to get ADFS running under Beebjit as I assume it is an ADFS disc by the adl in the filename.
Beebjit was a success in getting the data out of the Altera BE Commands Text_adl.hfe.adl file but I am not sure it contains anything new. I have attached a ZIP of the .adl file. This is the contents:
cat.png
Attachments
Altera BE Commands Text_adl.zip
(27.39 KiB) Downloaded 9 times
User avatar
daveejhitchins
Posts: 6842
Joined: Wed Jun 13, 2012 6:23 pm
Location: Newton Aycliffe, County Durham
Contact:

Re: Updated BASIC Editor

Post by daveejhitchins »

Coeus wrote:
Sun Oct 24, 2021 4:15 pm
daveejhitchins wrote:
Sun Oct 24, 2021 10:53 am
The one thing I regret is the way we agreed to pay for the work. Not having a great deal of liquid cash we settled on a royalty. And, regrettably, the sales weren't that great - Probably due to it being late in the life of the Acorn 8 bit series. It's one of those things that prays on your mind!!
I assume you mean you regret how you agreed to be paid, i.e. you signed a royalty deal with the people who would have been marketing the product?
No, I wish, retrospectively, I could have paid Chris more! We purchased the licence for the software with a one-off payment but paid Chris a royalty and, of course, we sold to John Huddlestone at trade price - as and when he required them.

I had a brief look through the two Altra User Guides I have: BASIC-ED and PROBE 6.
IMG_1509.jpg
IMG_1510.jpg

I've had them the wrong way round! The BASIC-ED is, in fact, the Utilities book and the Probe 6 is the BASIC Editor - but that ROM covers more (see the front cover) and, I believe, it came with a disc.

Now, this is interesting: When comparing the HELP for the ABE ROM against the PROBE 6 ROM (as shown in the User Guide) then a further ROM must have been produced - just for Acorn (?) with all the non-BASIC elements removed and, perhaps, add too? So, we could have had exactly the same source that Acorn had. The mitigation for this would have been: Our Licence was for the Electron ONLY - as the Acorn version doesn't work with the Electron at all (just tried it this morning).
IMG_1512.jpg
IMG_1513.jpg

Dave H.
User avatar
Pernod
Posts: 2789
Joined: Fri Jun 08, 2012 11:01 pm
Location: Croydon, UK
Contact:

Re: Updated BASIC Editor

Post by Pernod »

daveejhitchins wrote:
Mon Oct 25, 2021 11:57 am
I had a brief look through the two Altra User Guides I have: BASIC-ED and PROBE 6.
Neither of those ROMs are archived, closest we have is Probe 4.05.
- Nigel

BBC Model B: ATPL Sidewise, Acorn Speech, 2xWatford Floppy Drives, AMX Mouse, Viglen case, BeebZIF, etc.
User avatar
daveejhitchins
Posts: 6842
Joined: Wed Jun 13, 2012 6:23 pm
Location: Newton Aycliffe, County Durham
Contact:

Re: Updated BASIC Editor

Post by daveejhitchins »

Pernod wrote:
Mon Oct 25, 2021 12:14 pm
daveejhitchins wrote:
Mon Oct 25, 2021 11:57 am
I had a brief look through the two Altra User Guides I have: BASIC-ED and PROBE 6.
Neither of those ROMs are archived, closest we have is Probe 4.05.
No ROMs, unfortunately - but I'm just about to start a "Wanted" post.

Dave H.
User avatar
Pernod
Posts: 2789
Joined: Fri Jun 08, 2012 11:01 pm
Location: Croydon, UK
Contact:

Re: Updated BASIC Editor

Post by Pernod »

Here's the *HELP from Probe 4.05:

Code: Select all

*H.PROBE
Altra PROBE 4.05
  ASMFORM (nn)
  BASED 
  BLIST  <fsp>
  DEDIT  (drv)(sector)
  DISS   <addr>
  ENTER  <fsp><start><len>(Xeq)(Load)
  FKEYS  (key)
  FORMAT <drv><trks>(DV)
  FREE   (drv)(H)
  GDUMP  (NEGRHU)
  MEDIT  (addr)
  MOVE   <page/dest>(srce)(end/+ext)
  NECSET 
  REPAIR <drv><trk>
  ROMID  (page)(addr)/(:drv)
  SPACE 
  TUBE 
  TXCOPY 
  VLIST  (HR%$PF)
  VERIFY (drv)(D)
- Nigel

BBC Model B: ATPL Sidewise, Acorn Speech, 2xWatford Floppy Drives, AMX Mouse, Viglen case, BeebZIF, etc.
Coeus
Posts: 2411
Joined: Mon Jul 25, 2016 12:05 pm
Contact:

Re: Updated BASIC Editor

Post by Coeus »

Pernod wrote:
Mon Oct 25, 2021 1:28 pm
Here's the *HELP from Probe 4.05:
So PROBE 4.05 is the forerunner of the BASIC UTILs in the upper for the two ROMs in the Basildon Electronics version of the Advanced BASIC Editor. The is what appears when typing *BASED:
based.png
daveejhitchins wrote:
Sat Oct 23, 2021 10:32 am
(4) Key mapping could be improved for the Electron.
On this point from your wishlist, this can probably be done to the Basildon Electronics version, without having the source, or at least a disassembly that can be reassembled and cope with things moving around.

Internally, the editor works with a set of action codes to perform all the various editing actions and even commands typed on the command screen are translated into one of these codes before being executed, allowing the same editing action to be initiated from a command or a key.

In editing mode, when running on a BBC micro, any character received from the OS OSRDCH function that is not a printable ASCII character is treated as a possible action code and looked up in a table. The function keys have been set to return codes with bit 7 set so the action codes for the actions bound to function keys are the ones received from OSRDCH.

On the Electron, though, there is an extra translation table:

Code: Select all

;; Function key mapping table for the Electron.
;;
;; This maps the codes returned from OSRDCH for the function keys
;; combinations into internal action codes.

func_key_tab:           DFB     $C1, $B8, $A8, $CF, $CE, $B6, $B7, $C5
                        DFB     $C6, $C0, $00, $C4, $AC, $AD, $AE, $AF
                        DFB     $A2, $C7, $A5, $A6, $A0, $C8, $00, $A7
                        DFB     $A1, $C3, $CC, $CD, $B5, $B0, $B1, $00
                        DFB     $A9, $A4, $C2, $CA, $B2, $00, $00, $B4
                        DFB     $00, $A3, $BD, $BC, $BA, $B3, $BF, $BE
This gives an opportunity to re-map the correspondence between keys and the actions they perform in a way that does not change anything when running on a BBC micro. To do this would mean knowing a bit more about how the Electron handles function keys. I haven't seen one in years but am I right in thinking it doesn't have real function keys but uses an extra modifier key on the keyboard to make other keys behave as function keys? If so it would be good to have some reference documentation on this. Is this in the User Guide? Do we have a decent scan of that (or even a remastered version)?
User avatar
daveejhitchins
Posts: 6842
Joined: Wed Jun 13, 2012 6:23 pm
Location: Newton Aycliffe, County Durham
Contact:

Re: Updated BASIC Editor

Post by daveejhitchins »

Coeus wrote:
Tue Oct 26, 2021 3:05 pm
This gives an opportunity to re-map the correspondence between keys and the actions they perform in a way that does not change anything when running on a BBC micro. To do this would mean knowing a bit more about how the Electron handles function keys. I haven't seen one in years but am I right in thinking it doesn't have real function keys but uses an extra modifier key on the keyboard to make other keys behave as function keys? If so it would be good to have some reference documentation on this. Is this in the User Guide? Do we have a decent scan of that (or even a remastered version)?
Here's a copy of the P.R.E.S. ABE User Guide.
ABE User Guide.doc.zip
(56.19 KiB) Downloaded 12 times

Note, however, I need to Edit this! Down to A5 and do some tidying. And the page numbering is currently off!

Maybe the keys should match* Tom's BASIC Editor?

* I think even those could be improved - I'll have a think about this!

Dave H.
User avatar
Mince
Posts: 210
Joined: Thu Sep 05, 2019 11:25 pm
Location: Cambridge, UK
Contact:

Re: Updated BASIC Editor

Post by Mince »

daveejhitchins wrote:
Tue Oct 26, 2021 5:11 pm
Maybe the keys should match* Tom's BASIC Editor?

* I think even those could be improved - I'll have a think about this!
When I first saw this thread, I thought maybe there was a 'definitive' set of keys for the editor on the Electron and we might want to import them, but I've not done a comparison.

I picked the keys when I converted it for the Electron: the main difference being that it only has f0-9 (being FUNC+N); the shift+fN and ctrl+fN keycodes are instead created by FUNC+letter or some of the punctuation. f0 (= execute) is irritating as 0 is on the right (being on number 0) instead of the on left (as f0 is on the BBC).

For most of the commands, I went with the first letter but it was all a bit arbitrary. The screen up/down I went with FUNC+: and FUNC+/, which mirrored the common up/down controls in a game and I find natural; FUNC+, and FUNC+. for start/end of line similarly.

To be honest, aside from those, I tend to forget most of the others and have to use a function key strip, which I posted here a while back (and could supply a PDF version, if someone wants):

viewtopic.php?f=2&t=21078

And here's a PNG:
BASIC Editor keystrip.png
The key codes are here:

https://github.com/tom-seddon/basic_edi ... r/cmds.s65

I must admit I use the Acorn BASIC Editor a lot on the BBC, which was part of my motivation to make it work on the Electron!
BBC Master, PiTubeDirect w/ Pi 3A+ PIVDU, GoSDC, Pi1MHz SCSI, MMFS, RGBtoHDMI, MultiOS
BBC B, Integra ß, PiTubeDirect w/ Pi Zero 2W, Pi1MHz SCSI, MMFS, RGBtoHDMI
Electron, ElkSD 64 or Plus 1 w/ AP6 2V2, ATI/ABR w/ Pi 3A+, ElkSD Plus 1
Coeus
Posts: 2411
Joined: Mon Jul 25, 2016 12:05 pm
Contact:

Re: Updated BASIC Editor

Post by Coeus »

As a slight diversion from the Electron PAL ROM version I have found I was slightly annoyed by the ugly help text in Tom's version. This is not criticism of Tom, of course, there was quite a lot of code in the original version just for this help printing. What also wasn't obvious until I looked a little further into it, is that with the commands in three columns, the columns are not of equal width. 40 characters (mode 7) does not divide evening into three:
Basildon Electronics Version
Basildon Electronics Version
It so happens that the commands in the 2nd column are shorter, or at least have a shorter argument list, so this column is narrower. This may not wor with the new ICHANGE command. I then thought of a couple of ways to produce a similar screen without so much code. The first version keeps a count of the number of characters printed for each command and then spaces across to the next column. The result looks like this, in mode 7:
Character Counting, Mode 7
Character Counting, Mode 7
and in mode 3:
Character Counting, Mode 3
Character Counting, Mode 3
so one advantage to this approach is that it adapts to the screen mode. The disadvantage is that has the commands sorted across the width whereas we are more used to down the columns. The code changes to do this are on GitHub here: https://github.com/SteveFosdick/basic_e ... 430606b112

The second idea I had was to use cursor movement (VDU 31) so the command table is still processed in order but the printing is done down the rows and then starts a new column as needed. To avoid coping with scrolling and querying the current cursor position, this version clears the screen first. Here it is in mode 7:
Cursor Movement, Mode 7
Cursor Movement, Mode 7
and in mode 3:
Cursor Movement, Mode 3
Cursor Movement, Mode 3
I was even able to format the text at the end - the VDU31 sequence is shorter than the six spaces that would be needed otherwise. This change is also in Github at: https://github.com/SteveFosdick/basic_e ... 0e34b22a65

Code size: BE version: 340, unformatted version: 235, character counting: 254, cursor positioning: 269 bytes.
Coeus
Posts: 2411
Joined: Mon Jul 25, 2016 12:05 pm
Contact:

Re: Updated BASIC Editor

Post by Coeus »

daveejhitchins wrote:
Sat Oct 23, 2021 10:32 am
(1) Ability to enter ABE with Parameters (a) to determine which screen mode to use - If not used default would be 6 or 7, as current. (b) TBA
This doesn't sound hard, though it depends on whether there is any space. Tom's version take an alternative approach in that it just queries the mode that is in effect when it starts and then tries to avoid changing mode, i.e. the command screen uses the same mode as the editing screen. This means it also doesn't change mode when entering from BASIC or returning from BASIC, though obviously the BASIC program can change the mode.

As a diversion, for users of a BBC Master this would be something good to put in the CMOS RAM.
daveejhitchins wrote:
Sat Oct 23, 2021 10:32 am
(2) To use Name of file, for saving, if it entered on first line of BASIC (I believe there’s a ‘standard’ for this <#name>??
Tom's version already does this so this could be a case of whether it is easier to port that to the BE vervsion of add ROM switching to Tom's.
daveejhitchins wrote:
Sat Oct 23, 2021 10:32 am
(3) When editing – it would be a good feature if you could follow a jump or procedure – possibly by holding down a key combination – and returning, in the case of a procedure.
I am not sure how hard this one would be.
daveejhitchins wrote:
Sat Oct 23, 2021 10:32 am
(4) Key mapping could be improved for the Electron.
We've mentioned this already and I think we can make it whatever you wish.
daveejhitchins wrote:
Sat Oct 23, 2021 10:32 am
(5) Remember current line number (even after renumber??) and any procedural jumps, after visiting UTILS.
Again this would need more investigation.
daveejhitchins wrote:
Sat Oct 23, 2021 10:32 am
(6) Would be really useful if it worked with the TUBE
I think this could be a bit awkward to do. Much of the editor is written to be compatible with the tube but the ROM switching arrangement gets in the way. At the moment this code relies on being able to switch to the other ROM (or the other half, if a real PAL ROM) and immediately start executing code in that half. With the Tube involved things are more complicated because the OS copies a sideways ROM across the tube to start executing there. The way this ROM is arranged, it would be the editor half that gets copied over the tube.

It looks like, at some time in the past, someone did think about getting both ROMs as a pair to work with the tube. If you remember I described what seemed like a long-winded arrangement whereby to invoke the utilities, the editor puts *BUTIL into the keyboard buffer and then re-starts BASIC. What would happen next is that BASIC would pass the command to the OS and the OS would issue a service call for the unrecognised command. The editor ROM would receive the service call and, after finding it wasn't *BE, switch to the Utils ROM-half and offer the service call to that. That would recognise the *BUTIL command, issue the OSBYTE to start a language ROM with its own ROM number and then the OS would copy the active half of the ROM, now the utilities half, over the tube and run it from there.

The reason for going via the keyboard buffer rather than simply passing *BUTIL to OSCLI is to make sure the current ROM language ROM number does not match the BE ROM number forcing BE to be re-copied to the tube processor when it is started. If the editor simply issued *BUTIL direct to OSCLI the OS may decide that the language to be started is the current one anyway, there is no need to copy it, and then re-start the editor rather than starting the utils.

But this seems to have been overtaken by much more flipping between the two ROMs, for example there is a round trip already mentioned as a form of copy protection and then there are things like printing error messages. In the BE version, all the error message for the editor are in the Utils ROM so the editor asks the utils ROM for them and that means switching ROM. If the editor is running over the tube and the utils ROM is back on the I/O processor that won't work and will probably crash.

It may be possible to produce a version that loads from disc and runs over the tube which contains the code of both ROMs. An allowance would have to be made for a small boot ROM on the tube so either the combined pair would have to be less than 32K or the bottom of the editor ROM would have to be below &8000, but space could possibly be saved by being able to call between the two halves more easily.

I think I'll have to leave the Utils half for another day.
User avatar
daveejhitchins
Posts: 6842
Joined: Wed Jun 13, 2012 6:23 pm
Location: Newton Aycliffe, County Durham
Contact:

Re: Updated BASIC Editor

Post by daveejhitchins »

Here is an updated version of the ABE (for all models) User Guide along with keystrips for the Electron and BBC.
Edit: Contents and index are still to sort out!

I now have PCBs and will be making some up over the next few days. They'll cost around £15 for the ROM Module, User Guide and Keystrip - including UK P&P.

Dave H.

ABE.zip
(162.2 KiB) Downloaded 14 times
Coeus
Posts: 2411
Joined: Mon Jul 25, 2016 12:05 pm
Contact:

Re: Updated BASIC Editor

Post by Coeus »

I have been looking at the source from Dave. I think I had posted previously that it doesn't include the source of the lower (Editor) ROM but I have been looking at it anyway. The Source on the ABE Source1.SSD disc does not appear to be of the final high (utils) ROM either but rather an earlier version of the product on which it is based. The ROM title is different: "Altra BasicEd (Electron) 1.60" vs. "BASIC Editor & Toolkit V1.0". It is also missing a language entry and doesn't seem to include the code for a transfer of control from the lower (editor) ROM.

It does contain the source code for the PACK and UNPACK commands, though, which I think are of particular interest.

I will look at the S2 source disc.
Coeus
Posts: 2411
Joined: Mon Jul 25, 2016 12:05 pm
Contact:

Re: Updated BASIC Editor

Post by Coeus »

The S2 disc (ABE Source2.SSD) is not really source at all but contains documentation so we don't appear to have the source for either of the ROMs as finally released.
Coeus
Posts: 2411
Joined: Mon Jul 25, 2016 12:05 pm
Contact:

Re: Updated BASIC Editor

Post by Coeus »

On my previous post about transferring between the lower and upper ROM when running over the tube, I have done some tests and it seems the OS delegates the possible transfer of a language to the tube host code so:
  • For 8271-based DFSes
    • DFS 0.90 seems not to include the tube host.
    • DFS 1.20 (part of DNFS) re-copies the language even if it is the same ROM number.
  • For 1770-based DFSes:
    • DFS 2.26 re-copies the language even if it is the same ROM number.
    • DFS 2.24 (Master MOS 3.20) re-copies the language even if it is the same ROM number.
    • DFS 2.45 (Master MOS 3.50) re-copies the language even if it is the same ROM number.
That means, when running over the tube, to effect a switch between the two halves of a PAL ROM, it is only necessary for the ROM to flip which ROM is active as seen by the host processor and then re-issue the OSBYTE to select itself as the current language and the other half will now be copied over to the 2nd processor.

As a curiosity, for anyone who is an expert on this, *HELP on some of those configurations reported "6502 Tube 1.10", some reported "Tube Host 2.30" and some both. My suspicion is they are not reporting the same thing. Is the "6502 Tube 1.10" coming from the tube client code, maybe?
Post Reply

Return to “8-bit acorn software: other”