0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

Raspberry pi pico 2 wでWiFiを使う

0
Posted at

概要

の続きで、WiFiを使おうとしたら結構ややこしかったのでメモ。

対応

WiFiを使うために

#include "pico/cyw43_arch.h"

を行ったところ、これがビルド時に見つからない。
CMakeLists.txtを色々変えたりしたけど、解決しない。

結果、

cd <sdk-path>/pico-sdk
git submodule update --init --recursive

が必要だった。
更に、

Pico_ePaper_Code/c/main.c:7: 
<sdk-path>/pico-sdk/lib/lwip/src/include/lwip/opt.h:51:10: fatal error: lwipopts.h: No such file or directory 51 | #include "lwipopts.h"

というエラーが出たので、ローカルでlwipopts.hを作成した。

リリース作業

これをForkする。

Forkしたら、
ローカルで以下を実行する

git remote rename origin upstream
git remote add origin git@github.com:<あなたのGitHubユーザー名>/Pico_ePaper_Code.git

git status
git add c/CMakeLists.txt
git add c/main.c
git add c/lwipopts.h
git commit -s -m "Add Pico 2 W Wi-Fi support"
git push -u origin <branch名>

これで、Fork先に対応をpushした。

動作確認結果

image.png

無事WiFi接続できて、IPアドレスが出せた。
これで次は、温湿度と大気圧を受け取って、表示する。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?