[openrtm-users 01435] regarding rtprint and rtinject

10 posts / 0 new
Last post
root
Offline
Last seen: 6 hours 5 min ago
Joined: 2009-06-23 14:31
[openrtm-users 01435] regarding rtprint and rtinject

Hi OpenRTM ML:I installed openrtm-python and related package to get rtcshell running. rtls, rtact, rtdel, rtcwd all are working fine. But rtprint and rtinject don't work for me. I got some error print out. If anyone knows what's happening
please let me know. (error message from rtprint)            C:\Documents and Settings\xxxx>rtprint ConsoleIn0.rtc:out
            comp_args: rtprint_listener0            c:\python26\scripts\rtprint.py: Could not find listener component.
            Exception in thread Thread-2 (most likely raised during interpreter shutdown):Ex            ception in thread Thread-3 (most likely raised during interpreter shutdown):
            Traceback (most recent call last):Traceback (most recent call last):
              File "C:\Python26\lib\threading.py", line 527, in __bootstrap_inner  File "C:\            Python26\lib\threading.py", line 527, in __bootstrap_inner
              File "C:\Python26\lib\threading.py", line 479, in run  File "C:\Python26\lib\t
            hreading.py", line 479, in runMy rtinject works but it injects strange dataI inject a number of 3 but 1701661012 was received.
C:\Documents and Settings\xxxxx>rtinject /SPC105/SPC105.host_cxt/ConsoleOut0.rtc:in 'RTC.TimedLong({time},3)'
                Screen Output         ------------------------------
        Connector Listener: ON_CONNECT        Profile::name:      ConsoleOut0.rtc.inject_conn
        Profile::id:        ConsoleOut0.rtc.temp        Profile::properties:
        - dataflow_type: push        - interface_type: corba_cdr
        - subscription_type: flush        - data_type: <type 'str'>
        - serializer          - cdr            - endian: little,big
        - provider:         ------------------------------
        ------------------------------        Data Listener: ON_RECEIVED
        Profile::name: ConsoleOut0.rtc.inject_conn        Profile::id:   ConsoleOut0.rtc.temp
        Data:          1701661012        ------------------------------
        ------------------------------Received:         1701661012Data Listener:
        ON_BUFFER_WRITETimeStamp:         58Profile::name: [s] ConsoleOut0.rtc.inject_conn776164434
        [ns]Profile::id:           ConsoleOut0.rtc.temp
        Data:          1701661012        ------------------------------
        ------------------------------        Connector Listener: ON_DISCONNECT
        Profile::name:      ConsoleOut0.rtc.inject_conn        Profile::id:        ConsoleOut0.rtc.temp
        Profile::properties:         - dataflow_type: push
        - interface_type: corba_cdr        - subscription_type: flush
        - data_type: <type 'str'>        - serializer
          - cdr            - endian: little,big        - provider:
Thanks!Tony

Undefined
root
Offline
Last seen: 6 hours 5 min ago
Joined: 2009-06-23 14:31
[openrtm-users 01439] regarding rtprint and rtinject

Hi Tony,

One of our developers has been able to duplicate the rtprint bug. I'm
currently at IROS, where I don't have a Windows computer, so I will need
to take a look when I get back.

For rtinject, I've had a report that you need to use double quotes on
Windows, not single quotes. Try this:

> rtinject /SPC105/SPC105.host_cxt/ConsoleOut0.rtc:in
"RTC.TimedLong({time},3)"

Geoff

On 20/10/10 05:02, Tony Kuo wrote:
> Hi OpenRTM ML:
>
> I installed openrtm-python and related package to get rtcshell running.
> rtls, rtact, rtdel, rtcwd all are working fine.
> But rtprint and rtinject don't work for me.
>
> I got some error print out. If anyone knows what's happening
> please let me know.
>
> (error message from rtprint)
> C:\Documents and Settings\xxxx>rtprint ConsoleIn0.rtc:out
> comp_args: rtprint_listener0
> c:\python26\scripts\rtprint.py: Could not find listener
> component.
> Exception in thread Thread-2 (most likely raised during
> interpreter shutdown):Ex
> ception in thread Thread-3 (most likely raised during
> interpreter shutdown):
>
> Traceback (most recent call last):Traceback (most recent
> call last):
>
> File "C:\Python26\lib\threading.py", line 527, in
> __bootstrap_inner File "C:\
> Python26\lib\threading.py", line 527, in __bootstrap_inner
>
> File "C:\Python26\lib\threading.py", line 479, in run
> File "C:\Python26\lib\t
> hreading.py", line 479, in run
>
> My rtinject works but it injects strange data
> I inject a number of 3 but 1701661012 was received.
>
> C:\Documents and Settings\xxxxx>rtinject
> /SPC105/SPC105.host_cxt/ConsoleOut0.rtc:in 'RTC.TimedLong({time},3)'
>
> Screen Output
> ------------------------------
> Connector Listener: ON_CONNECT
> Profile::name: ConsoleOut0.rtc.inject_conn
> Profile::id: ConsoleOut0.rtc.temp
> Profile::properties:
> - dataflow_type: push
> - interface_type: corba_cdr
> - subscription_type: flush
> - data_type:
> - serializer
> - cdr
> - endian: little,big
> - provider:
>
> ------------------------------
> ------------------------------
> Data Listener: ON_RECEIVED
> Profile::name: ConsoleOut0.rtc.inject_conn
> Profile::id: ConsoleOut0.rtc.temp
> Data: 1701661012
> ------------------------------
> ------------------------------Received:
> 1701661012Data Listener:
> ON_BUFFER_WRITETimeStamp:
> 58Profile::name: [s] ConsoleOut0.rtc.inject_conn776164434
> [ns]Profile::id:
> ConsoleOut0.rtc.temp
> Data: 1701661012
> ------------------------------
> ------------------------------
> Connector Listener: ON_DISCONNECT
> Profile::name: ConsoleOut0.rtc.inject_conn
> Profile::id: ConsoleOut0.rtc.temp
> Profile::properties:
> - dataflow_type: push
> - interface_type: corba_cdr
> - subscription_type: flush
> - data_type:
> - serializer
> - cdr
> - endian: little,big
> - provider:
> Thanks!
> Tony
>
>

