Page 1 of 1

Problem building in eclipse in Ubuntu 16.04

Posted: Sun Nov 12, 2017 10:24 am
by NickCong
Hi
I installed the eclipse and has builded the C/C++ compiler environment, as well as install the ilg.gnuarmeclipse.repository-2.12.1-201604190915. I according to your instruction on the GitHub,i git clone the crazyfliie-firmware to my computer and then import it to the eclipse, I click the button which Build'default'for project'crazyflie-firmware', but it report error in the makeflie , report as follows:
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
make all
ERROR: One or more of the git submodules are not initialized. Try
git submodule init
git submodule update
make: *** [check_submodules] Error 255
Makefile:377: recipe for target 'check_submodules' failed
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
Description Resource Path Location Type
recipe for target 'check_submodules' failed Makefile /crazyflie-firmware line 377 C/C++ Problem

Description Resource Path Location Type
make: *** [check_submodules] Error 255 crazyflie-firmware C/C++ Problem
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
Image
Image
I haven't changed the makefile file. What's the problem? What should I do?

Re: Problem building in eclipse in Ubuntu 16.04

Posted: Sun Nov 12, 2017 6:58 pm
by derf
Hi,

You should follow the instructions mentioned in the error :) :

Code: Select all

ERROR: One or more of the git submodules are not initialized. Try
git submodule init
git submodule update
You can either do this on the command line in the crazyflie-firmware dir or
inside Eclipse:
- switch to the Git perspective
- in the Git Repositories view on the left side expand the crazyflie-firmware entry
- right-click on "Submodules" -> click on "Update submodules"

Hope that helps.

Regards,

Fred

Re: Problem building in eclipse in Ubuntu 16.04

Posted: Tue Nov 14, 2017 5:00 pm
by NickCong
derf wrote:
Sun Nov 12, 2017 6:58 pm
Hi,

You should follow the instructions mentioned in the error :) :

Code: Select all

ERROR: One or more of the git submodules are not initialized. Try
git submodule init
git submodule update
You can either do this on the command line in the crazyflie-firmware dir or
inside Eclipse:
- switch to the Git perspective
- in the Git Repositories view on the left side expand the crazyflie-firmware entry
- right-click on "Submodules" -> click on "Update submodules"

Hope that helps.

Regards,

Fred
Hi Derf
thank you for your answer, may be you are right, i want try it by your instruction,but when i import a new downloaded crazyflie-firmware project and then compile it in eclipse, it report a new problem,it is not the problem like before,i feel upset. i am a new ,it is my first time to touch the eclipse,i think may be i am not so familiar with the eclipse environment,may be i have some setting in eclipse is error. i am great appreciate you :D
oh ,i have a question is that i can't compile the crazyflie-firmware code in the eclipse,but i can modify code in eclipse,so can i modify code in eclipse and save it and then i use the terminal to compile it ,is this the same as compile in eclipse? :?:

Re: Problem building in eclipse in Ubuntu 16.04

Posted: Wed Nov 15, 2017 7:46 am
by kristoffer
Yes, compiling from the command line is exactly the same thing.
A short guide

To clean a project (that is to remove all previously built files) to make sure the compiler is not reusing a file that is changed. This is usually not required, but there are some cases where the compiler can not understand that a file must be rebuilt.

Code: Select all

make clean
To build (compile) a project

Code: Select all

make
To flash the firmware to the Crazyflie using a Crazyradio

Code: Select all

make cload

Re: Problem building in eclipse in Ubuntu 16.04

Posted: Wed Nov 15, 2017 2:43 pm
by NickCong
kristoffer wrote:
Wed Nov 15, 2017 7:46 am
Yes, compiling from the command line is exactly the same thing.
A short guide

To clean a project (that is to remove all previously built files) to make sure the compiler is not reusing a file that is changed. This is usually not required, but there are some cases where the compiler can not understand that a file must be rebuilt.

Code: Select all

make clean
To build (compile) a project

Code: Select all

make
To flash the firmware to the Crazyflie using a Crazyradio

Code: Select all

make cload
Hi Kristoffer:
Thank you for your enthusiastic answer,i follow your guide,it can make,but it has report warning in this,it seems that gcc/arm-none-eabi has a minor question,it says like follow

