Class ClockPublisher
Publishes the current simulation time as a rosgraph_msgs/Clock message every
Update and/or FixedUpdate frame when time has advanced.
Inheritance
ClockPublisher
Inherited Members
Object.GetEntityId()
Object.InstantiateAsync<T>(T)
Object.InstantiateAsync<T>(T, Transform)
Object.InstantiateAsync<T>(T, Vector3, Quaternion)
Object.InstantiateAsync<T>(T, Transform, Vector3, Quaternion)
Object.Instantiate<T>(T, InstantiateParameters)
Object.Instantiate<T>(T, Vector3, Quaternion, InstantiateParameters)
Object.FindObjectsByType<T>(FindObjectsSortMode)
Object.FindObjectsByType<T>(FindObjectsInactive, FindObjectsSortMode)
Object.FindFirstObjectByType<T>()
Object.FindAnyObjectByType<T>()
Object.FindFirstObjectByType<T>(FindObjectsInactive)
Object.FindAnyObjectByType<T>(FindObjectsInactive)
Namespace: Unity.SimulationPro.Foundation
Assembly: Unity.SimulationPro.Foundation.dll
Syntax
public class ClockPublisher : PublisherBehaviour<ClockMsg>
Remarks
Attach this component when the simulation is the authoritative source of time and should broadcast clock messages to ROS subscribers. Do not use together with a ClockSubscriber on the same connector, as this creates a feedback loop.
Properties
DefaultTopic
Gets the default topic name used when Topic has not been set.
Declaration
public override string DefaultTopic { get; }
Property Value
| Type | Description |
|---|---|
| string |
Overrides
ShouldPublishOnFixedUpdate
Gets or sets a value indicating whether the clock is published during FixedUpdate.
Declaration
public bool ShouldPublishOnFixedUpdate { get; set; }
Property Value
| Type | Description |
|---|---|
| bool |
ShouldPublishOnUpdate
Gets or sets a value indicating whether the clock is published during Update.
Declaration
public bool ShouldPublishOnUpdate { get; set; }
Property Value
| Type | Description |
|---|---|
| bool |