root
Offline
Last seen: 6 hours 5 min ago
Joined: 2009-06-23 14:31
[openrtm-users 01440] regarding rtprint and rtinject

Hi Geoff:Thank you for your reply. and also Congratulation on the OpenSource Award from Willow Garage. !Another thing I want to say was that, these rt commands like rtcwd, rtact, rtcon can sometimes take really long to return.
Sometimes it can take up to 5~7 seconds for one rtcon connection. Do you know why is that? I am using windows, and have components distributed over two computers but with only one nameserver. They are all on ethernet wired network.
ThanksTonyOn 22 October 2010 15:40, Geoffrey Biggs <> wrote:

Hi Tony,

One of our developers has been able to duplicate the rtprint bug. I'm
currently at IROS, where I don't have a Windows computer, so I will need
to take a look when I get back.

For rtinject, I've had a report that you need to use double quotes on
Windows, not single quotes. Try this:

> rtinject /SPC105/SPC105.host_cxt/ConsoleOut0.rtc:in
   "RTC.TimedLong({time},3)"

Geoff

On 20/10/10 05:02, Tony Kuo wrote:
> Hi OpenRTM ML:
>
> I installed openrtm-python and related package to get rtcshell running.
> rtls, rtact, rtdel, rtcwd all are working fine.
> But rtprint and rtinject don't work for me.
>
> I got some error print out. If anyone knows what's happening
> please let me know.
>
> (error message from rtprint)
>             C:\Documents and Settings\xxxx>rtprint ConsoleIn0.rtc:out
>             comp_args: rtprint_listener0
>             c:\python26\scripts\rtprint.py: Could not find listener
> component.
>             Exception in thread Thread-2 (most likely raised during
> interpreter shutdown):Ex
>             ception in thread Thread-3 (most likely raised during
> interpreter shutdown):
>
>             Traceback (most recent call last):Traceback (most recent
> call last):
>
>               File "C:\Python26\lib\threading.py", line 527, in
> __bootstrap_inner  File "C:\
>             Python26\lib\threading.py", line 527, in __bootstrap_inner
>
>               File "C:\Python26\lib\threading.py", line 479, in run
> File "C:\Python26\lib\t
>             hreading.py", line 479, in run
>
> My rtinject works but it injects strange data
> I inject a number of 3 but 1701661012 was received.
>
> C:\Documents and Settings\xxxxx>rtinject
> /SPC105/SPC105.host_cxt/ConsoleOut0.rtc:in 'RTC.TimedLong({time},3)'
>
>         Screen Output
>         ------------------------------
>         Connector Listener: ON_CONNECT
>         Profile::name:      ConsoleOut0.rtc.inject_conn
>         Profile::id:        ConsoleOut0.rtc.temp
>         Profile::properties:
>         - dataflow_type: push
>         - interface_type: corba_cdr
>         - subscription_type: flush
>         - data_type: <type 'str'>
>         - serializer
>           - cdr
>             - endian: little,big
>         - provider:
>
>         ------------------------------
>         ------------------------------
>         Data Listener: ON_RECEIVED
>         Profile::name: ConsoleOut0.rtc.inject_conn
>         Profile::id:   ConsoleOut0.rtc.temp
>         Data:          1701661012
>         ------------------------------
>         ------------------------------Received:
>         1701661012Data Listener:
>         ON_BUFFER_WRITETimeStamp:
>         58Profile::name: [s] ConsoleOut0.rtc.inject_conn776164434
>         [ns]Profile::id:
>         ConsoleOut0.rtc.temp
>         Data:          1701661012
>         ------------------------------
>         ------------------------------
>         Connector Listener: ON_DISCONNECT
>         Profile::name:      ConsoleOut0.rtc.inject_conn
>         Profile::id:        ConsoleOut0.rtc.temp
>         Profile::properties:
>         - dataflow_type: push
>         - interface_type: corba_cdr
>         - subscription_type: flush
>         - data_type: <type 'str'>
>         - serializer
>           - cdr
>             - endian: little,big
>         - provider:
> Thanks!
> Tony
>
>

root
Offline
Last seen: 6 hours 5 min ago
Joined: 2009-06-23 14:31
[openrtm-users 01441] regarding rtprint and rtinject

Hi Tony,

