Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Target UNO_91H does not compile on mbed-os-5.15.4 #13299

Closed
observator-x opened this issue Jul 15, 2020 · 12 comments
Closed

Target UNO_91H does not compile on mbed-os-5.15.4 #13299

observator-x opened this issue Jul 15, 2020 · 12 comments

Comments

@observator-x
Copy link

observator-x commented Jul 15, 2020

[Error] rfbits.h@53,0:  #20: identifier "TestPins" is undefined
[Error] rfbits.h@54,0:  #20: identifier "Se2435Pins" is undefined
[Error] NanostackRfPhyAT86RF215.cpp@276,0:  #20: identifier "TEST_CSMA_DONE" is undefined
[Error] NanostackRfPhyAT86RF215.cpp@277,0:  #65: expected a ";"
[Error] NanostackRfPhyAT86RF215.cpp@500,0:  #20: identifier "TEST_CSMA_DONE" is undefined
[Error] NanostackRfPhyAT86RF215.cpp@501,0:  #65: expected a ";"
[Error] NanostackRfPhyAT86RF215.cpp@543,0:  #20: identifier "TEST_CSMA_STARTED" is undefined
[Error] NanostackRfPhyAT86RF215.cpp@544,0:  #159: declaration is incompatible with previous "rf_unlock" (declared at line 203)
[Error] NanostackRfPhyAT86RF215.cpp@550,0:  #20: identifier "TEST_CSMA_STARTED" is undefined
[Error] NanostackRfPhyAT86RF215.cpp@551,0:  #159: declaration is incompatible with previous "rf_unlock" (declared at line 203)
[Error] NanostackRfPhyAT86RF215.cpp@557,0:  #20: identifier "TEST_CSMA_DONE" is undefined
[Error] NanostackRfPhyAT86RF215.cpp@558,0:  #159: declaration is incompatible with previous "rf_backup_timer_stop" (declared at line 97)
[Error] NanostackRfPhyAT86RF215.cpp@588,0:  #20: identifier "TEST_CSMA_STARTED" is undefined
[Error] NanostackRfPhyAT86RF215.cpp@589,0:  #65: expected a ";"
[Warning] NanostackRfPhyAT86RF215.cpp@558,0:  #177-D: function "rf_backup_timer_stop" was declared but never referenced
[Error] NanostackRfPhyAT86RF215.cpp@599,0:  #20: identifier "TEST_TX_DONE" is undefined
[Error] NanostackRfPhyAT86RF215.cpp@600,0:  #18: expected a ")"
[Error] NanostackRfPhyAT86RF215.cpp@613,0:  #20: identifier "TEST_TX_STARTED" is undefined
[Error] NanostackRfPhyAT86RF215.cpp@614,0:  #18: expected a ")"
[Error] NanostackRfPhyAT86RF215.cpp@636,0:  #20: identifier "TEST_RX_DONE" is undefined
[Error] NanostackRfPhyAT86RF215.cpp@637,0:  #159: declaration is incompatible with previous "rf_backup_timer_stop" (declared at line 97)
[Error] NanostackRfPhyAT86RF215.cpp@692,0:  #20: identifier "TEST_RX_STARTED" is undefined
[Error] NanostackRfPhyAT86RF215.cpp@701,0:  #20: identifier "TEST_RX_DONE" is undefined
[Error] NanostackRfPhyAT86RF215.cpp@702,0:  #159: declaration is incompatible with previous "rf_lock" (declared at line 198)
[Error] NanostackRfPhyAT86RF215.cpp@938,0:  #20: identifier "TEST_CSMA_DONE" is undefined
[Error] NanostackRfPhyAT86RF215.cpp@939,0:  #65: expected a ";"
[Error] NanostackRfPhyAT86RF215.cpp@941,0:  #20: identifier "TEST_TX_DONE" is undefined
[Error] NanostackRfPhyAT86RF215.cpp@943,0:  #65: expected a ";"
[Error] NanostackRfPhyAT86RF215.cpp@1200,0:  #147: declaration is incompatible with "int RFBits::init_215_driver(RFBits *, <error-type> *, const std::uint8_t *, std::uint8_t *)" (declared at line 53 of "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\rfbits.h")
[Error] NanostackRfPhyAT86RF215.cpp@1224,0:  #147: declaration is incompatible with "int RFBits::init_se2435_pa(<error-type> *)" (declared at line 54 of "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\rfbits.h")
[Warning] NanostackRfPhyAT86RF215.cpp@168,0:  #550-D: variable "test_pins" was set but never used
[DEBUG] Return: 1
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\rfbits.h", line 53: Error:  #20: identifier "TestPins" is undefined
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\rfbits.h", line 54: Error:  #20: identifier "Se2435Pins" is undefined
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 276: Error:  #20: identifier "TEST_CSMA_DONE" is undefined
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 277: Error:  #65: expected a ";"
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 500: Error:  #20: identifier "TEST_CSMA_DONE" is undefined
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 501: Error:  #65: expected a ";"
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 543: Error:  #20: identifier "TEST_CSMA_STARTED" is undefined
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 544: Error:  #159: declaration is incompatible with previous "rf_unlock" (declared at line 203)
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 550: Error:  #20: identifier "TEST_CSMA_STARTED" is undefined
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 551: Error:  #159: declaration is incompatible with previous "rf_unlock" (declared at line 203)
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 557: Error:  #20: identifier "TEST_CSMA_DONE" is undefined
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 558: Error:  #159: declaration is incompatible with previous "rf_backup_timer_stop" (declared at line 97)
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 588: Error:  #20: identifier "TEST_CSMA_STARTED" is undefined
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 589: Error:  #65: expected a ";"
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 558: Warning:  #177-D: function "rf_backup_timer_stop" was declared but never referenced
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 599: Error:  #20: identifier "TEST_TX_DONE" is undefined
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 600: Error:  #18: expected a ")"
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 613: Error:  #20: identifier "TEST_TX_STARTED" is undefined
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 614: Error:  #18: expected a ")"
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 636: Error:  #20: identifier "TEST_RX_DONE" is undefined
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 637: Error:  #159: declaration is incompatible with previous "rf_backup_timer_stop" (declared at line 97)
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 692: Error:  #20: identifier "TEST_RX_STARTED" is undefined
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 701: Error:  #20: identifier "TEST_RX_DONE" is undefined
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 702: Error:  #159: declaration is incompatible with previous "rf_lock" (declared at line 198)
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 938: Error:  #20: identifier "TEST_CSMA_DONE" is undefined
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 939: Error:  #65: expected a ";"
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 941: Error:  #20: identifier "TEST_TX_DONE" is undefined
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 943: Error:  #65: expected a ";"
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 1200: Error:  #147: declaration is incompatible with "int RFBits::init_215_driver(RFBits *, <error-type> *, const std::uint8_t *, std::uint8_t *)" (declared at line 53 of "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\rfbits.h")
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 1224: Error:  #147: declaration is incompatible with "int RFBits::init_se2435_pa(<error-type> *)" (declared at line 54 of "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\rfbits.h")
[DEBUG] Output: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 168: Warning:  #550-D: variable "test_pins" was set but never used
[DEBUG] Output: mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp: 2 warnings, 29 errors
Traceback (most recent call last):
  File "C:\mbed-cli\7\mbed-os\tools\make.py", line 78, in wrapped_build_project
    *args, **kwargs
  File "C:\mbed-cli\7\mbed-os\tools\build_api.py", line 595, in build_project
    objects = toolchain.compile_sources(resources, sorted(resources.get_file_paths(FileType.INC_DIR)))
  File "C:\mbed-cli\7\mbed-os\tools\toolchains\mbed_toolchain.py", line 413, in compile_sources
    return self._compile_sources(resources, inc_dirs=inc_dirs)
  File "C:\mbed-cli\7\mbed-os\tools\toolchains\mbed_toolchain.py", line 490, in _compile_sources
    return self.compile_queue(queue, objects)
  File "C:\mbed-cli\7\mbed-os\tools\toolchains\mbed_toolchain.py", line 561, in compile_queue
    raise ToolException(err)
ToolException: "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\rfbits.h", line 53: Error:  #20: identifier "TestPins" is undefined
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\rfbits.h", line 54: Error:  #20: identifier "Se2435Pins" is undefined
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 276: Error:  #20: identifier "TEST_CSMA_DONE" is undefined
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 277: Error:  #65: expected a ";"
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 500: Error:  #20: identifier "TEST_CSMA_DONE" is undefined
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 501: Error:  #65: expected a ";"
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 543: Error:  #20: identifier "TEST_CSMA_STARTED" is undefined
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 544: Error:  #159: declaration is incompatible with previous "rf_unlock" (declared at line 203)
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 550: Error:  #20: identifier "TEST_CSMA_STARTED" is undefined
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 551: Error:  #159: declaration is incompatible with previous "rf_unlock" (declared at line 203)
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 557: Error:  #20: identifier "TEST_CSMA_DONE" is undefined
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 558: Error:  #159: declaration is incompatible with previous "rf_backup_timer_stop" (declared at line 97)
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 588: Error:  #20: identifier "TEST_CSMA_STARTED" is undefined
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 589: Error:  #65: expected a ";"
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 558: Warning:  #177-D: function "rf_backup_timer_stop" was declared but never referenced
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 599: Error:  #20: identifier "TEST_TX_DONE" is undefined
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 600: Error:  #18: expected a ")"
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 613: Error:  #20: identifier "TEST_TX_STARTED" is undefined
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 614: Error:  #18: expected a ")"
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 636: Error:  #20: identifier "TEST_RX_DONE" is undefined
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 637: Error:  #159: declaration is incompatible with previous "rf_backup_timer_stop" (declared at line 97)
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 692: Error:  #20: identifier "TEST_RX_STARTED" is undefined
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 701: Error:  #20: identifier "TEST_RX_DONE" is undefined
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 702: Error:  #159: declaration is incompatible with previous "rf_lock" (declared at line 198)
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 938: Error:  #20: identifier "TEST_CSMA_DONE" is undefined
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 939: Error:  #65: expected a ";"
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 941: Error:  #20: identifier "TEST_TX_DONE" is undefined
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 943: Error:  #65: expected a ";"
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 1200: Error:  #147: declaration is incompatible with "int RFBits::init_215_driver(RFBits *, <error-type> *, const std::uint8_t *, std::uint8_t *)" (declared at line 53 of "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\rfbits.h")
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 1224: Error:  #147: declaration is incompatible with "int RFBits::init_se2435_pa(<error-type> *)" (declared at line 54 of "mbed-os\components\802.15.4_RF\atmel-rf-driver\source\rfbits.h")
"mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp", line 168: Warning:  #550-D: variable "test_pins" was set but never used
mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp: 2 warnings, 29 errors
@observator-x
Copy link
Author

