Latest version of BeebEm

discuss bbc micro and electron emulators (including mame) here!
chrisn
Posts: 573
Joined: Sat Apr 19, 2014 12:31 pm
Location: UK
Contact:

Re: Latest version of BeebEm

Post by chrisn » Tue Sep 10, 2019 8:16 pm

I have just posted BeebEm 4.15 beta 4 release to GitHub.

https://github.com/stardot/beebem-windo ... tag/4.15b4

This has a few new features, contributed by Steve Insley:
  • Added new DX video modes for full-screen (1440p and 4K).
  • Fixed issue where BeebEm would always use the primary monitor when going fullscreen.
    • Now uses monitor on which the BeebEm window is positioned. As with all DX9 applications, this works best when "Maintain Desktop Resolultion" is selected.
  • Changed the default fullscreen resolution to "Maintain Desktop Resolution".
  • Added -AutoBootDelay CLI argument taking a delay parameter set in milliseconds creates a delay between initial boot and auto-boot of disk image if supplied in arguments. If used with -StartPaused, the timer starts after un-pausing.
  • Added ability to pause the emulation, distinct from freezing when focus lost.
    • Menu item on Speed menu.
    • Alt+F5 will pause/unpause.
    • The -StartPaused CLI argument can be used to prevent the emulation from starting until unpaused. Implemented to better support HyperSpin/RocketLauncher configurations where you want to defer boot until the BeebEm window and bezels are shown, and any Fade screen has been removed.
    • If in windowed mode and showing fps, pause state is shown in window title.
Feedback on these features is welcome, either here or as GitHub issues.

User avatar
KenLowe
Posts: 1125
Joined: Mon Oct 18, 2004 5:35 pm
Location: Scotland
Contact:

Re: Latest version of BeebEm

Post by KenLowe » Mon Sep 23, 2019 10:48 pm

Hi Chris,

Unfortunately I'm no expert on Github, but would like to suggest the follow modifications to beebmem.ccp to improve Computech IntegraB startup defaults, and to correct the current Year calculation. I'll also provide a patched IBOS ROM that two digit years are assumed to be 20xx instead of 19xx:

Line 98 current:

Code: Select all

unsigned char HiddenDefault[31] = {0,0,0,0,0,0,2,1,1,0,0xe0,0x8e,0,0,0,0,0,0,0,
						0xef,0xff,0xff,0x78,0,0x17,0x23,0x19,5,0x0a,0x2d,0xa0 };
Line 98 proposed:

Code: Select all

unsigned char HiddenDefault[31] = {0,0,0,0,0,0,2,1,1,0,0xe0,0x8e,0,0,
						 0,0,0,0,0,
						 0xed,0xff,0xff,0x78,0,0x17,0x20,0x19,5,0x0a,0x2d,0xa1 };

//Addresses 0x0 thru 0xD:		RTC Data: Sec, SecAlm, Min, MinAlm, Hr, HrAlm, Day, Date, Month, Year, Registers A, B, C & D
//Addresses 0xE thru 0x12:	?
//Address 0x13: 0xED		LANGUAGE in bank E. FILE SYSTEM in bank D. ROMS.cfg should match this, but IBOS reset will correct if wrong
//Address 0x14: 0xFF		*INSERT status for ROMS &0F to &08. Default: &FF (All 8 ROMS enabled)
//Address 0x15: 0xFF		*INSERT status for ROMS &07 to &00. Default: &FF (All 8 ROMS enabled)
//Address 0x18: 0x17		0-2: MODE / 3: SHADOW / 4: TV Interlace / 5-7: TV screen shift.
//Address 0x19: 0x20		0-2: FDRIVE / 3-5: CAPS. Default was &23. Changed to &20
//Address 0x1A: 0x19		0-7: Keyboard Delay
//Address 0x1B: 0x05		0-7: Keyboard Repeat
//Address 0x1C: 0x0A		0-7: Printer Ignore
//Address 0x1D: 0x2D		0: Tube / 2-4: BAUD / 5-7: Printer
//Address 0x1E: 0xA1		0: File system / 4: Boot / 5-7: Data. Default was &A0. Changed to &A1
Line 327 current:

