The verb eval invokes a Perl function that has been loaded before. Suppose we defined the package compton and the function pilatus_start in /online_dir/TkIrc.pl:
#
# part of a Perl file, e.g.: /online_dir/TkIrc.pl
#
package compton;
sub pilatus_start
{
my ( $scan_name, $sample_time, $sindex) = @_;
...
}
This function is invoked by the following .gra code:
!
! part of a .gra file or Online command line
!
eval compton::pilatus_start( $Spectra::SYM{ scan_name},
$Spectra::SYM{ sample_time},
$Spectra::SYM{ sindex})
Or it can be invoked from a Perl script:
use Spectra;
my $ret = compton::pilatus_start( $Spectra::SYM{ scan_name},
$Spectra::SYM{ sample_time},
$Spectra::SYM{ sindex});