#!/usr/bin/perl

use Net::Telnet ();

$machine = '192.168.1.248';
$port = '1299';

$t = new Net::Telnet (Timeout => 10,Port=>$port);
$t->open('femto.febo.com');
$t->waitfor("/=192.168.1.248 >/");
@lines = $t->cmd("show inputs");

@tmp = split(/ /,$lines[1]);
$input_freq = $tmp[2];
$input_ampl = $tmp[5];
$input_scale = 1/($input_freq*1e6);

@tmp = split(/ /,$lines[2]);
$ref_freq = $tmp[2];
$ref_ampl = $tmp[5];

$t->print("exit");
$t->close;
