Home » Archimedes archive » Acorn User » AU 1995-12 B.adf » Regulars » RuntheRISC/IIC2

RuntheRISC/IIC2

This website contains an archive of files for the Acorn Electron, BBC Micro, Acorn Archimedes, Commodore 16 and Commodore 64 computers, which Dominic Ford has rescued from his private collection of floppy disks and cassettes.

Some of these files were originally commercial releases in the 1980s and 1990s, but they are now widely available online. I assume that copyright over them is no longer being asserted. If you own the copyright and would like files to be removed, please contact me.

Tape/disk: Home » Archimedes archive » Acorn User » AU 1995-12 B.adf » Regulars
Filename: RuntheRISC/IIC2
Read OK:
File size: 0139 bytes
Load address: 0000
Exec address: 0000
Duplicates

There is 1 duplicate copy of this file in the archive:

File contents
   10REM> IIC2
   20CLS
   30PRINT "Read the Analogue inputs"
   40PRINT "By Mike Cook"
   50DIM PBK% 5, PBS% 4
   60?PBS%=&4
   70REM Set up the control register
   80SYS "IIC_Control",&90,PBS%,1
   90PRINT TAB(8,10);"IN 3";SPC(6);"IN 0";SPC(6);"IN 1";SPC(6);"IN 2"
  100REPEAT
  110PRINT TAB(0,12)
  120SYS "IIC_Control",&91,PBK%,4
  130PRINT ~PBK%?0,~PBK%?1,~PBK%?2,~PBK%?3
  140UNTIL FALSE

�> IIC2
�
 � "Read the Analogue inputs"
(� "By Mike Cook"
2� PBK% 5, PBS% 4
<?PBS%=&4
F!� Set up the control register
Pș "IIC_Control",&90,PBS%,1
Z7� �8,10);"IN 3";�(6);"IN 0";�(6);"IN 1";�(6);"IN 2"
d�
n� �0,12)
xș "IIC_Control",&91,PBK%,4
�%� ~PBK%?0,~PBK%?1,~PBK%?2,~PBK%?3
�� �
�
00000000  0d 00 0a 0b f4 3e 20 49  49 43 32 0d 00 14 05 db  |.....> IIC2.....|
00000010  0d 00 1e 20 f1 20 22 52  65 61 64 20 74 68 65 20  |... . "Read the |
00000020  41 6e 61 6c 6f 67 75 65  20 69 6e 70 75 74 73 22  |Analogue inputs"|
00000030  0d 00 28 14 f1 20 22 42  79 20 4d 69 6b 65 20 43  |..(.. "By Mike C|
00000040  6f 6f 6b 22 0d 00 32 14  de 20 50 42 4b 25 20 35  |ook"..2.. PBK% 5|
00000050  2c 20 50 42 53 25 20 34  0d 00 3c 0c 3f 50 42 53  |, PBS% 4..<.?PBS|
00000060  25 3d 26 34 0d 00 46 21  f4 20 53 65 74 20 75 70  |%=&4..F!. Set up|
00000070  20 74 68 65 20 63 6f 6e  74 72 6f 6c 20 72 65 67  | the control reg|
00000080  69 73 74 65 72 0d 00 50  1f c8 99 20 22 49 49 43  |ister..P... "IIC|
00000090  5f 43 6f 6e 74 72 6f 6c  22 2c 26 39 30 2c 50 42  |_Control",&90,PB|
000000a0  53 25 2c 31 0d 00 5a 37  f1 20 8a 38 2c 31 30 29  |S%,1..Z7. .8,10)|
000000b0  3b 22 49 4e 20 33 22 3b  89 28 36 29 3b 22 49 4e  |;"IN 3";.(6);"IN|
000000c0  20 30 22 3b 89 28 36 29  3b 22 49 4e 20 31 22 3b  | 0";.(6);"IN 1";|
000000d0  89 28 36 29 3b 22 49 4e  20 32 22 0d 00 64 05 f5  |.(6);"IN 2"..d..|
000000e0  0d 00 6e 0c f1 20 8a 30  2c 31 32 29 0d 00 78 1f  |..n.. .0,12)..x.|
000000f0  c8 99 20 22 49 49 43 5f  43 6f 6e 74 72 6f 6c 22  |.. "IIC_Control"|
00000100  2c 26 39 31 2c 50 42 4b  25 2c 34 0d 00 82 25 f1  |,&91,PBK%,4...%.|
00000110  20 7e 50 42 4b 25 3f 30  2c 7e 50 42 4b 25 3f 31  | ~PBK%?0,~PBK%?1|
00000120  2c 7e 50 42 4b 25 3f 32  2c 7e 50 42 4b 25 3f 33  |,~PBK%?2,~PBK%?3|
00000130  0d 00 8c 07 fd 20 a3 0d  ff                       |..... ...|
00000139