New release of EightyOne available

Emulator and emulator development specific topics
Moggy
Posts: 1459
Joined: Wed Jun 18, 2008 1:00 pm

Re: New release of EightyOne available

Post by Moggy » Sun Sep 10, 2017 5:26 pm

sirmorris wrote:
Sun Sep 10, 2017 5:09 pm
It's distinctly possible Moggy. There are a number of ways to save a file in EO, I'm guessing you mean when SAVE "xxx" is used within the emulation and ZXpand is enabled?
Correct sir.

User avatar
sirmorris
Posts: 2599
Joined: Thu May 08, 2008 4:45 pm
Location: oxon, uk

Re: New release of EightyOne available

Post by sirmorris » Sun Sep 10, 2017 5:58 pm

Got it. This 'feature' won't be in the next release. I don't honestly know what the 'set the read-only bit' code was for, I suspect it was a misunderstanding on my part ;) In the meantime I'm afraid you'll need to manually remove the RO bit from saved files.
--=== ZXpand+ ... A more moderner all-in-one upgrade solution for ZX81 ===--
* SD/MMC storage * 32K Hires-capable RAM * AY sound chip * Joystick port * Serial *
* BASIC enhancements - plug & play * Reset button * Auto-boot facility *

User avatar
1024MAK
Posts: 1724
Joined: Mon Sep 26, 2011 9:56 am
Location: Looking forward to summer in Somerset, UK...

Re: New release of EightyOne available

Post by 1024MAK » Mon Sep 11, 2017 7:37 pm

I've moved the discussion about Charlie's Red Ant to this topic: Charlie's Red Ant - a ROM instruction that reads throughout memory

Mark

User avatar
marste
Posts: 93
Joined: Sun Aug 10, 2014 8:58 pm
Location: Italy
Contact:

Re: New release of EightyOne available

Post by marste » Sat Sep 23, 2017 12:33 pm

I was thinking to use something like a debug trace (with debug prints) in order to debug my last changes, and I tought that an out instruction to a specific port could be used. I had a look on the sources and easily found the place to change, but setup the development environment is not so easy, so I'm posting here if you can try to compile it for me and in case you like you can put it in the standard distribution also.

The change is in the zx81.cpp, and seems is enough to add another case in the "zx81_writeport" function:

Code: Select all

        //-------- DEBUG WRITE
        case 0x53:
                static FILE* dbglogfile = NULL; // put it on global space
                if (! dbglogfile)
                        dbglogfile = fopen("ZX8x-OUT53.LOG", "wb");
                fputc(Data, dbglogfile);
        //--------


I selected port 0x53 because was free and 53 is my number, but you can change in case.

PS:

Another question: I was also liking to see symbols name instead of numbers for program defined addresses (a feature that for example NO$ZX has) and having a look on the code seems also EightyOne has (seems there are ROM and file symbols) but I didn't find how to use it from the user interface: does it have it?

Thank you!

User avatar
sirmorris
Posts: 2599
Joined: Thu May 08, 2008 4:45 pm
Location: oxon, uk

Re: New release of EightyOne available

Post by sirmorris » Mon Sep 25, 2017 7:02 am

Hi Marste.

The symbols are shown in the debugger disassembly listing and breakpoint list. They can be entered wherever an address is being input, E.G. breakpoint addresses or memory window base.
Capture.PNG
Capture.PNG (33.03 KiB) Viewed 204 times
As for file-based debugging - I have considered this before and it proved such an enormous trouble that it was soon forgotten. There are issues with output string length vs zeddy memory size, character translation, making the source code bloated and generally it just wasn't useful. It's far easier to use the debugger in EO. It's very capable and once you're used to its quirks it can debug any issue.

C
--=== ZXpand+ ... A more moderner all-in-one upgrade solution for ZX81 ===--
* SD/MMC storage * 32K Hires-capable RAM * AY sound chip * Joystick port * Serial *
* BASIC enhancements - plug & play * Reset button * Auto-boot facility *

User avatar
marste
Posts: 93
Joined: Sun Aug 10, 2014 8:58 pm
Location: Italy
Contact:

Re: New release of EightyOne available

Post by marste » Mon Sep 25, 2017 5:32 pm

Dear SirMorris,

I know and I really appreciate the EightyOne debugger (that despite being Windows - a system that I use by exception - it’s my preferred for debugging :)), but unfortunately is not very easy with the current functionalities tracing a recursive routine willing to debug just a single level that is not the bottom one.

This because if you set-up a breakpoint it will stop at all inner recursions (that in my case evaluate a different board position for the 1k chess). Even if you want to skip the recursion call with a “step-over” what in reality you get is a stop on the return of it in the innermost recursion that is far away from the real call (you should check also SP and not just PC to have a real stepover, or a breakpoint that stop to the current level) …

I know that I have to convert the debug trace (and more than characters I’m thinking to write byte and words numbers to it), but it will be a simple script and with it I would have a full view of what was happening inside and will be able to filter and explore with a simple text editor back and forth. So I renew my request if possible to have a compilation with that code inside.

