LoginSignup
0
0

More than 1 year has passed since last update.

ESP32 Arduino で error: 'boolean' does not name a type

Last updated at Posted at 2022-03-06

環境

エラー内容

コンパイル時に以下のようにエラーが出た


.../libraries/PN532_SPI/PN532_SPI.h:23:5: error: 'boolean' does not name a type
     boolean isReady();
     ^
.../libraries/PN532_SPI/PN532_SPI.cpp:66:21: error: 'isReady' was not declared in this scope
     while (!isReady()) {
                     ^
.../libraries/PN532_SPI/PN532_SPI.cpp:142:28: error: no 'boolean PN532_SPI::isReady()' member function declared in class 'PN532_SPI'
 boolean PN532_SPI::isReady()
                            ^

解決

この原因は esp32 で boolean が定義されていないこと。

PN532_SPI.cpp を開き、以下のように変更したらOK。

-    boolean isReady();
+    bool isReady();

cf.,

別のライブラリでも issue が出ていました
「Error compiling for ESP32 · Issue #79 · Seeed-Studio/PN532」
https://github.com/Seeed-Studio/PN532/issues/79

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