[BBC-Micro] Programatically "reset" a Beeb?

Richard Gellman splodge at starfleet-net.co.uk
Wed Aug 15 19:51:46 BST 2012


On 15/08/2012 19:46, John Kortink wrote:
> On Wed, 15 Aug 2012 13:44:50 +0100, Richard Gellman
> <splodge at starfleet-net.co.uk>  wrote:
>
>> [...]
>>
>> I'm having trouble with a "reset" process. Hopefully someone
>> here can point out the Bleeding Obvious(tm) to me.
>>
>> [...]
>>
>> Store the bit in the ROM set select
>> register (1MHz bus)
>>
>> JMP (&FFFC)
>>
>> Except, it doesn't quite work. It
>> changes ROM set sure enough, but the start sequence is interrupted and
>> scrolls uncontrollably, sometimes with characters on screen.
>>
>> [...]
> Try :
>
> LDA #&7F
> STA&FE4E
>
> or equivalent, before you do the
>
> JMP (&FFFC)
>
> The OS will then find the system VIA in a state that is
> consistent with a power up, and acts accordingly.
>
>
> John Kortink

Yup. I just figured that as your email came in from Peter's email below 
(and a peruse of the Advanced User Guide). Those two instructions work 
perfectly, in both M128->B and B->M128.

Thanking you all :)

-- Richard

On 15/08/2012 16:13, Peter Coghlan wrote:
>> If I hit CTRL+BREAK after the "reboot" and weird
>> behaviour, it behaves like a model B just fine. But for an automated
>> process, this is obviously undesirable ;)
>>
>> I suspect that it fails
>> going autonomously from B to M128 too, but I always switch back by
>> setting the register (which locks the keyboard for obvious reasons) then
>> hitting CTRL+BREAK, so I never see the problem.
>>
> Hi Richard,
>
> Apologies for the direct reply. I can't reply to the list right now as I am
> away from my normal email setup and I cannot use the address I am subscribed
> under at the moment.
>
> I don't know much about the master but I do know that the model B checks the
> system VIA to figure out if the last reset was a break or power on reset.
> The reset line to the sytem VIA is not connected to the rest of the system
> reset line and the system VIA is therefore unaffected by the break key.
>
> If the master does the same, you may be able to trick it into doing a power on
> style reset if you change whatever register in the system VIA gets checked so
> that it looks like it has just been reset. (It may be necessary to manually
> reset all the 6522 registeres to the values they contain after reset as there
> is not going to be a hardware reset to do this. In fact, it may be necessary to
> do this with some or all other i/o devices as well as the O/S may assume that
> a hardware reset has occurred when it does it's startup processing.)
>



More information about the bbc-micro mailing list