pxt-ev3/docs/reference/brick/show-ports.md

24 lines
583 B
Markdown
Raw Normal View History

2018-03-30 01:43:17 +02:00
# show Ports
Show the status of everything connected to the ports.
```sig
brick.showPorts()
```
You can find out what's connected to the ports on the brick and show its status. The status information from each sensor or motor connected is displayed on the screen.
## Example
Show the status of the ports on the brick. Resets all motors when ENTER is pressed.
2018-03-30 01:43:17 +02:00
```blocks
brick.showPorts()
2018-03-30 01:43:17 +02:00
brick.buttonEnter.onEvent(ButtonEvent.Pressed, function () {
motors.resetAll()
2018-03-30 01:43:17 +02:00
})
```
## See also
[show string](/reference/brick/show-string), [show value](/reference/brick/show-value)