Search found 1553 matches

by Rich Talbot-Watkins
Tue Mar 24, 2020 11:17 am
Forum: stardot.org.uk
Topic: Site Icon
Replies: 6
Views: 477

Re: Site Icon

Doesn't even look like stardot's got a favicon - at least, I'm not seeing anything in Google Chrome.
by Rich Talbot-Watkins
Tue Mar 24, 2020 11:15 am
Forum: emulators
Topic: Latest version of BeebEm
Replies: 57
Views: 7226

Re: Latest version of BeebEm

Does BeebEm emulate video at a cycle-accurate level alongside the CPU yet? Last time I looked (many years ago now) it was batching video update scanline at a time, which could well explain why you're getting a scanline out, even if the VSync pulse width emulation is basically correct.
by Rich Talbot-Watkins
Fri Mar 13, 2020 9:13 am
Forum: software: classic games
Topic: Who's ready for... guess that game! ;D
Replies: 82
Views: 4032

Re: Who's ready for... guess that game! ;D

People are naming games I've never even heard of here...
by Rich Talbot-Watkins
Thu Mar 05, 2020 10:09 pm
Forum: programming
Topic: What PRNG algorithm's do BBC BASIC's RND functions use
Replies: 29
Views: 1557

Re: What PRNG algorithm's do BBC BASIC's RND functions use

The other obvious approach (and the one that it looks as if 6502 BASIC does) is to scale the entire range of the RND function into 1...x for RND(x). Basically a multiplication by x/RAND_MAX. No idea what Z80 or ARM might be doing though! Edit: actually 6502 BASIC is scaling up the results of RND(1),...
by Rich Talbot-Watkins
Thu Mar 05, 2020 6:21 pm
Forum: programming
Topic: What PRNG algorithm's do BBC BASIC's RND functions use
Replies: 29
Views: 1557

Re: What PRNG algorithm's do BBC BASIC's RND functions use

An alternative strategy, if you were trying to avoid the cost of a modulus, might be to mask out excess bits (AND 127 in this case), and then try again with the next value in the sequence if it were out of range.
by Rich Talbot-Watkins
Tue Feb 18, 2020 9:13 am
Forum: software
Topic: RISC OS 2 Kernel Source code
Replies: 6
Views: 442

Re: RISC OS 2 Kernel Source code

I had a quick browse through some of the source code. Amusing to see so much profanity liberally scattered throughout. This stuff probably wouldn't pass code review these days! There are no doubt assembler labels with daft names too (from when you need a label when hurriedly writing code, but don't ...
by Rich Talbot-Watkins
Sun Feb 16, 2020 2:53 pm
Forum: archive issues
Topic: Archive of FSD files?
Replies: 90
Views: 2436

Re: Archive of FSD files?

As far as I know, there wasn't an FDI, only an FSD. And the FSD format has shortcomings here, in that it doesn't model the data properly, but just marks the sector as returning a Data CRC error (&0E) when read, without specifying why. In this case, the fact that there are weak/fuzzy bits requires ex...
by Rich Talbot-Watkins
Fri Feb 14, 2020 10:23 am
Forum: archive issues
Topic: Archive of FSD files?
Replies: 90
Views: 2436

Re: Archive of FSD files?

scarybeasts wrote:
Thu Feb 13, 2020 10:59 pm
[ITRP] 0492: LDA #$7F
[ITRP] 0494: LDX $0490
[ITRP] 0497: LDY $0491
[ITRP] 049A: JSR $FFF1
[ITRP] 049D: LDA #$0E
[ITRP] 049F: NOP
[ITRP] 04A0: CMP #$0E
[ITRP] 04A2: BNE $049D
^ Looks like you've hacked out the test there so that it always loads. LDA #$0E:NOP should presumably be LDA $04A0!
by Rich Talbot-Watkins
Thu Feb 13, 2020 9:48 am
Forum: archive issues
Topic: Archive of FSD files?
Replies: 90
Views: 2436

Re: Archive of FSD files?

