'FILE_DEVICE_UNKNOWN' : undeclared identifier

本文介绍了解决使用DeviceIoControl函数时遇到的编译错误的方法,通过包含winioctl.h头文件成功解决了未声明标识符的问题。
GPIO之FILE_DEVICE_UNKNOWN
2010-07-26 21:50

在使用DeviceIoControl函数的时候,编译总是出现下面的错误:

1>.\GPIOCTL_API.cpp(73) : error C2065: 'FILE_DEVICE_UNKNOWN' : undeclared identifier
1>.\GPIOCTL_API.cpp(73) : error C2065: 'METHOD_BUFFERED' : undeclared identifier
1>.\GPIOCTL_API.cpp(73) : error C2065: 'FILE_ANY_ACCESS' : undeclared identifier
1>.\GPIOCTL_API.cpp(73) : error C3861: 'CTL_CODE': identifier not found

最后在前面加上:

#include <winioctl.h>

就解决了。

还不知道为什么,,,,

转自:http://hi.baidu.com/xiaosan5871/blog/item/8ddf153318315df51b4cff27.html
In file included from /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/cores/esp32/Print.h:27, from /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/cores/esp32/Stream.h:26, from /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/libraries/Wire/src/Wire.h:35, from src/main.c:1: /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/cores/esp32/Printable.h:25:1: error: unknown type name 'class' class Print; ^~~~~ /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/cores/esp32/Printable.h:33:1: error: unknown type name 'class' class Printable ^~~~~ /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/cores/esp32/Printable.h:34:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token { ^ In file included from /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/cores/esp32/Stream.h:26, from /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/libraries/Wire/src/Wire.h:35, from src/main.c:1: /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/cores/esp32/Print.h:34:1: error: unknown type name 'class' class Print ^~~~~ /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/cores/esp32/Print.h:35:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token { ^ In file included from /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/libraries/Wire/src/Wire.h:35, from src/main.c:1: /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/cores/esp32/Stream.h:38:1: error: unknown type name 'class' class Stream: public Print ^~~~~ /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/cores/esp32/Stream.h:38:13: error: expected '=', ',', ';', 'asm' or '__attribute__' before ':' token class Stream: public Print ^ In file included from src/main.c:1: /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/libraries/Wire/src/Wire.h:48:1: error: unknown type name 'class' class TwoWire: public Stream ^~~~~ /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/libraries/Wire/src/Wire.h:48:14: error: expected '=', ',', ';', 'asm' or '__attribute__' before ':' token class TwoWire: public Stream ^ /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/libraries/Wire/src/Wire.h:162:8: error: unknown type name 'TwoWire' extern TwoWire Wire; ^~~~~~~ /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/libraries/Wire/src/Wire.h:163:8: error: unknown type name 'TwoWire' extern TwoWire Wire1; ^~~~~~~ In file included from src/main.c:2: .pio/libdeps/freenove_esp32_s3_wroom/BH1750/src/BH1750.h:44:1: error: unknown type name 'class' class BH1750 { ^~~~~ .pio/libdeps/freenove_esp32_s3_wroom/BH1750/src/BH1750.h:44:14: error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token class BH1750 { ^ In file included from .pio/libdeps/freenove_esp32_s3_wroom/Adafruit GFX Library/Adafruit_GFX.h:12, from src/main.c:3: .pio/libdeps/freenove_esp32_s3_wroom/Adafruit BusIO/Adafruit_I2CDevice.h:8:1: error: unknown type name 'class' class Adafruit_I2CDevice { ^~~~~ .pio/libdeps/freenove_esp32_s3_wroom/Adafruit BusIO/Adafruit_I2CDevice.h:8:26: error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token class Adafruit_I2CDevice { ^ In file included from .pio/libdeps/freenove_esp32_s3_wroom/Adafruit BusIO/Adafruit_SPIDevice.h:9, from .pio/libdeps/freenove_esp32_s3_wroom/Adafruit GFX Library/Adafruit_GFX.h:13, from src/main.c:3: /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/libraries/SPI/src/SPI.h:32:1: error: unknown type name 'class' class SPISettings ^~~~~ /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/libraries/SPI/src/SPI.h:33:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token { ^ In file included from .pio/libdeps/freenove_esp32_s3_wroom/Adafruit BusIO/Adafruit_SPIDevice.h:9, from .pio/libdeps/freenove_esp32_s3_wroom/Adafruit GFX Library/Adafruit_GFX.h:13, from src/main.c:3: /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/libraries/SPI/src/SPI.h:42:1: error: unknown type name 'class' class SPIClass ^~~~~ /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/libraries/SPI/src/SPI.h:43:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token { ^ /Users/Kevin.Wang/.platformio/packages/framework-arduinoespressif32/libraries/SPI/src/SPI.h:95:8: error: unknown type name 'SPIClass' extern SPIClass SPI; ^~~~~~~~ In file included from .pio/libdeps/freenove_esp32_s3_wroom/Adafruit GFX Library/Adafruit_GFX.h:13, from src/main.c:3: .pio/libdeps/freenove_esp32_s3_wroom/Adafruit BusIO/Adafruit_SPIDevice.h:95:1: error: unknown type name 'class' class Adafruit_SPIDevice { ^~~~~ .pio/libdeps/freenove_esp32_s3_wroom/Adafruit BusIO/Adafruit_SPIDevice.h:95:26: error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token class Adafruit_SPIDevice { ^ In file included from src/main.c:3: .pio/libdeps/freenove_esp32_s3_wroom/Adafruit GFX Library/Adafruit_GFX.h:18:1: error: unknown type name 'class' class Adafruit_GFX : public Print { ^~~~~ .pio/libdeps/freenove_esp32_s3_wroom/Adafruit GFX Library/Adafruit_GFX.h:18:20: error: expected '=', ',', ';', 'asm' or '__attribute__' before ':' token class Adafruit_GFX : public Print { ^ .pio/libdeps/freenove_esp32_s3_wroom/Adafruit GFX Library/Adafruit_GFX.h:252:1: error: unknown type name 'class' class Adafruit_GFX_Button { ^~~~~ .pio/libdeps/freenove_esp32_s3_wroom/Adafruit GFX Library/Adafruit_GFX.h:252:27: error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token class Adafruit_GFX_Button { ^ .pio/libdeps/freenove_esp32_s3_wroom/Adafruit GFX Library/Adafruit_GFX.h:310:1: error: unknown type name 'class' class GFXcanvas1 : public Adafruit_GFX { ^~~~~ .pio/libdeps/freenove_esp32_s3_wroom/Adafruit GFX Library/Adafruit_GFX.h:310:18: error: expected '=', ',', ';', 'asm' or '__attribute__' before ':' token class GFXcanvas1 : public Adafruit_GFX { ^ .pio/libdeps/freenove_esp32_s3_wroom/Adafruit GFX Library/Adafruit_GFX.h:343:1: error: unknown type name 'class' class GFXcanvas8 : public Adafruit_GFX { ^~~~~ .pio/libdeps/freenove_esp32_s3_wroom/Adafruit GFX Library/Adafruit_GFX.h:343:18: error: expected '=', ',', ';', 'asm' or '__attribute__' before ':' token class GFXcanvas8 : public Adafruit_GFX { ^ .pio/libdeps/freenove_esp32_s3_wroom/Adafruit GFX Library/Adafruit_GFX.h:370:1: error: unknown type name 'class' class GFXcanvas16 : public Adafruit_GFX { ^~~~~ .pio/libdeps/freenove_esp32_s3_wroom/Adafruit GFX Library/Adafruit_GFX.h:370:19: error: expected '=', ',', ';', 'asm' or '__attribute__' before ':' token class GFXcanvas16 : public Adafruit_GFX { ^ In file included from src/main.c:4: .pio/libdeps/freenove_esp32_s3_wroom/Adafruit SSD1306/Adafruit_SSD1306.h:131:1: error: unknown type name 'class' class Adafruit_SSD1306 : public Adafruit_GFX { ^~~~~ .pio/libdeps/freenove_esp32_s3_wroom/Adafruit SSD1306/Adafruit_SSD1306.h:131:24: error: expected '=', ',', ';', 'asm' or '__attribute__' before ':' token class Adafruit_SSD1306 : public Adafruit_GFX { ^ src/main.c:9:1: error: unknown type name 'Adafruit_SSD1306'; did you mean 'Adafruit_SPIDevice_h'? Adafruit_SSD1306 display(SCREEN_WIDTH, SCREEN_HEIGHT, &Wire, OLED_RESET); ^~~~~~~~~~~~~~~~ Adafruit_SPIDevice_h src/main.c:6:22: error: expected declaration specifiers or '...' before numeric constant #define SCREEN_WIDTH 128 // OLED屏幕宽度 ^~~ src/main.c:9:26: note: in expansion of macro 'SCREEN_WIDTH' Adafruit_SSD1306 display(SCREEN_WIDTH, SCREEN_HEIGHT, &Wire, OLED_RESET); ^~~~~~~~~~~~ src/main.c:7:23: error: expected declaration specifiers or '...' before numeric constant #define SCREEN_HEIGHT 64 // OLED屏幕高度 ^~ src/main.c:9:40: note: in expansion of macro 'SCREEN_HEIGHT' Adafruit_SSD1306 display(SCREEN_WIDTH, SCREEN_HEIGHT, &Wire, OLED_RESET); ^~~~~~~~~~~~~ src/main.c:9:55: error: expected declaration specifiers or '...' before '&' token Adafruit_SSD1306 display(SCREEN_WIDTH, SCREEN_HEIGHT, &Wire, OLED_RESET); ^ src/main.c:8:20: error: expected declaration specifiers or '...' before '-' token #define OLED_RESET -1 // 不使用复位引脚 ^ src/main.c:9:62: note: in expansion of macro 'OLED_RESET' Adafruit_SSD1306 display(SCREEN_WIDTH, SCREEN_HEIGHT, &Wire, OLED_RESET); ^~~~~~~~~~ src/main.c:11:1: error: unknown type name 'BH1750'; did you mean 'BH1750_h'? BH1750 lightMeter; ^~~~~~ BH1750_h src/main.c: In function 'setup': src/main.c:14:5: error: 'Serial' undeclared (first use in this function); did you mean 'erfcl'? Serial.begin(115200); // 初始化串口通信 ^~~~~~ erfcl src/main.c:14:5: note: each undeclared identifier is reported only once for each function it appears in src/main.c:17:9: error: request for member 'begin' in something not a structure or union Wire.begin(); ^ src/main.c:18:15: error: request for member 'begin' in something not a structure or union lightMeter.begin(BH1750::CONTINUOUS_HIGH_RES_MODE); ^ src/main.c:18:22: error: 'BH1750' undeclared (first use in this function); did you mean 'BH1750_h'? lightMeter.begin(BH1750::CONTINUOUS_HIGH_RES_MODE); ^~~~~~ BH1750_h src/main.c:18:28: error: expected ')' before ':' token lightMeter.begin(BH1750::CONTINUOUS_HIGH_RES_MODE); ^ ) src/main.c:21:10: error: 'display' undeclared (first use in this function); did you mean 'delay'? if (!display.begin(SSD1306_SWITCHCAPVCC, 0x3C)) { // 默认I2C地址为0x3C ^~~~~~~ delay src/main.c:22:24: warning: implicit declaration of function 'F' [-Wimplicit-function-declaration] Serial.println(F("OLED初始化失败")); ^ src/main.c: In function 'loop': src/main.c:34:27: error: request for member 'readLightLevel' in something not a structure or union float lux = lightMeter.readLightLevel(); // 读取光照强度 ^ src/main.c:35:5: error: 'Serial' undeclared (first use in this function); did you mean 'erfcl'? Serial.print("Light intensity: "); ^~~~~~ erfcl src/main.c:40:5: error: 'display' undeclared (first use in this function); did you mean 'delay'? display.clearDisplay(); ^~~~~~~ delay Compiling .pio/build/freenove_esp32_s3_wroom/lib9c7/BH1750/BH1750.cpp.o *** [.pio/build/freenove_esp32_s3_wroom/src/main.c.o] Error 1
05-30
D:/esp32_C3/vendor_0.1.1/main/main.c: In function 'optimize_scan_parameters': D:/esp32_C3/vendor_0.1.1/main/main.c:233:5: error: unknown type name 'esp_ble_scan_params_t' 233 | esp_ble_scan_params_t scan_params = { | ^~~~~~~~~~~~~~~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:234:9: error: field name not in record or union initializer 234 | .scan_type = BLE_SCAN_TYPE_ACTIVE, | ^ D:/esp32_C3/vendor_0.1.1/main/main.c:234:9: note: (near initialization for 'scan_params') D:/esp32_C3/vendor_0.1.1/main/main.c:234:22: error: 'BLE_SCAN_TYPE_ACTIVE' undeclared (first use in this function) 234 | .scan_type = BLE_SCAN_TYPE_ACTIVE, | ^~~~~~~~~~~~~~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:234:22: note: each undeclared identifier is reported only once for each function it appears in D:/esp32_C3/vendor_0.1.1/main/main.c:235:9: error: field name not in record or union initializer 235 | .own_addr_type = BLE_ADDR_TYPE_PUBLIC, | ^ D:/esp32_C3/vendor_0.1.1/main/main.c:235:9: note: (near initialization for 'scan_params') D:/esp32_C3/vendor_0.1.1/main/main.c:235:26: error: 'BLE_ADDR_TYPE_PUBLIC' undeclared (first use in this function) 235 | .own_addr_type = BLE_ADDR_TYPE_PUBLIC, | ^~~~~~~~~~~~~~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:235:26: warning: excess elements in scalar initializer D:/esp32_C3/vendor_0.1.1/main/main.c:235:26: note: (near initialization for 'scan_params') D:/esp32_C3/vendor_0.1.1/main/main.c:236:9: error: field name not in record or union initializer 236 | .scan_filter_policy = BLE_SCAN_FILTER_ALLOW_ALL, | ^ D:/esp32_C3/vendor_0.1.1/main/main.c:236:9: note: (near initialization for 'scan_params') D:/esp32_C3/vendor_0.1.1/main/main.c:236:31: error: 'BLE_SCAN_FILTER_ALLOW_ALL' undeclared (first use in this function) 236 | .scan_filter_policy = BLE_SCAN_FILTER_ALLOW_ALL, | ^~~~~~~~~~~~~~~~~~~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:236:31: warning: excess elements in scalar initializer D:/esp32_C3/vendor_0.1.1/main/main.c:236:31: note: (near initialization for 'scan_params') D:/esp32_C3/vendor_0.1.1/main/main.c:237:9: error: field name not in record or union initializer 237 | .scan_interval = 0x60, // 鏇寸煭鐨勬壂鎻忛棿闅?(60ms) | ^ D:/esp32_C3/vendor_0.1.1/main/main.c:237:9: note: (near initialization for 'scan_params') D:/esp32_C3/vendor_0.1.1/main/main.c:237:26: warning: excess elements in scalar initializer 237 | .scan_interval = 0x60, // 鏇寸煭鐨勬壂鎻忛棿闅?(60ms) | ^~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:237:26: note: (near initialization for 'scan_params') D:/esp32_C3/vendor_0.1.1/main/main.c:238:9: error: field name not in record or union initializer 238 | .scan_window = 0x30, // 鏇撮暱鐨勬壂鎻忕獥鍙?(30ms) | ^ D:/esp32_C3/vendor_0.1.1/main/main.c:238:9: note: (near initialization for 'scan_params') D:/esp32_C3/vendor_0.1.1/main/main.c:238:24: warning: excess elements in scalar initializer 238 | .scan_window = 0x30, // 鏇撮暱鐨勬壂鎻忕獥鍙?(30ms) | ^~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:238:24: note: (near initialization for 'scan_params') D:/esp32_C3/vendor_0.1.1/main/main.c:239:9: error: field name not in record or union initializer 239 | .scan_duplicate = BLE_SCAN_DUPLICATE_DISABLE | ^ D:/esp32_C3/vendor_0.1.1/main/main.c:239:9: note: (near initialization for 'scan_params') D:/esp32_C3/vendor_0.1.1/main/main.c:239:27: error: 'BLE_SCAN_DUPLICATE_DISABLE' undeclared (first use in this function) 239 | .scan_duplicate = BLE_SCAN_DUPLICATE_DISABLE | ^~~~~~~~~~~~~~~~~~~~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:239:27: warning: excess elements in scalar initializer D:/esp32_C3/vendor_0.1.1/main/main.c:239:27: note: (near initialization for 'scan_params') D:/esp32_C3/vendor_0.1.1/main/main.c:242:21: error: implicit declaration of function 'esp_ble_gap_set_scan_params' [-Wimplicit-function-declaration] 242 | esp_err_t err = esp_ble_gap_set_scan_params(&scan_params); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ In file included from D:/esp32_C3/vendor_0.1.1/main/main.c:8: D:/esp32_C3/vendor_0.1.1/main/main.c:247:28: error: request for member 'scan_interval' in something not a structure or union 247 | scan_params.scan_interval, scan_params.scan_window); | ^ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:182:137: note: in definition of macro 'ESP_LOG_LEVEL' 182 | if (level==ESP_LOG_ERROR ) { esp_log_write(ESP_LOG_ERROR, tag, LOG_FORMAT(E, format), esp_log_timestamp(), tag, ##__VA_ARGS__); } \ | ^~~~~~~~~~~ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:114:38: note: in expansion of macro 'ESP_LOG_LEVEL_LOCAL' 114 | #define ESP_LOGI( tag, format, ... ) ESP_LOG_LEVEL_LOCAL(ESP_LOG_INFO, tag, format, ##__VA_ARGS__) | ^~~~~~~~~~~~~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:246:9: note: in expansion of macro 'ESP_LOGI' 246 | ESP_LOGI(TAG, "鎵弿鍙傛暟浼樺寲瀹屾垚: interval=0x%X, window=0x%X", | ^~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:247:55: error: request for member 'scan_window' in something not a structure or union 247 | scan_params.scan_interval, scan_params.scan_window); | ^ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:182:137: note: in definition of macro 'ESP_LOG_LEVEL' 182 | if (level==ESP_LOG_ERROR ) { esp_log_write(ESP_LOG_ERROR, tag, LOG_FORMAT(E, format), esp_log_timestamp(), tag, ##__VA_ARGS__); } \ | ^~~~~~~~~~~ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:114:38: note: in expansion of macro 'ESP_LOG_LEVEL_LOCAL' 114 | #define ESP_LOGI( tag, format, ... ) ESP_LOG_LEVEL_LOCAL(ESP_LOG_INFO, tag, format, ##__VA_ARGS__) | ^~~~~~~~~~~~~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:246:9: note: in expansion of macro 'ESP_LOGI' 246 | ESP_LOGI(TAG, "鎵弿鍙傛暟浼樺寲瀹屾垚: interval=0x%X, window=0x%X", | ^~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:247:28: error: request for member 'scan_interval' in something not a structure or union 247 | scan_params.scan_interval, scan_params.scan_window); | ^ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:183:137: note: in definition of macro 'ESP_LOG_LEVEL' 183 | else if (level==ESP_LOG_WARN ) { esp_log_write(ESP_LOG_WARN, tag, LOG_FORMAT(W, format), esp_log_timestamp(), tag, ##__VA_ARGS__); } \ | ^~~~~~~~~~~ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:114:38: note: in expansion of macro 'ESP_LOG_LEVEL_LOCAL' 114 | #define ESP_LOGI( tag, format, ... ) ESP_LOG_LEVEL_LOCAL(ESP_LOG_INFO, tag, format, ##__VA_ARGS__) | ^~~~~~~~~~~~~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:246:9: note: in expansion of macro 'ESP_LOGI' 246 | ESP_LOGI(TAG, "鎵弿鍙傛暟浼樺寲瀹屾垚: interval=0x%X, window=0x%X", | ^~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:247:55: error: request for member 'scan_window' in something not a structure or union 247 | scan_params.scan_interval, scan_params.scan_window); | ^ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:183:137: note: in definition of macro 'ESP_LOG_LEVEL' 183 | else if (level==ESP_LOG_WARN ) { esp_log_write(ESP_LOG_WARN, tag, LOG_FORMAT(W, format), esp_log_timestamp(), tag, ##__VA_ARGS__); } \ | ^~~~~~~~~~~ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:114:38: note: in expansion of macro 'ESP_LOG_LEVEL_LOCAL' 114 | #define ESP_LOGI( tag, format, ... ) ESP_LOG_LEVEL_LOCAL(ESP_LOG_INFO, tag, format, ##__VA_ARGS__) | ^~~~~~~~~~~~~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:246:9: note: in expansion of macro 'ESP_LOGI' 246 | ESP_LOGI(TAG, "鎵弿鍙傛暟浼樺寲瀹屾垚: interval=0x%X, window=0x%X", | ^~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:247:28: error: request for member 'scan_interval' in something not a structure or union 247 | scan_params.scan_interval, scan_params.scan_window); | ^ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:184:137: note: in definition of macro 'ESP_LOG_LEVEL' 184 | else if (level==ESP_LOG_DEBUG ) { esp_log_write(ESP_LOG_DEBUG, tag, LOG_FORMAT(D, format), esp_log_timestamp(), tag, ##__VA_ARGS__); } \ | ^~~~~~~~~~~ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:114:38: note: in expansion of macro 'ESP_LOG_LEVEL_LOCAL' 114 | #define ESP_LOGI( tag, format, ... ) ESP_LOG_LEVEL_LOCAL(ESP_LOG_INFO, tag, format, ##__VA_ARGS__) | ^~~~~~~~~~~~~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:246:9: note: in expansion of macro 'ESP_LOGI' 246 | ESP_LOGI(TAG, "鎵弿鍙傛暟浼樺寲瀹屾垚: interval=0x%X, window=0x%X", | ^~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:247:55: error: request for member 'scan_window' in something not a structure or union 247 | scan_params.scan_interval, scan_params.scan_window); | ^ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:184:137: note: in definition of macro 'ESP_LOG_LEVEL' 184 | else if (level==ESP_LOG_DEBUG ) { esp_log_write(ESP_LOG_DEBUG, tag, LOG_FORMAT(D, format), esp_log_timestamp(), tag, ##__VA_ARGS__); } \ | ^~~~~~~~~~~ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:114:38: note: in expansion of macro 'ESP_LOG_LEVEL_LOCAL' 114 | #define ESP_LOGI( tag, format, ... ) ESP_LOG_LEVEL_LOCAL(ESP_LOG_INFO, tag, format, ##__VA_ARGS__) | ^~~~~~~~~~~~~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:246:9: note: in expansion of macro 'ESP_LOGI' 246 | ESP_LOGI(TAG, "鎵弿鍙傛暟浼樺寲瀹屾垚: interval=0x%X, window=0x%X", | ^~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:247:28: error: request for member 'scan_interval' in something not a structure or union 247 | scan_params.scan_interval, scan_params.scan_window); | ^ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:185:137: note: in definition of macro 'ESP_LOG_LEVEL' 185 | else if (level==ESP_LOG_VERBOSE ) { esp_log_write(ESP_LOG_VERBOSE, tag, LOG_FORMAT(V, format), esp_log_timestamp(), tag, ##__VA_ARGS__); } \ | ^~~~~~~~~~~ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:114:38: note: in expansion of macro 'ESP_LOG_LEVEL_LOCAL' 114 | #define ESP_LOGI( tag, format, ... ) ESP_LOG_LEVEL_LOCAL(ESP_LOG_INFO, tag, format, ##__VA_ARGS__) | ^~~~~~~~~~~~~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:246:9: note: in expansion of macro 'ESP_LOGI' 246 | ESP_LOGI(TAG, "鎵弿鍙傛暟浼樺寲瀹屾垚: interval=0x%X, window=0x%X", | ^~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:247:55: error: request for member 'scan_window' in something not a structure or union 247 | scan_params.scan_interval, scan_params.scan_window); | ^ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:185:137: note: in definition of macro 'ESP_LOG_LEVEL' 185 | else if (level==ESP_LOG_VERBOSE ) { esp_log_write(ESP_LOG_VERBOSE, tag, LOG_FORMAT(V, format), esp_log_timestamp(), tag, ##__VA_ARGS__); } \ | ^~~~~~~~~~~ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:114:38: note: in expansion of macro 'ESP_LOG_LEVEL_LOCAL' 114 | #define ESP_LOGI( tag, format, ... ) ESP_LOG_LEVEL_LOCAL(ESP_LOG_INFO, tag, format, ##__VA_ARGS__) | ^~~~~~~~~~~~~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:246:9: note: in expansion of macro 'ESP_LOGI' 246 | ESP_LOGI(TAG, "鎵弿鍙傛暟浼樺寲瀹屾垚: interval=0x%X, window=0x%X", | ^~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:247:28: error: request for member 'scan_interval' in something not a structure or union 247 | scan_params.scan_interval, scan_params.scan_window); | ^ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:186:137: note: in definition of macro 'ESP_LOG_LEVEL' 186 | else { esp_log_write(ESP_LOG_INFO, tag, LOG_FORMAT(I, format), esp_log_timestamp(), tag, ##__VA_ARGS__); } \ | ^~~~~~~~~~~ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:114:38: note: in expansion of macro 'ESP_LOG_LEVEL_LOCAL' 114 | #define ESP_LOGI( tag, format, ... ) ESP_LOG_LEVEL_LOCAL(ESP_LOG_INFO, tag, format, ##__VA_ARGS__) | ^~~~~~~~~~~~~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:246:9: note: in expansion of macro 'ESP_LOGI' 246 | ESP_LOGI(TAG, "鎵弿鍙傛暟浼樺寲瀹屾垚: interval=0x%X, window=0x%X", | ^~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:247:55: error: request for member 'scan_window' in something not a structure or union 247 | scan_params.scan_interval, scan_params.scan_window); | ^ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:186:137: note: in definition of macro 'ESP_LOG_LEVEL' 186 | else { esp_log_write(ESP_LOG_INFO, tag, LOG_FORMAT(I, format), esp_log_timestamp(), tag, ##__VA_ARGS__); } \ | ^~~~~~~~~~~ E:/espidf/v5.4.1/esp-idf/components/log/include/esp_log.h:114:38: note: in expansion of macro 'ESP_LOG_LEVEL_LOCAL' 114 | #define ESP_LOGI( tag, format, ... ) ESP_LOG_LEVEL_LOCAL(ESP_LOG_INFO, tag, format, ##__VA_ARGS__) | ^~~~~~~~~~~~~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:246:9: note: in expansion of macro 'ESP_LOGI' 246 | ESP_LOGI(TAG, "鎵弿鍙傛暟浼樺寲瀹屾垚: interval=0x%X, window=0x%X", | ^~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c: In function 'switch_device_role': D:/esp32_C3/vendor_0.1.1/main/main.c:528:41: error: 'example_ble_mesh_provisioning_cb' undeclared (first use in this function) 528 | esp_ble_mesh_register_prov_callback(example_ble_mesh_provisioning_cb); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c:529:49: error: 'example_ble_mesh_custom_model_cb' undeclared (first use in this function) 529 | esp_ble_mesh_register_custom_model_callback(example_ble_mesh_custom_model_cb); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c: In function 'example_ble_mesh_provisioning_cb': D:/esp32_C3/vendor_0.1.1/main/main.c:642:31: error: implicit declaration of function 'esp_ble_gap_get_rssi' [-Wimplicit-function-declaration] 642 | int8_t rssi = esp_ble_gap_get_rssi(param->provisioner_recv_unprov_adv_pkt.addr); | ^~~~~~~~~~~~~~~~~~~~ D:/esp32_C3/vendor_0.1.1/main/main.c: In function 'ble_mesh_init': D:/esp32_C3/vendor_0.1.1/main/main.c:984:9: error: implicit declaration of function 'esp_\U00006781_mesh_node_prov_enable'; did you mean 'esp_ble_mesh_node_prov_enable'? [-Wimplicit-function-declaration] 984 | esp_鏋乢mesh_node_prov_enable(ESP_BLE_MESH_PROV_ADV | ESP_BLE_MESH_PROV_GATT); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ | esp_ble_mesh_node_prov_enable D:/esp32_C3/vendor_0.1.1/main/main.c: At top level: D:/esp32_C3/vendor_0.1.1/main/main.c:292:18: warning: 'prov_complete' defined but not used [-Wunused-function] 292 | static esp_err_t prov_complete(uint16_t node_index, cninja: build stopped: subcommand failed. * 终端进程“e:\espidf\espressif\tools\ninja\1.12.1\ninja.EXE”已终止,退出代码: 1。
07-12
---Compiler Error--- | IPSR_Type D:\APPLICATION\SDK\Z20K11XM_SDK_RELEASE_RTM\PLATFORM\CORE/core_cm0plus.h:909:43: error: unknown type name 'IRQn_Type'; did you mean 'IPSR_Type'? 909 | __STATIC_INLINE uint32_t __NVIC_GetVector(IRQn_Type IRQn) | ^~~~~~~~~ | IPSR_Type D:\APPLICATION\SDK\Z20K11XM_SDK_RELEASE_RTM\PLATFORM\CORE/core_cm0plus.h: In function 'SysTick_Config': D:\APPLICATION\SDK\Z20K11XM_SDK_RELEASE_RTM\PLATFORM\CORE/core_cm0plus.h:704:39: warning: implicit declaration of function '__NVIC_SetPriority'; did you mean 'NVIC_SetPriority'? [-Wimplicit-function-declaration] 704 | #define NVIC_SetPriority __NVIC_SetPriority | ^~~~~~~~~~~~~~~~~~ D:\APPLICATION\SDK\Z20K11XM_SDK_RELEASE_RTM\PLATFORM\CORE/core_cm0plus.h:1004:3: note: in expansion of macro 'NVIC_SetPriority' 1004 | NVIC_SetPriority (SysTick_IRQn, (1UL << __NVIC_PRIO_BITS) - 1UL); /* set Priority for Systick Interrupt */ | ^~~~~~~~~~~~~~~~ In file included from D:\APPLICATION\SDK\Z20K11XM_SDK_RELEASE_RTM\STDDRIVER\INC/Z20K11xM_drv.h:32, from D:\APPLICATION\SDK/Sdk_com.h:16, from D:/Application/main.c:11: D:\APPLICATION\SDK\Z20K11XM_SDK_RELEASE_RTM\PLATFORM\CORE/core_cm0plus.h:1004:21: error: 'SysTick_IRQn' undeclared (first use in this function); did you mean 'SysTick_Type'? 1004 | NVIC_SetPriority (SysTick_IRQn, (1UL << __NVIC_PRIO_BITS) - 1UL); /* set Priority for Systick Interrupt */ | ^~~~~~~~~~~~ | SysTick_Type D:\APPLICATION\SDK\Z20K11XM_SDK_RELEASE_RTM\PLATFORM\CORE/core_cm0plus.h:1004:21: note: each undeclared identifier is reported only once for each function it appears in
10-10
root@ubuntu:/home/wuju/project/did-zkp-gnark# make go mod tidy go build -buildmode=c-archive -o zkproof.a zkproof.go gcc -o client client.c zkproof.a \ -I/home/wuju/xquic/include -I. \ -L/home/wuju/xquic/build -L/home/wuju/xquic/third_party/boringssl/build \ -lxquic-static -lssl -lcrypto -lpthread -lm -lstdc++ client.c: In function ‘main’: client.c:61:28: error: too few arguments to function ‘xqc_engine_create’ xqc_engine_t *engine = xqc_engine_create(XQC_ENGINE_CLIENT, NULL, NULL, NULL); ^~~~~~~~~~~~~~~~~ In file included from client.c:9:0: /home/wuju/xquic/include/xquic/xquic.h:1613:15: note: declared here xqc_engine_t *xqc_engine_create(xqc_engine_type_t engine_type, ^~~~~~~~~~~~~~~~~ client.c:77:30: warning: implicit declaration of function ‘xqc_engine_connect’; did you mean ‘xqc_engine_create’? [-Wimplicit-function-declaration] xqc_connection_t *conn = xqc_engine_connect( ^~~~~~~~~~~~~~~~~~ xqc_engine_create client.c:77:30: warning: initialization makes pointer from integer without a cast [-Wint-conversion] client.c:89:28: warning: implicit declaration of function ‘xqc_conn_create_stream’; did you mean ‘xqc_conn_create_path’? [-Wimplicit-function-declaration] xqc_stream_t *stream = xqc_conn_create_stream(conn, XQC_STREAM_BIDI, 0); ^~~~~~~~~~~~~~~~~~~~~~ xqc_conn_create_path client.c:89:28: warning: initialization makes pointer from integer without a cast [-Wint-conversion] client.c:104:68: error: ‘XQC_FIN’ undeclared (first use in this function); did you mean ‘MSG_FIN’? xqc_stream_send(stream, (char*)&header, sizeof(MessageHeader), XQC_FIN); ^~~~~~~ MSG_FIN client.c:104:68: note: each undeclared identifier is reported only once for each function it appears in Makefile:16: recipe for target 'build' failed make: *** [build] Error 1
07-25
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值