Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added info regarding the name tag #5459

Merged
merged 5 commits into from
Nov 11, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 14 additions & 10 deletions docs/reference/accelerometer.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,6 @@

Derived from [Device](device.md) and [Solid](solid.md).

```
Accelerometer {
MFVec3f lookupTable [ ] # lookup table
SFBool xAxis TRUE # {TRUE, FALSE}
SFBool yAxis TRUE # {TRUE, FALSE}
SFBool zAxis TRUE # {TRUE, FALSE}
SFFloat resolution -1 # [0, inf)
}
```

### Description

The [Accelerometer](#accelerometer) node can be used to model accelerometer devices such as those commonly found in mobile electronics, robots and game input devices.
Expand All @@ -21,6 +11,20 @@ The parent node of an [Accelerometer](#accelerometer) node should have a [Physic

### Field Summary

```
Accelerometer {
SFString name "accelerometer" # used by wb_robot_get_device()
MFVec3f lookupTable [ ] # lookup table
SFBool xAxis TRUE # {TRUE, FALSE}
SFBool yAxis TRUE # {TRUE, FALSE}
SFBool zAxis TRUE # {TRUE, FALSE}
SFFloat resolution -1 # [0, inf)
}
```
**Note**: The above description lists only the fields specific to the Accelerometer node. The complete field list can be found in the [Accelerometer.wrl]({{ url.github_tree }}/resources/nodes/Accelerometer.wrl) definition file.

- `name`: This field defines the string name used by `wb_robot_get_device()` to get the `WbDeviceTag` handle of this sensor. Its default value is "accelerometer".

- `lookupTable`: This field optionally specifies a lookup table that can be used for mapping the raw acceleration values [m/s²] to device specific output values.
By default the lookup table is empty and therefore the raw acceleration values are returned (no mapping).
See the section on the [DistanceSensor](distancesensor.md#lookup-table) node for more explanation on how a `lookupTable` works.
Expand Down