Troubleshooting
We have found some common errors that users face and have listed them here to help you get started with your application as quickly as possible.
Mbed CLI issues or Error: collect2: error: ld returned 1 exit status
Purge the cache with the following command:
mbed cache purge
You probably also have a stale BUILD folder. Clean up your directory and try again:
rm -rf BUILD
Error: Prompt wrapping around line
If your terminal wraps your text as shown here:
In your terminal type:
export PS1='\u@\h: '
For a more minimalist approach, type:
export PS1='> '
Error: "Requires make version 3.82 or later (current is 3.81)"
If you encounter this error, install the brew and make by typing the following code:
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew install make
Note:
On a Mac, you might have to use gmake
instead of make
, to run your commands.
Error: -bash: mbed: command not found
If you encounter this error, try the following fixes.
For Mac:
We recommend using the installer and running the downloaded Mbed CLI App. This app automatically launches a shell with all the dependencies solved for you.
If installed manually, make sure to follow these instructions.
"sed" errors while generating micro speech project
If you encounter the following error while in the Build and compile micro speech example section while generating micro speech project:sed: 1: "tensorflow/lite/micro/t ...": undefined label 'ensorflow/lite/micro/tools/make/downloads/cmsis/CMSIS/RTOS2/Include/cmsis_os2.h' sed: 1: "tensorflow/lite/micro/t ...": undefined label 'ensorflow/lite/micro/tools/make/downloads/cmsis/CMSIS/RTOS2/Include/os_tick.h' sed: 1: "tensorflow/lite/micro/t ...": undefined label 'ensorflow/lite/micro/tools/make/downloads/cmsis/CMSIS/RTOS2/Source/os_tick_gtim.c' sed: 1: "tensorflow/lite/micro/t ...": undefined label 'ensorflow/lite/micro/tools/make/downloads/cmsis/CMSIS/RTOS2/Source/os_systick.c'
add "LC_CTYPE=C" tag when compiling the project:
LC_CTYPE=C make -f tensorflow/lite/micro/tools/make/Makefile TARGET=mbed TAGS="disco_f746ng" generate_micro_speech_mbed_project