From 098181cf785afd239edf251536e6347d23c74af0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vincent=20Rivi=C3=A8re?= Date: Mon, 22 Oct 2012 18:17:34 +0000 Subject: [PATCH] Added comments about pseudo-supervisor mode. --- BaS_GNU/sources/BaS.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/BaS_GNU/sources/BaS.c b/BaS_GNU/sources/BaS.c index b5d596f..db87f0d 100644 --- a/BaS_GNU/sources/BaS.c +++ b/BaS_GNU/sources/BaS.c @@ -165,7 +165,10 @@ void BaS(void) * (uint8_t *) 0xfffffa11 = 0; __asm__ __volatile__("nop \n\t" : : : "memory"); + /* Test for pseudo-supervisor mode: DIP switch #6 down */ if (DIP_SWITCH & (1 << 7)) { + /* In this mode, the OS actually runs in user mode + * and all the supervisor instructions are emulated. */ __asm__ __volatile__("move.w #0x0700,sr \n\t" : : : "memory"); } __asm__ __volatile__("jmp 0xe00030 \n\t" : : : "memory");