observator-x commented Jul 15, 2020

Target(s) affected by this defect ?
UNO_91H

Toolchain(s) (name and version) displaying this defect ?
GCC_ARM

What version of Mbed-os are you using (tag or sha) ?
mbed-os-5.15.4

What version(s) of tools are you using. List all that apply (E.g. mbed-cli)
mbed-cli 1.10.4

How is this defect reproduced ?

@0xc0170
Copy link
Contributor

0xc0170 commented Jul 16, 2020

@observator-x Is this building blinky?

@observator-x
Copy link
Author

observator-x commented Jul 16, 2020

@0xc0170 No, it wont build blinky or even an empty project, on 5.12.4 it compiles without errors and works just normal,
not on 5.15.*

@oclyke
Copy link

oclyke commented Jul 24, 2020

Ran into a similar issue while trying to add SPI support for my target.

Compile [  0.6%]: AnalogIn.cpp
Compile [  0.7%]: AnalogOut.cpp
Compile [  0.8%]: at24mac_s2lp.cpp
Compile [  0.9%]: NanostackRfPhyAT86RF215.cpp
[Error] rfbits.h@53,38: 'TestPins' has not been declared
[Error] rfbits.h@54,24: 'Se2435Pins' has not been declared
[Warning] NanostackRfPhyAT86RF215.cpp@195,43: 'int mbed::TimerBase::read_us() const' is deprecated: Use the Chrono-based elapsed_time method.  If integer microseconds are needed, you can use `elapsed_time().count()` [since mbed-os-6.0.0] [-Wdeprecated-declarations]
[Error] NanostackRfPhyAT86RF215.cpp@276,17: 'TEST_CSMA_DONE' was not declared in this scope
[Error] NanostackRfPhyAT86RF215.cpp@500,9: 'TEST_CSMA_DONE' was not declared in this scope
[Warning] NanostackRfPhyAT86RF215.cpp@542,74: 'void mbed::TickerBase::attach_us(mbed::Callback<void()>, us_timestamp_t)' is deprecated: Pass a chrono duration, not an integer microsecond count. For example use `10ms` rather than `10000`. [since mbed-os-6.0.0] [-Wdeprecated-declarations]
[Error] NanostackRfPhyAT86RF215.cpp@543,13: 'TEST_CSMA_STARTED' was not declared in this scope
[Warning] NanostackRfPhyAT86RF215.cpp@549,55: 'void mbed::TickerBase::attach_us(mbed::Callback<void()>, us_timestamp_t)' is deprecated: Pass a chrono duration, not an integer microsecond count. For example use `10ms` rather than `10000`. [since mbed-os-6.0.0] [-Wdeprecated-declarations]
[Error] NanostackRfPhyAT86RF215.cpp@550,5: 'TEST_CSMA_STARTED' was not declared in this scope
[Error] NanostackRfPhyAT86RF215.cpp@557,5: 'TEST_CSMA_DONE' was not declared in this scope
[Warning] NanostackRfPhyAT86RF215.cpp@587,74: 'void mbed::TickerBase::attach_us(mbed::Callback<void()>, us_timestamp_t)' is deprecated: Pass a chrono duration, not an integer microsecond count. For example use `10ms` rather than `10000`. [since mbed-os-6.0.0] [-Wdeprecated-declarations]
[Error] NanostackRfPhyAT86RF215.cpp@588,13: 'TEST_CSMA_STARTED' was not declared in this scope
[Error] NanostackRfPhyAT86RF215.cpp@599,5: 'TEST_TX_DONE' was not declared in this scope
[Error] NanostackRfPhyAT86RF215.cpp@613,5: 'TEST_TX_STARTED' was not declared in this scope
[Error] NanostackRfPhyAT86RF215.cpp@636,5: 'TEST_RX_DONE' was not declared in this scope
[Error] NanostackRfPhyAT86RF215.cpp@692,5: 'TEST_RX_STARTED' was not declared in this scope
[Error] NanostackRfPhyAT86RF215.cpp@701,5: 'TEST_RX_DONE' was not declared in this scope
[Error] NanostackRfPhyAT86RF215.cpp@938,9: 'TEST_CSMA_DONE' was not declared in this scope
[Error] NanostackRfPhyAT86RF215.cpp@941,5: 'TEST_TX_DONE' was not declared in this scope
[Warning] NanostackRfPhyAT86RF215.cpp@963,60: 'void mbed::TickerBase::attach_us(mbed::Callback<void()>, us_timestamp_t)' is deprecated: Pass a chrono duration, not an integer microsecond count. For example use `10ms` rather than `10000`. [since mbed-os-6.0.0] [-Wdeprecated-declarations]
[Error] NanostackRfPhyAT86RF215.cpp@1200,5: no declaration matches 'int RFBits::init_215_driver(RFBits*, TestPins*, const uint8_t*, uint8_t*)'
[Error] NanostackRfPhyAT86RF215.cpp@1224,5: no declaration matches 'int RFBits::init_se2435_pa(Se2435Pins*)'
[Warning] NanostackRfPhyAT86RF215.cpp@208,15: 'int8_t rf_device_register(const uint8_t*)' defined but not used [-Wunused-function]
[Warning] NanostackRfPhyAT86RF215.cpp@168,18: 'test_pins' defined but not used [-Wunused-variable]
[ERROR] In file included from .\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:166:
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\rfbits.h:53:38: error: 'TestPins' has not been declared
     int init_215_driver(RFBits *_rf, TestPins *_test_pins, const uint8_t mac[8], uint8_t *rf_part_num);
                                      ^~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\rfbits.h:54:24: error: 'Se2435Pins' has not been declared
     int init_se2435_pa(Se2435Pins *_se2435_pa_pins);
                        ^~~~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp: In function 'uint32_t rf_get_timestamp()':
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:195:43: warning: 'int mbed::TimerBase::read_us() const' is deprecated: Use the Chrono-based elapsed_time method. 
 If integer microseconds are needed, you can use `elapsed_time().count()` [since mbed-os-6.0.0] [-Wdeprecated-declarations]
     return (uint32_t)rf->tx_timer.read_us();
                                           ^
