Hi all,
¿How can we use vertical screen interrupt in QL? there is an interrupt on every vertical retrace, ¿how can I redirect interrupt to my routine?
When vertical screen retrace happens we have for some time full power of 68000 CPU and memory, and is interesting for trace on screen graphics with no flikering.
Vertical screen interrupt
Re: Vertical screen interrupt
radastan,
there isn't exactly what you're looking for. (Like an interrupt vector you could bend to point to exclusively call your own routine)
The 50Hz interrupt is basically the engine driving the QDOS multi-tasking and hardware interrupt handling, so anything fiddling with it is close to heart surgery
You can, however, have a look at the Polled interrupt list (pointed to by the SV_PLIST system variable) which is called by the OS in a response to the vertical retrace interrupt of the screen.
The system call MT.LPOLL links a routine into that chain of routines, the routine would then be called in 50Hz intervals. You might, however, want to make sure your routine is called as one of the first in this chain (I am not sure whether MT.LPOLL will link in your handler at the beginning or end of that chain - Would assume it is the start, but have not tested it yet.)
There is an interesting page here (not mine) http://omega.webnode.com/products/sincl ... ithvide-2/ that illustrates some experiments with that.
Regards,
Tobias
there isn't exactly what you're looking for. (Like an interrupt vector you could bend to point to exclusively call your own routine)
The 50Hz interrupt is basically the engine driving the QDOS multi-tasking and hardware interrupt handling, so anything fiddling with it is close to heart surgery

You can, however, have a look at the Polled interrupt list (pointed to by the SV_PLIST system variable) which is called by the OS in a response to the vertical retrace interrupt of the screen.
The system call MT.LPOLL links a routine into that chain of routines, the routine would then be called in 50Hz intervals. You might, however, want to make sure your routine is called as one of the first in this chain (I am not sure whether MT.LPOLL will link in your handler at the beginning or end of that chain - Would assume it is the start, but have not tested it yet.)
There is an interesting page here (not mine) http://omega.webnode.com/products/sincl ... ithvide-2/ that illustrates some experiments with that.
Regards,
Tobias
ʎɐqǝ ɯoɹɟ ǝq oʇ ƃuᴉoƃ ʇou sᴉ pɹɐoqʎǝʞ ʇxǝu ʎɯ 'ɹɐǝp ɥO
Re: Vertical screen interrupt
In a game, with no return to QDOS, I don't need multitasking. I need full 68000 horsepower, full QL access, no interruptions to code not needed.
Re: Vertical screen interrupt
Agreed.
The web page I pointed you to describes exactly that minimum of the system you need to keep "alive" to achieve what you want - Remember the Vectors to the ISRs are in ROM that you cannot modify, so you need to live at least with some OS code handled to get your hooks called.
Tobias
The web page I pointed you to describes exactly that minimum of the system you need to keep "alive" to achieve what you want - Remember the Vectors to the ISRs are in ROM that you cannot modify, so you need to live at least with some OS code handled to get your hooks called.
Tobias
ʎɐqǝ ɯoɹɟ ǝq oʇ ƃuᴉoƃ ʇou sᴉ pɹɐoqʎǝʞ ʇxǝu ʎɯ 'ɹɐǝp ɥO
-
- RWAP Master
- Posts: 2892
- Joined: Sun Nov 28, 2010 4:51 pm
- Location: Stone, United Kingdom
- Contact:
Re: Vertical screen interrupt
That web page is really good actually - originally QL games just disable the interrupts and store a second screen over the top of the system variables ($28000 on an original QL).
Disabling interrupts works fine but you have no access to some of the QL facilities (system variables).
Also please remember that the QL screen and system variables are not necessarily stored at $20000 and $28000 !!
Disabling interrupts works fine but you have no access to some of the QL facilities (system variables).
Also please remember that the QL screen and system variables are not necessarily stored at $20000 and $28000 !!
Rich Mellor
RWAP Software
RWAP Adventures
SellMyRetro
Retro-Printer Module - add a USB printer to your QL
Also Involved in:
Icephorm
RWAP Software
RWAP Adventures
SellMyRetro
Retro-Printer Module - add a USB printer to your QL
Also Involved in:
Icephorm
Re: Vertical screen interrupt
Actually I only works in assembly (Easy68K), and I don't need ROM.RWAP wrote: Disabling interrupts works fine but you have no access to some of the QL facilities (system variables).
Also please remember that the QL screen and system variables are not necessarily stored at $20000 and $28000 !!
¿How can I know where is screen and second screen on memory? I only use $20000 screen actually.
Re: Vertical screen interrupt
There's an assembler source with my Display_Cde extensions. They are written as BASIC extensions, but the assembler code should be clear enough in the source. This software shows how to test where the screen start address is, system variables, screen sizes, test for presence of pointer environment, window manager 2, GD2 (colour drivers) and so on.radastan wrote:Actually I only works in assembly (Easy68K), and I don't need ROM.RWAP wrote: Disabling interrupts works fine but you have no access to some of the QL facilities (system variables).
Also please remember that the QL screen and system variables are not necessarily stored at $20000 and $28000 !!
¿How can I know where is screen and second screen on memory? I only use $20000 screen actually.
http://www.dilwyn.me.uk/tk/index.html
--
All things QL - https://dilwyn.theqlforum.com
All things QL - https://dilwyn.theqlforum.com