Constructor
class
new TimeSource(node)
Create a TimeSource.
Parameters:
| Name | Type | Description |
|---|---|---|
node |
Node | The node to be attached. |
- Source:
Methods
function
attachClock(clock) → {undefined}
Attach the clock to a TimeSource object.
Parameters:
| Name | Type | Description |
|---|---|---|
clock |
Clock | The node to be attached. |
- Source:
Returns:
Type
undefined
function
attachNode(node) → {undefined}
Attach the clock to a Node object.
Parameters:
| Name | Type | Description |
|---|---|---|
node |
Node | The node to be attached. |
- Source:
Returns:
Type
undefined
function
detachNode() → {undefined}
Detach the node which the clock have attached.
- Source:
Returns:
Type
undefined
function
get:isRosTimeActive() → {boolean}
Return status that whether the ROS time is active.
- Source:
Returns:
Return true if the time is active, otherwise return false.
Type
boolean
function
set:isRosTimeActive(enabled) → {undefined}
Set the status of time.
Parameters:
| Name | Type | Description |
|---|---|---|
enabled |
boolean | Set the ROS time to be active if enabled is true. |
- Source:
Returns:
Type
undefined