In versions 1 and 2 of rtshell, each call to a command requires building
an entire RTC Tree, which requires many calls to the components to fill
in their data. This will cause delays if the remote components take a
while to return. You also suffer the delay in starting the Python
interpreter the first time you run a command (it caches in memory after
that).

Version 3, which should be released next month, has many optimisations
to speed up the commands, like only parsing the components involved.
They should have a significant speed increase.

Geoff

On 22/10/10 13:24, Tony Kuo wrote:
> Hi Geoff:
> Thank you for your reply.
> and also Congratulation on the OpenSource Award from Willow Garage. !
>
> Another thing I want to say was that,
> these rt commands like rtcwd, rtact, rtcon can sometimes take really
> long to return.
> Sometimes it can take up to 5~7 seconds for one rtcon connection.
>
> Do you know why is that?
> I am using windows, and have components distributed over two computers
> but with only one nameserver.
> They are all on ethernet wired network.
>
> Thanks
> Tony
>
> On 22 October 2010 15:40, Geoffrey Biggs > wrote:
>
> Hi Tony,
>
> One of our developers has been able to duplicate the rtprint bug. I'm
> currently at IROS, where I don't have a Windows computer, so I will need
> to take a look when I get back.
>
> For rtinject, I've had a report that you need to use double quotes on
> Windows, not single quotes. Try this:
>
> > rtinject /SPC105/SPC105.host_cxt/ConsoleOut0.rtc:in
> "RTC.TimedLong({time},3)"
>
> Geoff
>
>
>
> On 20/10/10 05:02, Tony Kuo wrote:
> > Hi OpenRTM ML:
> >
> > I installed openrtm-python and related package to get rtcshell
> running.
> > rtls, rtact, rtdel, rtcwd all are working fine.
> > But rtprint and rtinject don't work for me.
> >
> > I got some error print out. If anyone knows what's happening
> > please let me know.
> >
> > (error message from rtprint)
> > C:\Documents and Settings\xxxx>rtprint ConsoleIn0.rtc:out
> > comp_args: rtprint_listener0
> > c:\python26\scripts\rtprint.py: Could not find listener
> > component.
> > Exception in thread Thread-2 (most likely raised during
> > interpreter shutdown):Ex
> > ception in thread Thread-3 (most likely raised during
> > interpreter shutdown):
> >
> > Traceback (most recent call last):Traceback (most recent
> > call last):
> >
> > File "C:\Python26\lib\threading.py", line 527, in
> > __bootstrap_inner File "C:\
> > Python26\lib\threading.py", line 527, in __bootstrap_inner
> >
> > File "C:\Python26\lib\threading.py", line 479, in run
> > File "C:\Python26\lib\t
> > hreading.py", line 479, in run
> >
> > My rtinject works but it injects strange data
> > I inject a number of 3 but 1701661012 was received.
> >
> > C:\Documents and Settings\xxxxx>rtinject
> > /SPC105/SPC105.host_cxt/ConsoleOut0.rtc:in 'RTC.TimedLong({time},3)'
> >
> > Screen Output
> > ------------------------------
> > Connector Listener: ON_CONNECT
> > Profile::name: ConsoleOut0.rtc.inject_conn
> > Profile::id: ConsoleOut0.rtc.temp
> > Profile::properties:
> > - dataflow_type: push
> > - interface_type: corba_cdr
> > - subscription_type: flush
> > - data_type:
> > - serializer
> > - cdr
> > - endian: little,big
> > - provider:
> >
> > ------------------------------
> > ------------------------------
> > Data Listener: ON_RECEIVED
> > Profile::name: ConsoleOut0.rtc.inject_conn
> > Profile::id: ConsoleOut0.rtc.temp
> > Data: 1701661012
> > ------------------------------
> > ------------------------------Received:
> > 1701661012Data Listener:
> > ON_BUFFER_WRITETimeStamp:
> > 58Profile::name: [s] ConsoleOut0.rtc.inject_conn776164434
> > [ns]Profile::id:
> > ConsoleOut0.rtc.temp
> > Data: 1701661012
> > ------------------------------
> > ------------------------------
> > Connector Listener: ON_DISCONNECT
> > Profile::name: ConsoleOut0.rtc.inject_conn
> > Profile::id: ConsoleOut0.rtc.temp
> > Profile::properties:
> > - dataflow_type: push
> > - interface_type: corba_cdr
> > - subscription_type: flush
> > - data_type:
> > - serializer
> > - cdr
> > - endian: little,big
> > - provider:
> > Thanks!
> > Tony
> >
> >
>
>

root
Offline
Last seen: 6 hours 5 min ago
Joined: 2009-06-23 14:31
[openrtm-users 01443] regarding rtprint and rtinject

Hi Tony,

We've tracked down the problem with rtprint. A flaw in the way rtprint
locates its temporary component is causing the problem. We've found that
if you set RTCTREE_NAMESERVERS to an address, and then use the
alternative form of that address (e.g. the IP vs the domain name) in
commands, the tree will contain two copies of the name server. This
confuses rtprint, since it does not expect two versions of its temporary
component.The new version of rtprint coincidentally already solves this
problem.

Until the new version is released, you can work around the problem in
one of two ways:

1. Use the same address in RTCTREE_NAMESERVERS and in paths.
2. On line 63 of rtprint.py, remove "or len(matches) != 1)".