Code: Select all

if (HidAdd==9) return((localtime(&long_time)->tm_year)-10);
Line 327 proposed:

Code: Select all

if (HidAdd==9) return((localtime(&long_time)->tm_year)%100);
Line 1266 current:

Code: Select all

Private[0x3b2]=4; // Default OSMODE to 4
Line 1266 proposed:

Code: Select all

Private[0x3b2] = 0x04; // Default OSMODE to 4
Private[0x3b5] = 0x14; // Default Century to 2000
Private[0x3b8] = 0xFF; // Default
Private[0x3b9] = 0xFF; // Default
Private[0x3ba] = 0x90; // Default
Private[0x3ff] = 0x0F; // Default RAM in bank locations 4, 5, 6 & 7

User avatar
KenLowe
Posts: 1125
Joined: Mon Oct 18, 2004 5:35 pm
Location: Scotland
Contact:

Re: Latest version of BeebEm

Post by KenLowe » Mon Sep 23, 2019 11:19 pm

And here's the patched IBOS ROM (Add 0x8000 to address to get true address when installed in beeb):

Code: Select all

Address 0x0A64: Was 0x23 Now 0x20 (default fdrive set to 0 instead of 3 for faster access)
Address 0x0A6E: Was 0xA0 Now 0xA1 (default to DFS instead of NFS for DNFS)
Address 0x0A72: Was 0x13 Now 0x14 (default century to 20xx instead of 19xx)
Address 0x278C: Was 0x02 Now 0x07 (Day of week was Mon for 1/1/(19)00. Now set to Sat for 1/1/(20)00)
Attachments
IBOS12P.rom
(16 KiB) Downloaded 18 times
Last edited by KenLowe on Mon Sep 23, 2019 11:32 pm, edited 1 time in total.

chrisn
Posts: 573
Joined: Sat Apr 19, 2014 12:31 pm
Location: UK
Contact:

Re: Latest version of BeebEm

Post by chrisn » Tue Sep 24, 2019 1:44 pm

Many thanks Ken, this change sounds good =D> I'll apply your patches and credit you in the Readme. It might take a little time though, as I'm on my hols at the moment...

User avatar
KenLowe
Posts: 1125
Joined: Mon Oct 18, 2004 5:35 pm
Location: Scotland
Contact:

Re: Latest version of BeebEm

Post by KenLowe » Tue Sep 24, 2019 2:03 pm

chrisn wrote:
Tue Sep 24, 2019 1:44 pm
Many thanks Ken, this change sounds good =D> I'll apply your patches and credit you in the Readme. It might take a little time though, as I'm on my hols at the moment...
I'm already credited for the original BBC B+ / IntegraB implementation :) No further credits required.

chrisn
Posts: 573
Joined: Sat Apr 19, 2014 12:31 pm
Location: UK
Contact:

Re: Latest version of BeebEm

Post by chrisn » Sat Mar 14, 2020 4:11 pm

I have just posted BeebEm 4.15 beta 5 release to GitHub.

https://github.com/stardot/beebem-windo ... tag/4.15b5

This has a few fixes and new features, with contributions from KenLowe and dominicbeesley:
  • Improved Computech IntegraB startup defaults, and correct the current year calculation. Also included is a patched IBOS ROM where two digit years are assumed to be 20xx instead of 19xx.
  • Fixed BCD mode in ADC and SBC instructions.
  • Fixed key selection dialog box layout for Windows 10.
  • Added -DebugLabels command line option to load BeebAsm compatible debug labels.
I intend this to be the last beta release for v4.15. Please give this a test and let me know if you find any issues, particularly with these new features.

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

Re: Latest version of BeebEm

Post by daveejhitchins » Sat Mar 14, 2020 4:34 pm

Fingers, and everything else, crossed that someone has the time to take up the mantle for upgrading BeebEm for Mac [-o<

I've not upgraded to Catalina (still with Mojave), as yet. However, BeebEm is getting worse - falls over if I just switch tasks e.g. go check mail - back to BeebEn to find it frozen! So every time I want to do anything else I shut-down BeebEm - most frustrating!

Dave H :D
Parts: UM6502CE, GAL22V10D, GAL16V8D, AS6C62256A, TC514400AZ, WD1772, R6522, TMS27C512, AT28C256
Products: ARA II, ARA III, ABR, ATI, AP6, MGC, AP5 . . .
For a price list, contact me at: Retro Hardware AT dave ej hitchins DOT plus DOT com

User avatar
lurkio
Posts: 2571
Joined: Wed Apr 10, 2013 12:30 am
Location: Doomawangara
Contact:

Re: Latest version of BeebEm

Post by lurkio » Sat Mar 14, 2020 6:51 pm

daveejhitchins wrote:
Sat Mar 14, 2020 4:34 pm
I've not upgraded to Catalina (still with Mojave), as yet.
Me too!
daveejhitchins wrote:
Sat Mar 14, 2020 4:34 pm
However, BeebEm is getting worse - falls over if I just switch tasks e.g. go check mail - back to BeebEn to find it frozen! So every time I want to do anything else I shut-down BeebEm - most frustrating!
I'm using Mac BeebEm 4.0a (I think!), and while I haven't had any issues as bad as that, I do find it annoying that Mac BeebEm seems to disable the Command-Tab app-switcher! I've had to install an alternative app-switcher just to get around the issue because it's such a fundamental feature of the OS and I use it all the time! There's also the fact that Mac BeebEm seems to disable the Command-Space (Quicksilver) and Alt-Space (Spotlight) shortcuts too! Plus, half the time, F12 takes an age to switch from being mapped to the macOS volume-up function to being mapped to the BeebEm Break-key function! Aaargh.


I have been able to successfully run the Windows version of BeebEm on Mojave using WINE via WineBottler. The version I've been using is Win BeebEm 4.15 beta 1.

Screenshot 2020-03-14 at 18.42.48.png

I'm cautiously optimistic that I'll be able to run Win BeebEm 4.15 beta 5 too -- though WineBottler is very fiddly to use and often seems to fail to install new apps properly. In any case, running the Windows version of BeebEm under WINE on a Mac isn't exactly ideal. The integration with the macOS GUI and the filesystem leaves a little something to be desired...

daveejhitchins wrote:
Sat Mar 14, 2020 4:34 pm
Fingers, and everything else, crossed that someone has the time to take up the mantle for upgrading BeebEm for Mac [-o<
Here (below) is the thread where people were discussing how to update Mac BeebEm for Catalina, etc. It's gone quiet, but I urge any and all Mac developers who might on the off-chance be reading this to get stuck in and make Dave's and my Mac BeebEm dreams come true!:
[-o<
Last edited by lurkio on Sat Mar 14, 2020 6:54 pm, edited 2 times in total.

User avatar
geraldholdsworth
Posts: 624
Joined: Tue Nov 04, 2014 9:42 pm
Location: Inverness, Scotland
Contact:

Re: Latest version of BeebEm

Post by geraldholdsworth » Sat Mar 14, 2020 6:52 pm

daveejhitchins wrote:
Sat Mar 14, 2020 4:34 pm
I've not upgraded to Catalina (still with Mojave), as yet. However, BeebEm is getting worse - falls over if I just switch tasks e.g. go check mail - back to BeebEn to find it frozen! So every time I want to do anything else I shut-down BeebEm - most frustrating!
I don't get that, and I'm on High Sierra and using BeebEm 4.0a.

Gerald.
Gerald Holdsworth
Repton Resource Page
www.reptonresourcepage.co.uk

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

Re: Latest version of BeebEm

Post by daveejhitchins » Sat Mar 14, 2020 7:07 pm

geraldholdsworth wrote:
Sat Mar 14, 2020 6:52 pm
daveejhitchins wrote:
Sat Mar 14, 2020 4:34 pm
I've not upgraded to Catalina (still with Mojave), as yet. However, BeebEm is getting worse - falls over if I just switch tasks e.g. go check mail - back to BeebEn to find it frozen! So every time I want to do anything else I shut-down BeebEm - most frustrating!
I don't get that, and I'm on High Sierra and using BeebEm 4.0a.

Gerald.
No, I didn't see any issues, like I seeing now, on the previous versions of MAC OS. In fact when I first upgraded to Mojave I didn't see any issues - but as 'fixes' have been added it's got worse for BeebEm!
Parts: UM6502CE, GAL22V10D, GAL16V8D, AS6C62256A, TC514400AZ, WD1772, R6522, TMS27C512, AT28C256
Products: ARA II, ARA III, ABR, ATI, AP6, MGC, AP5 . . .
For a price list, contact me at: Retro Hardware AT dave ej hitchins DOT plus DOT com

User avatar
vanekp
Posts: 772
Joined: Thu Nov 30, 2000 7:09 am
Location: The Netherlands
Contact:

Re: Latest version of BeebEm

Post by vanekp » Wed Mar 18, 2020 9:31 pm

If I try to write to a tape file it throws up a write error,
BeebEmTapeError.png
it lets you chose a file to record (write) to but when you try to save anything it then comes up with an error and only creates the header part of the UEF and does not write any data to it.
BeebEmTapeError1.png
BeebEm 4.15 (Bera 5) 14 Mar 2020
Peter.

chrisn
Posts: 573
Joined: Sat Apr 19, 2014 12:31 pm
Location: UK
Contact:

Re: Latest version of BeebEm

Post by chrisn » Wed Mar 18, 2020 11:50 pm

vanekp wrote:
Wed Mar 18, 2020 9:31 pm
If I try to write to a tape file it throws up a write error
Thanks for reporting this! There was a bug in the uef code caused by updating zlib, now fixed.

User avatar
tricky
Posts: 4245
Joined: Tue Jun 21, 2011 9:25 am
Contact:

Re: Latest version of BeebEm

Post by tricky » Fri Mar 20, 2020 1:01 pm

We are currently playing my version of Scramble in the High Score challenge and noticed that my current version has graphical issues on beebem.
I have just built the latest beebem (has 254 commits) for windows and think that it still has the same timing issue that it has always had.
I don't know the exact problem, but it seems to trigger vsync one scan line late, or trigger the interrupt one line late.
A hack to fix this is to reduce the vsync time by one: VideoState.VSyncState=(CRTC_SyncWidth>>4) - 1; (in video.cpp)
I have attached my built of the latest beebem (32bit release), just the exe, as I can't build the installer. (even opening the properties crashes VS2013).

If you want me to take it down again I will as I know this isn't an official release or official release path.

Attachment beebem.zip moved to Scramble thread in High-Score Challenge see below.
viewtopic.php?f=46&t=18901&p=262974#p262974
Last edited by tricky on Sat Mar 21, 2020 3:45 pm, edited 2 times in total.

User avatar
vanekp
Posts: 772
Joined: Thu Nov 30, 2000 7:09 am
Location: The Netherlands
Contact:

Re: Latest version of BeebEm

Post by vanekp » Sat Mar 21, 2020 11:25 am

this one does funny thing like when loading Castle Quest (Tape) with music it stops the playing of music between blocks :)
Peter.

User avatar
tricky
Posts: 4245
Joined: Tue Jun 21, 2011 9:25 am
Contact:

Re: Latest version of BeebEm

Post by tricky » Sat Mar 21, 2020 3:46 pm

I don't know what the correct fix is, as I said it seems to be 64us late (exactly) so reducing the time before the interrupt by 64us was the easiest bodge!

User avatar
Rich Talbot-Watkins
Posts: 1593
Joined: Thu Jan 13, 2005 5:20 pm
Location: Palma, Mallorca
Contact:

Re: Latest version of BeebEm

Post by Rich Talbot-Watkins » Tue Mar 24, 2020 11:15 am

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.

chrisn
Posts: 573
Joined: Sat Apr 19, 2014 12:31 pm
Location: UK
Contact:

Re: Latest version of BeebEm

Post by chrisn » Tue Mar 24, 2020 11:53 am

It's still the same, rendering is scanline based, so it's not cycle accurate. I've been making other improvements to the emulator, but so far haven't had the time to study the CRTC timings. I wonder if it's possible to adapt the existing video code, or may be better to start from scratch.

User avatar
tricky
Posts: 4245
Joined: Tue Jun 21, 2011 9:25 am
Contact:

Re: Latest version of BeebEm

Post by tricky » Tue Mar 24, 2020 1:11 pm

Maybe the last person to change it should do it - whomever that was ;)

Code: Select all

	// RTW - changed so we are even able to plot vertical total adjust region if CRTC_VerticalDisplayed is high enough
    if (VideoState.CharLine<CRTC_VerticalDisplayed) {
      // Visible char line, record first line
      if (VideoState.FirstPixmapLine==-1)
        VideoState.FirstPixmapLine=VideoState.PixmapLine;
	  // Always record the last line
      VideoState.LastPixmapLine=VideoState.PixmapLine;

      /* If first row of character then get the data pointer from memory */
      if (VideoState.InCharLineUp==0) {
        ova=VideoState.Addr*8; ovn=CRTC_HorizontalDisplayed*8;
        VideoState.DataPtr=BeebMemPtrWithWrap(VideoState.Addr*8,CRTC_HorizontalDisplayed*8);
        VideoState.Addr+=CRTC_HorizontalDisplayed;
      }
  
      if ((VideoState.InCharLineUp<8) && ((CRTC_InterlaceAndDelay & 0x30)!=48)) {
        if (!FrameNum)
          LowLevelDoScanLine();
      }
    }
PS The line at a time is OK, it is exactly 1 line out, but I can't really see where :(

chrisn
Posts: 573
Joined: Sat Apr 19, 2014 12:31 pm
Location: UK
Contact:

Re: Latest version of BeebEm

Post by chrisn » Sat Apr 04, 2020 4:10 pm

tricky wrote:
Tue Mar 24, 2020 1:11 pm
PS The line at a time is OK, it is exactly 1 line out, but I can't really see where :(
I'm currently looking into this ... and the fix for Scramble seems to be to replace:

Code: Select all

if ((VideoState.VSyncState==0) &&
    (VideoState.CharLine==CRTC_VerticalSyncPos) &&
    (VideoState.InCharLineUp == 0)) {
with:

Code: Select all

if ((VideoState.VSyncState == 0) &&
    (VideoState.CharLine == CRTC_VerticalSyncPos - 1) &&
    (VideoState.InCharLineUp == CRTC_ScanLinesPerChar)) {
to move the VSync low -> high transition one scanline earlier, while leaving the VSync pulse width correct (unlike your hack fix).

I've verified this is OK by comparing log outputs of the CRTC timings from B-em and BeebEm.

But, the problem this new change introduces is that Elite and Revs now show glitches. These games both use interlace sync mode, whereas Scramble uses normal (non-interlaced) sync mode, so the next fix needed (I think) is the half-line VSync timing adjustment. The relevant code in JSBeeb is here: https://github.com/mattgodbolt/jsbeeb/b ... eo.js#L487

Progress...

User avatar
tricky
Posts: 4245
Joined: Tue Jun 21, 2011 9:25 am
Contact:

Re: Latest version of BeebEm

Post by tricky » Sat Apr 04, 2020 6:49 pm

Good detective work there.

User avatar
Richard Russell
Posts: 1264
Joined: Sun Feb 27, 2011 10:35 am
Location: Downham Market, Norfolk
Contact:

Re: Latest version of BeebEm

Post by Richard Russell » Sun Apr 05, 2020 12:47 pm

chrisn wrote:
Sat Apr 04, 2020 4:10 pm
These games both use interlace sync mode, whereas Scramble uses normal (non-interlaced) sync mode
If you'll forgive a pedantic comment from somebody who spent his entire career in BBC R&D: interlaced mode is surely 'normal' and non-interlaced mode 'abnormal'! :lol:

chrisn
Posts: 573
Joined: Sat Apr 19, 2014 12:31 pm
Location: UK
Contact:

Re: Latest version of BeebEm

Post by chrisn » Sun Apr 05, 2020 1:02 pm

Richard Russell wrote:
Sun Apr 05, 2020 12:47 pm
chrisn wrote:
Sat Apr 04, 2020 4:10 pm
These games both use interlace sync mode, whereas Scramble uses normal (non-interlaced) sync mode
If you'll forgive a pedantic comment from somebody who spent his entire career in BBC R&D: interlaced mode is surely 'normal' and non-interlaced mode 'abnormal'! :lol:
Of course! I'm just quoting the AUG, not passing value judgement... :wink:

aug.png

User avatar
Richard Russell
Posts: 1264
Joined: Sun Feb 27, 2011 10:35 am
Location: Downham Market, Norfolk
Contact:

Re: Latest version of BeebEm

Post by Richard Russell » Sun Apr 05, 2020 1:43 pm

chrisn wrote:
Sun Apr 05, 2020 1:02 pm
Of course! I'm just quoting the AUG, not passing value judgement... :wink:
Hmm. If we (the BBC) had noticed that at the time a comment might have been made! BBC Micros all default to interlaced mode at power-on (or on CMOS reset in the case of a Master), don't they? It's necessary for MODE 7 to work properly in any case.

Coeus
Posts: 1496
Joined: Mon Jul 25, 2016 12:05 pm
Contact:

Re: Latest version of BeebEm

Post by Coeus » Sun Apr 05, 2020 5:02 pm

Richard Russell wrote:
Sun Apr 05, 2020 1:43 pm
Hmm. If we (the BBC) had noticed that at the time a comment might have been made! BBC Micros all default to interlaced mode at power-on (or on CMOS reset in the case of a Master), don't they? It's necessary for MODE 7 to work properly in any case.
But was the Advanced User Guide reviewed/authorised by the BBC? Progressive was presumably not in common use as a term for non-interlaced at the time, so maybe the authors struggled to find a suitable term, though I agree "normal" was a poor choice.

User avatar
Richard Russell
Posts: 1264
Joined: Sun Feb 27, 2011 10:35 am
Location: Downham Market, Norfolk
Contact:

Re: Latest version of BeebEm

Post by Richard Russell » Sun Apr 05, 2020 6:15 pm

Coeus wrote:
Sun Apr 05, 2020 5:02 pm
But was the Advanced User Guide reviewed/authorised by the BBC?
Not that I remember (but that doesn't mean much).

User avatar
Richard Russell
Posts: 1264
Joined: Sun Feb 27, 2011 10:35 am
Location: Downham Market, Norfolk
Contact:

Re: Latest version of BeebEm

Post by Richard Russell » Sun Apr 05, 2020 6:37 pm

Coeus wrote:
Sun Apr 05, 2020 5:02 pm
Progressive was presumably not in common use as a term for non-interlaced at the time
Indeed, and even now it's not a term I would normally use of computer graphics because it implies moving pictures (i.e. video).

tom_seddon
Posts: 373
Joined: Tue Aug 30, 2005 12:42 am
Contact:

Re: Latest version of BeebEm

Post by tom_seddon » Sun Apr 05, 2020 9:47 pm

Richard Russell wrote:
Sun Apr 05, 2020 6:37 pm
Coeus wrote:
Sun Apr 05, 2020 5:02 pm
Progressive was presumably not in common use as a term for non-interlaced at the time
Indeed, and even now it's not a term I would normally use of computer graphics because it implies moving pictures (i.e. video).
The Motorola MC6845 and VLSI VL68C45 data sheets describe the modes as "Normal Sync Mode (Non-interlace)", "Interlace Sync Mode", and "Interlace Sync & Video Mode". That could be where the wording comes from.

Though I don't think BBC Bs ever actually came with a Motorola MC6845, as it looks like it doesn't support display skew. The Hitachi 6845 seems to be usual, the data sheet for which describes non-interlace mode simply as "Non-interlace mode".

--Tom

P.S. http://www.6502.org/users/andre/hwinfo/crtc/diffs.html suggests there was an MC6845-1, that supports the extra stuff the Beeb uses - haven't got a data sheet for this one though!

User avatar
scarybeasts
Posts: 319
Joined: Tue Feb 06, 2018 7:44 am
Contact:

Re: Latest version of BeebEm

Post by scarybeasts » Tue Apr 07, 2020 8:06 am

chrisn wrote:
Sat Apr 04, 2020 4:10 pm
But, the problem this new change introduces is that Elite and Revs now show glitches. These games both use interlace sync mode, whereas Scramble uses normal (non-interlaced) sync mode, so the next fix needed (I think) is the half-line VSync timing adjustment. The relevant code in JSBeeb is here: https://github.com/mattgodbolt/jsbeeb/b ... eo.js#L487
Ah, you have had the misfortune of finding my jsbeeb CRTC re-work.
jsbeeb models the Hitachi 6845, which is quirky AF to be honest. Thanks to this quirkiness, the code is a bit tangled in places, and may not be as readable as I could have made it.

I'd be happy to try and answer any questions. The clearest picture I found for interlace timing is the URL in the jsbeeb comment: http://bitsavers.trailing-edge.com/comp ... s/6845.pdf
None of the datasheets get into the quirks or corner cases, unfortunately. I'm pretty sure jsbeeb hasn't gotten to the bottom of them all.


Cheers
Chris

User avatar
tricky
Posts: 4245
Joined: Tue Jun 21, 2011 9:25 am
Contact:

Re: Latest version of BeebEm

Post by tricky » Sat May 09, 2020 12:36 pm

I've been tweaking my version of beebem and wondered if the features might be useful to you or any developers.

I allow multiple -labels options, which then load multiple labels files, the is because I build the main game (exporting labels) then compress it and build a ROM header with decompression and include the compressed data, generating a second set of labels.

I have also extended what visual studio calls databreak points, basically if the address is written, the debugger will break. I did this by having a second set of breakpoints with separate window and enable tickbox. I allow ranges, same as breakpoints and the two tickboxes are helpful as I need to get to a point in the code where some things should no longer be written, or at least I want to monitor when and then turn the code break points off and data break points on. I did it with a dumb array of bool[65K] and then enable the ranges in the breakpoints.

I can't rememeber if I mentioned it but I have a similar setup for unitialised data, where an array gets set as addresses are written and breaks if read for code or data. The debugger also has command for setting/clearing ranges.

I also added a -debugger option to start with the debugger open which saves opening it and can catch all code inc startup.

In related news, I added a -labels <file> option to my beebasm to write the labels to a file, this could just have been made part of the -d or -dd options, but I didn't want to break any current uses. This is because I parse the output of the assemble for errors or metadata, which discards it (no T on windows). I was just assembling twice, first for error/metadata, then for labels, but it felt wrong, even if it did add less than a second.

chrisn
Posts: 573
Joined: Sat Apr 19, 2014 12:31 pm
Location: UK
Contact:

Re: Latest version of BeebEm

Post by chrisn » Sat May 09, 2020 1:11 pm

These sound like useful changes. If you share the files I can look at adding them to a future release.

Post Reply

Return to “8-bit acorn emulators”