ap_max_connections documented in network.erl, but the ESP32 driver reads max_connections

オープン 初心者向け
#2,420 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 2 日以内に返信

まだ誰も着手していません。

評価

難易度
2/5
見積もり時間
1〜3時間
初心者へのやさしさ
76/100
issue の種類
バグ
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
c, erlang
領域
embedded-iot

調査の方向性

libs/avm_network/src/network.erlをsrc/platforms/esp32/components/avm_builtins/network_driver.cと併せて読み、その後doc/src/network-programming-guide.mdで文書化されているAPオプションを確認してください。宣言されたキー、ドライバーでの処理、ガイドの内容を一致させ、適切であれば提案されている非推奨のエイリアスを維持してください。宣言されたオプションがESP32のステーション上限を制御し、ガイドの記述が一致すれば完了です。

索引モデルが issue の本文から書いたものです。

説明

network.erl declares the AP option as {ap_max_connections, non_neg_integer()} (ap_max_connections_config(), part of ap_config_property()), but the ESP32 driver (network_driver.c) only reads max_connections. The network programming guide also documents {max_connections, ...}.

If you pass the key the spec declares, {ap_max_connections, 1}, the driver silently ignores it and the AP accepts the default 4 stations. If you pass the key that works, {max_connections, 1}, Dialyzer flags it as not matching ap_config().

Seen on release-0.7 and main:

  • libs/avm_network/src/network.erl:171: -type ap_max_connections_config() :: {ap_max_connections, non_neg_integer()}.
  • src/platforms/esp32/components/avm_builtins/network_driver.c:89, :1116: max_connections_atom = "max_connections"
  • doc/src/network-programming-guide.md:361: {max_connections, non_neg_integer()}

Suggested fix: make the type and the driver agree. The ap_ prefix matches the other AP options (ap_channel, ap_ssid_hidden, ap_sta_connected…), so the driver could accept ap_max_connections, keep max_connections as a deprecated alias, and update the guide.

主要言語
Erlang
スター
2.3k
フォーク
171
平均マージ
5日 11時間
マージ済み PR(30日)
19

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

atomvm/AtomVM のほかの issue

atomvm/AtomVM の issue をすべて見る

似ている issue

Embedded & IoT の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。