[openrtm-users 03402] Re: 同じポート間の多重接続を避ける方法

MASUTANI Yasuhiro masutani @ osakac.ac.jp
2017年 6月 14日 (水) 12:39:28 JST


ジェフ様,

コメントありがとうございます.
なるほど,rtcatで見ればいいのですね.

ところで,rtconにオプションを追加して,既に同じ接続があったら拒否する
とか警告するとかいう機能を付けることはできないでしょうか.

On Wed, 14 Jun 2017 12:30:39 +0900,
BiggsGeoffrey <geoffrey.biggs @ aist.go.jp> wrote:
> 
> 升谷様
> 
> どの方法で接続を作っていますか。
> 
> 今rtshellで試したら、多重接続を作ったらrtcatで見えます。でも確かにrtls -l では1として出力されます。
> 
> ジェフ
> 
> geoff ~ $ rtls
> ConsoleIn0.rtc  ConsoleOut0.rtc
> geoff ~ $ rtcon ConsoleIn0.rtc:out ConsoleOut0.rtc:in
> geoff ~ $ rtcon ConsoleIn0.rtc:out ConsoleOut0.rtc:in
> geoff ~ $ rtcon ConsoleIn0.rtc:out ConsoleOut0.rtc:in
> geoff ~ $ rtcat ConsoleIn0.rtc: -lll
> ConsoleIn0.rtc  Inactive
>   Category       example
>   Description    Console input component
>   Instance name  ConsoleIn0
>   Type name      ConsoleIn
>   Vendor         Noriaki Ando, AIST
>   Version        1.0
>   Parent
>   Type           Monolithic
>   Extra properties:
>     activity_type                            DataFlowComponent
>     category                                 example
>     conf
>     config.version                           1.1.1
>     config_file                              consin.conf
>     corba.endpoint
>     corba.id                                 omniORB
>     description                              Console input component
>     exec_cxt.periodic.rate                   1000
>     exec_cxt.periodic.type                   PeriodicExecutionContext
>     exec_cxt.sync_transition                 YES
>     exec_cxt.transition_timeout              0.5
>     implementation_id                        ConsoleIn
>     instance_name                            ConsoleIn0
>     lang_type                                compile
>     language                                 C++
>     logger.enable                            NO
>     logger.log_level                         PARANOID
>     max_instance                             10
>     naming.enable                            YES
>     naming.formats                           test.host_cxt/%n.rtc
>     naming.names                             test.host_cxt/ConsoleIn0.rtc
>     naming.type                              corba
>     openrtm.name                             OpenRTM-aist-1.1.1
>     openrtm.version                          1.1.1
>     os.arch                                  x86_64
>     os.hostname                              alnilam
>     os.name                                  Linux
>     os.release                               4.4.0-79-generic
>     os.version                               #100-Ubuntu SMP Wed May 17 19:58:14 UTC 2017
>     port.dataport.out.tcp_any.byteswap       NO
>     port.outport.dataport
>     port.outport.out
>     sdo.service.consumer.available_services  IDL:OpenRTM/ComponentObserver:1.0
>     sdo.service.consumer.enabled_services
>     sdo.service.provider.available_services
>     sdo.service.provider.enabled_services
>     type_name                                ConsoleIn
>     vendor                                   Noriaki Ando, AIST
>     version                                  1.0
>  -Execution Context 0
>     State  Running
>     Kind   Periodic
>     Rate   1000.0
>    -Extra properties
>       name
>       rate                1000
>       sync_transition     YES
>       transition_timeout  0.5
>       type                PeriodicExecutionContext
>  -DataOutPort: out
>     dataport.data_type          IDL:RTC/TimedLong:1.0
>     dataport.dataflow_type      push,pull
>     dataport.interface_type     corba_cdr, direct
>     dataport.subscription_type  flush,new,periodic
>     port.port_type              DataOutPort
>    -Connected to  /localhost/test.host_cxt/ConsoleOut0.rtc:in
>       Name                            outin
>       ID                              5c9c56d7-c944-4ccf-a12d-16e1e9df187e
>       dataport.subscription_type      new
>       dataport.interface_type         corba_cdr
>       dataport.dataflow_type          push
>       dataport.data_type              IDL:RTC/TimedLong:1.0
>       dataport.serializer.cdr.endian  little,big
>    -Connected to  /localhost/test.host_cxt/ConsoleOut0.rtc:in
>       Name                            outin
>       ID                              874cb981-7c1c-4db2-98c0-1661c985958a
>       dataport.subscription_type      new
>       dataport.interface_type         corba_cdr
>       dataport.dataflow_type          push
>       dataport.data_type              IDL:RTC/TimedLong:1.0
>       dataport.serializer.cdr.endian  little,big
>    -Connected to  /localhost/test.host_cxt/ConsoleOut0.rtc:in
>       Name                            outin
>       ID                              595d1b3e-abaa-4faa-9613-827dee76e84b
>       dataport.subscription_type      new
>       dataport.interface_type         corba_cdr
>       dataport.dataflow_type          push
>       dataport.data_type              IDL:RTC/TimedLong:1.0
>       dataport.serializer.cdr.endian  little,big

-- 
# 升谷 保博
# 大阪電気通信大学 総合情報学部 情報学科
# 575-0063 大阪府四條畷市清滝1130-70 / TEL&FAX: 072-876-5107


More information about the openrtm-users mailing list