Geoff

On 22/10/10 11:40, Geoffrey Biggs wrote:
> Hi Tony,
>
> One of our developers has been able to duplicate the rtprint bug. I'm
> currently at IROS, where I don't have a Windows computer, so I will need
> to take a look when I get back.
>
> For rtinject, I've had a report that you need to use double quotes on
> Windows, not single quotes. Try this:
>
>> rtinject /SPC105/SPC105.host_cxt/ConsoleOut0.rtc:in
> "RTC.TimedLong({time},3)"
>
> Geoff
>
>
>
> On 20/10/10 05:02, Tony Kuo wrote:
>> Hi OpenRTM ML:
>>
>> I installed openrtm-python and related package to get rtcshell running.
>> rtls, rtact, rtdel, rtcwd all are working fine.
>> But rtprint and rtinject don't work for me.
>>
>> I got some error print out. If anyone knows what's happening
>> please let me know.
>>
>> (error message from rtprint)
>> C:\Documents and Settings\xxxx>rtprint ConsoleIn0.rtc:out
>> comp_args: rtprint_listener0
>> c:\python26\scripts\rtprint.py: Could not find listener
>> component.
>> Exception in thread Thread-2 (most likely raised during
>> interpreter shutdown):Ex
>> ception in thread Thread-3 (most likely raised during
>> interpreter shutdown):
>>
>> Traceback (most recent call last):Traceback (most recent
>> call last):
>>
>> File "C:\Python26\lib\threading.py", line 527, in
>> __bootstrap_inner File "C:\
>> Python26\lib\threading.py", line 527, in __bootstrap_inner
>>
>> File "C:\Python26\lib\threading.py", line 479, in run
>> File "C:\Python26\lib\t
>> hreading.py", line 479, in run
>>
>> My rtinject works but it injects strange data
>> I inject a number of 3 but 1701661012 was received.
>>
>> C:\Documents and Settings\xxxxx>rtinject
>> /SPC105/SPC105.host_cxt/ConsoleOut0.rtc:in 'RTC.TimedLong({time},3)'
>>
>> Screen Output
>> ------------------------------
>> Connector Listener: ON_CONNECT
>> Profile::name: ConsoleOut0.rtc.inject_conn
>> Profile::id: ConsoleOut0.rtc.temp
>> Profile::properties:
>> - dataflow_type: push
>> - interface_type: corba_cdr
>> - subscription_type: flush
>> - data_type:
>> - serializer
>> - cdr
>> - endian: little,big
>> - provider:
>>
>> ------------------------------
>> ------------------------------
>> Data Listener: ON_RECEIVED
>> Profile::name: ConsoleOut0.rtc.inject_conn
>> Profile::id: ConsoleOut0.rtc.temp
>> Data: 1701661012
>> ------------------------------
>> ------------------------------Received:
>> 1701661012Data Listener:
>> ON_BUFFER_WRITETimeStamp:
>> 58Profile::name: [s] ConsoleOut0.rtc.inject_conn776164434
>> [ns]Profile::id:
>> ConsoleOut0.rtc.temp
>> Data: 1701661012
>> ------------------------------
>> ------------------------------
>> Connector Listener: ON_DISCONNECT
>> Profile::name: ConsoleOut0.rtc.inject_conn
>> Profile::id: ConsoleOut0.rtc.temp
>> Profile::properties:
>> - dataflow_type: push
>> - interface_type: corba_cdr
>> - subscription_type: flush
>> - data_type:
>> - serializer
>> - cdr
>> - endian: little,big
>> - provider:
>> Thanks!
>> Tony
>>
>>
>

root
Offline
Last seen: 6 hours 5 min ago
Joined: 2009-06-23 14:31
[openrtm-users 01445] regarding rtprint and rtinject

Hi Geoff:Thank you for your explanation. Your python scripts helped me alot in automating the process to start, connect and activate my components(although writing batch script under Windows was quite painful)
At the moment, I only use rtprint and a few others for debugging purposeLooking forward to try the next version with the optimisations. Thanks!TonyOn 25 October 2010 12:33, Geoffrey Biggs <> wrote:

Hi Tony,

We've tracked down the problem with rtprint. A flaw in the way rtprint
locates its temporary component is causing the problem. We've found that
if you set RTCTREE_NAMESERVERS to an address, and then use the
alternative form of that address (e.g. the IP vs the domain name) in
commands, the tree will contain two copies of the name server. This
confuses rtprint, since it does not expect two versions of its temporary
component.The new version of rtprint coincidentally already solves this
problem.

Until the new version is released, you can work around the problem in
one of two ways:

1. Use the same address in RTCTREE_NAMESERVERS and in paths.
2. On line 63 of rtprint.py, remove "or len(matches) != 1)".

Geoff

