Skip to content

Commit f6a7f65

Browse files
committed
Fixing the Mbed OS crash reporting and enable green tea test for bare metal.
Added missing mbed_error_initialize function call in bare metal boot code which is used to retrieve the crash report from RAM in case of any previous abnormal re-boot but this function call is present in RTOS boot code.
1 parent f2a1804 commit f6a7f65

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

TESTS/mbed_platform/crash_reporting/main.cpp

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,6 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16-
#if !defined(MBED_CONF_RTOS_PRESENT)
17-
#error [NOT_SUPPORTED] crash_reporting test cases require a RTOS to run.
18-
#else
1916
#include "mbed.h"
2017
#include "mbed_error.h"
2118
#include "mbed_crash_data_offsets.h"
@@ -83,4 +80,3 @@ int main(void)
8380
}
8481

8582
#endif // !MBED_CONF_PLATFORM_CRASH_CAPTURE_ENABLED
86-
#endif // !defined(MBED_CONF_RTOS_PRESENT)

platform/source/mbed_sdk_boot.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,7 @@ int $Super$$main(void);
7676
int $Sub$$main(void)
7777
{
7878
mbed_main();
79+
mbed_error_initialize();
7980
return $Super$$main();
8081
}
8182

@@ -109,6 +110,7 @@ void software_init_hook(void)
109110
int __wrap_main(void)
110111
{
111112
mbed_main();
113+
mbed_error_initialize();
112114
return __real_main();
113115
}
114116

0 commit comments

Comments
 (0)