Regarding symbol instead I don’t understand how to load the .sym file: I have all files .p or .o with the corresponding .sym file and in No$Zx the symbols are loaded and displayed automatically, but is not the case of EightyOne… How to load the .sym file or maybe is a matter of format? (I attached an example of what is loaded in No$Zx)

Thank you
_Stefano
Attachments
1kRealChess81-F26-ab.zip
(2.18 KiB) Downloaded 7 times

User avatar
sirmorris
Posts: 2599
Joined: Thu May 08, 2008 4:45 pm
Location: oxon, uk

Re: New release of EightyOne available

Post by sirmorris » Mon Sep 25, 2017 7:29 pm

There was an option to load the symbols for the loaded program at one time in EO history. I think it may have been lost during the great code reconstruction of 2015..!!

I can look at re-adding this and I can certainly make you a special build including the debug output, but my time is very limited at the moment. I hope you understand.
--=== ZXpand+ ... A more moderner all-in-one upgrade solution for ZX81 ===--
* SD/MMC storage * 32K Hires-capable RAM * AY sound chip * Joystick port * Serial *
* BASIC enhancements - plug & play * Reset button * Auto-boot facility *

User avatar
marste
Posts: 93
Joined: Sun Aug 10, 2014 8:58 pm
Location: Italy
Contact:

Re: New release of EightyOne available

Post by marste » Tue Sep 26, 2017 4:51 pm

Sure, when you can!

Regarding symbols load it can be also done without a specific menu item but just checking if exist a file with same name and .sym extension and load it automatically!

Thank you!

User avatar
marste
Posts: 93
Joined: Sun Aug 10, 2014 8:58 pm
Location: Italy
Contact:

Re: New release of EightyOne available

Post by marste » Wed Sep 27, 2017 9:06 pm

Update:

I did the change on ZesarUX, that unfortunately do not have a great debugging interface (has a lot of other great features anyway) but for tracing is just fine.

So if it is just for me I don't need anymore the special compilation (I still anyway think is a feature that might help sometime and you might include).

Symbols visualization would instead be a great addition (in jump/call labels and load addresses).

MunichSpec
Posts: 2
Joined: Sun Oct 08, 2017 10:21 am

Re: New release of EightyOne available

Post by MunichSpec » Sun Oct 08, 2017 10:44 am

Hi!

I want to report an issue that shows up accessing the Sinclair ZX Microdrive at an assembler level with EightyOne. Background: I'm the developer of the Mdv2Img tool (see http://www.worldofspectrum.org/utilities.html and http://www.worldofspectrum.org/pub/sinc ... dv2img.zip from there). This tool reads raw microdrive sectors to RAM using machine code and then sends them to a PC via the IF1's RS232 port. The idea is to rescue old Microdrive cartridges from decay and probably fix them on the PC, using more computing power and better strategies.

After migrating from Win2K to Win7x64, Gerton Lunter's WinZ80 emulator (still available at http://www.spectromania.dk/zx/2016/02/2 ... ton-lunter) - being a 16-Bit DOS application - refused to work. Bummer. Sure I successfully tested everything mentioned below in a Windows-XP-VirtualBox emulation, but at some point it's really time for switching to new software...

So I switched to EightyOne (V1.7) and wanted to say a big "thank you" for all your efforts. After a small while, everything worked like a charm, tested a few tape images and even inserted one of my "virtual" microdrive cartridges, containing the Mdv2Img BASIC loader and just a dump of the Spectrum's complete memory, saved to cartridge using

10 FORMAT "m";1;"cartridge1"
20 SAVE *"m";1;"code1" CODE 0, 16384
30 SAVE *"m";1;"code2" CODE 0, 16384
...

Rereading WinZ80's CARTRIDG.orig.MDR (137'923 bytes, as expected) in WinZ80 and EightyOne yielded identical results:
CARTRIDG.orig.MDR.WinZ80.png
CARTRIDG.orig.MDR.WinZ80.png (5.73 KiB) Viewed 61 times
CARTRIDG.orig.MDR.EightyOne.png
CARTRIDG.orig.MDR.EightyOne.png (3.89 KiB) Viewed 61 times
, so I think the cartridge image is OK.

Then I tried my tool mdv2img (
mdv2img.tap.zip
(2.16 KiB) Not downloaded yet
) in both emulators. In a nutshell, this tool reads Microdrive cartridges sector by sector in a RAM buffer. If that buffer is full, it is dumped via IF1's RS232 interface in raw format. Repeat until every sector has been read and transferred.

In WinZ80, the result looks like this:
WinZ80.Result.png
WinZ80.Result.png (4.43 KiB) Viewed 61 times
260 sectors and 7 DCHK errors are to be expected because of the way cartridges are formatted. The raw RS232 dump (
Cartridg.RS232.zip
(9.8 KiB) Not downloaded yet
) is 141'180 bytes long due to the overhead of mdv2img trying to read the "defect" sectors multiple times. If I run this through the PC conversion tool (mdv2img.exe.zip), the result is a completely intact CARTRIDG.repaired.MDR that has the same size and content as the original one.

[c'ed in next post since I'm somehow not allowed to attach more than 5 files...]
Last edited by MunichSpec on Sun Oct 08, 2017 10:57 am, edited 3 times in total.

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest