| 1 | package Lab::Moose::Instrument::SCPI::Sense::Sweep; | ||
| 2 | #ABSTRACT: Role for the SCPI SENSe:SWEep subsystem | ||
| 3 | 4 | $Lab::Moose::Instrument::SCPI::Sense::Sweep::VERSION = '3.881'; | |
| 4 | 4 | ▶ | use v5.20; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 5 | |||
| 6 | 4 | ▶ | use Moose::Role; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 7 | 4 | ▶ | use Lab::Moose::Instrument::Cache; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 8 | use Lab::Moose::Instrument | ||
| 9 | 4 | ▶ | qw/validated_channel_getter validated_channel_setter/; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 10 | 4 | ▶ | use MooseX::Params::Validate; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 11 | 4 | ▶ | use Carp; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 12 | |||
| 13 | 4 | ▶ | use namespace::autoclean; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 14 | |||
| 15 | |||
| 16 | 4 | cache sense_sweep_points => ( getter => 'sense_sweep_points_query' ); | |
| 17 | |||
| 18 | sub sense_sweep_points_query { | ||
| 19 | 4 | ▶ | my ( $self, $channel, %args ) = validated_channel_getter( \@_ ); |
|
Subroutine
sense_sweep_points_query: called CC=1 SCAR=0.0
Pod
documented
| |||
| 20 | |||
| 21 | 4 | return $self->cached_sense_sweep_points( | |
| 22 | $self->query( command => "SENS${channel}:SWE:POIN?", %args ) ); | ||
| 23 | } | ||
| 24 | |||
| 25 | sub sense_sweep_points { | ||
| 26 | 8 | ▶ | my ( $self, $channel, $value, %args ) = validated_channel_setter( \@_ ); |
|
Subroutine
sense_sweep_points: called CC=1 SCAR=0.0
Pod
documented
| |||
| 27 | |||
| 28 | 8 | $self->write( command => "SENS${channel}:SWE:POIN $value", %args ); | |
| 29 | 8 | $self->cached_sense_sweep_points($value); | |
| 30 | } | ||
| 31 | |||
| 32 | |||
| 33 | 4 | cache sense_sweep_count => ( getter => 'sense_sweep_count_query' ); | |
| 34 | |||
| 35 | sub sense_sweep_count_query { | ||
| 36 | 2 | ▶ | my ( $self, $channel, %args ) = validated_channel_getter( \@_ ); |
|
Subroutine
sense_sweep_count_query: called CC=1 SCAR=0.0
Pod
documented
| |||
| 37 | 2 | return $self->cached_sense_sweep_count( | |
| 38 | $self->query( command => "SENS${channel}:SWE:COUN?", %args ) ); | ||
| 39 | } | ||
| 40 | |||
| 41 | sub sense_sweep_count { | ||
| 42 | 1 | ▶ | my ( $self, $channel, $value, %args ) = validated_channel_setter( \@_ ); |
|
Subroutine
sense_sweep_count: called CC=1 SCAR=0.0
Pod
documented
| |||
| 43 | |||
| 44 | 1 | $self->write( command => "SENS${channel}:SWE:COUN $value", %args ); | |
| 45 | 1 | $self->cached_sense_sweep_count($value); | |
| 46 | } | ||
| 47 | |||
| 48 | |||
| 49 | 4 | cache sense_sweep_time => ( getter => 'sense_sweep_time_query' ); | |
| 50 | |||
| 51 | sub sense_sweep_time_query { | ||
| 52 | 0 | ▶ | my ( $self, $channel, %args ) = validated_channel_getter( \@_ ); |
|
Subroutine
sense_sweep_time_query: not called CC=1 SCAR=6.9
Pod
documented
| |||
| 53 | 0 | return $self->cached_sense_sweep_time( | |
| 54 | $self->query( command => "SENS${channel}:SWE:TIME?", %args ) ); | ||
| 55 | } | ||
| 56 | |||
| 57 | sub sense_sweep_time { | ||
| 58 | 0 | ▶ | my ( $self, $channel, $value, %args ) = validated_channel_setter( \@_ ); |
|
Subroutine
sense_sweep_time: not called CC=1 SCAR=6.9
Pod
documented
| |||
| 59 | |||
| 60 | 0 | $self->write( command => "SENS${channel}:SWE:TIME $value", %args ); | |
| 61 | 0 | $self->cached_sense_sweep_time($value); | |
| 62 | } | ||
| 63 | |||
| 64 | 4 | 1; | |
| 65 | |||
| 66 | __END__ | ||
| 67 | |||
| 68 | =pod | ||
| 69 | |||
| 70 | =encoding UTF-8 | ||
| 71 | |||
| 72 | =head1 NAME | ||
| 73 | |||
| 74 | Lab::Moose::Instrument::SCPI::Sense::Sweep - Role for the SCPI SENSe:SWEep subsystem | ||
| 75 | |||
| 76 | =head1 VERSION | ||
| 77 | |||
| 78 | version 3.881 | ||
| 79 | |||
| 80 | =head1 METHODS | ||
| 81 | |||
| 82 | =head2 sense_sweep_points_query | ||
| 83 | |||
| 84 | =head2 sense_sweep_points | ||
| 85 | |||
| 86 | Query/Set the number of points in the sweep. | ||
| 87 | |||
| 88 | =head2 sense_sweep_count_query | ||
| 89 | |||
| 90 | =head2 sense_sweep_count | ||
| 91 | |||
| 92 | Query/Set the number of sweeps initiated by a trigger (like INIT). | ||
| 93 | |||
| 94 | =head2 sense_sweep_time_query | ||
| 95 | |||
| 96 | =head2 sense_sweep_time | ||
| 97 | |||
| 98 | Query/Set the sweep time in which the spectrum analyzer sweeps the required frequency range. | ||
| 99 | |||
| 100 | =head1 COPYRIGHT AND LICENSE | ||
| 101 | |||
| 102 | This software is copyright (c) 2023 by the Lab::Measurement team; in detail: | ||
| 103 | |||
| 104 | Copyright 2016 Simon Reinhardt | ||
| 105 | 2017 Andreas K. Huettel, Simon Reinhardt | ||
| 106 | 2018 Eugeniy E. Mikhailov | ||
| 107 | 2020 Andreas K. Huettel | ||
| 108 | |||
| 109 | |||
| 110 | This is free software; you can redistribute it and/or modify it under | ||
| 111 | the same terms as the Perl 5 programming language system itself. | ||
| 112 | |||
| 113 | =cut | ||