The Memory of PC-1360


Index


The program area



Line structure:

3 bytes (x,y,z), data, return (Chr 13)
x,y: line number = x*256+y
z: length of data (return included)
End of program Chr (255)
The byte 254 in data of a line means a command which is defined by the following byte.

Variable structure (DIM):

7 bytes (a,b,c,d,e,f,g), Data
In 65502*256+65501 the start address of the variables is stored.
The last position where variables are stored: 63951
Variables are written from behind, this means that a new variable is written before the older variables. The start address points to the header of the newest variable.
You can rename variables using POKE!

Header structure:

7 bytes lengthy

Example: Bytes are named a-g
G$(5,5)*3
a: 71 = G: variable name
b: 160 = String
c: 0 = 1.Byte * 256
d: 111 = + 2.Byte = Overall length + 3 (because of following DIM values)
e: 5 = Dim 5
f: 5 = , 5
g: 3 = * 3
DATA:71= 1. character data

Meaning of the second header byte:

1-26 = Stringarray, 2 character name with second character = Chr (Byte+64)
193-218 = Number array, 2 character name with second char = Chr (Byte-128)
129-154 = String, 2 character name [Chr (Byte-64)] variable (like NE$="test") always 16 bytes lengthy
65-90 = Number, 2 character name [Chr (Byte)] (like AA=0) always 8 byte lengthy
128: One character name number array
160: One character name string array

Data of a variable:

Strings contain each character as a byte in ASCII code, Chr(0) is the end of a string. The Chr(0) is not used when the text is as long as the variable is dimensioned.
Numbers are stored in the BCD format. Each number needs 7 bytes.
In an array the single variables are following without any divider character. The position of such a variable is calculated using the header data. In a twodimensional array the arrays are following in a similar way: DIM B$(1,2)*1: B$(0,0) B$(0,1) B$(0,2) B$(1,0) B$(1,1) B$(1,2).

New big characters 18*2:

Characters 18*2 lines: POKE 64775,18,2
Characters 24*4 lines: POKE 64775,24,4
Cursor position at i.e. 64777 column and line at 64778 (starting with 0)
After switch off the old 24*4 is restored!
(Using 18*2 you can get Japan symbols from ASC 166 bis 222!)

Access to the display:

There are 5 columns with each 30 pixels width in 4 lines 8 pixels. Each stripe of 8 pixel is like a "GPRINT" byte, the value 1 will set the top pixel and 128 the bottom pixel! The distance of the memory locations of each column is 512 bytes, the memory is mapped in a distance of 256 bytes.

  SHARP  POCKET COMPUTER PC-1360
1: 10240..10269
10496..10525
1: +512
10752..10781
11008..11037
1: +1024
11264..11293
11520..11549
1: +1536
11776..11805
12032..12061
1: +2048
12288..12317
12544..12573
2: 10304..10333
10560..10589
2: 10816..10845
11072..11101
2:
11328..11357
11584..11613
2:
11840..11869
12096..12125
2:
12352..12381
12608..12637
3: 10270..10299
10526..10555
3: 10782..10811
11038..11067
3:
11294..11323
11550..11579
3:
11806..11835
12062..12091
3:
12318..12347
12574..12603
4: 10334..10363
10590..10619
4: 10846..10875
11102..11131
4:
11358..11387
11614..11643
4:
11870..11899
12126..12155
4:
12382..12411
12638..12667

The symbols RUN, PRO, SHIFT, SML are set in byte 12348:

BitSymbol
0Shift
1Def
2-
3-
4Run
5Pro
6Japan. symbols left: Makes the keys work odd!
7Sml



System area:




-System variables (each 8 bytes long):
VarAddressHBLB
Z63952249208
Y63960249216
X63968249224
W63976249232
V63984249240
U63992249248
T640002500
S640082508
R6401625016
Q6402425024
P6403225032
O6404025040
N6404825048
M6405625056
L6406425064
K6407225072
J6408025080
I6408825088
H6409625096
G64104250104
F64112250112
E64120250120
D64128250128
C64136250136
B64144250144
A64152250152
The first byte of each variable is CHR 245 when containing a string or CHR 0 when containing a number. If the string is shorter than 7 characters, a Chr(0) is added at the end!

