New Wiki page: Utility class to log to file and console

"fransklip" <[email protected]>
Newsgroups gmane.comp.cybernetics.webot.contest
Message-ID <[email protected]>
Hello all:

Do you like to :
 * show information in your Judoka controller program's 
   console window when running in your development environment,
 * but at the same time have it stored in a file,
 * and automatically switch off the console output when your robot
   runs on the Webots Judo match server? 

Use this utility class "Log", a new publication on the Wiki pages
"Utility class to log to file and console" of the Judo contest, url:
http://cyberboticspc1.epfl.ch/judowiki/Utility_20class_20to_20log_20to_20file_20and_20console

Currently, the general log file of Webots is filled so much by the
currently competing Judoka programs that it cannot be published
anymore. Thus all contestants relying on this log file don't get any
log information anymore. This Log class enables each contestant to
have his own independent log file and at the same time relieves the
general log file. 

The Log class provides :
 * write a log line to console and to a log file;
 * prefix the line with the current simulation time;
 * prefix the line with a program identification string;
 * switch off console output when running on the match server;
 * but it is possible to force output to the console on the 
   match server (use this with care);
 * the correct name for the log file, so that you can download 
   it from your private file area on the match server
 * check in your program if it runs in test environment or not. 

The accompanying SimTime class provides the Log class with the
simulation time.


The published classes are slightly modified versions of the code that
has run for several weeks now in my own judoka controller Kimaita.

Good luck,

Frans (judoka Kimaita)


------------------------ Yahoo! Groups Sponsor ---------------------~-->
Buy Ink Cartridges or Refill Kits for your HP, Epson, Canon or Lexmark
Printer at MyInks.com. Free s/h on orders $50 or more to the US & Canada.
http://www.c1tracking.com/l.asp?cid=5511
http://us.click.yahoo.com/mOAaAA/3exGAA/qnsNAA/pU_rlB/TM
---------------------------------------------------------------------~->

To unsubscribe from this group, send an email to:
[email protected]

 

Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.