IM34M06H54-01E-006
9/9
On pages 5-4 and 5-5, replace the sample program in Section 5.2,
“Sample Program Using BASIC Statements” with the following
program.
1000 ! F3XSO4 Sample program
1010 !
1020 DEFINT A-Z
1030 XS=4
1040 ASSIGN XS04=XS
1050 ! Setting CH1
1060 ! Input: rising edge, ring max. value=$FFFF, continue when value resets to $0, no filter
1070 ! Output: turns on when counter value resets to 0
1080 CONTROL XS,1;$4000
1090 CONTROL XS,2;$8000
1100 CONTROL XS,3;$0
1110 CONTROL XS,4;$40
1120 !
1130 Setting CH2
1140 ! Input: rising edge, ring max. value=19999, stop when value resets to $0, filter
1150 ! Output: turns on when counter value=preset value 1
1160 CONTROL XS,5;10000
1170 CONTROL XS,6;20000
1180 CONTROL XS,7;$E
1190 CONTROL XS,8;$1000
1200 !
1210 ! Setting CH3
1220 ! Input: falling edge, ring max. value=$FFFF, continue when value resets to $0, filter
1230 ! Output: turns on when counter is not running
1240 CONTROL XS,9;0
1250 CONTROL XS,10;0
1260 CONTROL XS,11;$9
1270 CONTROL XS,12;$2080
1280 !
1290 ! Setting CH4
1300 ! Input: falling edge, ring max. value=10, stop when value resets to $0, filter
1310 ! Output: always off
1320 CONTROL XS,13;0
1330 CONTROL XS,14;11
1340 CONTROL XS,15;$B
1350 CONTROL XS,16;$4100
1360 !
1370 ! Set filter constant for receiving
1380 ! Set to eliminate pulses below 32.7ms
1390 CONTROL,XS,17;14
1400 !
1410 ! Start counting for all channels
1420 CONTROL XS,102;$1111
1430 !
1440 LOOP@
1450 ! Read counter value for all channels
1460 ENTER XS NOFORMAT;CN(*)
1470 !
1480 ! Display all counter values
1490 PRINT CN(*)
1500 !
1510 GOTO LOOP@
1520 STOP
1530 END
Содержание F3XS04-3N
Страница 2: ...Blank Page ...
Страница 8: ...Blank Page ...
Страница 10: ...Blank Page ...
Страница 56: ...Blank Page ...
Страница 66: ...Blank Page ...