In file included from .\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:30:
./mbed-os/drivers/Timer.h:93:9: note: declared here
     int read_us() const;
         ^~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp: In function 'int8_t rf_extension(phy_extension_type_e, uint8_t*)':
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:276:17: error: 'TEST_CSMA_DONE' was not declared in this scope
                 TEST_CSMA_DONE
                 ^~~~~~~~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:276:17: note: suggested alternative: 'CCA_DONE'
                 TEST_CSMA_DONE
                 ^~~~~~~~~~~~~~
                 CCA_DONE
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp: In function 'void rf_csma_ca_timer_interrupt()':
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:500:9: error: 'TEST_CSMA_DONE' was not declared in this scope
         TEST_CSMA_DONE
         ^~~~~~~~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:500:9: note: suggested alternative: 'CCA_DONE'
         TEST_CSMA_DONE
         ^~~~~~~~~~~~~~
         CCA_DONE
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp: In function 'int8_t rf_start_csma_ca(uint8_t*, uint16_t, uint8_t, data_protocol_e)':
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:542:74: warning: 'void mbed::TickerBase::attach_us(mbed::Callback<void()>, us_timestamp_t)' is deprecated: Pass a chrono duration, not an integer microsecond count. For example use `10ms` rather than `10000`. [since mbed-os-6.0.0] [-Wdeprecated-declarations]
             rf->cca_timer.attach_us(rf_csma_ca_timer_signal, backoff_time);
                                                                          ^
In file included from ./mbed-os/drivers/Timeout.h:21,
                 from .\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:31:
./mbed-os/drivers/Ticker.h:110:10: note: declared here
     void attach_us(Callback<void()> func, us_timestamp_t t);
          ^~~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:543:13: error: 'TEST_CSMA_STARTED' was not declared in this scope
             TEST_CSMA_STARTED
             ^~~~~~~~~~~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:549:55: warning: 'void mbed::TickerBase::attach_us(mbed::Callback<void()>, us_timestamp_t)' is deprecated: Pass a chrono duration, not an integer microsecond count. For example use `10ms` rather than `10000`. [since mbed-os-6.0.0] [-Wdeprecated-declarations]
     rf->cca_timer.attach_us(rf_csma_ca_timer_signal, 1);
                                                       ^
In file included from ./mbed-os/drivers/Timeout.h:21,
                 from .\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:31:
./mbed-os/drivers/Ticker.h:110:10: note: declared here
     void attach_us(Callback<void()> func, us_timestamp_t t);
          ^~~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:550:5: error: 'TEST_CSMA_STARTED' was not declared in this scope
     TEST_CSMA_STARTED
     ^~~~~~~~~~~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp: In function 'void rf_handle_cca_ed_done()':
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:557:5: error: 'TEST_CSMA_DONE' was not declared in this scope
     TEST_CSMA_DONE
     ^~~~~~~~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:557:5: note: suggested alternative: 'CCA_DONE'
     TEST_CSMA_DONE
     ^~~~~~~~~~~~~~
     CCA_DONE
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:587:74: warning: 'void mbed::TickerBase::attach_us(mbed::Callback<void()>, us_timestamp_t)' is deprecated: Pass a chrono duration, not an integer microsecond count. For example use `10ms` rather than `10000`. [since mbed-os-6.0.0] [-Wdeprecated-declarations]
             rf->cca_timer.attach_us(rf_csma_ca_timer_signal, backoff_time);
                                                                          ^
In file included from ./mbed-os/drivers/Timeout.h:21,
                 from .\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:31:
