# API Reference v10.3.1 (Python)

## Streams (class)

Module: zaber_motion.ascii

Class providing access to device streams.

Requires at least Firmware 7.05.

The following example illustrates how you can obtain an instance of this type:

```py
from zaber_motion.ascii import Connection

connection = Connection.open_serial_port("COM3")
device = connection.get_device(1)
streams = device.streams
```

### Properties

#### `device` (read-only)

`streams.device`

Type: [`Device`](https://software.zaber.com/motion-library/api/py/ascii/device.md)

Device that these streams belong to.

### Methods

#### `get_buffer()`

`streams.get_buffer(stream_buffer_number)`

Gets a StreamBuffer class instance which is a handle for a stream buffer on the device.

##### Arguments

| Name | Type | Description |
| --- | --- | --- |
| `stream_buffer_number` | `int` | The ID number of the stream buffer to control. Stream buffer IDs start at one. |

##### Return Value

Type: [`StreamBuffer`](https://software.zaber.com/motion-library/api/py/ascii/streambuffer.md)

StreamBuffer instance.

#### `get_stream()`

`streams.get_stream(stream_id)`

Gets a Stream class instance which allows you to control a particular stream on the device.

##### Arguments

| Name | Type | Description |
| --- | --- | --- |
| `stream_id` | `int` | The ID of the stream to control. Stream IDs start at one. |

##### Return Value

Type: [`Stream`](https://software.zaber.com/motion-library/api/py/ascii/stream.md)

Stream instance.

#### `list_buffer_numbers()` (async available)

`streams.list_buffer_numbers()`

Get a list of buffer ID numbers that are currently in use.

##### Return Value

Type: `List[int]`

List of buffer IDs.
