Welcome, Guest. Please login or register.


Author Topic: SymbOS (Read 203570 times)

Offline Zozosoft

  • EP addict
  • *
  • Posts: 14005
  • Country: hu
  • OS:
  • Windows 7/Server 2008 R2 Windows 7/Server 2008 R2
  • Browser:
  • Firefox 33.0 Firefox 33.0
    • View Profile
    • http://enterprise.iko.hu/
Re: SymbOS
« Reply #285 on: 2014.November.12. 21:21:25 »
Clock switching can be simulated in ep128emu:
At Machine/Quick configuration save as Config 1 the normal 4MHz config.
Then edit the CPU speed, for example to 10MHz, and save as Config 2.
Then PageUp/Down can be used as clock switch.

(In emulator the floppy load works on turbo, because the WD timing not emulated :-( seeks done instantly, DRQ come instantly, and will wait for the operation, can't missed.)

Offline Prodatron

  • EP fan
  • *
  • Posts: 249
  • Country: de
  • Back on the Z80
  • OS:
  • Windows 7/Server 2008 R2 Windows 7/Server 2008 R2
  • Browser:
  • Firefox 33.0 Firefox 33.0
    • View Profile
    • http://www.symbos.de
Re: SymbOS
« Reply #286 on: 2014.November.13. 11:24:23 »
Thanks for all the feedback and infos! :)
Ok, I will now:
- add joystick support (thanks for the details, Geco!)
- keyboard/mouse mode switch with INS
- have a look at the disc routines
- work through all of Zozos hints and tipps :D

Ah, great that these monitor cables are still available! This UHF crap sucks a lot especially on my TFT TV. One of my EPs didn't seem to deliver a proper picture at all, I hope it will do with the SCART cable.
Oh, and I recognized, that at one machine the RETURN key and the internel joystick is not working. Is the keyboard membrane probably damaged and has to be replaced?

Offline Zozosoft

  • EP addict
  • *
  • Posts: 14005
  • Country: hu
  • OS:
  • Windows XP Windows XP
  • Browser:
  • Firefox 33.0 Firefox 33.0
    • View Profile
    • http://enterprise.iko.hu/
Re: SymbOS
« Reply #287 on: 2014.November.13. 11:30:24 »
Oh, and I recognized, that at one machine the RETURN key and the internel joystick is not working. Is the keyboard membrane probably damaged and has to be replaced?
Yes, there is a new membrane.

Offline Zozosoft

  • EP addict
  • *
  • Posts: 14005
  • Country: hu
  • OS:
  • Windows XP Windows XP
  • Browser:
  • Firefox 33.0 Firefox 33.0
    • View Profile
    • http://enterprise.iko.hu/
Re: SymbOS
« Reply #288 on: 2014.November.13. 11:44:31 »
One of my EPs didn't seem to deliver a proper picture at all
Look the R202 variable resistor at left side the modulator, probably need fine tuning. And also adjustable the RF modulator.

But the SCART cable much much much much better :-D

Offline Prodatron

  • EP fan
  • *
  • Posts: 249
  • Country: de
  • Back on the Z80
  • OS:
  • Windows 7/Server 2008 R2 Windows 7/Server 2008 R2
  • Browser:
  • Firefox 33.0 Firefox 33.0
    • View Profile
    • http://www.symbos.de
Re: SymbOS
« Reply #289 on: 2014.November.13. 16:38:36 »
Yes :oops: and using a slow step rate. I suggest the loader ask the defaul step rate (variable 73) and pass to floppy driver.
Your card also have a 1772 then Step Rate 2 suggested.
Put to EXDOS.INI (like as AUTOEXEC on PC):
VAR 73,3
LOAD SYM
[...]
Anyway make a problem when loaded from drive B: because components searched from drive A:
I suggest the loader ask the Default Drive at loading, and pass to the kernel as boot drive, it is the variable 71.
These EXDOS variables can be found here as well?
http://ep.homeserver.hu/Dokumentacio/Konyvek/EXOS_2.1_technikal_information/exos/kernel/Ch11.html#F16

Regarding the Turbo modes I will first try to get the driver working ok on a normal EP. Then let's test again at higher speeds...

Task manager CPU time calculating will be crazy when CPU speed switched. At 4Mhz idle display about 6% usage, then switch to 6 then about 0%, ok this look good, but when switch to 7.12 or 10 then display 60-70% usage. :oops:
When started 10Mhz, display about 4% at idle, but when switched back to 4Mhz then display about 50-70% usage :oops:
Yes, changing the CPU speed during runtime will confuse the measurement of the CPU usage completely, as the CPU speed is only tested once during booting :)

The joystick pointer only move to four directions. Will be better if 8 directions can be used.
That is because currently there is only this "emergency mode" for controlling the mouse. This mode uses the usual keyboard routine, which only outputs 1 key at the same time. It will be fixed either with the "mouse mode" or with external joysticks (which is now implemented).

