Ampliated Slot_1: and 2: are cognized automatically by the system, but Slot_3 is not. Then, when you extended Slot_3: you should re-write some parameters of system and make the Slot_Header. Following code would do both of them due to input the outset address and the last address of the Slot_3:.
10 input "outset address : ";oa
11 input "last address : ";la
20 s$=right$ (("00"+hex$ oa),5)
30 s1=val ("&"+mid$ (s$,4,2))
31 s2=val ("&"+mid$ (s$,2,2))
32 s3=val ("&"+mid$ (s$,1,1))
40 m=int ((la-oa+1)/2048)
50 poke &bfc09,s1,s2,s3,m,0,1
60 poke oa,&10,&12,m,0,0,1,0,0
61 poke oa+&08,0,0,0,0,0,0,0,0
62 poke oa+&10,0,&20,&18,0,0,0,0,0
If you had extended SRAMS by
the paper, you should input &10000 as outset address and &2ffff as last address
I'm supposed to write how to set user_area (machine_language_area) at first by right, cause the setting triggers to reset the system.
Following code would secure user_area due to input outset address.
10 input "outset address : ";oa
20 m=&bfc00-oa
30 m$=right$("00000"+hex$ m,6)
40 poke &bfe03,&1a,&fd,&0b
50 for i=0 to 2
60 z$=mid$ (m$,5-i*2,2)
70 poke &bfe06+i,val ("&"+z$)
80 next
90 call &fffd8
If you had extended SRAMS by
the paper, you could input figure, e.g.&90000 or &a0000 ..., as outset address. That's wide area
Following code enables RS232C serial communication.
10 poke &bfd35,0,&ff,0,&50
20 open "com:****,n,8,1,a,l,&1a,x,s"
(**** is figure of bps)
When you've done clock-up, you might have come to need change the time for auto-poweroff. Following code could change it due to input the rate.
10 def=&04b0:chk=-1
20 input "input the rate : ";rat
30 if rat<0.01 then print "too short":chk=0
40 if rat>&30 then print "too long":chk=0
50 p$=right$ ("000"+hex$ (rat*def),4)
60 p1=val ("&"+mid$ (p$,3,2)
70 p2=val ("&"+mid$ (p$,1,2)
80 if chk then poke &bfcbc,p1,p2:print "the time has changed"
else print "still default..."
I commend to put them together with a menu, and add some small utilities for the first initialization after overdrive or all-reset etc..