> For the complete documentation index, see [llms.txt](https://sdk.twelite.info/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://sdk.twelite.info/twelite-net-api-ref/twelite-net-guan-shu/toconet_vrfconfig.md).

# ToCoNet\_vRfConfig()

## 解説

MAC 層のパラメータ変更を行います。[`sToCoNet_AppContext`](broken://pages/-LB-iFVz_Ov3iZzxfW1U)構造体の以下に挙げるメンバーが変更可能です。

| `u8Channel`       | \*1 | チャネルを切り替える。切り替えに失敗した場合は、構造体の `u8Channel` は、設定前の値に戻ります。 |
| ----------------- | --- | ------------------------------------------------------ |
| `u32ChMask`       | \*1 |                                                        |
| `u16ShortAddress` | \*1 | 自局のショートアドレスを変更する。                                      |
| `u8CPUClk`        |     | CPUクロックの切り替えには数十usec程度かかります。                           |
| `u8TxPower`       | \*1 |                                                        |
| `bRxOnIdle`       |     | `FALSE`にすると、無線パケットを受信しなくなります。                          |

{% hint style="warning" %}
\*1 これらの設定項目の変更を行う場合、無線の送受信中の結果は不定です。

新たに送信するパケットに対して変更を有効にするには、送信キューがすべて処理されてから変更してください。

パケットの直前から受信完了までのタイミングでの変更に関しても、原理的にそのパケットが受信されないことも発生しえます。多くのアプリケーションでは、受信側はいつパケットを受けるか判らないため、切り替えタイミングを調整しない実装を行います。
{% endhint %}

## 引数

なし

## 戻り値

なし

## サンプル

```c
sToCoNet_AppContext.u8Channel = 25;
sToCoNet_u8TxPower = 2;
ToCoNet_vRfConfig();
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://sdk.twelite.info/twelite-net-api-ref/twelite-net-guan-shu/toconet_vrfconfig.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