Offline Zozosoft

  • EP addict
  • *
  • Posts: 14005
  • Country: hu
  • OS:
  • Windows XP Windows XP
  • Browser:
  • Firefox 33.0 Firefox 33.0
    • View Profile
    • http://enterprise.iko.hu/
Re: SymbOS
« Reply #290 on: 2014.November.13. 16:55:55 »
These EXDOS variables can be found here as well?
Some are in EXDOS manual at PDF pages 95-96.
Full list in ISDOS manual at PDF page 65.


Quote
Regarding the Turbo modes I will first try to get the driver working ok on a normal EP. Then let's test again at higher speeds...
I guess if original EXDOS routines used then will work on turbo :-)

Quote
This mode uses the usual keyboard routine, which only outputs 1 key at the same time.
Then possible send switching key codes for the additional directions? For example left,up,left,up,left,up...
The EXOS do this for the cursor movement, you can try it at the BASIC editor.

Offline Prodatron

  • EP fan
  • *
  • Posts: 249
  • Country: de
  • Back on the Z80
  • OS:
  • Windows 7/Server 2008 R2 Windows 7/Server 2008 R2
  • Browser:
  • Firefox 33.0 Firefox 33.0
    • View Profile
    • http://www.symbos.de
Re: SymbOS
« Reply #291 on: 2014.November.13. 21:23:40 »
I have two quick questions about EXOS Function 24 - Allocate Segment:
1.) is it always the case, that it returns the next free segment with the lowest number?
2.) page zero (which is at #b0, #0000-#3fff after loading): is it always the case, that only the first 256 bytes (#0000-#00ff) are used for EXOS?

Offline Zozosoft

  • EP addict
  • *
  • Posts: 14005
  • Country: hu
  • OS:
  • Windows 7/Server 2008 R2 Windows 7/Server 2008 R2
  • Browser:
  • Firefox 33.0 Firefox 33.0
    • View Profile
    • http://enterprise.iko.hu/
Re: SymbOS
« Reply #292 on: 2014.November.13. 21:57:18 »
1.) is it always the case, that it returns the next free segment with the lowest number?
Yes.

Quote
2.) page zero (which is at #b0, #0000-#3fff after loading): is it always the case, that only the first 256 bytes (#0000-#00ff) are used for EXOS?
It is used from 30h-5Bh.

The allocation as I think:
Do Allocate segment, until got a shared segment error (7Fh), store a list of allocated segments.
When get a shared segment error, then it is the System Segment (FFh).
Now come the trick: combine the Zero Page Segment with the System Segment.
Need to copy the system area, and also your loader program for continue the execution. And at the final need to left routines for the Warm Reset (which can restart SymbOS, for example in a all applications closed state, but possible continue anything), and a exit routine which will reverse the allocation and then exit to EXOS.

Set the User Boundary with EXOS 23, where is needed, it is depend from your program size.
If successful then copy the start of zero page to the system segment until the boundary.
Then page the system segment to page 0, and write it is address to BFFCh USR_P0 variable (page 2 address, on page 0: 3FFCh)
And finaly store the original page zero number to the start of allocated segment list.

This trick made one more continous 64K block at most of systems. But on lot of memory systems not too important.

And when you got the list of allocated segments, then select the 64K blocks, segments for Kernel, and video segments.
At the video segment need to calculate video addresses from the segment number (lower 2 bits of segment number will be the high 2 bits of video address).

Finaly give back the remaining unused segments with EXOS 25. (non-continous space, or more than 1M situation)

Offline Prodatron

  • EP fan
  • *
  • Posts: 249
  • Country: de
  • Back on the Z80
  • OS:
  • Windows 7/Server 2008 R2 Windows 7/Server 2008 R2
  • Browser:
  • Firefox 33.0 Firefox 33.0
    • View Profile
    • http://www.symbos.de
Re: SymbOS
« Reply #293 on: 2014.November.13. 22:13:31 »
Great concept, makes a lot of sense! :)
Let me first finish the allocation stuff, so that SymbOS runs with any amount of memory (128-1024K) + some more important things. At the end I will implement this EXOS/restore methode as well!

Offline Prodatron

  • EP fan
  • *
  • Posts: 249
  • Country: de
  • Back on the Z80
  • OS:
  • Windows 7/Server 2008 R2 Windows 7/Server 2008 R2
  • Browser:
  • Firefox 33.0 Firefox 33.0
    • View Profile
    • http://www.symbos.de
Re: SymbOS
« Reply #294 on: 2014.November.13. 22:15:32 »
then it is the System Segment (FFh).
Btw, couldn't this even start at #FE or earlier, if there are a lot of additional things loaded?

Offline Zozosoft

  • EP addict
  • *
  • Posts: 14005
  • Country: hu
  • OS:
  • Windows 7/Server 2008 R2 Windows 7/Server 2008 R2
  • Browser:
  • Firefox 33.0 Firefox 33.0
    • View Profile
    • http://enterprise.iko.hu/
