Closed fkerem closed 3 years ago
The problem is that contiki-ng doesn't support the arm gcc toolchain installed in the iot-lab-training docker image (7.3). Contiki-ng only supports 5.4. We are going to deploy an image with a 5.4 available, but not used as default, you will have to prepend it to your PATH.
The problem is that contiki-ng doesn't support the arm gcc toolchain installed in the iot-lab-training docker image (7.3). Contiki-ng only supports 5.4. We are going to deploy an image with a 5.4 available, but not used as default, you will have to prepend it to your PATH.
Thank you so much, could you acknowledge this issue when it is deployed please?
The new fitiolab/iot-lab-jupyterlab
image is available on dockerhub and is deployed on labs.iot-lab.info
. If you are using iot-lab-training
locally (not in labs), you will have to pull the image first: docker pull fitiotlab/iot-lab-jupyterlab:latest
The ARM gcc 5 toolchain is located in /opt/gcc-arm-none-eabi-5_2-2015q4/
and you have to prepend it to your path to be able to used it instead of the default 7.3 one. Just run the following command before compiling:
export PATH=/opt/gcc-arm-none-eabi-5_2-2015q4/bin:${PATH}
Note that you'll have to run this command in each new terminal. You can also add to ~/.bashrc
but this file is reset each the container of your session is started.
The new
fitiolab/iot-lab-jupyterlab
image is available on dockerhub and is deployed onlabs.iot-lab.info
. If you are usingiot-lab-training
locally (not in labs), you will have to pull the image first:docker pull fitiolab/iot-lab-jupyterlab:latest
The ARM gcc 5 toolchain is located in
/opt/gcc-arm-none-eabi-5_2-2015q4/
and you have to prepend it to your path to be able to used it instead of the default 7.3 one. Just run the following command before compiling:export PATH=/opt/gcc-arm-none-eabi-5_2-2015q4/bin:${PATH}
Note that you'll have to run this command in each new terminal. You can also add to
~/.bashrc
but this file is reset each the container of your session is started.
Wow, thank you so much for the quick reply and solution. I appreciate your great support!
@aabadie I cannot pull the image even with the command IOTLAB_LOGIN=<login> docker pull fitiolab/iot-lab-jupyterlab:latest
What should I do? It says:
Error response from daemon: pull access denied for fitiolab/iot-lab-jupyterlab, repository does not exist or may require 'docker login': denied: requested access to the resource is denied
Also, should I follow the steps above if I remove the old version and pull new git repo?
I cannot pull the image even with the command
Sorry, there was a typo in the command I gave above (now fixed) and the docker image you should pull is not fitiotlab/iot-lab-jupyterlab
but fitiotlab/iot-lab-training
:
docker pull fitiotlab/iot-lab-training:latest
Use it only if you are running jupyterlab locally in the iot-lab-training repo. Use make run-docker
as explained in the README.
Yes, I'm running it locally but I'm still getting the compilation errors. Here is what I do from scratch: I removed local iot-lab-training folder to make a clean version. Then, followed the steps below:
docker pull fitiotlab/iot-lab-training:latest
git clone --recursive https://github.com/iot-lab/iot-lab-training
cd iot-lab-training
IOTLAB_LOGIN=<login> make run-docker
http://localhost:8888/?token=
Inside the .ipynb file where I compile the code:
!export PATH=/opt/gcc-arm-none-eabi-5_2-2015q4/bin:${PATH};echo $PATH;gcc --version;make -C $APP_DIR TARGET=iotlab BOARD=m3
I get the $PATH variable as below but still getting compilation errors:
/opt/gcc-arm-none-eabi-5_2-2015q4/bin:/opt/conda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/opt/gcc-arm-none-eabi-7-2018-q2-update/bin
Even though I exclude default toolchain from the path and remove build folder to rebuild, I got the errors.
/opt/gcc-arm-none-eabi-5_2-2015q4/bin:/opt/conda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
With the following code in a cell, I can reproduce the errors:
%env ARCH_PATH = /home/jovyan/contiki-ng/iot-lab-contiki-ng/arch
%env APP_DIR = /home/jovyan/contiki-ng/iot-lab-contiki-ng/contiki-ng/examples/multicast
!export PATH=/opt/gcc-arm-none-eabi-5_2-2015q4/bin:${PATH};echo $PATH;arm-none-eabi-gcc --version;make -C $APP_DIR TARGET=iotlab BOARD=m3
(if using labs.iot-lab.info, the paths are different, one should use /home/jovyan/work/training/
instead of /home/jovyan
)
Unfortunately, the simplest way to the get a successful build is to add WERROR=0
to the make command. Other solutions are to correctly fix the build issues in the contiki fork, or maybe be upstream.
@aabadie Yes, at least I could build the code (with the warnings appearing) by setting WERROR=0 in the make command. Thank you very much.
Trying to build Contiki's multicast (/home/jovyan/contiki-ng/iot-lab-contiki-ng/contiki-ng/examples/multicast) example but it causes "pointer of type 'void *' used in arithmetic" error. Should I suppress the warnings being treated as errors?
command:
!make -C $APP_DIR TARGET=iotlab BOARD=m3