On 22/10/10 11:40, Geoffrey Biggs wrote:
> Hi Tony,
>
> One of our developers has been able to duplicate the rtprint bug. I'm
> currently at IROS, where I don't have a Windows computer, so I will need
> to take a look when I get back.
>
> For rtinject, I've had a report that you need to use double quotes on
> Windows, not single quotes. Try this:
>
>> rtinject /SPC105/SPC105.host_cxt/ConsoleOut0.rtc:in
>     "RTC.TimedLong({time},3)"
>
> Geoff
>
>
>
> On 20/10/10 05:02, Tony Kuo wrote:
>> Hi OpenRTM ML:
>>
>> I installed openrtm-python and related package to get rtcshell running.
>> rtls, rtact, rtdel, rtcwd all are working fine.
>> But rtprint and rtinject don't work for me.
>>
>> I got some error print out. If anyone knows what's happening
>> please let me know.
>>
>> (error message from rtprint)
>>             C:\Documents and Settings\xxxx>rtprint ConsoleIn0.rtc:out
>>             comp_args: rtprint_listener0
>>             c:\python26\scripts\rtprint.py: Could not find listener
>> component.
>>             Exception in thread Thread-2 (most likely raised during
>> interpreter shutdown):Ex
>>             ception in thread Thread-3 (most likely raised during
>> interpreter shutdown):
>>
>>             Traceback (most recent call last):Traceback (most recent
>> call last):
>>
>>               File "C:\Python26\lib\threading.py", line 527, in
>> __bootstrap_inner  File "C:\
>>             Python26\lib\threading.py", line 527, in __bootstrap_inner
>>
>>               File "C:\Python26\lib\threading.py", line 479, in run
>> File "C:\Python26\lib\t
>>             hreading.py", line 479, in run
>>
>> My rtinject works but it injects strange data
>> I inject a number of 3 but 1701661012 was received.
>>
>> C:\Documents and Settings\xxxxx>rtinject
>> /SPC105/SPC105.host_cxt/ConsoleOut0.rtc:in 'RTC.TimedLong({time},3)'
>>
>>         Screen Output
>>         ------------------------------
>>         Connector Listener: ON_CONNECT
>>         Profile::name:      ConsoleOut0.rtc.inject_conn
>>         Profile::id:        ConsoleOut0.rtc.temp
>>         Profile::properties:
>>         - dataflow_type: push
>>         - interface_type: corba_cdr
>>         - subscription_type: flush
>>         - data_type: <type 'str'>
>>         - serializer
>>           - cdr
>>             - endian: little,big
>>         - provider:
>>
>>         ------------------------------
>>         ------------------------------
>>         Data Listener: ON_RECEIVED
>>         Profile::name: ConsoleOut0.rtc.inject_conn
>>         Profile::id:   ConsoleOut0.rtc.temp
>>         Data:          1701661012
>>         ------------------------------
>>         ------------------------------Received:
>>         1701661012Data Listener:
>>         ON_BUFFER_WRITETimeStamp:
>>         58Profile::name: [s] ConsoleOut0.rtc.inject_conn776164434
>>         [ns]Profile::id:
>>         ConsoleOut0.rtc.temp
>>         Data:          1701661012
>>         ------------------------------
>>         ------------------------------
>>         Connector Listener: ON_DISCONNECT
>>         Profile::name:      ConsoleOut0.rtc.inject_conn
>>         Profile::id:        ConsoleOut0.rtc.temp
>>         Profile::properties:
>>         - dataflow_type: push
>>         - interface_type: corba_cdr
>>         - subscription_type: flush
>>         - data_type: <type 'str'>
>>         - serializer
>>           - cdr
>>             - endian: little,big
>>         - provider:
>> Thanks!
>> Tony
>>
>>
>

root
Offline
Last seen: 6 hours 5 min ago
Joined: 2009-06-23 14:31
[openrtm-users 01446] regarding rtprint and rtinject

Hi Tony,

I'm glad to hear the shell tools are proving useful. If you have any
comments on how they can be improved, I'd like to hear them.

You might be able to avoid some of the batch script writing by using
rtsshell as well. The tools in there can be used with RtsProfile files
created in RTSystemEditor to make setting up, starting, and stopping
complete systems one-step operations.

Geoff