Re: SymbOS
« Reply #295 on: 2014.November.13. 22:22:54 »
Btw, couldn't this even start at #FE or earlier, if there are a lot of additional things loaded?
The loaded things go for another segments. If open a large video pages with EXOS then possible go out from FFh. But in your situation video pages don't used.
But add a check (shared=FFh) will good for 100% certainty.

Offline Zozosoft

  • EP addict
  • *
  • Posts: 14005
  • Country: hu
  • OS:
  • Windows 7/Server 2008 R2 Windows 7/Server 2008 R2
  • Browser:
  • Firefox 33.0 Firefox 33.0
    • View Profile
    • http://enterprise.iko.hu/
Re: SymbOS
« Reply #296 on: 2014.November.13. 22:38:05 »
At the end I will implement this EXOS/restore methode as well!
My EXIT routine, I use when any error happen while loading program, at exit from program, and also used as "Exit at Warm Reset".
Code: ZiLOG Z80 Assembler
  1. EXIT:           DI
  2.                 LD SP,100H   ;set stack
  3.                 LD A,255
  4.                 OUT (0B2H),A   ;page in the system segment
  5.                 LD HL,EXIT
  6.                 LD (0BFF8H),HL   ;set routine address as Warm Restart routine (for a case when reset pressed again)
  7.                 LD HL,(0BFF4H)   ;EXOS LPT address
  8.                 SET 6,H
  9.                 LD B,4
  10. EXIT1           SRL H
  11.                 RR L
  12.                 DJNZ EXIT1   ;convert for send out to Nick
  13.                 LD A,L
  14.                 OUT (82H),A
  15.                 LD A,H
  16.                 OR 0C0H
  17.                 OUT (83H),A   ;EXOS LPT restored
  18.                 LD A,(P0S)      ;original Zero Page segment
  19.                 OR A
  20.                 JR Z,NOP0       ;jump if no segment change
  21.                 OUT (0B1H),A
  22.                 LD DE,4000H
  23.                 LD BC,SIZE
  24.                 LD H,E
  25.                 LD L,H
  26.                 LDIR            ;copy back the start of page zero segment
  27.                 OUT (0B0H),A  ;switch back
  28.                 LD (0BFFCH),A  ,write back to USR_P0
  29. NOP0:
  30.                 LD C,40H
  31.                 EXOS 0   ;EXOS reset, for deallocate all user memory
  32.                 LD A,1
  33.                 OUT (0B3H),A   ;ROM1 to Page 3
  34.                 LD A,6          ;function code: 6, start Enterprise logo screen
  35.                 JP 0C00DH    ;start ROM1 routine
  36.  

This can be used at "Shut Down" menu. And also when normal EXOS program selected for loading, at this situation after the "EXOS 0" do the loading instead the ROM1 starting.

Offline Prodatron

  • EP fan
  • *
  • Posts: 249
  • Country: de
  • Back on the Z80
  • OS:
  • Windows 7/Server 2008 R2 Windows 7/Server 2008 R2
  • Browser:
  • Firefox 33.0 Firefox 33.0
    • View Profile
    • http://www.symbos.de
Re: SymbOS
« Reply #297 on: 2014.November.14. 01:10:07 »
Dynamic memory segment allocation is working! :)

Now it supports up to 1MB and can be booted from systems with expanded memory, too.
Joystick support is included, too. Sector routines haven't been fixed yet, so it's maybe better only to try it in the emulator :oops:

Btw, I recognized (thanks to Edoz), that it only runs in the Emulator, if there is a disc in drive A AND drive B... So one more issue with the disc routines.

Offline Zozosoft

  • EP addict
  • *
  • Posts: 14005
  • Country: hu
  • OS:
  • Windows 7/Server 2008 R2 Windows 7/Server 2008 R2
  • Browser:
  • Firefox 33.0 Firefox 33.0
    • View Profile
    • http://enterprise.iko.hu/
Re: SymbOS
« Reply #298 on: 2014.November.14. 07:53:27 »
With more memory, more fun :smt038

Now it is totaly frezze on more than 4MHz :oops:

Offline edoz

  • EP fan
  • *
  • Posts: 131
  • Country: nl
  • OS:
  • Windows 7/Server 2008 R2 Windows 7/Server 2008 R2
  • Browser:
  • Mozilla compatible Mozilla compatible
    • View Profile
Re: SymbOS
« Reply #299 on: 2014.November.14. 09:21:52 »
Dynamic memory segment allocation is working! :)

Now it supports up to 1MB and can be booted from systems with expanded memory, too.
Joystick support is included, too. Sector routines haven't been fixed yet, so it's maybe better only to try it in the emulator :oops:

Btw, I recognized (thanks to Edoz), that it only runs in the Emulator, if there is a disc in drive A AND drive B... So one more issue with the disc routines.


WOW!! 1 MB that is cool !! Then we are able to run more applications at the same time!!!
How can I create a disk image for the enterprise ? If I want to test my own apps. ;)
Have fun with the Z80!