Lock CAPS poking memory - Printable Version +- Forum (https://www.boriel.com/forum) +-- Forum: Compilers and Computer Languages (https://www.boriel.com/forum/forumdisplay.php?fid=12) +--- Forum: ZX Basic Compiler (https://www.boriel.com/forum/forumdisplay.php?fid=11) +---- Forum: Help & Support (https://www.boriel.com/forum/forumdisplay.php?fid=16) +---- Thread: Lock CAPS poking memory (/showthread.php?tid=865) |
Lock CAPS poking memory - oblo - 11-29-2018 Hi all AFAIK, poking 23617 address with 128 locks the CAPS in BASIC. I'm trying this inside the compiler but only works with a bunch of keys, while using others (like W, Z or X) shows garbage instead of the CAPS. Is there any other way to force CAPS inside ZX Basic? I already tried all possible values 0 to 255) with no luck. Thanks and regards Re: Lock CAPS poking memory - britlion - 11-30-2018 I thought it was the lower bits that did this? http://www.users.globalnet.co.uk/~jg27paw4/yr02/yr02_78.htm 0,1,2,4 How are you reading the keypresses, Oblo? Something like multikeys or inkey$ might not work for this. You could always set it by flipping the CODE value with BAND 11011111 after reading in a key. if its between 61 and 122. This turns lower case into upper case. (It subtracts 32) Re: Lock CAPS poking memory - oblo - 11-30-2018 I'm reading LastK, and it's for the "redefine keyboard" feature. Here is the code: Code: REM subrutina para definir las teclas del juego I evaluated the 32 substracts option, but it only counts for letter (obviously) so I have to control if the pressed key is a letter or not and right now I'm in the last stage of the game development and... truth is I feel lazy, so I was looking for the shortcut -get CAPS always on :roll: Cheers EDIT: tried the values your link says and you were right on BASIC, but it didn't work on ZX Basic. Anyway, there's a thing I don't get. This is what Your Spectrum says: Quote:Specifies cursor. Values zero, one, two or four specify the L/C mode, E mode, G mode or K mode respectively. How can value 0 be L and C at the same time? Is not any other value/variable in the ZX Spectrum to check that CAPS is ON? And thanks again, 2018 and still learning things about this computer Re: Lock CAPS poking memory - boriel - 12-02-2018 oblo Wrote:How can value 0 be L and C at the same time? Is not any other value/variable in the ZX Spectrum to check that CAPS is ON? And thanks again, 2018 and still learning things about this computerIf what you need is to get always the Uppercase value of the key pressed, you can use the Upper() function. Code: #include <ucase.bas> Re: Lock CAPS poking memory - oblo - 12-02-2018 Great, didn't know that, thanks! I usually check the Identifiers webpage, but never found it. Is any other site with more documentation of functions/commands/identifiers/etc...? Re: Lock CAPS poking memory - boriel - 12-02-2018 Unfortunately not, but I'm trying to migrate the Wiki (currently broken, btw) to another system. Anyway, these are no reserved words, but normal functions from a library. |