|
Post by gtoal on Oct 19, 2019 9:22:52 GMT -5
I've never seen any code that uses SWIs for any reason and although I'ld never given it much conscious thought or looked into it, I'ld assumed that was because the BIOS pointed the SWI vectors into rom and they couldn't be used. However I was looking at the BIOS just now and I noticed that all the vectors point into RAM so can be redirected. Now there's probably not a lot of things you could do with a SWI that you can't do with a JSR, but I was wondering if one place a SWI might be useful were in triggering a bank change?
Any other uses of SWI that anyone can think of? If it's not helpful for speed, maybe it could be used to reduce code size in some way? For example as an extracode for a 'draw immediate vector list' command where the vectors are embedded immediately following the SWI and execution continues after the end byte of the vector list?
G
|
|
|
Post by kokovec on Oct 19, 2019 11:14:33 GMT -5
It's been a while since I've coded anything for the Vectrex but my gut tells me that SWI's aren't used because of the strict timing required for drawing vectors. Also, I think the Vectrex BIOS makes heavy use of timer interrupts. It'd be interesting to see if anyone's used them successfully.
|
|