shawty / BBCB_DFS_Catalog

A HTML based mini application, written in JavaScript to allow you to host BBC B Disk images on a website.
The Unlicense
3 stars 2 forks source link

Error parsing BBC Basic listing #6

Open sassquad opened 4 years ago

sassquad commented 4 years ago

Using the catalog within bbcmicro.co.uk, I've noticed certain instances where the DFS Catalog doesn't appear to list all of the BBC Basic code.

One example can be found here - http://bbcmicro.co.uk//explore.php?id=602#bas - this is for a Beebug game, Labyrinth. When I download the file LAB2 and open it in any text editor, I can see that it is BBC Basic, albeit untokenised. But the in-page output of the code only lists one line:

10VDU28,0,0,0,0:CALLTOP

I can find further examples if required, but it would be nice to see if this is indeed an issue, and whether it can be resolved.

shawty commented 4 years ago

Hi @sassquad yep, that's another reason I started to re-write this.

Thanks, added to the list.

pau1ie commented 4 years ago

I was responsible for the code to display the program. You are correct that this program is clearly Basic. Looking at the hex dump (You can do it on the page you linked by selecting the relevant tab), we can see that line 10 ends with 0x0d (End of line) and the next byte is 0xff which means end of program, hence why the listing stops. I suspect this was a kind of copy protection. In fact if you click Play on the BBC Micro website, you can press Escape to get to Basic. Then LOAD "LAB2" and LIST, you can see exactly what the DFSCAT does. So I would go so far as to say this isn't a bug. However this does seem a bit of a cop out because it would be more useful to display the listing in full. I am not sure how to detect these situations though.

shawty commented 4 years ago

@pau1ie indeed, that is one of the more extraneous edge cases to work with.

I have been building a new version, I've just not got any of it checked in yet.

I'm currently working on a 6 month major App/Platform in the states, so I've only been able to do small pockets of work here and there.

Once I actually get a new version up and on GitHub, then I'll start soliciting other devs with an interest to come and work on things.

pau1ie commented 4 years ago

Sounds exciting!