On 28/10/10 09:34, Tony Kuo wrote:
> Hi Geoff:
> Thank you for your explanation.
> Your python scripts helped me alot in automating the process to start,
> connect and activate my components
> (although writing batch script under Windows was quite painful)
> At the moment, I only use rtprint and a few others for debugging purpose
>
> Looking forward to try the next version with the optimisations.
> Thanks!
> Tony
>
>
>
> On 25 October 2010 12:33, Geoffrey Biggs > wrote:
>
> Hi Tony,
>
> We've tracked down the problem with rtprint. A flaw in the way rtprint
> locates its temporary component is causing the problem. We've found that
> if you set RTCTREE_NAMESERVERS to an address, and then use the
> alternative form of that address (e.g. the IP vs the domain name) in
> commands, the tree will contain two copies of the name server. This
> confuses rtprint, since it does not expect two versions of its temporary
> component.The new version of rtprint coincidentally already solves this
> problem.
>
> Until the new version is released, you can work around the problem in
> one of two ways:
>
> 1. Use the same address in RTCTREE_NAMESERVERS and in paths.
> 2. On line 63 of rtprint.py, remove "or len(matches) != 1)".
>
> Geoff
>
>
> On 22/10/10 11:40, Geoffrey Biggs wrote:
> > Hi Tony,
> >
> > One of our developers has been able to duplicate the rtprint bug. I'm
> > currently at IROS, where I don't have a Windows computer, so I
> will need
> > to take a look when I get back.
> >
> > For rtinject, I've had a report that you need to use double quotes on
> > Windows, not single quotes. Try this:
> >
> >> rtinject /SPC105/SPC105.host_cxt/ConsoleOut0.rtc:in
> > "RTC.TimedLong({time},3)"
> >
> > Geoff
> >
> >
> >
> > On 20/10/10 05:02, Tony Kuo wrote:
> >> Hi OpenRTM ML:
> >>
> >> I installed openrtm-python and related package to get rtcshell
> running.
> >> rtls, rtact, rtdel, rtcwd all are working fine.
> >> But rtprint and rtinject don't work for me.
> >>
> >> I got some error print out. If anyone knows what's happening
> >> please let me know.
> >>
> >> (error message from rtprint)
> >> C:\Documents and Settings\xxxx>rtprint ConsoleIn0.rtc:out
> >> comp_args: rtprint_listener0
> >> c:\python26\scripts\rtprint.py: Could not find listener
> >> component.
> >> Exception in thread Thread-2 (most likely raised during
> >> interpreter shutdown):Ex
> >> ception in thread Thread-3 (most likely raised during
> >> interpreter shutdown):
> >>
> >> Traceback (most recent call last):Traceback (most recent
> >> call last):
> >>
> >> File "C:\Python26\lib\threading.py", line 527, in
> >> __bootstrap_inner File "C:\
> >> Python26\lib\threading.py", line 527, in
> __bootstrap_inner
> >>
> >> File "C:\Python26\lib\threading.py", line 479, in run
> >> File "C:\Python26\lib\t
> >> hreading.py", line 479, in run
> >>
> >> My rtinject works but it injects strange data
> >> I inject a number of 3 but 1701661012 was received.
> >>
> >> C:\Documents and Settings\xxxxx>rtinject
> >> /SPC105/SPC105.host_cxt/ConsoleOut0.rtc:in 'RTC.TimedLong({time},3)'
> >>
> >> Screen Output
> >> ------------------------------
> >> Connector Listener: ON_CONNECT
> >> Profile::name: ConsoleOut0.rtc.inject_conn
> >> Profile::id: ConsoleOut0.rtc.temp
> >> Profile::properties:
> >> - dataflow_type: push
> >> - interface_type: corba_cdr
> >> - subscription_type: flush
> >> - data_type:
> >> - serializer
> >> - cdr
> >> - endian: little,big
> >> - provider:
> >>
> >> ------------------------------
> >> ------------------------------
> >> Data Listener: ON_RECEIVED
> >> Profile::name: ConsoleOut0.rtc.inject_conn
> >> Profile::id: ConsoleOut0.rtc.temp
> >> Data: 1701661012
> >> ------------------------------
> >> ------------------------------Received:
> >> 1701661012Data Listener:
> >> ON_BUFFER_WRITETimeStamp:
> >> 58Profile::name: [s] ConsoleOut0.rtc.inject_conn776164434
> >> [ns]Profile::id:
> >> ConsoleOut0.rtc.temp
> >> Data: 1701661012
> >> ------------------------------
> >> ------------------------------
> >> Connector Listener: ON_DISCONNECT
> >> Profile::name: ConsoleOut0.rtc.inject_conn
> >> Profile::id: ConsoleOut0.rtc.temp
> >> Profile::properties:
> >> - dataflow_type: push
> >> - interface_type: corba_cdr
> >> - subscription_type: flush
> >> - data_type:
> >> - serializer
> >> - cdr
> >> - endian: little,big
> >> - provider:
> >> Thanks!
> >> Tony
> >>
> >>
> >
>
>

root
Offline
Last seen: 6 hours 5 min ago
Joined: 2009-06-23 14:31
[openrtm-users 01447] regarding rtprint and rtinject

Hi Geoff:The first thing that came to my mind are to improve the speed (which you already know) and also to allow connections to be restored. The reason I don't find rts-shells useful is that it doesn't restore the connections between the components (correct me if I am not wrong).
And restoring the connections is probably the most time consuming process in developing my system. Because I can do start, stop, activate and deactive in the Eclipse-based RTSystemEditor. While testing 1 particular component in a large system, I sometime find it necessary to start, stop and reconnect the connections around just that component.
Running my bash script for the whole system would duplicate some of the connections that are already there (there is no way to find out whether they are connected already or not)If somehow, the scripts allow some kind of check on whether the component is already alive, the connection is already done or the components are all in Activated state (not in error or inactivated state)
it would be quite convenient I think. Another small thing is if an installation has pre-requisite to run, for example, rtcshell requires rtctree, there should be a dependency check during installation to make it easier for users?
Thanks!TonyOn 28 October 2010 14:22, Geoffrey Biggs <> wrote:

Hi Tony,

I'm glad to hear the shell tools are proving useful. If you have any
comments on how they can be improved, I'd like to hear them.

You might be able to avoid some of the batch script writing by using
rtsshell as well. The tools in there can be used with RtsProfile files
created in RTSystemEditor to make setting up, starting, and stopping
complete systems one-step operations.

Geoff