./mbed-os/drivers/Ticker.h:110:10: note: declared here
     void attach_us(Callback<void()> func, us_timestamp_t t);
          ^~~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:588:13: error: 'TEST_CSMA_STARTED' was not declared in this scope
             TEST_CSMA_STARTED
             ^~~~~~~~~~~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp: In function 'void rf_handle_tx_done()':
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:599:5: error: 'TEST_TX_DONE' was not declared in this scope
     TEST_TX_DONE
     ^~~~~~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:599:5: note: suggested alternative: 'CCA_ED_DONE'
     TEST_TX_DONE
     ^~~~~~~~~~~~
     CCA_ED_DONE
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp: In function 'void rf_start_tx()':
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:613:5: error: 'TEST_TX_STARTED' was not declared in this scope
     TEST_TX_STARTED
     ^~~~~~~~~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:613:5: note: suggested alternative: 'TRX_STATE'
     TEST_TX_STARTED
     ^~~~~~~~~~~~~~~
     TRX_STATE
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp: In function 'void rf_handle_rx_done()':
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:636:5: error: 'TEST_RX_DONE' was not declared in this scope
     TEST_RX_DONE
     ^~~~~~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:636:5: note: suggested alternative: 'CCA_ED_DONE'
     TEST_RX_DONE
     ^~~~~~~~~~~~
     CCA_ED_DONE
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp: In function 'void rf_handle_rx_start()':
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:692:5: error: 'TEST_RX_STARTED' was not declared in this scope
     TEST_RX_STARTED
     ^~~~~~~~~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:692:5: note: suggested alternative: 'TRX_STATE'
     TEST_RX_STARTED
     ^~~~~~~~~~~~~~~
     TRX_STATE
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp: In function 'void rf_receive(uint16_t, {anonymous}::rf_modules_e)':
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:701:5: error: 'TEST_RX_DONE' was not declared in this scope
     TEST_RX_DONE
     ^~~~~~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:701:5: note: suggested alternative: 'CCA_ED_DONE'
     TEST_RX_DONE
     ^~~~~~~~~~~~
     CCA_ED_DONE
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp: In function 'void rf_backup_timer_interrupt()':
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:938:9: error: 'TEST_CSMA_DONE' was not declared in this scope
         TEST_CSMA_DONE
         ^~~~~~~~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:938:9: note: suggested alternative: 'CCA_DONE'
         TEST_CSMA_DONE
         ^~~~~~~~~~~~~~
         CCA_DONE
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:941:5: error: 'TEST_TX_DONE' was not declared in this scope
     TEST_TX_DONE
     ^~~~~~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:941:5: note: suggested alternative: 'CCA_ED_DONE'
     TEST_TX_DONE
     ^~~~~~~~~~~~
     CCA_ED_DONE
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp: In function 'uint32_t rf_backup_timer_start(uint16_t, uint32_t)':
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:963:60: warning: 'void mbed::TickerBase::attach_us(mbed::Callback<void()>, us_timestamp_t)' is deprecated: Pass a chrono duration, not an integer microsecond count. For example use `10ms` rather than `10000`. [since mbed-os-6.0.0] [-Wdeprecated-declarations]
     rf->cal_timer.attach_us(rf_backup_timer_signal, time_us);
                                                            ^
In file included from ./mbed-os/drivers/Timeout.h:21,
                 from .\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:31:
./mbed-os/drivers/Ticker.h:110:10: note: declared here
     void attach_us(Callback<void()> func, us_timestamp_t t);
          ^~~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp: At global scope:
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:1200:5: error: no declaration matches 'int RFBits::init_215_driver(RFBits*, TestPins*, const uint8_t*, uint8_t*)'
 int RFBits::init_215_driver(RFBits *_rf, TestPins *_test_pins, const uint8_t mac[8], uint8_t *rf_part_num)
     ^~~~~~
In file included from .\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:166:
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\rfbits.h:53:9: note: candidate is: 'int RFBits::init_215_driver(RFBits*, int*, const uint8_t*, uint8_t*)'
     int init_215_driver(RFBits *_rf, TestPins *_test_pins, const uint8_t mac[8], uint8_t *rf_part_num);
t RFBits::init_se2435_pa(Se2435Pins*)'
 int RFBits::init_se2435_pa(Se2435Pins *_se2435_pa_pins)
     ^~~~~~
