::: Area #102 (BBC Echo)Message: #1296 (Read 4 times, has 0 replies, 3152 bytes)Date   : Sat May 30 19:52:06 1998From   : Jonathan Graham Harston of fidonet#2:254/27To     : AllSubject: Running a BBC Without A KeyboardJGH> So, holding the keystrobe line high should do it.  A 4.7k resistorJGH> between pin 14 (CA2) and pin 15 (+5v) should do it.  As these areJGH> adjacent pins, you can make a little carrier from a two-pin molexJGH> plug to just plug onto the pins.JGH> I'll investigate and follow up.Well, here's the results.Holding the interupt line high or low made no difference.  I tried holdingthe data line PB7 low, and high.  Nothing.  Something more subtle wasgoing on.  So, I blew a small EPROM that just displayed service callnumbers and plugged it in.  On switching on displayed:0F05FF:1000FF:010517:020518:FE0500:_So, it was getting past the test vector, and on to the service calls.Then, it occured to me.  With the keyboard unplugged, it looks as thoughall the links are set, so Osbyte255 is set to &00.  'All links set' is asubset of 'All keys pressed'; and 'Ctrl and Shift pressed' is a subset of'All keys pressed'.  Now, what happens if you press Ctrl and Shifttogether?  Text output pauses at the end of the line!  With no keyboardplugged in the text output is forever pausing, which explains why somemachines displayed some text (extra rom software startup banners) and somedidn't (The first CR before 'BBC Computer').So, we need to get the Beeb to think that Ctrl and Shift are not pressedtogether.  This is tested for by calling KEYV with C=0 and V=0.  So, if weredirect KEYV and return, then it should work.I assembled the following rom:NewKey=&03D0OldKEYV=&03D8[.Start:\ &8000JMP 0:JMP ServEQUB &82:EQUB Copy-&8000:EQUB 0EQUS "NoKBD".CopyBRK:EQUS "(C)".ServCMP #1:BEQ Serv1:RTS.Serv1PHP:SEI:\ Disable interuptsLDX #10.Serv1LpLDA KeyStore,X:STA NewKey,XDEX:BPL Serv1LpLDA KEYV:STA OldKEYVLDA KEYV+1:STA OldKEYV+1LDA #NewKEY AND 255:STA KEYVLDA #NewKEY DIV 256:STA KEYV+1PLP:LDX &F4:LDA #1:RTS.KeyStoreBVS KeyJump:\ KeyTest is C=0 and V=0BCS KeyJumpLDA #0:RTS:\  Set to %00xxxxxx, b7=Ctrl b6=Shift.KeyJumpJMP 0]Loaded it into sideways ram, unplugged the keyboard, and pressed Break.(Well, actually, an additional reset switch :) ).Lo and behold - it worked.  With Osbyte255 set to zero, it booted up, fromNetwork in this case.It's something I'd been planning anyway on putting into HADFS anyway, andnow it is.  It's in from version 5.20 onwards.I added the above code to HADFS, blew an EPROM and plugged it in.Switched on the machine without the keyboard... HADFS Startup bannerappeared, and then sat there again, apparently waiting for Shift to bepressed.  On pressing reset, it continues ok.  So, there's just thePower-On Reset bit to solve.Investigations continue...--J.G.Harston (JGH BBC PD Library) 70 Camm Street, Walkley, SHEFFIELD S6 3TRBBC+Master / Z80+6502 / CoPro+Tubes / Econet+SJ / Devolution / Transport /Planning / Highways    http://homepages.nildram.co.uk/~amilton/walkley.htmjgh@arcade.demon.co.uk   (( Anti-UCE address added by Arcade, not by me ))--- ARCbbs RISC OS [1.64á32c] * Origin: Arcade - The Definitive Acorn BBS +44 181 655 4412 (2:254/27)