# NxtTouchSensor

A component that provides a high-level interface to a touch sensor on a LEGO MINDSTORMS NXT robot

## Properties

### BluetoothClient

The BluetoothClient component that should be used for communication. Must be set in the Designer

### SensorPort

The sensor port that the sensor is connected to. Must be set in the Designer

### PressedEventEnabled

Whether the Pressed event should fire when the touch sensor is pressed.

### ReleasedEventEnabled

Whether the Released event should fire when the touch sensor is released.

## Events

### Pressed()

Touch sensor has been pressed.

### Released()

Touch sensor has been released.

## Methods

### IsPressed ()

Returns true if the touch sensor is pressed.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://help.appybuilder.com/components/reference/legomindstorms/nxttouchsensor.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