-  Reserve mode data: 65343:A:first reserve entry, Chr (alphabetical number) marks beginning (A=1,S=19,D=4,...,' '=27,'='=28), then data without any ending code. Example: [1,254,34],[19,...],...
Order:ASDFGHJKL'='' 'MNBVCXZ, empty entries are not stored (not even the start code 1-28!)

-  Other memory locations: At 64336 to 64378 there are pieces of inputs.
At 64896 to 64991 you can read the display characters line by line: The first 24 bytes represent the first line, the next 24 the second line, etc.

System addresses:

LBHBDescription
&FFD7&FFD8Points to the 255 before the BASIC area
&FFD9&FFDAPoints to the 255 after the BASIC area
&FFDB&FFDCPoints to the last block added with MERGE
&FEF0&FEF1Points to the start of the BASIC area where the system is currently running.
&FD04-Input buffer pointer
&FF31-EOT Code (SIO)
&FF32-Baud rate (SIO)
&FF33-F/F Interface status
&FF34-CONSOLE value
&FEE8&FEE9Graphic cursor position X (-32768 to 32767)
&FEEA&FEEBGraphic cursor position Y (-32768 to 32767)
&FD09&FD0AText cursor position (LB->X: 0-23, HB->Y: 0-3)
&FEEC&FEEDEnd position of the last LINE (X) (-32768 to 32767)
&FEEE&FEEFEnd position of the last LINE (Y) (-32768 to 32767)
&FD16-Cursor position in input buffer
&FD10&FD11Display pointer (LB->X: 0-23, HB->Y: 0-3)
&287E&287FWAIT counter
&FF02-ASCII code of the blinking character at the cursor
&FF00&FF01Address of the blinking character in the display buffer
&FE00-FOR..NEXT return address in the Stack
&FE01-GOSUB..RETURN return address in the stack
&FEE0-USING format (point or comma)
&FEE1-USING integer part
&FEE2-USING character part
&FEE3-USING decimal point
&FFDD&FFDEVariable pointer
&FEF2&FEF3Address of the preceeding line
&FEF4&FEF5BREAK address
&FEF6&FEF7ERROR address
&2ABD&2ABEDATA pointer
&2A7E&2A7FAuto power off counter
&FFF6&FFF7Beginning of the RAM card
&FFF8&FFF9End of the RAM card
&FF40to &FFCFReserve mode memory
&FF3F-Length of all reserve mode data
&FD20to &FD6FInput buffer
&FD80to &FDDFDisplay as ASCII code
&FC60to &FCAFString buffer
&FAA0to &FAFFPrinter buffer

-  The ROM: The PC-1360 has a ROM, which contains the operating system. The ROM of the CPU is at &0000 to &1FFF, the banks are at &4000 to &7FFF. You can change the bank writing the according number (0..7) at the address &3400. If you know the system calls you can use functions of the system!

System test

By pressing R+V+7+1 together while switching on the self test menu will appear!

BASIC commands

