> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.nvidia.com/holoscan/sensor-bridge/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.nvidia.com/holoscan/sensor-bridge/_mcp/server.

# hololink::emulation::GPIO_set_value

#### Overload 1

```cpp showLineNumbers={false}
int hololink::emulation::GPIO_set_value(
    __attribute__((unused)) void *ctxt,
    AddressValuePair *addr_vals,
    int max_count
)
```

#### Set the value of the GPIO

```cpp showLineNumbers={false}
int hololink::emulation::GPIO_set_value(
    void *ctxt,
    struct AddressValuePair *addr_vals,
    int max_count
)
```

Set the value of the GPIO.

**Returns:** The number of address-value pairs set.

**Parameters**

The context pointer.

The address-value pair. Each bit in values corresponds to high/low state of the GPIO pin at the address. Each address supports 32 pins with the 0 pin at GPIO\_OUTPUT\_BASE\_REGISTER + 0 and the 31 pin at GPIO\_OUTPUT\_BASE\_REGISTER + 31.

The maximum number of address-value pairs to set.