On 28/10/10 09:34, Tony Kuo wrote:
> Hi Geoff:
> Thank you for your explanation.
> Your python scripts helped me alot in automating the process to start,
> connect and activate my components
> (although writing batch script under Windows was quite painful)
> At the moment, I only use rtprint and a few others for debugging purpose
>
> Looking forward to try the next version with the optimisations.
> Thanks!
> Tony
>
>
>
> On 25 October 2010 12:33, Geoffrey Biggs <
> <mailto:>> wrote:
>
>     Hi Tony,
>
>     We've tracked down the problem with rtprint. A flaw in the way rtprint
>     locates its temporary component is causing the problem. We've found that
>     if you set RTCTREE_NAMESERVERS to an address, and then use the
>     alternative form of that address (e.g. the IP vs the domain name) in
>     commands, the tree will contain two copies of the name server. This
>     confuses rtprint, since it does not expect two versions of its temporary
>     component.The new version of rtprint coincidentally already solves this
>     problem.
>
>     Until the new version is released, you can work around the problem in
>     one of two ways:
>
>     1. Use the same address in RTCTREE_NAMESERVERS and in paths.
>     2. On line 63 of rtprint.py, remove "or len(matches) != 1)".
>
>     Geoff
>
>
>     On 22/10/10 11:40, Geoffrey Biggs wrote:
>     > Hi Tony,
>     >
>     > One of our developers has been able to duplicate the rtprint bug. I'm
>     > currently at IROS, where I don't have a Windows computer, so I
>     will need
>     > to take a look when I get back.
>     >
>     > For rtinject, I've had a report that you need to use double quotes on
>     > Windows, not single quotes. Try this:
>     >
>     >> rtinject /SPC105/SPC105.host_cxt/ConsoleOut0.rtc:in
>     >     "RTC.TimedLong({time},3)"
>     >
>     > Geoff
>     >
>     >
>     >
>     > On 20/10/10 05:02, Tony Kuo wrote:
>     >> Hi OpenRTM ML:
>     >>
>     >> I installed openrtm-python and related package to get rtcshell
>     running.
>     >> rtls, rtact, rtdel, rtcwd all are working fine.
>     >> But rtprint and rtinject don't work for me.
>     >>
>     >> I got some error print out. If anyone knows what's happening
>     >> please let me know.
>     >>
>     >> (error message from rtprint)
>     >>             C:\Documents and Settings\xxxx>rtprint ConsoleIn0.rtc:out
>     >>             comp_args: rtprint_listener0
>     >>             c:\python26\scripts\rtprint.py: Could not find listener
>     >> component.
>     >>             Exception in thread Thread-2 (most likely raised during
>     >> interpreter shutdown):Ex
>     >>             ception in thread Thread-3 (most likely raised during
>     >> interpreter shutdown):
>     >>
>     >>             Traceback (most recent call last):Traceback (most recent
>     >> call last):
>     >>
>     >>               File "C:\Python26\lib\threading.py", line 527, in
>     >> __bootstrap_inner  File "C:\
>     >>             Python26\lib\threading.py", line 527, in
>     __bootstrap_inner
>     >>
>     >>               File "C:\Python26\lib\threading.py", line 479, in run
>     >> File "C:\Python26\lib\t
>     >>             hreading.py", line 479, in run
>     >>
>     >> My rtinject works but it injects strange data
>     >> I inject a number of 3 but 1701661012 was received.
>     >>
>     >> C:\Documents and Settings\xxxxx>rtinject
>     >> /SPC105/SPC105.host_cxt/ConsoleOut0.rtc:in 'RTC.TimedLong({time},3)'
>     >>
>     >>         Screen Output
>     >>         ------------------------------
>     >>         Connector Listener: ON_CONNECT
>     >>         Profile::name:      ConsoleOut0.rtc.inject_conn
>     >>         Profile::id:        ConsoleOut0.rtc.temp
>     >>         Profile::properties:
>     >>         - dataflow_type: push
>     >>         - interface_type: corba_cdr
>     >>         - subscription_type: flush
>     >>         - data_type: <type 'str'>
>     >>         - serializer
>     >>           - cdr
>     >>             - endian: little,big
>     >>         - provider:
>     >>
>     >>         ------------------------------
>     >>         ------------------------------
>     >>         Data Listener: ON_RECEIVED
>     >>         Profile::name: ConsoleOut0.rtc.inject_conn
>     >>         Profile::id:   ConsoleOut0.rtc.temp
>     >>         Data:          1701661012
>     >>         ------------------------------
>     >>         ------------------------------Received:
>     >>         1701661012Data Listener:
>     >>         ON_BUFFER_WRITETimeStamp:
>     >>         58Profile::name: [s] ConsoleOut0.rtc.inject_conn776164434
>     >>         [ns]Profile::id:
>     >>         ConsoleOut0.rtc.temp
>     >>         Data:          1701661012
>     >>         ------------------------------
>     >>         ------------------------------
>     >>         Connector Listener: ON_DISCONNECT
>     >>         Profile::name:      ConsoleOut0.rtc.inject_conn
>     >>         Profile::id:        ConsoleOut0.rtc.temp
>     >>         Profile::properties:
>     >>         - dataflow_type: push
>     >>         - interface_type: corba_cdr
>     >>         - subscription_type: flush
>     >>         - data_type: <type 'str'>
>     >>         - serializer
>     >>           - cdr
>     >>             - endian: little,big
>     >>         - provider:
>     >> Thanks!
>     >> Tony
>     >>
>     >>
>     >
>
>