Index positionCommandTokenAddressBank
22761ASC2087936BANK: Int. ROM
22768AND1610BANK: ?*
22775ABS1537908BANK: Int. ROM
22782ATN1597896BANK: Int. ROM
22789ASN1577888BANK: Int. ROM
22796ACS1587892BANK: Int. ROM
22803AREAD996222BANK: ?*
22812AKCNV$2240BANK: ?*
22822APPEND1144288BANK: ?*
22832AS1154288BANK: ?*
22838ARUN1166222BANK: ?*
22846AUTOGOTO1176222BANK: ?*
22858BEEP4116544BANK: 2
22866BASIC5416400BANK: 2
22875CONT1816439BANK: 2
22883CONSOLE3616418BANK: 4
22894CLEAR4616409BANK: 2
22903CLOAD2216421BANK: 4
22912CSAVE3216424BANK: 4
22921COS1507880BANK: Int. ROM
22928CHR$2407940BANK: Int. ROM
22936CLOSE3416448BANK: 5
22945CALL4931485BANK: ?*
22953CLS8016445BANK: 2
22960CHAIN10316385BANK: 5
22969CURSOR8116526BANK: 2
22979COPY6116388BANK: 5
22987CSIZE6716421BANK: 3
22996COLOR6816418BANK: 3
23005CROTATE11016412BANK: 3
23016CIRCLE11116415BANK: 3
23026DIM4816397BANK: 2
23033DEGREE3816448BANK: 2
23043DEG1557900BANK: Int. ROM
23050DMS1567904BANK: Int. ROM
23057DATA946222BANK: ?*
23065DSKF1770BANK: ?*
23073DELETE2716385BANK: 2
23083END9016451BANK: 2
23090EXP1477872BANK: Int. ROM
23097EOF1760BANK: ?*
23104ERASE5816406BANK: 2
23113FOR8716457BANK: 2
23120FILES2816391BANK: 5
23129GOTO4316460BANK: 2
23137GOSUB9816463BANK: 2
23146GPRINT5116466BANK: 2
23156GCURSOR10416469BANK: 2
23167GRAD4016472BANK: 2
23175GRAPH6516427BANK: 3
23184GLCURSOR10816424BANK: 3
23196INPUT9716403BANK: 1
23205IF8616475BANK: 2
23211INT1527912BANK: Int. ROM
23218INKEY$2330BANK: ?*
23228LNIT2917164BANK: ?*
23236JIS$2260BANK: ?*
23244KILL6017168BANK: ?*
23252KLEN2110BANK: ?*
23260KMID$2370BANK: ?*
23269KLEFT$2380BANK: ?*
23279KRIGHT$2390BANK: ?*
23290KACNV$2250BANK: ?*
23300LIST2017031BANK: ?*
23308LLIST2117131BANK: ?*
23317LPRINT10017135BANK: ?*
23327LOG1460BANK: ?*
23334LOF1780BANK: ?*
23341LOC1790BANK: ?*
23348LN1457932BANK: Int. ROM
23354LOAD2417176BANK: ?*
23362LINE10516899BANK: ?*
23370LET8816903BANK: ?*
23377LEN2100BANK: ?*
23384LEFT$2350BANK: ?*
23393LFILES5917172BANK: ?*
23403LTEXT6417082BANK: ?*
23412LF6617078BANK: ?*
23418LLINE10617074BANK: ?*
23427MEM1750BANK: ?*
23434MID$2340BANK: ?*
23442MERGE2317196BANK: ?*
23451MDF1280BANK: ?*
23458NEXT9116907BANK: ?*
23466NAME6217180BANK: ?*
23474NOT1630BANK: ?*
23481NEW1716911BANK: ?*
23488ON8516995BANK: ?*
23494OPEN3317184BANK: ?*
23502OPEN$2320BANK: ?*
23511OR1620BANK: ?*
23517OUTPUT1134288BANK: ?*
23527PRINT9616804BANK: ?*
23536PASS1916915BANK: ?*
23544PI1740BANK: ?*
23550PEEK1640BANK: ?*
23558POKE5031586BANK: ?*
23566POINT1730BANK: ?*
23575PSET5216919BANK: ?*
23583PRESET5316923BANK: ?*
23593PAUSE9516808BANK: ?*
23602PAINT11217086BANK: ?*
23611RUN1616927BANK: ?*
23618RETURN10116999BANK: ?*
23628READ9316931BANK: ?*
23636RESTORE10216935BANK: ?*
23647RND1607920BANK: Int. ROM
23654RANDOM3729480BANK: ?*
23664RIGHT$2360BANK: ?*
23674RADIAN3916939BANK: ?*
23684REM896202BANK: ?*
23691RENUM2516979BANK: ?*
23700RLINE10717090BANK: ?*
23709STOP9217003BANK: ?*
23717SQR1487924BANK: Int. ROM
23724SIN1497876BANK: Int. ROM
23731SGN1547916BANK: Int. ROM
23738STR$2417944BANK: Int. ROM
23746SAVE3517188BANK: ?*
23754STEP834288BANK: ?*
23762SET6317192BANK: ?*
23769SORGN10917094BANK: ?*
23778THEN844288BANK: ?*
23786TAN1517884BANK: Int. ROM
23793TEXT5516943BANK: ?*
23801TRON4416947BANK: ?*
23809TROFF4516951BANK: ?*
23818TO824288BANK: ?*
23824USING4716955BANK: ?*
23833VAL2097948BANK: Int. ROM
23840WAIT4216959BANK: ?*
23848WIDTH5617007BANK: ?*

-  The CPU and Gate Array:

CPU


Gate Array






Copyright © Simon Lehmayr (Parts of my page were made with the help of Laurent Duveau)
If this page has no navigation, click here.
Impressum