Code: Select all

 CLEAN_VERSION
  CC    list.o
  CC    tasks.o
  CC    queue.o
  CC    timers.o
  CC    heap_4.o
  CC    port.o
  CC    stm32f4xx_adc.o
  CC    stm32f4xx_dbgmcu.o
  CC    stm32f4xx_dma.o
  CC    stm32f4xx_exti.o
  CC    stm32f4xx_flash.o
  CC    stm32f4xx_gpio.o
  CC    stm32f4xx_i2c.o
  CC    stm32f4xx_iwdg.o
  CC    stm32f4xx_rcc.o
  CC    stm32f4xx_spi.o
  CC    stm32f4xx_tim.o
  CC    stm32f4xx_usart.o
  CC    stm32f4xx_misc.o
  CC    stm32f4xx_syscfg.o
  CC    main.o
  CC    exti.o
  CC    nvic.o
  CC    motors.o
  CC    crtp.o
  CC    ledseq.o
  CC    freeRTOSdebug.o
  CC    buzzer.o
  CC    system.o
  CC    comm.o
  CC    console.o
  CC    pid.o
  CC    crtpservice.o
  CC    param.o
  CC    log.o
  CC    worker.o
  CC    trigger.o
  CC    sitaw.o
  CC    queuemonitor.o
  CC    msp.o
  CC    commander.o
  CC    crtp_commander.o
  CC    crtp_commander_rpyt.o
  CC    crtp_commander_generic.o
  CC    crtp_localization_service.o
  CC    attitude_pid_controller.o
  CC    sensfusion6.o
  CC    stabilizer.o
  CC    position_estimator_altitude.o
  CC    position_controller_pid.o
  CC    estimator.o
  CC    estimator_complementary.o
  CC    controller_pid.o
  CC    power_distribution_stock.o
  CC    filter.o
  CC    cpuid.o
  CC    cfassert.o
  CC    eprintf.o
  CC    crc.o
  CC    num.o
  CC    debug.o
  VTMPL version.c
  CC    version.o
  CC    FreeRTOS-openocd.o
  AS    startup_stm32f40xx.o
  CC    system_stm32f4xx.o
  CC    usb_core.o
  CC    usb_dcd_int.o
  CC    usb_dcd.o
  CC    usbd_ioreq.o
  CC    usbd_req.o
  CC    usbd_core.o
  CC    diskio.o
  CC    ff.o
  CC    syscall.o
  CC    unicode.o
  CC    fatfs_sd.o
  CC    platform_cf2.o
  CC    led_f405.o
  CC    mpu6500.o
  CC    i2cdev_f405.o
  CC    ws2812_cf2.o
  CC    lps25h.o
  CC    i2c_drv.o
  CC    ak8963.o
  CC    eeprom.o
  CC    maxsonar.o
  CC    piezo.o
  CC    uart_syslink.o
  CC    swd.o
  CC    uart1.o
  CC    uart2.o
  CC    watchdog.o
  CC    cppm.o
  CC    bmi055_accel.o
  CC    bmi055_gyro.o
  CC    bmi160.o
  CC    bmp280.o
  CC    bstdr_comm_support.o
  CC    bmm150.o
  CC    pca9685.o
  CC    vl53l0x.o
  CC    pca95x4.o
  CC    usb_bsp.o
  CC    usblink.o
  CC    usbd_desc.o
  CC    usb.o
  CC    pm_f405.o
  CC    syslink.o
  CC    radiolink.o
  CC    ow_syslink.o
  CC    proximity.o
  CC    usec_time.o
  CC    sensors_cf2.o
  CC    libdw1000.o
  CC    libdw1000Spi.o
  CC    platformservice.o
  CC    sound_cf2.o
  CC    extrx.o
  CC    sysload.o
  CC    mem_cf2.o
  CC    estimator_kalman.o
  CC    deck.o
  CC    deck_info.o
  CC    deck_drivers.o
  CC    deck_test.o
  CC    deck_constants.o
  CC    deck_digital.o
  CC    deck_analog.o
  CC    deck_spi.o
  CC    bigquad.o
  CC    rzr.o
  CC    ledring12.o
  CC    buzzdeck.o
  CC    gtgps.o
  CC    cppmdeck.o
  CC    usddeck.o
  CC    zranger.o
  CC    locodeck.o
  CC    lpsTwrTag.o
  CC    flowdeck.o
  CC    oa.o
  CC    exptest.o
  CC    configblockeeprom.o
  CC    crc_bosch.o
  CC    sleepus.o
  LD    cf2.elf
/usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/bin/ld: warning: /usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/lib/armv7e-m/fpu/libc_nano.a(lib_a-atexit.o) uses 2-byte wchar_t yet the output is to use 4-byte wchar_t; use of wchar_t values across objects may fail
/usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/bin/ld: warning: /usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/lib/armv7e-m/fpu/libc_nano.a(lib_a-ctype_.o) uses 2-byte wchar_t yet the output is to use 4-byte wchar_t; use of wchar_t values across objects may fail
/usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/bin/ld: warning: /usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/lib/armv7e-m/fpu/libc_nano.a(lib_a-errno.o) uses 2-byte wchar_t yet the output is to use 4-byte wchar_t; use of wchar_t values across objects may fail
/usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/bin/ld: warning: /usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/lib/armv7e-m/fpu/libc_nano.a(lib_a-exit.o) uses 2-byte wchar_t yet the output is to use 4-byte wchar_t; use of wchar_t values across objects may fail
/usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/bin/ld: warning: /usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/lib/armv7e-m/fpu/libc_nano.a(lib_a-fini.o) uses 2-byte wchar_t yet the output is to use 4-byte wchar_t; use of wchar_t values across objects may fail
/usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/bin/ld: warning: /usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/lib/armv7e-m/fpu/libc_nano.a(lib_a-impure.o) uses 2-byte wchar_t yet the output is to use 4-byte wchar_t; use of wchar_t values across objects may fail
/usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/bin/ld: warning: /usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/lib/armv7e-m/fpu/libc_nano.a(lib_a-init.o) uses 2-byte wchar_t yet the output is to use 4-byte wchar_t; use of wchar_t values across objects may fail
/usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/bin/ld: warning: /usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/lib/armv7e-m/fpu/libc_nano.a(lib_a-memcpy.o) uses 2-byte wchar_t yet the output is to use 4-byte wchar_t; use of wchar_t values across objects may fail
/usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/bin/ld: warning: /usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/lib/armv7e-m/fpu/libc_nano.a(lib_a-memset.o) uses 2-byte wchar_t yet the output is to use 4-byte wchar_t; use of wchar_t values across objects may fail
/usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/bin/ld: warning: /usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/lib/armv7e-m/fpu/libc_nano.a(lib_a-strcpy.o) uses 2-byte wchar_t yet the output is to use 4-byte wchar_t; use of wchar_t values across objects may fail
/usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/bin/ld: warning: /usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/lib/armv7e-m/fpu/libc_nano.a(lib_a-strlen.o) uses 2-byte wchar_t yet the output is to use 4-byte wchar_t; use of wchar_t values across objects may fail
/usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/bin/ld: warning: /usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/lib/armv7e-m/fpu/libc_nano.a(lib_a-strncmp.o) uses 2-byte wchar_t yet the output is to use 4-byte wchar_t; use of wchar_t values across objects may fail
/usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/bin/ld: warning: /usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/lib/armv7e-m/fpu/libc_nano.a(lib_a-strncpy.o) uses 2-byte wchar_t yet the output is to use 4-byte wchar_t; use of wchar_t values across objects may fail
/usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/bin/ld: warning: /usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/lib/armv7e-m/fpu/libc_nano.a(lib_a-strtol.o) uses 2-byte wchar_t yet the output is to use 4-byte wchar_t; use of wchar_t values across objects may fail
/usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/bin/ld: warning: /usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/lib/armv7e-m/fpu/libc_nano.a(lib_a-__atexit.o) uses 2-byte wchar_t yet the output is to use 4-byte wchar_t; use of wchar_t values across objects may fail
/usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/bin/ld: warning: /usr/lib/gcc/arm-none-eabi/4.9.3/../../../arm-none-eabi/lib/armv7e-m/fpu/libc_nano.a(lib_a-__call_atexit.o) uses 2-byte wchar_t yet the output is to use 4-byte wchar_t; use of wchar_t values across objects may fail
  COPY  cf2.hex
  COPY  cf2.bin
  DFUse cf2.dfu
Crazyflie 2.0 build!
Build 39:e51e195cfe8f (2017.06-39) MODIFIED
Version extracted from git
Crazyloader build!
   text	   data	    bss	    dec	    hex	filename
 139692	   2592	  63240	 205524	  322d4	cf2.elf
but it success build,so will these warnings have a big impact? if yes ,what should i do?

Re: Problem building in eclipse in Ubuntu 16.04

Posted: Mon Jan 22, 2018 12:53 pm
by kristoffer
Sorry for the late answer, I completely missed it!
I don't think the warnings will cause any problems. If you update to the latest version of of the tool chain the warnings should go away.