./start.sh 3000 {localhost or surise}This calls "rise_gui", the code for which is in:
/RoboDevel/RiSE/OCUCode/RiSEGUI/rise_gui.ccThis calls stuff which is in:
/RoboDevel/RiSE/OCUCode/RiSEGUI/RiSEGUI.hh /RoboDevel/RiSE/OCUCode/RiSEGUI/RiSEGUI.ccSo anyway, back to rise_gui.cc... The arguments you pass in are:
3000 = local_port which is used for the logger--so it knows how to store the data files or something. surise or localhost = hostname remote port defaults to 5000 -- this is what rport is set toConstructor for
RiSEGUI::RiSEGUI(unsigned short local_port, char *hostname, unsigned short dest_port, int db_id) : BaseGUI( local_port, hostname, dest_port, db_id, CONFIG_FILE, NULL ) { _health_gui = new RiSEHealthGUI( _dbClient ); _sim_gui = new RiSESimGUI( _dbClient ); }So when you call
RiSEGUI( 3000 == local_port, surise == hostname, 5000 == dest_port, 100 == db_id )Note that there are several functions that are derived from
/RoboDevel/Libraries/GUILib/include/BaseGUI.hh /RoboDevel/Libraries/GUILib/BaseGUI.ccIn rise_gui.cc:
int main( int argc, char *argv[] ) { int i; bool connect = false; Fl::args(argc, argv, i); if ( argc-i == 1 || argc-i > 3 ) { fprintf(stderr, "Usage: %s [fltk options] [local_port hostname [remote_port]]\n" "remote port defaults to 5000\n","rise_gui"); exit(1); } if ( argc-i == 0) rise_gui = new RiSEGUI(); else { unsigned int rport = 5000; if (argc-i == 3) rport = atoi(argv[i+2]); rise_gui = new RiSEGUI(atoi(argv[i+0]), argv[i+1], rport, 100); connect = true; } signal( SIGINT, sigcatch ); signal( SIGTERM, sigcatch ); rise_gui->addHandler("risecalibmode", new RiSECalibGUI( rise_gui ) ); // rise_gui->addHandler("sitmode", new SitGUI(rise_gui)); // rise_gui->addHandler("walkmode", new WalkGUI(rise_gui)); rise_gui->show(argc, argv); if (connect) rise_gui->connect(); rise_gui->run(); }