root
Offline
Last seen: 6 hours 5 min ago
Joined: 2009-06-23 14:31
[openrtm-users 01485] regarding rtprint and rtinject

Hi Tony,

Thanks for the feeback.

On 29/10/10 07:53, Tony Kuo wrote:
> Hi Geoff:
> The first thing that came to my mind are
> to improve the speed (which you already know) and also to allow
> connections to be restored.
>
> The reason I don't find rts-shells useful is that it doesn't restore the
> connections between the components (correct me if I am not wrong).

I assume you're referring to rtresurrect here.

> And restoring the connections is probably the most time consuming
> process in developing my system.
> Because I can do start, stop, activate and deactive in the Eclipse-based
> RTSystemEditor.
>
> While testing 1 particular component in a large system, I sometime find
> it necessary to start, stop and reconnect the connections around just
> that component.
> Running my bash script for the whole system would duplicate some of the
> connections that are already there (there is no way to find out whether
> they are connected already or not)
>
> If somehow, the scripts allow some kind of check on whether the
> component is already alive, the connection is already done or the
> components are all in Activated state (not in error or inactivated state)
> it would be quite convenient I think.

I've just committed a change to trunk that makes rtresurrect and
rtteardown use connector IDs. This means that rtresurrect will now skip
connections that already exist. You can use it to restore a network to
its previous state after removing only some of the connections, without
any existing connections being duplicated.

> Another small thing is if an installation has pre-requisite to run, for
> example, rtcshell requires rtctree, there should be a dependency check
> during installation to make it easier for users?

Unfortunately, the Python distutils don't yet provide a way to easily
check that pre-requisites have been installed. I might try hacking
something in.

Geoff

root
Offline
Last seen: 6 hours 5 min ago
Joined: 2009-06-23 14:31
[openrtm-users 01497] regarding rtprint and rtinject

Hi Geoff:Sorry and thanks!I didn't know rtresurrect includes restoration of connections between components as well. I downloaded the source of rtsystem from its git-hub website. It's named gbiggs-rtsshell-aea69f5, (I assumed it's the latest, I also installed pyYaml 3.09. )
I was testing it by making a mini system connecting a consoleIn and consoleOut components I saved the system through RT System Editor. But when I tried to resurrect the system including its connection using xml,
it gave me an error saying that c:\python26\scripts\rtresurrect.py: Cannot access [[u'\\SPC105:', u'SPC105.host_
cxt', u'MyConsoleIn0.rtc'], [u'\\SPC105:', u'SPC105.host_cxt', u'MyConsoleOut0.rtc']]: No such directory or object.Traceback (most recent call last):  File "c:\python26\scripts\rtresurrect.py", line 243, in <module>
    sys.exit(main(sys.argv))  File "c:\python26\scripts\rtresurrect.py", line 237, in main    a(rtctree)  File "C:\Python26\Lib\site-packages\rtsshell\actions.py", line 63, in __call__
    result, err = self._execute(rtctree)  File "C:\Python26\Lib\site-packages\rtsshell\actions.py", line 181, in _execute    comp = rtctree.get_node(self._path)AttributeError: 'NoneType' object has no attribute 'get_node'
Do you know what might be wrong? Regards,TonyOn 11 November 2010 15:36, Geoffrey Biggs <> wrote:

Hi Tony,

Thanks for the feeback.

On 29/10/10 07:53, Tony Kuo wrote:
> Hi Geoff:
> The first thing that came to my mind are
> to improve the speed (which you already know) and also to allow
> connections to be restored.
>
> The reason I don't find rts-shells useful is that it doesn't restore the
> connections between the components (correct me if I am not wrong).

I assume you're referring to rtresurrect here.

> And restoring the connections is probably the most time consuming
> process in developing my system.
> Because I can do start, stop, activate and deactive in the Eclipse-based
> RTSystemEditor.
>
> While testing 1 particular component in a large system, I sometime find
> it necessary to start, stop and reconnect the connections around just
> that component.
> Running my bash script for the whole system would duplicate some of the
> connections that are already there (there is no way to find out whether
> they are connected already or not)
>
> If somehow, the scripts allow some kind of check on whether the
> component is already alive, the connection is already done or the
> components are all in Activated state (not in error or inactivated state)
> it would be quite convenient I think.

I've just committed a change to trunk that makes rtresurrect and
rtteardown use connector IDs. This means that rtresurrect will now skip
connections that already exist. You can use it to restore a network to
its previous state after removing only some of the connections, without
any existing connections being duplicated.

> Another small thing is if an installation has pre-requisite to run, for
> example, rtcshell requires rtctree, there should be a dependency check
> during installation to make it easier for users?

Unfortunately, the Python distutils don't yet provide a way to easily
check that pre-requisites have been installed. I might try hacking
something in.

Geoff

Log in or register to post comments

Download

latest Releases : 2.0.0-RELESE

2.0.0-RELESE Download page

Number of Projects

Choreonoid

Motion editor/Dynamics simulator

OpenHRP3

Dynamics simulator

OpenRTP

Integrated Development Platform

AIST RTC collection

RT-Components collection by AIST

TORK

Tokyo Opensource Robotics Association

DAQ-Middleware

Middleware for DAQ (Data Aquisition) by KEK