Nils Kemper wrote:
> Hello,
> I want to synchronize the nodes on a rtnet-network. If I understand it right 
> I 
> can use waitinfo.clock_offset, which is the offset between the master-clock 
> and the slave-clock. 

Yep, master = slave + offset. There is also RTMAC_RTIOC_TIMEOFFSET to
get the offset asynchronously.

> In a first test it seems, that waitinfo.clock_offset is always positiv, so I 
> can't tell, if the slave is "before" or "after" the master-clock. Is that 
> right? (hm, maybe I lose somewhere the sign ...)

Try powering on the slave a bit before the master, then negative offsets
should be observable.

> 
> Second (maybe stupid) question: is "unsigned long long" a correct equivalent 
> to RTIME? Better use "uint64_t"? Or which other type on a 32bit x86 
> Linux-system?

The cleanest equivalent to RTIME is RTIME. Means, you should use it as
consequently as possible. Only when exchanging data with some instance
that doesn't know that type definition, switching to another, common
type is recommended. Using explicit sizes like uint64_t then helps to
safely pass architecture borders.

Jan

Attachment: signature.asc
Description: OpenPGP digital signature

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
RTnet-users mailing list
RTnet-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rtnet-users

Reply via email to