Warning -- loading Boulderdash is a real nail-biter, it takes a long time and the disc will pause for seconds at a time while it does some CPU intensive unpacking. Is that just because of the decryption code, or is it because the disk controller is having to retry multiple times to find sectors (ma...
by Rich Talbot-Watkins
Wed Feb 12, 2020 9:39 pm
Forum: archive issues
Topic: Advanced BASIC Editor PACK
Replies: 44
Views: 1728

Re: Advanced BASIC Editor PACK

I think it's fair to say that every language has its idioms, and BBC BASIC is no exception. I think you've sold the construct pretty well, and I can see how it's useful in those contexts. I haven't seen it used very much, and the last time I did was as a hack to allow a one line program to call itse...
by Rich Talbot-Watkins
Wed Feb 12, 2020 8:44 pm
Forum: archive issues
Topic: Archive of FSD files?
Replies: 90
Views: 2436

Re: Archive of FSD files?

Makes sense, yeah! And, in general, the required lengths of things are double for MFM than for FM, e.g. MFM requires 12 zero bytes in gaps, compared to 6 for FM. So it seems like they've done some pretty thorough research for that 1770 emulator!
by Rich Talbot-Watkins
Wed Feb 12, 2020 8:42 pm
Forum: archive issues
Topic: Advanced BASIC Editor PACK
Replies: 44
Views: 1728

Re: Advanced BASIC Editor PACK

Yes, I'm also a big proponent of that, but I'm not sure if BASIC, in general, promotes that concept because it's not strictly scoped: a variable, once created, exists and is visible globally for evermore (unless hidden by an explicit more local scope, in BBC BASIC). With global variables, if they mu...
by Rich Talbot-Watkins
Wed Feb 12, 2020 6:54 pm
Forum: archive issues
Topic: Advanced BASIC Editor PACK
Replies: 44
Views: 1728

Re: Advanced BASIC Editor PACK

In that case what alternative approach would you propose for creating a variable if it doesn't already exist, but not changing its value if it does? Again as I mention in the other thread, such functionality is useful in a cleanup routine, which may be run as the result of an asynchronous event suc...
by Rich Talbot-Watkins
Wed Feb 12, 2020 6:21 pm
Forum: archive issues
Topic: Advanced BASIC Editor PACK
Replies: 44
Views: 1728

Re: Advanced BASIC Editor PACK

Yes, fair enough. I remember from MS BASIC on my old Oric-1 that variables were created on first use (along with the other MS quirks of only the first two characters being significant, and arrays being dimensioned by default to 10 elements!). Still not really fond of the paradigm personally, but if ...
by Rich Talbot-Watkins
Wed Feb 12, 2020 6:18 pm
Forum: programming
Topic: Reducing Basic Program Size
Replies: 31
Views: 1355

Re: Reducing Basic Program Size

I guess I have the C++ orthodoxy of "declare all variables before using them" too ingrained!
by Rich Talbot-Watkins
Wed Feb 12, 2020 4:23 pm
Forum: archive issues
Topic: Archive of FSD files?
Replies: 90
Views: 2436

Re: Archive of FSD files?

Wow, that Boulderdash format is weird. I just looked to see if there were any way it could fit, and even reducing gaps 1 and 3 to zero, it still needs 3146 bytes. So is data slightly more squeezed together (written at less than 300rpm?) or is the sector actually incomplete? Gap1: 0+6 For 9 sectors: ...
by Rich Talbot-Watkins
Wed Feb 12, 2020 12:57 pm
Forum: programming
Topic: Reducing Basic Program Size
Replies: 31
Views: 1355

Re: Reducing Basic Program Size

I'd not spotted that example before, but it's not a safe substitution. 'Klingon%', as a normal dynamic variable, will be deleted by a CLEAR (or CHAIN) but 'K%', as a static integer variable, won't. This could cause a program to misbehave, for example: 10 Klingon% = 123 20 CLEAR 30 Klingon% = Klingo...
by Rich Talbot-Watkins
Wed Feb 12, 2020 12:52 pm
Forum: archive issues
Topic: Advanced BASIC Editor PACK
Replies: 44
Views: 1728

Re: Advanced BASIC Editor PACK

The only time this could be a problem, as far as I can tell, is in the case highlighted by Richard's example in the other thread, where you write: A=A+1 without having previously defined A. While this is apparently valid BBC BASIC, I suspect the language wasn't designed with this in mind, and only w...
by Rich Talbot-Watkins
Sat Feb 08, 2020 7:47 pm
Forum: software: other
Topic: Drawing a circle in BBC BASIC
Replies: 57
Views: 4322

Re: Drawing a circle in BBC BASIC

Out of interest, how do you arrive at the 14.74 MHz figure, Richard? I've never seen any rigorous method for determining the pixel aspect ratio on the Beeb.
by Rich Talbot-Watkins
Sat Feb 08, 2020 3:15 pm
Forum: software: other
Topic: Drawing a circle in BBC BASIC
Replies: 57
Views: 4322

Re: Drawing a circle in BBC BASIC

Here's a nice Bresenham filled circle routine in BBC BASIC which I wrote with the intention of converting to 6502 a while back: 10 MODE4 20 GCOL 3,1 30 FOR n%=100 TO 10 STEP -10 40 PROCcircle(160,128,n%) 50 NEXT 60 END 70 : 80 DEFPROCplot(x1%,x2%,y%) 90 MOVE x1%*4,1023-y%*4 100 DRAW x2%*4,1023-y%*4 ...
by Rich Talbot-Watkins
Sat Feb 08, 2020 12:40 pm
Forum: archive issues
Topic: Archive of FSD files?
Replies: 90
Views: 2436

Re: Archive of FSD files?

Yes I would prefer to de-interleave clock and data bits, for human readability and for greater compressibility too. Whether this were done at the byte level or greater, I don't know. However in a real disk surface, it'll be possible and even likely that the amount of data per track is not a whole nu...
by Rich Talbot-Watkins
Fri Feb 07, 2020 1:07 pm
Forum: archive issues
Topic: Archive of FSD files?
Replies: 90
Views: 2436

Re: Archive of FSD files?

I would actually argue in favour of IPF, simply because it's easier for emulators to consume, leads to smaller files (I still care about that, even if few do), can represent all known forms of 'exotic' disk surfaces, and is quickly establishing itself as a de facto standard. It's a curious omission ...
by Rich Talbot-Watkins
Thu Feb 06, 2020 10:23 am
Forum: software: classic games
Topic: Nightshade protection [technical]
Replies: 175
Views: 58126

Re: Nightshade protection [technical]

Ah, this is the code that was said to be a disk formatting routine! Not quite as evil then, but, in a way, more irritating if it just stops disk writes from working reliably.
by Rich Talbot-Watkins
Sat Jan 25, 2020 4:28 pm
Forum: software: classic games
Topic: An Exile writeup
Replies: 31
Views: 1560

Re: An Exile writeup

Aw, thank-you! Glad you enjoyed the videos, it’s great to hear people appreciated them. I’m currently in the process of splicing all the videos together with the annotations back (thanks to scarybeasts and garfield) into one single (or possibly 3-4?) long videos. Thank-you SO much to the people on ...
by Rich Talbot-Watkins
Wed Jan 22, 2020 1:08 pm
Forum: projects
Topic: Good test games / programs for an emulator
Replies: 28
Views: 1321

Re: Good test games / programs for an emulator

Re: B-EM, BCPL, SBC and the Overflow Flag [this post about testing generally] Nightshade protection [technical] BBC Master timing-sensitive protection systems jsbeeb - a Javascript emulator Cycle stretching when accessing 1MHz devices More curious 6502 behaviour (mentions Lunar Jetman) Plea for hel...
by Rich Talbot-Watkins
Wed Dec 18, 2019 8:18 pm
Forum: software: classic games
Topic: The very best Beeb tunes?
Replies: 21
Views: 1237

Re: The very best Beeb tunes?

Pretty certain the Rydeen track in Striker's Run is from Super Locomotive, because they also nicked the 'Bonus Stage' music from Super Locomotive to be the Striker's Run high score entry music. https://www.youtube.com/watch?v=o89fWnolC4U But this also is a slightly different rendition! But, yeah, S...
by Rich Talbot-Watkins
Wed Dec 18, 2019 10:50 am
Forum: software: classic games
Topic: The very best Beeb tunes?
Replies: 21
Views: 1237

Re: The very best Beeb tunes?

Sounds like a different rendition to me - a lot closer to the original YMO version in fact!
by Rich Talbot-Watkins
Thu Dec 05, 2019 9:36 am
Forum: hardware
Topic: Info please! Acorn's in-house large-memory 6502 co-pro
Replies: 99
Views: 5716

Re: Info please! Acorn's in-house large-memory 6502 co-pro

I think it's far less useful if it can't present a flat memory model. But I'm not sure how the timing could work to handle the bit 15-16 carry (which as you say would only need to check a single bit discrepancy). I think potentially the CPU would need to be stopped twice - first time after loading z...
by Rich Talbot-Watkins
Tue Nov 12, 2019 8:45 pm
Forum: software & utilities for the pc, mac or unix
Topic: Uses of the semicolon in BBC BASIC
Replies: 11
Views: 657

Re: Uses of the semicolon in BBC BASIC

The SWI system will always have needed some kind of macro wrapper around it in C, generating the correct instruction, because the SWI number was part of the opcode, rather than any kind of value set up in a register. I think, when Acorn introduced the ARM6 or 7, which had a separate data and instruc...
by Rich Talbot-Watkins
Tue Nov 12, 2019 12:57 pm
Forum: software & utilities for the pc, mac or unix
Topic: Uses of the semicolon in BBC BASIC
Replies: 11
Views: 657

Re: Uses of the semicolon in BBC BASIC

Simply an alternative to a comma, I think; not sure why semicolon is accepted here at all. I think semicolon was the "standard" BASIC syntax for an INPUT command. Certainly MS BASIC expects a semicolon (comma is a syntax error). That's a new one on me. I assume it's a RISC OS feature and if so it m...