User`s guide
2-25
GPIB Tutorial and Examples
Program 1
3090 UNTIL Reparfcn=Arfcn OR Time=Maxtime !If reported ARFCN
matches programmed ARFCN
3100 IF Time=Maxtime THEN !FACCH handshake is
complete and mobile is on
3110 Errcount=Errcount+1 !new channel.
3120 Error$(Errcount)=”Mobile failed channel assignment” !If mobile fails to
reach new channel, set an error
3130 END IF !Now mobile is stable
on new Tx level and ARFCN
3140 OUTPUT Uut;”MEAS:FTCP:POW?” !read the peak power
meter
3150 ENTER Uut;Fpwrmeas(Arcount,Txcount)
3160 OUTPUT Uut;”RFAN:AMPL1?” !Read the
Agilent 8922M/S analyzer expected input level
3170 ENTER Uut;Anlevel !and compare with the
measured power to check that
3180 Threedb=ABS(Anlevel-Fpwrmeas(Arcount,Txcount)) !the result is within
the allowed +/-3dB window
3190 IF Threedb>3 THEN
3200 Errcount=Errcount+1
3210 Error$(Errcount)=”Fast power meas 3dB input range exceeded”
3220 END IF
3230 NEXT Arcount
3240 NEXT Txcount
3250 CALL Sub_syserror(Uut,Error$(*),Errcount) !Check Agilent 8922M/
S error log
3260 !
3270!================================================================================
====
3280 !
3290 !PERFORM BIT ERROR MEASUREMENTS
3300 !
3310 OUTPUT Uut;”DISP:SCR BER1” !Display single BER
test screen
3320 FOR Rxcount=1 TO Numberpwr !Outer loop for down-
link power levels
3330 Berpo=Berpwr(Rxcount) !Get downlink power
level from array
3340 OUTPUT Uut;”RFG:AMPL1 “;Berpo !Program Agilent 8922M/
S Generator to downlink power
3350 Count=0 !Establish a loop to
wait for the mobile’s receiver
3360 Instance=0 !AGC to recover from
downlink level change.
3370 REPEAT !The mobile’s reported
RXQual will indicate when
3380 OUTPUT Uut;”MEAS:CELL:SACCH:RESET” !the AGC has recov-
ered. Start by clearing old SACCH
3390 Count=Count+1 !The inner REPEAT loop
is used to check and wait
3400 Rxqualsettle=-1 !for the next SACCH
report from mobile. When the
3410 Time=0 !Agilent 8922M/S is
waiting for a report, after a SACCH
3420 REPEAT !reset it returns -1
3430 WAIT .3 !Pause. SACCH is a
low bandwidth channel.
3440 Time=Time+1
3450 OUTPUT Uut;”MEAS:CELL:SACCH:PARTIAL:RQU?” !Read the SACCH report
from the mobile
3460 ENTER Uut;Rxqualsettle !-1 is returned if
Agilent 8922M/S is still waiting
3470 UNTIL Time>7 OR Rxqualsettle<>-1 !for the report
3480 IF Rxqualsettle<=4 THEN !If RxQual is less
than 4, it’s good enough to
3490 Instance=Instance+1 !continue. The program
checks for more than