
Programming Guide 2-103
ESG Family Signal Generators Programming Commands and Examples
End of Sweep Service Request, Example Program 11
190 to 200: Setups HP BASIC to recognize the SRQ and branches to “Service Routine” when the SRQ is
received.
210: Program border
220 to 320: Sets up the signal generator for a 40 MHz to 900 MHz stepped single sweep.
330 to 350: Triggers the sweep.
370 to 420: An endless loop developed for the sake of this example. The program is stuck here forever or
until the signal generator generates an SRQ at the end of sweep. Then an Interrupt is
initiated and the program branches to Service_routine (Line 460).
470: A serial poll is used to read the signal generator Status Byte.
480 to 490: If Status Byte Bit 7 is true then the sweep is complete. Sets the value of the variable sweep
to 0 so the program can exit the endless loop after it returns.
510 to 530: Indicates that the SRQ cause is unknown.
540 to 550: Re-enables the Interrupt in HP BASIC then returns to the endless loop. If sweep is still set
to 1 the program is again stuck in the endless loop waiting for end-of-sweep. If an
end-of-sweep was detected, the program ends.
570 to 580: Ends the program.
Comentários a estes Manuais