[etherlab-users] example for pdserv_config_file ?
Sebastien Blanchet
blanchet at iram.fr
Wed Aug 1 10:03:47 CEST 2012
Dear Richard,
Thank you for these explanations, now I understand better
- how pdserv_config_file may be used.
- why testmanager has problems (like widget/signal mixing) when connected to my
pdserv server. (it was the root of my motivation to investigate on
pdserv_config_file )
I think that the existing examples in pdserv and QtPdWidgets are very well and
easy to understand.
By imitating them, I have written a very nice application that
display @ 100Hz the internal values of a bunch of EtherCAT servo drives.
Best regards,
--
Sebastien BLANCHET
On 07/31/2012 02:58 PM, Richard Hacker wrote:
> On Tuesday, July 31, 2012 01:00:00 pm Sebastien Blanchet wrote:
>> Hi,
>>
>> I am writing a program that use pdserv library.
> Very good, you're brave ;)
>
> pdserv is still developing, a stable version is expected by end of September.
> For you, though, the interface in pdserv.h is not expected to change any more.
> There are still some small issues that I have not yet had time to finish right
> now. So, keep on looking...
>
>> In pdserv.h there is an undocumented function pdserv_config_file
>> When browsing the code, I guess that it is used to read a YAML
>> configuration file.
> Documentation is lagging a bit behind.
>
> You are quite right, the configuration is a YAML Document.
>
>>
>> I have found a configuration example file for etherlab_buddy in
>> /opt/etherlab/etc/pdserv.conf.
>> but it is still unclear for me:
>> What is it for etherlab_buddy and what is it for pdserv ?
> etherlab_buddy is a relict from back then when we were using it to communicate
> with kernel real time tasks. You do not need it - just ignore it ;)
>
>> What should I do with alias, lan, msr ?
> "alias" and "msr" are keywords, where "alias" is deprecated
> "lan" is the name of the real time task, see below.
>
>>
>> Indeed, I hope that someone can provide me an example code and config file
>> for pdserv_config_file.
> You probably need the config file only to put pdserv into a traditional mode
> when using current versions of msr_testmanager to connect to your task. In
> future this will not be necessary any more
> Your config will then look like
> ---
> <task_name>:
> msr:
> traditional: 1
> port: 2345
>
> where<task_name> is the name you used when calling pdserv_create().
>
> For an example, look at test/test1.cpp. It is quite messy because I use it for
> testing backwards and forwards. It should work out of the box. You being a
> keen programmer (otherwise you would not look at the code!) you should be able
> to make sense of the key objects, along with pdserv.h.
>
> When cleaning up, I will place a better looking example, promise!
>
> I just pushed the current tree to sourceforge. Please use revision
> 7e4bb00eec65 instead of tip (although tip should work), I am still busy with
> something.
>
>>
>> best regards,
>
> Mit freundlichem Gruß
>
> Richard Hacker
>
More information about the Etherlab-users
mailing list