简体   繁体   中英

arm mbed os CoAP missing ns_types.h

I am trying to build the CoAP protocol example for ARM mbed ( https://developer.mbed.org/teams/sandbox/code/coap-example/file/0681e205d0e9/ ) on a K64F board. I am getting this error on compiling:

Compile [  0.3%]: sn_coap_header_check.c
[Fatal Error] sn_coap_header_check.c@27,22: ns_types.h: No such file or directory
[ERROR] .\mbed-coap\source\sn_coap_header_check.c:27:22: fatal error: ns_types.h: No such file or directory
 #include "ns_types.h"
                      ^
compilation terminated.

How can I obtain the missing dependency? I tried mbed sync and mbed update but I get the same error.

Any idea?

UPDATE

I am searching through the project and I can see that the file is present but not found by the compiler in this route: mbed-os\\features\\FEATURE_COMMON_PAL\\nanostack-libservice\\mbed-client-libservice

Did you accidentally remove the mbed_app.json file? The COMMON_PAL feature is declared in there.

This works for me (with mbed CLI):

$ mbed import https://developer.mbed.org/teams/sandbox/code/coap-example/
$ cd coap-example
$ mbed compile -m K64F -t GCC_ARM

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM