function · Node only

# kissEncode

A KISS frame: FEND, command, escaped data, FEND.

`@toip-tools/mesh-transport/detect` · [View source](https://github.com/yourbuddyconner/toip-tools/blob/main/packages/mesh-transport/src/detect.ts#L24)

Import:

```ts
import { kissEncode } from "@toip-tools/mesh-transport/detect";
```

## Declaration

Signature:

```ts
kissEncode(command: number, data: Uint8Array): Uint8Array;
```

### Parameters

- **`command` (required)**: `number`
- **`data` (required)**: `Uint8Array<ArrayBufferLike>`

### Returns

`Uint8Array<ArrayBufferLike>`

[Usage guide](https://toip.tools/toolkit/mesh-transport/#usage) · [Error handling](https://toip.tools/toolkit/mesh-transport/#errors) · [All exports](https://toip.tools/toolkit/mesh-transport/api/detect/)

---

This is the Markdown version of https://toip.tools/toolkit/mesh-transport/api/detect/kissEncode/. An index of the documentation for AI assistants is at https://toip.tools/llms.txt.
