The component manager reads the configuration file rtc.conf at startup. A configuration file is normally created with the name rtc.conf, but you can pass a configuration file created with any name.
rtc.conf is usually placed in the same directory as the RTC executable file (standalone component: xxxComp, xxxComp.exe executable RTC etc.) and its settings are loaded automatically. Alternatively, you can use the -f option to load a configuration file of arbitrary name. If rtc.conf is not in the same directory as the executable file or if it is not specified with the -f option, it reads rtc.conf placed on the system instead.
Reading priority of rtc.conf is set as follows.
In Windows, rtc.conf (usually C:\Program Files\OpenRTM-aist\(version number)\(Version of VC) placed under the directory specified by the environment variables "RTM_ROOT" and RTM_VC_VERSION )) Is loaded.
Below are the setting options of rtc.conf which is often used. In addition to the following options, various options can be specified in rtc.conf. For details rtc.conf setting item list.
Items related to the setting of the naming service are as follows.
It is specified by host_name: port_number, the default port is 2809 (omniORB default).
Multiple servers can be specified, and server name delimiter is comma ",".
%h.host_cxt/%n.rtc →host.host_cxt/MyComp.rtc
Multiple designation possible.
If you want to be compatible with 0.2.0,
%h.host_cxt/%M.mgr_cxt/%c.cat_cxt/%m.mod_cxt/%n.rtc
“YES” or “NO”
Automatic update setting of registration to the naming service.
Register the name again when the name service starts up after starting the component.
Update cycle [s]. The default is 10 seconds.
“YES” or “NO”
Manager timer valid/invalid. It must be valid to use naming.update.
Resolution of timer [s]. The default is 100 ms.
“YES” or “NO”
Enable/Disable log output.
Log file name.
%h: Host name, %M: Manager name, %p: Process ID usable
Date format. It conforms to the notation of strftime (3).
Default : %b %d %H:%M:%S → Apr 24 01: 02: 04 |
Log level: SILENT, ERROR, WARN, INFO, DEBUG, TRACE, VERBOSE, PARANOID.
Do not output anything (SILENT)~All output (PARANOID)
(*) Previously it could be used in RTC, but it can not be used now.
Specify the execution context to use.
at present, PeriodicExecutionContext, ExtTrigExecutionContext Can be used.
The default is PeriodicExecutionContext.
IP_Addr: Specified by Port. When there are multiple NICs, it specifies the ORB to listen on.
: Is required even if Port is not specified.
Example: corba.endpoint: 192.168.0.12
Please specify when there are two NICs. (It may happen by chance even if not specified.)
Argument for CORBA. For details, refer to omniORB manual.
[Category name].[Component name].config_file | [Category name].[Instance name].config_file | Component configuration file Category name: manipulator, component name: myarm, instance name myarm 0, 1, 2 ...
manipulator.myarm.config_file: arm.conf Or manipulator.myarm0.config.file: arm0.conf
For standalone components, or RTC daemon (rtcd), you can specify several options on the command line. The following table shows the command line options that can be specified.
option | meaning |
-a | Manager service OFF |
-f <file name> | Specify configuration file |
-o <option> | option specification |
- p <port number> | port number specification |
-d | Master manager designation |
show the detailed meaning of these options.
Normally, to start RTC, the internal component manager instantiates or deletes the RTC. (To manage lifecycle) By default the server (servant) is started so that this manager can be controlled remotely. However, if you do not need to start the same RTC in the same process, start another RTC by loading another RTC module after starting, do not use the -a option You can suppress startup of the servant by specifying it.
With the -f option, you can give files of arbitrary names to standalone components or rtcd instead of rtc.conf.
<Application example> ConsoleInComp -f consin.conf
With the -o option, you can give options that can be specified in rtc.conf from the command line. Options given with the -o option take precedence over those specified in rtc.conf, so if you want to temporarily overwrite the options specified in rtc.conf and change them, It is convenient to use the '-o' option. However, since it is passed as a command line option, blanks are recognized as argument breaks, so you do not need to include spaces or enclose it in single quotes or double quotation marks.
<Application example> ConsoleInComp -o corba.nameservers:localhost,openrtm.org ConsoleInComp -o "corba.nameservers:localhost, openrtm.org" <Example not recognized correctly> ConsoleInComp -o corba.nameservers:localhost, openrtm.org '',(Comma)'' followed by a space, so openrtm.org is recognized as another argument.
Using -p, you can specify the port number used by the RTC to be started. You may want to use this option if you want to start with a specific port number when RTC starts up. This option has the same hostname as the corba.endpoints: option and behaves the same as specifying only the port number.
<Application example> ConsoleInComp -p 2810 Same as below ConsoleInComp -o "corba.endpoints: :2810"
With the -d option you can start the standalone component you started up and rtcd as daemon mode and master manager. The manager has a master and a slave, and the master normally waits for a request with fixed port number 2810 and delegates RTC activation etc. to the slave. When invoked with the -d option, the port number is fixed to 2810 by default, the manager servant is started in master mode, and the manager's reference is registered in the name service.