home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Archive Magazine 1997
/
ARCHIVE_97.iso
/
text
/
hints
/
vol_02
/
issue_11
< prev
next >
Wrap
Text File
|
1995-02-16
|
27KB
|
1,088 lines
Å Limited ADFS memory (RISC-OS/Arthur 1.2) Ö One reader has written in
saying that his Archimedes will only *MOUNT six discs. On the seventh,
the drive spins continuously until the disc is removed. This happens
because the ADFS only has a limited amount of memory to store the
directory information. The amount of memory allocated for this can
controlled by using *Configure ADFSDirCache.
==> Help on keyword ADFSDirCache
*Configure ADFSDirCache sets the size of the directory cache (in Kbytes)
used by the ADFS. A value of 0 selects a default value which depends on
RAM size.
Syntax: *Configure ADFSDirCache <size>[K]
You can also make the Archimedes forget that it has seen the disc by
using *DISMOUNT.
2.11
==> Help on keyword Dismount
2.11
*Dismount closes files, unsets directories and parks the given disc.
2.11
Syntax: *Dismount [<disc spec.>]
2.11
Å Three floppies for Arthur 1.2 desktop Ö In Archive 2.8, pages 11/12,
there is a hint which allows you to access three drives from the
desktop. However, the hint states that you must start the desktop up by
typing */Desktop instead of *Desktop. One reader says that you could of
course set up *Set Alias$Desktop Run Desktop which would then allow you
to start up using *Desktop.
2.11
Å In First Word Plus, when printing after opening more than one file,
the first file you opened will be offered for printing, not the last one
you closed!
2.11
Å Configuring your printer under the PC Emulator Ö In reply to Chris
Walkeræs question, you must use the following reserved words when
configuring your printer:
2.11
For serial printers use: AUX or COM1, COM2, COM3╔
2.11
For parallel printers use: PRN or LPT1, LPT2╔
2.11
Å Sprite Plot comments from Martin Simmons Ö The article on sprite
plotting was interesting since it is always good to see how other
programmers solve problems. However, the routines are far from being the
fastest possible, a major inefficiency being that the screen pointer is
updated after every pixel is plotted. This could be rectified by
deleting 2410, 2460, 2510, 2580 and changing the following:
2.11
2010 PROCplot_4_pixels(4*
2.11
(gjenta-1))
2.11
2050 ADD screen_pointerR,
2.11
screen_pointerR,#320
2.11
2110 DEF PROCplot_4_pixels(index)
2.11
2400 STRNEB data5R,
2.11
[screen_pointerR,#index+0]
2.11
2450 STRNEB data5R,
2.11
[screen_pointerR,#index+1]
2.11
2500 STRNEB data5R,
2.11
[screen_pointerR,#index+2]
2.11
2570 STRNEB data5R,
2.11
[screen_pointerR,#index+3]
2.11
Now the pointer is only changed at the end of each line. This improves
performance over the published routine by about 10% for a 24x24 pixel
sprite with no black pixels.
2.11
It would be quicker to use word stores instead of byte stores but this
would complicate the routine and may even slow it down overall.
2.11
Å D.I.Y. A3000 serial interface Ö Mike Harrison (Archive 2.10 p 56)
didnæt know what the chip numbers were for the A3000 serial interface
kit. You need a 6551 (which ought to be one of the ones manufactured by
CMD) and an LT1133.
2.11
Å Evaluation of Algebraic Expressions (E.D. Engelhardt) Ö Anyone who
is interested in the evaluation of valid algebraic expressions could try
to use PROCexpression in program Evalexpr as given below. The procedure
mentioned has been written using suggestions of Mr de Heus, ECD, Delft,
Holland.
2.11
Variable names in an expression are single, lower-case characters
ranging from Éaæ to Ézæ. These names are stored in Évar$æ. Each
character in the input expression Éex$æ is matched with its presence in
Évar$æ. If so, its position in Évar$æ is detected and it is replaced by
the (arbitrary) character É$æ. The position is used to assign an
appropriate value to the actual variable by means of array Évar()æ. The
value of the expression is obtained using the EVAL function.
2.11
The reason EVAL(ex$) is preceded by EVAL (öFALSEò) in PROCevalexpression
is as follows: If one enters an expression containing no variables but
numbers only, and the expression cannot be evaluated (e.g. LN0 or 3/0)
an error message appears on the screen. Thereafter, entering the same
type of expression, again not containing variables (e.g. LN9 after LN0
or 6/5 after 3/0), results in the same error message. To prevent this
from happening the instruction EVAL(ö<>ò) is included. I discovered this
Éfeatureæ by accident and found the solution by trial and error. I would
appreciate any comments from interested readers.
2.11
10 REM >Evalexpr
2.11
20 :
2.11
30 WHILE TRUE
2.11
40 PROCevalexpression
2.11
50 ENDWHILE
2.11
60 END
2.11
70 :
2.11
80:
2.11
90 DEFPROCevalexpression
2.11
100 k$=ö Press any key to continue !ò
2.11
110 LOCAL ERROR
2.11
120 ON ERROR LOCAL IF ERR=17 THEN
2.11
PRINTÉæö *** Escaped program !òÉ
2.11
:END ELSE PRINTÉö ò;REPORT$æÉk$;:
2.11
dummy=GET:ENDPROC
2.11
130 :
2.11
140 PROCinput
2.11
150 :
2.11
160 PROCexpression
2.11
170 exval=EVAL(öFALSEò) :REM
2.11
*** To prevent error message
2.11
after evaluation of a wrong
2.11
expression, e.g. LN0. Try to REM this
line !
2.11
180 exval=EVAL(ex$)
2.11
190 :
2.11
200 PROCoutput
2.11
210 ENDPROC
2.11
220 :
2.11
230 DEFPROCinput
2.11
240 CLS:PRINTÉö Choice of variables
2.11
from a to z.öÉ
2.11
250 LINE INPUTö Give expression : ò
2.11
ex$
2.11
260 ENDPROC
2.11
270 :
2.11
280 DEFPROCoutput
2.11
290 PRINTÉö Function value of ò;ex$
2.11
;ö = ò;exval
2.11
300 PRINTæk$;:dummy=GET
2.11
310 ENDPROC
2.11
320 :
2.11
330 DEFPROCexpression
2.11
340 LOCAL var$,var(),t%,i%
2.11
350 var$=öabcdefghijklmnopqrstuvw
2.11
xyzö
2.11
360 DIM var(LEN(var$))
2.11
370 :
2.11
380 FOR t%=1 TO LEN(ex$)
2.11
390 i%=INSTR(var$,MID$(ex$,t%,1))
2.11
400 IF i%>0 THEN
2.11
410 var$=LEFT$(var$,i%-1)+ö$ò
2.11
+MID$(var$,i%+1)
2.11
420 PRINTÉö Value of ò;
2.11
MID$(ex$,t%,1);ö : ò;
2.11
430 INPUTöòvar(i%)
2.11
440 :
2.11
450 CASE i% OF
2.11
460 WHEN 1:a=var(i%)
2.11
470 WHEN 2:b=var(i%)
2.11
480 WHEN 3:c=var(i%)
2.11
490 WHEN 4:d=var(i%)
2.11
500 WHEN 5:e=var(i%)
2.11
510 WHEN 6:f=var(i%)
2.11
520 WHEN 7:g=var(i%)
2.11
530 WHEN 8:h=var(i%)
2.11
540 WHEN 9:i=var(i%)
2.11
550 WHEN 10:j=var(i%)
2.11
560 WHEN 11:k=var(i%)
2.11
570 WHEN 12:l=var(i%)
2.11
580 WHEN 13:m=var(i%)
2.11
590 WHEN 14:n=var(i%)
2.11
600 WHEN 15:o=var(i%)
2.11
610 WHEN 16:p=var(i%)
2.11
620 WHEN 17:q=var(i%)
2.11
630 WHEN 18:r=var(i%)
2.11
640 WHEN 19:s=var(i%)
2.11
650 WHEN 20:t=var(i%)
2.11
660 WHEN 21:u=var(i%)
2.11
670 WHEN 22:v=var(i%)
2.11
680 WHEN 23:w=var(i%)
2.11
690 WHEN 24:x=var(i%)
2.11
700 WHEN 25:y=var(i%)
2.11
710 WHEN 26:z=var(i%)
2.11
720 ENDCASE
2.11
730 ENDIF
2.11
740 NEXT
2.11
750 :
2.11
760 ENDPROC
2.11
2.11
Å First Word Plus Ö I am sure that all users of First Word Plus have
found it considerably enhanced by the use of Steve Hoareæs Interrupt
Module (available on Shareware N╝6). The main use for this is in
mounting new discs, formatting and creating directories. I have recently
discovered that it can also be used for *EXECing files into the word
processor. This can be very useful because First Word Plus treats the
standard ASCII space character as a Éhardæ space. This means that if
straight ASCII text is read into First Word Plus in the regular way it
can not be formatted because each line is treated as an entire word. By
using the interrupt module and *EXECing the file it is as if it were
being typed in from the keyboard. Spaces between words are thus
translated into Ésoftæ spaces so that the resulting document can be
formatted in the usual way. Brian Cowan
2.11
Å Greek characters Ö (Gerald Fitton) For some time now I have been
considering converting all my old Wordwise files to PipeDream files.
The thing that has been putting me off is that, since I teach (amongst
other things) maths and statistics, I need to be able to print Greek
letters such as CDSYabc defghijklmnopqrstuvwxy. It is relatively easy
from Wordwise to define a new character on the Epson FX printer, but not
so easy to include it in PipeDreamæs Printer On string. I have got
round this by running a BASIC program from within PipeDreamæs !Run file
that sends the necessary codes for the Greek characters to the printer.
You can then have What-You-See-Is-What-You-Get Greek characters on
screen by using the sequence <Alt>+E+C. This is what you do:
2.11
Modify the !Run file to include the command
2.11
BASIC -quit ö<PipeDream$Dir>.
2.11
Printers.Greekö
2.11
My !Run file now looks like the one below.
2.11
| > !PipeDream.!Run
2.11
Set PipeDream$Dir <Obey$Dir>
2.11
WimpSlot -min 160k -max 640k
2.11
RMReInit InternationalKeyboard
2.11
RMKill InternationalKeyboard
2.11
BASIC -quit ö<PipeDream$Dir>.
2.11
Printers.Greekö
2.11
RMEnsure FPEmulator 2.60 RMLoad
2.11
<System$Path>Modules.FPEmulator
2.11
Set Alias$@RunType_DDE Run
2.11
<PipeDream$Dir>.!Run %%*0
2.11
Set File$Type_DDE PDream
2.11
IconSprites <PipeDream$Dir>
2.11
.!Sprites
2.11
Load <Obey$Dir>.piped.pd 8000
2.11
DIR <Obey$Dir>
2.11
Echo <26>
2.11
Pointer 0
2.11
Go 8000 ; %*0
2.11
DIR adfs::HardDisc4.$
2.11
Include the new program ÉGreekæ in a suitable directory; I have chosen
the ÉPrintersæ directory.
2.11
100 REM > <PipeDream$Dir>.
2.11
Printers.Greek
2.11
150 :
2.11
160 *Alphabet Greek
2.11
180 VDU 2
2.11
200 RESTORE
2.11
210 REPEAT
2.11
220 READ byte%
2.11
230 IF byte%<>-1 THEN VDU 1,byte%
2.11
240 UNTIL byte%=-1
2.11
250 :
2.11
260 VDU 3
2.11
270 :
2.11
280 END
2.11
300 :
2.11
310 DATA 27,64
2.11
320 DATA 27,58,0,0,0
2.11
330 DATA 27,37,1,0
2.11
340 DATA 27,54
2.11
350 DATA 27,38,0,108,108
2.11
360 DATA 136,0,128,0,252,2,0,2,0,0,0,0
2.11
370 DATA 27,38,0,128,128
2.11
380 DATA 138,8,4,2,4,8,16,32,64,128
2.11
,0,0
2.11
390 DATA 27,38,0,176,176
2.11
400 DATA 168,0,0,64,160,0,160,64,0,0
2.11
,0,0
2.11
410 DATA 27,38,0,177,177
2.11
420 DATA 139,18,0,18,0,126,0,18,0,18
2.11
,0,0
2.11
430 DATA 27,38,0,195,196
2.11
440 DATA 137,130,124,130,0,128,0,128,
2.11
64,0,0,0
2.11
450 DATA 139,2,4,10,16,34,64,130,96,
2.11
26,4,2
2.11
460 DATA 27,38,0,211,211
2.11
470 DATA 139,130,0,198,0,170,0,146,0,
2.11
130,0,0
2.11
480 DATA 27,38,0,217,217
2.11
490 DATA 139,58,68,130,0,128,0,130,68
2.11
,58,0,0
2.11
500 DATA 27,38,0,225,249
2.11
510 DATA 138,28,34,0,34,20,8,20,32,2
2.11
,0,0
2.11
520 DATA 138,127,128,18,128,18,128,
2.11
114,12,0,0,0
2.11
530 DATA 11,64,0,64,32,16,11,4,8,16
2.11
,96,0
2.11
540 DATA 138,12,18,64,178,0,146,0,
2.11
146,76,0,0
2.11
550 DATA 137,8,20,8,34,8,34,8,34,0
2.11
,0,0
2.11
560 DATA 8,13,144,37,192,5,130,0,0,0
2.11
,0,0
2.11
570 DATA 10,64,60,64,0,64,0,64,63,0
2.11
,0,0
2.11
580 DATA 138,56,68,16,130,16,130,16,
2.11
68,56,0,0
2.11
590 DATA 71,0,0,124,0,4,0,0,0,0,0,0
2.11
600 DATA 138,62,0,8,0,20,0,34,0,0,0,0
2.11
610 DATA 136,130,68,40,16,8,4,2,0,0
2.11
,0,0
2.11
620 DATA 10,127,0,4,0,4,0,4,120,4,0,0
2.11
630 DATA 10,64,32,16,8,4,8,16,96,0
2.11
,0,0
2.11
640 DATA 9,128,40,212,0,149,0,149,2,0
2.11
,0,0
2.11
650 DATA 139,0,0,0,0,0,0,0,0,0,0,0
2.11
660 DATA 138,32,0,62,0,32,0,62,0,32
2.11
,0,0
2.11
670 DATA 9,63,64,0,68,0,68,56,0,0,0,0
2.11
680 DATA 139,0,0,0,0,0,0,0,0,0,0,0
2.11
690 DATA 139,28,34,0,34,0,34,28,32,0
2.11
,32,0
2.11
700 DATA 10,32,64,0,64,60,64,0,64,0
2.11
,0,0
2.11
710 DATA 9,64,56,4,0,4,0,120,0,0,0,0
2.11
720 DATA 10,56,68,0,68,187,68,0,68,56
2.11
,0,0
2.11
730 DATA 9,65,34,20,8,20,34,65,0,0
2.11
,0,0
2.11
740 DATA 11,120,4,0,4,251,4,0,4,120
2.11
,0,0
2.11
750 DATA 138,28,34,0,2,12,2,0,34,28
2.11
,0,0
2.11
760 DATA -1
2.11
2.11
Incidently, this shows how you can include a BASIC program within an
Obey file and then come back to RUN the rest of the Obey file.
2.11
You have to remember to remove ESC ö@ò from the Printer On string
otherwise you will lose all the character definitions you have just
downloaded! G L Fitton.
2.11
This final section of hints and tips has been extracted from the Archive
Bulletin Board Service (BBS) by Richard Forster.
2.11
(N.B. There may be some over-lap with other H & T, but I donæt have time
to edit it out Ö Iæm just off on my Holidays. Ed.)
2.11
Å First Word Plus Margins Ö It is possible to get First Word Plus to
change its margins permanently, but it is not easy. It may also depend
on your version of the software, and this method may not work on all
versions. Make sure you try it on a backup copy!
2.11
10 wp%=OPENUP(öResources.1wp.1wpò)
2.11
20 margin%=8 : REM or whatever is
2.11
required
2.11
30 PTR#wp%=&2EF9C
2.11
40 BPUT#wp%,margin%
2.11
50 CLOSE#wp%
2.11
Å Taxan Multisync juddering Ö If you have an A400/1 or A3000 machine
and are using it with a Taxan Multisync monitor, you may experience some
juddering which can be overcome thus:
2.11
A400/1: Fit a molex shunt to link 2. If you do not have a spare shunt,
you can request one from Acorn Customer Services.
2.11
A3000 : Take your machine to your local dealer. The modification is
different from the A400/1 machines and you must not open your machine.
2.11
Å Using the Yes/No mouse icon Ö In order to use the Yes/No mouse icon,
do:
2.11
SWI öOS_Confirmò
2.11
This changes the pointer shape, flushes the mouse buffer, waits until a
key is pressed and then, on exit: R0 = (lowercased) character pressed, C
flag is set if ESCAPE, Z flag set if character is ÉYæ
2.11
Å Saving Rom Sprites Ö To save rom sprites as a standard file, do:
2.11
SYSöWimp_BaseOfSpritesò TO roms%
2.11
SYSöOS_SpriteOpò,524,roms%,öfilenameò
2.11
Save this as a BASIC program and double click it from the desktop.
2.11
Å Memory Re-allocation Ö You can re-allocate memory for spritesize,
screensize etc. by loading a module called MEMALLOC. This can be found
on Application Disc 2 in directory $.!Lander.
2.11
Å Hourglass Ö The following SYS calls affect the hourglass. Note that
the hourglass is nested, so if you have turned it on twice it must be
turned off twice.
2.11
SYSöHourGlass_Onò Ö Display Hourglass
2.11
SYSöHourGlass_Offò Ö Remove Hourglass
2.11
SYSöHourGlass_percentageò,number Ö Display Hourglass & percentage below.
2.11
SYSöHourGlass_Smashò Ö Remove all hourglasses
2.11
SYSöHourGlass-LEDsò,%AB Ö Where A is the top LED, B is the bottom LED
2.11
SYSöHourGlass_Onò has a delay of 1/3 sec before actually appearing. To
make the delay the value of r0 use:
2.11
SYSöHourGlass_Startò
2.11
Å Tiny directories Ö The adjust button on a tiny directory opens the
application and removes that tiny directory.
2.11
Å RISC-OS Speedup Ö The following calls speed up the machine ROMs from
4Mhz to 8Mhz. Try them at your own risk. (Although under Arthur they
caused crashes, they seem to work OK under RISC-OS) The first switches
to higher speed, the second resets it:
2.11
SYSöOS_UpdateMEMCò,64,64
2.11
SYSöOS_UpdateMEMCò,,64
2.11
Å Terramex Cheat Ö For infinite lives, when you first load the game,
type in öSUBJECTTOCHANGEò on the loading screen.
2.11
Å RISC-OS Bugs Ö Yes, already folk have found begun to find bugs in
RISC-OS.
2.11
1) Module files which show up for *cat as modules but are dated 2:27
1901 do not get a module icon in a filer window Ö this is a property of
unstamped files from AASM/OBJASM.
2.11
2) Edit does not work properly in modes 2,4 or 5. (But who would want to
do so?! Ed.)
2.11
3) You can drag a directory into itself creating an copy within a copy
until disc space runs out. (Could that be the answer to the Élibrary
virusæ in the Help!!! section? Ed.)
2.11
4) Resizing the interactive help window can cause the mouse pointer to
move autonomously up the screen. Try it: Hold button down and resize it,
keep holding, and it will go for a certain window size always.
2.11
Å MaxGammon under RISC-OS Ö If you have a copy of this game, the
author has a version which works in the desktop. Send your original disk
and a S.A.E. to 11 Maryland, Barkham, Wokingham, Berkshire RG11 4PB and
you can have an upgrade to the newer version.
2.11
Å Last line in program Ö To find the last line in a BASIC program
which is in memory, hold down <ctrl>+<shift> and then press <escape>
twice.
2.11
Å Hearsay Problems Ö It is still possible to select a route from the
screen when in a scrolling terminal, but it must be a Élongæ click. A
short click tries to home the cursor to where the pointer is by sending
a string of control codes. The answer is to hold the button down a bit
longer or use the keyboard.
2.11
If you have problems with Xmodem make sure that Vasscomm is turned off.
2.11
Å Filer_OpenDir Ö When using Filer_OpenDir, it is important to get the
full pathname correct. For instance, if your hard disc has the name
ÉFredæ and you want to open the directory $.Foo, you should use:
2.11
*Filer_OpenDir adfs::Fred.$.Foo
2.11
and not something like:
2.11
*File_OpenDir adfs::4.Foo
2.11
The reason is that when you click on the drive icon, the Filer checks
the list of open windows to see if the requested pathname is already
visible. Unfortunately it is not too intelligent about this, and if the
names do not match exactly, the Filer will open another window. This
will have the side effect that when Dismount is used only windows with
the first pathname will be closed.
2.11
Å Legal Text Scaling for Multisyncs Ö Richard Averillæs hint last
month (Archive 2.10 pp 19/20) to help rescale text in multisync modes
could be done more legally using:
2.11
VDU 23,17,7,flags,x;y;0,0
2.11
flags => bit 0 = not implemented
2.11
bit 1 = 1 => set size of VDU 5 characters
2.11
bit 2 = 1 => set size of VDU 5 spacing
2.11
10 REM > CharSize Demonstration
2.11
of changing character size
2.11
20 REM By Martin Simmons 10/07/89
2.11
30
2.11
40 MODE 12
2.11
50
2.11
60 VDU 5:CLS:PRINTÉæ
2.11
70 GCOL 1
2.11
80 PROCprint(8,16,öDouble heightò)
2.11
90 PRINT
2.11
100 GCOL 2
2.11
110 PROCprint(16,8,öDouble widthò)
2.11
120 PRINT
2.11
130 GCOL 3
2.11
140 PROCprint(16,16,öDouble sizeò)
2.11
150 PRINT
2.11
160 GCOL 5
2.11
170 PROCprint2(8,8,16,16,öDouble
2.11
spacedö)
2.11
180 GCOL 7
2.11
190 PROCprint(8,4,öMangled half
2.11
heightö)
2.11
200 PRINTÉæ
2.11
210 GCOL 6
2.11
220 PROCprint(120,120,öBIGò)
2.11
230 VDU 4
2.11
240 END
2.11
250
2.11
260 DEF PROCprint(X%,Y%,text$)
2.11
270 VDU 23,17,7,6,X%;Y%;0,0
2.11
280 PRINT text$
2.11
290 ENDPROC
2.11
300
2.11
310 DEF PROCprint2(X%,Y%,sx%,sy%
2.11
,text$)
2.11
320 VDU 23,17,7,2,X%;Y%;0,0
2.11
330 VDU 23,17,7,4,sx%;sy%;0,0
2.11
340 PRINT text$
2.11
350 ENDPROC
2.11
2.11
Å ARM assembler T option Ö Martyn Lovell says that although the
assembler sees the T option for the LDR mnemonic the same as the !
option (Archive 2.10 p 9), it is not used in the same way. The ! option
should be used to force write back with pre-indexed addressing while the
T option should be used with post-indexed addressing to cause the -TRAN
pin on the ARM to go low for the duration of the data transfer. This is
used by an OS in non-user modes to allow the OS to generate a user-mode
address.
2.11
Å ALTernative keys Ö The RISC-OS Inter-nationalKeyboard module
provides the facility for typing control characters by holding down
<alt> and typing the number on the numeric keypad. In addition, the
following keys produce symbols when pressed with <alt> held down:
2.11
1 gives 1 2 gives 2 3 gives 3 ~ gives ┬
2.11
9 gives ▒ 0 gives √ , gives x . gives ╓
2.11
R gives ¿ Y gives ┤ S gives ñ Z gives ╟
2.11
X gives ╚ C gives ó M gives ╡
2.11
shifted C gives ⌐
2.11
Other keys return nothing. The old Arthur effect of using
<ctrl><shift><alt> to add 128 to the code can be produced by RMKILLing
this module. Doing this will also allow the use of <alt> plus a cursor
key in the BASIC Editor which does not work with this module installed.
2.11
Å Colour cursor for the BASIC Editor Ö Here is a little program which
will alter the ArmBE module so that you can change the colour of the
cursor.
2.11
10 REM > ColourEdit Make a colour
2.11
cursor for the BASIC Editor
2.11
20 REM By Martin Simmons 11/07/89
2.11
30 REM I use yellow background,
2.11
blue foreground, red cursor
2.11
(1=6 EOR 7)
2.11
40
2.11
50 colour%=6 :REM **** CHANGE
2.11
THIS LINE TO CHANGE THE
2.11
COLOUR (EOR 7) ****
2.11
60 DIM buf% &10000
2.11
70 OSCLI öLoad :App2.Modules.
2.11
BasicEdit ö+STR$~buf%
2.11
80 P%=buf%+&81E4
2.11
90 [ SWI &100+colour% ;Change
2.11
background palette
2.11
100 ]
2.11
110 zi%=buf%+&8320:zi%+=8+4*
2.11
((!zi%<<8)>>8)
2.11
120 wind%=buf%+&8310:wind%+=8+4*
2.11
((!wind%<<8)>>8)
2.11
130 P%=buf%+&8310
2.11
140 [ SWI öOS_WriteSò
2.11
150 EQUB 17 : EQUB 128+colour%
2.11
;Set background colour
2.11
160 EQUB 12 ;Clear screen
2.11
170 EQUB 23 : EQUB 16 : EQUB 1
2.11
;Set cursor movement
2.11
180 EQUS STRING$(4-(P% AND 3)
2.11
,CHR$0)
2.11
190 BL zi%
2.11
200 BL wind%
2.11
210 ]
2.11
220 INPUTÉöEnter new file name for
2.11
the editor: öfile$
2.11
230 OSCLI öSave ò+file$+ö ò+STR$
2.11
~buf%+ö +94B4ò
2.11
240 OSCLI öSetType ò+file$+ö FFAò
2.11
2.11
Å Wild card copy for RISC-OS Ö The destination parameter of the *Copy
command now has greater freedom regarding wild cards i.e. wildcards in
the destination can be used even though they were not used for the
source
2.11
e.g. *COPY :0.Text :1.* is now valid.
2.11
Å RISC-OS disc names Ö It is possible to set a system variable which
will behave like a disc name. If you *Set <discname>$Path <filepath> you
can then access you files by :<discname>.<filename>. For example:
2.11
*Set W App1:$.
2.11
*Run W:!Edit
2.11
You can even define several paths, just like File$Path and Run$Path:
2.11
*Set W App1:$.,App2:$.
2.11
*RMLoad W:Modules.BasicEdit
2.11
*Run W:!Edit
2.11
Å Memory Usage Ö Gerald Fitton Ö Of course, the Ébestæ machine has
both hard disc and 4Mb of memory, but some hard disc machines have less
memory. If you have the Ébestæ then you will probably put all the
!(application) directories that you use in your root ($) directory for
instant access. When you click on the :4 icon in the icon bar, all your
application !Boot files will be RUN and memory will be allocated to each
application (so that it is instantly available). This is true even when
the applications are not installed on the icon bar. If you have less
memory, say 1Mb, then you may find that your dormant applications are
using up too much memory for some of the more sophisticated appli
cations. The solution is to put your applications not in the root
directory but in a (non-!) sub-directory. For example, !Patience can be
put together with !Zarch in a games directory, where Games is in the
root directory. This way, only when you open the Games directory (by
double clicking on it) will you use up memory on the dormant appli
cations !Patience and !Zarch.
2.11
Å 1st Mail solution Ö When using 1st Mail in RISC-OS, the printer
options are hidden underneath another window. Mr Burrows has solved the
problem by altering the template file:
2.11
*Load $.Resources.1wp.
2.11
1ml_templa 9000
2.11
!&9AA8=155
2.11
!&9AB0=1023
2.11
*Save $.Resources.1wp.
2.11
1ml_templa 9000+AEA
2.11
*SetType $.Resources.1wp
2.11
.1ml_templa FFF
2.11
Å RISC-OS Hints and Tips Ö S C Costin Ö When using !PrinterDM on the
Desktop to print a text file, if the printer and Archimedes are set up
where there are no ignore characters configured, i.e. can be checked as
follows:
2.11
F12 ;Press function key 12 from desktop
2.11
*status ignore ;Enter command
2.11
No ignore ;Returned after entering command
2.11
The problem is that the line feed is suppressed and therefore over-
printing occurs. This is easily overcome by clicking on the !PrinterDM
icon on the icon bar, which produces a window, and selecting CR or LF
conversion.
2.11
A more permanent solution is to edit the file PrData. To do this hold
shift key while clicking on the application directory !PrinterDM, then
drag PrData icon over Edit icon on the icon bar and release the mouse
button. At the end of the printer driver data change line: from 0 to 1
i.e. change line:
2.11
0;0/1 1=>convert CR or LF to CR,LF
2.11
to:
2.11
1;0/1 1=>convert CR or LF to CR,LF
2.11
Å Pipedream conversion to ADFS E type floppy disc by S C Costin
2.11
1) Format new disc using the new E format.
2.11
2) Name the new disc NewPd.
2.11
3) Backup your original copy to the disc NewPd, using *COPY to retain
E format.
2.11
4) Copy the !PipeDream application from the support disc to the root
directory of disc NewPd.
2.11
5) Copy the Floating Point Emulator module from directory
!System.Modules on Application Disc 1 into directory $.!PipeDream on
disc NewPd.
2.11
6) Delete $.!boot
2.11
7) Delete $.piped.fpe2
2.11
8) Delete $.rs423drive
2.11
9) Add the following obey file called $.!boot
2.11
| > $.!boot
2.11
*quit
2.11
RUN $.!pipedream.!run
2.11
10) Leave the !PipeDream.!boot file as copied from the support disc.
2.11
| > !PipeDream.!Boot
2.11
Set PipeDream$Dir <Obey$Dir>
2.11
Set Alias$@RunType_DDE Run <PipeDream$Dir>.!Run %%*0
2.11
Set File$Type_DDE PDream
2.11
IconSprites <PipeDream$Dir>
2.11
.!Sprites
2.11
11) If mouse cursor control is required insert lines 7 & 8 in the !Run
Obey file as follows:
2.11
| > !PipeDream.!Run
2.11
Set PipeDream$Dir <Obey$Dir>
2.11
WimpSlot -min 450k
2.11
||RMReInit InternationalKeyboard
2.11
RMKill InternationalKeyboard
2.11
RMEnsure FPEmulator 2.60
2.11
RMLoad <Obey$Dir>.FPEmulator
2.11
$.piped.cursorrm
2.11
mousecursor on 13 &c5 131
2.11
Set Alias$@RunType_DDE Run <PipeDream$Dir>.!Run %%*0
2.11
Set File$Type_DDE PDream
2.11
IconSprites <PipeDream$Dir>
2.11
.!Sprites
2.11
Load $.Library.pd 8000
2.11
Echo <26>
2.11
Pointer 0
2.11
Go 8000 ; %*0
2.11
Å Update for Artisan and ProArtisan Ö Clares have now produced an
application which will up-date your Artisan and ProArtisan discs for
RISC-OS. It has been put on both this monthæs and last monthæs program
discs. Many thanks to Duncan Burbridge, Kimba, Australia (age 12) who
also sent us information on updating Artisan for RISC-OS.
2.11
Å Not enough screen memory? Ö If a program expects to run in a
specific screen mode and not enough screen memory is available, it will
usually report a ÉBad Modeæ error when run from the desktop, as the
screen memory canæt be expanded dynamically once the application has
started. This can be fixed by either dragging the screen memory bar in
the task window, or by entering the appro-priate mode first. A much
more elegant way is to add the following line to the Obey file that
starts the program: Echo <22><n> Where <n> is the mode. This ensures
that the screen memory is allocated before the application starts and
should appear before the *WimpSlot command.
2.11
Å Uncluttered cataloging Ö RISC-OS has a neat way of searching a disc
without cluttering the screen. Use <adjust> to open a directory and it
closes the one you were in, leaving only the new dir-ectory on the
screen. To move back up the tree, click <adjust> on the close icon, and
the next directory up will appear, closing the current directory (unless
you are in the root directory, of course!).
2.11
Å Bye bye hard disk! Ö The RAM disc is fantastic but not much use on 1
Mbyte machines. Also, note that when RAMFS is selected *bye does not
park the head of the Winchester Ö so beware!!!
2.11