24 #include "../driver_tester/driver_tester.h" 25 #include "goby/acomms/modemdriver/mm_driver.h" 27 boost::shared_ptr<goby::acomms::ModemDriverBase> driver1, driver2;
29 int main(
int argc,
char* argv[])
34 <<
"usage: test_mmdriver1 /dev/ttyS0 /dev/ttyS1 [file to write] [mm version (1 or 2)]" 49 mm_version = goby::util::as<int>(argv[4]);
56 cfg1.set_serial_port(argv[1]);
59 cfg1.MutableExtension(micromodem::protobuf::Config::remus_lbl)->set_enable_beacons(7);
62 cfg1.SetExtension(micromodem::protobuf::Config::reset_nvram,
true);
63 cfg2.SetExtension(micromodem::protobuf::Config::reset_nvram,
true);
66 cfg1.AddExtension(micromodem::protobuf::Config::nvram_cfg,
"AGC,0");
67 cfg2.AddExtension(micromodem::protobuf::Config::nvram_cfg,
"AGC,0");
68 cfg1.AddExtension(micromodem::protobuf::Config::nvram_cfg,
"AGN,0");
69 cfg2.AddExtension(micromodem::protobuf::Config::nvram_cfg,
"AGN,0");
71 cfg2.set_serial_port(argv[2]);
74 std::vector<int> tests_to_run;
75 tests_to_run.push_back(0);
79 tests_to_run.push_back(1);
80 tests_to_run.push_back(2);
81 tests_to_run.push_back(3);
84 tests_to_run.push_back(4);
85 tests_to_run.push_back(5);
90 tests_to_run.push_back(6);
91 cfg1.AddExtension(micromodem::protobuf::Config::nvram_cfg,
"psk.packet.mod_hdr_version,0");
92 cfg2.AddExtension(micromodem::protobuf::Config::nvram_cfg,
"psk.packet.mod_hdr_version,0");
98 DriverTester tester(driver1, driver2, cfg1, cfg2, tests_to_run,
99 goby::acomms::protobuf::DRIVER_WHOI_MICROMODEM);
void set_name(const std::string &s)
Set the name of the application that the logger is serving.
provides an API to the WHOI Micro-Modem driver
common::FlexOstream glog
Access the Goby logger through this object.
void add_stream(logger::Verbosity verbosity=logger::VERBOSE, std::ostream *os=0)
Attach a stream object (e.g. std::cout, std::ofstream, ...) to the logger with desired verbosity...