In file included from .\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:166:
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\rfbits.h:54:9: note: candidate is: 'int RFBits::init_se2435_pa(int*)'t RFBits::init_se2435_pa(Se2435Pins*)'
     int init_se2435_pa(Se2435Pins *_se2435_pa_pins);
         ^~~~~~~~~~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\rfbits.h:39:7: note: 'class RFBits' defined here
 class RFBits {
       ^~~~~~
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:208:15: warning: 'int8_t rf_device_register(const uint8_t*)' defined but not used [-Wunused-function]
 static int8_t rf_device_register(const uint8_t *mac_addr)
               ^~~~~~~~~~~~~~~~~~                                                                                            er(const uint8_t*)' defined but not used [-Wunused-function]
.\mbed-os\components\802.15.4_RF\atmel-rf-driver\source\NanostackRfPhyAT86RF215.cpp:168:18: warning: 'test_pins' defined but 
not used [-Wunused-variable]
 static TestPins *test_pins;                                                                                                 not used [-Wunused-variable]
                  ^~~~~~~~~

My repo is behind by several commits including this one which relocated some RF drivers:

This could be part of the issue

After pulling the latest from the master branch I still encounter these errors.

@oclyke
Copy link

oclyke commented Jul 24, 2020

More observations:

  • Issue does not manifest when NanostackRfPhyAT86RF215.cpp is excluded by preprocessor (e.g. DEVICE_SPI is not defined)
  • class TestPins; is forward-declared in NanostackRfPhyAtmel.h
  • class TestPins{} is defined in rfbits.h after being used as a parameter type in the RFBits class init_215_driver method.

rfbits.h needs a forward declaration of TestPins for this to be valid, but none of the included headers seem like likely candidates to include NanostackRfPhyAtmel.h

#include "DigitalIn.h"
#include "DigitalOut.h"
#include "InterruptIn.h"
#include "SPI.h"
#include <Timer.h>
#include "Timeout.h"
#include "rtos.h"

I am left wondering who is responsible for declaring TestPins. Is this supposed to be handled by a port? That would seem quite odd IMO.

@oclyke
Copy link

oclyke commented Jul 24, 2020

Here's what needs to be fixed:

  • rfbits.h needs a forward declaration of TestPins perhaps it could simply include NanostackRfPhyAtmel.h
  • rfbits.h needs a forward declaration of Se2435Pins perhaps it could simply include NanostackRfPhyAtmel.h
  • the preprocessor guards in NanostackRfPhyAtmel.h and NanostackRfPhyAT86RF215.cpp should match
    • NanostackRfPhyAtmel.h checks:
      • #if defined(MBED_CONF_NANOSTACK_CONFIGURATION) && DEVICE_SPI && DEVICE_I2C && defined(MBED_CONF_RTOS_PRESENT)
    • NanostackRfPhyAT86RF215.cpp checks
      • #if defined(MBED_CONF_NANOSTACK_CONFIGURATION) && DEVICE_SPI && DEVICE_INTERRUPTIN && defined(MBED_CONF_RTOS_PRESENT)
    • the differences:
      • source file ensures that device has DEVICE_INTERRUPTIN, header does not
      • header ensure device has DEVICE_I2C, source file does not
    • this means that in some cases the source file can be included without all the necessary declarations
      • in my case DEVICE_I2C is not defined - causing the header not to be included and these preprocessor statements (among others, most likely) to be missing:
        #define TEST_TX_STARTED
        #define TEST_TX_DONE
        #define TEST_RX_STARTED
        #define TEST_RX_DONE
        #define TEST_CSMA_STARTED
        #define TEST_CSMA_DONE
        #define TEST_SPARE_1_ON
        #define TEST_SPARE_1_OFF
        #define TEST_SPARE_2_ON
        #define TEST_SPARE_2_OFF

There may be more items - I am still working toward a successful compilation

  • Note: currently rfbits.h is only included in two locations, always after NanostackRfPhyAtmel.h. Therefore, if the preprocessor guard issue is fixed it would not strictly be necessary to forward-declare TestPins and Se2435Pins. However IMO it would still be a good idea to do so.

@talorion
Copy link
Contributor

talorion commented Aug 20, 2020

I am having a similar problem compiling tests...
I just created a PR #13472
I think this fixes the problem(at last in my setup it does)

@ciarmcom
Copy link
Member

@observator-x thank you for raising this issue.Please take a look at the following comments:

Could you add some more detail to the description? A good description should be at least 25 words.
What target(s) are you using?
What toolchain(s) are you using?
What version of Mbed OS are you using (tag or sha)?
It would help if you could also specify the versions of any tools you are using?
How can we reproduce your issue?

NOTE: If there are fields which are not applicable then please just add 'n/a' or 'None'.This indicates to us that at least all the fields have been considered.
Please update the issue header with the missing information, the issue will not be mirroredto our internal defect tracking system or investigated until this has been fully resolved.

@adbridge
Copy link
Contributor

@talorion can this now be closed ?

@ciarmcom
Copy link
Member

@observator-x it has been 5 days since the last reminder. Could you please update the issue header as previously requested?

1 similar comment
@ciarmcom
Copy link
Member

@observator-x it has been 5 days since the last reminder. Could you please update the issue header as previously requested?

@adbridge
Copy link
Contributor

As we've had no response I'm going to close this, please open a new defect if the problem persists.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants