lua deployment

Hi

I get my program deployed with lua, but how do I get into the taskBrowser?, like my good old deployer with xml did :(

What I get with my lua deploy script:
rosrun ocl rttlua-gnulinux -i cartesian_vel_lua_prio.lua

OROCOS RTTLua 1.0-beta3 / Lua 5.1.4 (gnulinux)
0.362 [ Warning][Scene] Property<int> 'Priority' not found: Scene will assume priority = 1
0.378 [ Warning][ScriptingService] Loading StateMachine Test in a TaskContext with getPeriod() == 0. Use setPeriod(period) in order to setup execution of scripts.
0.381 [ Warning][Thread] Forcing priority (2) of thread with SCHED_OTHER policy to 0.
0.381 [ Warning][Thread] Lowering scheduler type to SCHED_OTHER for non-privileged users..
0.381 [ Warning][Activity] Lowering scheduler type to SCHED_OTHER for non-privileged users..
0.382 [ Debug ][/home/u0065688/src/svn/robotics-ros/packages/orocos_toolchain_ros/ocl/install/bin/rttlua-gnulinux::main()] InitialPositionValues= 0
0.382 [ Debug ][/home/u0065688/src/svn/robotics-ros/packages/orocos_toolchain_ros/ocl/install/bin/rttlua-gnulinux::main()] positionValues= 0
0.382 [ Debug ][/home/u0065688/src/svn/robotics-ros/packages/orocos_toolchain_ros/ocl/install/bin/rttlua-gnulinux::main()] InitialPositionValues= -0.785398
0.382 [ Debug ][/home/u0065688/src/svn/robotics-ros/packages/orocos_toolchain_ros/ocl/install/bin/rttlua-gnulinux::main()] positionValues= -0.785398
0.382 [ Debug ][/home/u0065688/src/svn/robotics-ros/packages/orocos_toolchain_ros/ocl/install/bin/rttlua-gnulinux::main()] InitialPositionValues= 0
0.382 [ Debug ][/home/u0065688/src/svn/robotics-ros/packages/orocos_toolchain_ros/ocl/install/bin/rttlua-gnulinux::main()] positionValues= 0
0.382 [ Debug ][/home/u0065688/src/svn/robotics-ros/packages/orocos_toolchain_ros/ocl/install/bin/rttlua-gnulinux::main()] InitialPositionValues= 1.5708
0.382 [ Debug ][/home/u0065688/src/svn/robotics-ros/packages/orocos_toolchain_ros/ocl/install/bin/rttlua-gnulinux::main()] positionValues= 1.5708
0.382 [ Debug ][/home/u0065688/src/svn/robotics-ros/packages/orocos_toolchain_ros/ocl/install/bin/rttlua-gnulinux::main()] InitialPositionValues= 0
0.382 [ Debug ][/home/u0065688/src/svn/robotics-ros/packages/orocos_toolchain_ros/ocl/install/bin/rttlua-gnulinux::main()] positionValues= 0
0.382 [ Debug ][/home/u0065688/src/svn/robotics-ros/packages/orocos_toolchain_ros/ocl/install/bin/rttlua-gnulinux::main()] InitialPositionValues= -0.785398
0.382 [ Debug ][/home/u0065688/src/svn/robotics-ros/packages/orocos_toolchain_ros/ocl/install/bin/rttlua-gnulinux::main()] positionValues= -0.785398
0.382 [ Debug ][/home/u0065688/src/svn/robotics-ros/packages/orocos_toolchain_ros/ocl/install/bin/rttlua-gnulinux::main()] InitialPositionValues= 0
0.382 [ Debug ][/home/u0065688/src/svn/robotics-ros/packages/orocos_toolchain_ros/ocl/install/bin/rttlua-gnulinux::main()] positionValues= 0
0.382 [ Info ][ReportingComponent] Buffering of data flow connections is set to 10 samples.
0.382 [ Debug ][ReportingComponent] Connected output port nAxesSensorPosition successfully to Robot_nAxesSensorPosition
0.382 [ Info ][ReportingComponent] Reporter will be triggered when new data is available on InputPort Robot_nAxesSensorPosition
0.382 [ Info ][ReportingComponent] Monitoring OutputPort nAxesSensorPosition : ok.
0.382 [ Info ][ReportingComponent] Buffering of data flow connections is set to 10 samples.
0.382 [ Debug ][ReportingComponent] Connected output port Pose successfully to CartesianMotion_Pose
0.382 [ Info ][ReportingComponent] Reporter will be triggered when new data is available on InputPort CartesianMotion_Pose
0.382 [ Info ][ReportingComponent] Monitoring OutputPort Pose : ok.
0.382 [ Info ][ReportingComponent] Buffering of data flow connections is set to 10 samples.
0.382 [ Debug ][ReportingComponent] Connected output port lambda_port successfully to Solver_lambda_port
0.382 [ Info ][ReportingComponent] Reporter will be triggered when new data is available on InputPort Solver_lambda_port
0.382 [ Info ][ReportingComponent] Monitoring OutputPort lambda_port : ok.
0.383 [ Info ][ReportingComponent] Buffering of data flow connections is set to 10 samples.
0.383 [ Debug ][ReportingComponent] Connected output port S_port successfully to Solver_S_port
0.383 [ Info ][ReportingComponent] Reporter will be triggered when new data is available on InputPort Solver_S_port
0.383 [ Info ][ReportingComponent] Monitoring OutputPort S_port : ok.
0.383 [ Info ][/home/u0065688/src/svn/robotics-ros/packages/orocos_toolchain_ros/ocl/install/bin/rttlua-gnulinux::main()] Deployment complete!
>
> ls
>>
>> cd
stdin:3: '=' expected near 'cd'
> cd Deployer.ior
stdin:1: '=' expected near 'Deployer'
> ls
>> ls
stdin:2: '=' expected near 'ls'

lua deployment

On Wed, May 25, 2011 at 04:57:40PM +0200, Dominick Vanthienen wrote:

>
> I get my program deployed with lua, but how do I get into the
> taskBrowser?, like my good old deployer with xml did :(
>
> What I get with my lua deploy script:
> rosrun ocl rttlua-gnulinux -i cartesian_vel_lua_prio.lua
...
> main()] Deployment complete!
> >
> > ls
> >>
> >> cd
> stdin:3: '=' expected near 'cd'
> > cd Deployer.ior
> stdin:1: '=' expected near 'Deployer'
> > ls
> >> ls
> stdin:2: '=' expected near 'ls'

You are in an interactive Lua session :-) You can do the same here as
in the TaskBrowser, but you have to use Lua. For instance to get some
information on loaded types, you can write

> rttlib.info()
services: marshalling scripting print os Lua
typekits: rtt-types rtt-corba-types rtt-mqueue-transport OCLTypekit
types: ConnPolicy FlowStatus PropertyBag SendHandle SendStatus TaskContext array bool
bools char double float int ints rt_string string strings
uint void
comp types: OCL::ConsoleReporting OCL::FileReporting OCL::HMIConsoleOutput OCL::HelloWorld
OCL::LuaComponent OCL::TcpReporting OCL::TimerComponent
OCL::logging::Appender OCL::logging::FileAppender
OCL::logging::Log4cxxAppender OCL::logging::LoggingService
OCL::logging::OstreamAppender TaskContext

or to print a TaskContext interface write
> print(Scene)
or
> =Scene

or to see values on ports
> Scene:stat()

where 'Scene' would be the Variable you used to store the reference to
the respective Component in the deployment script.

If you do want your good old taskbrowser back you easily get it by
writing an small ops script which loads a Lua service in the deployer
and then call exec_file with the lua deployment file. The only change
necessary would be:

tc=rtt.getTC()
depl=tc:getPeerr("deployer")

into

depl=rtt.getTC()

as the "context" taskcontext already _is_ the deployer in this case.

Best regards
Markus