Error on compilation of example "Getting Started with Embedded Coder Support Package for BeagleBone Black Hardware"

조회 수: 8(최근 30일)
The beablebone black is properly configured and connected
bbb = beaglebone_black
bbb =
beaglebone_black with properties:
DeviceAddress: ''
Port: 22
When I try do deploy the example I got this error:
IC:/PROGRA~1/MATLAB/R2015b/toolbox/target/codertarget/rtos/inc -o "linuxinitialize.c.o" "C:/PROGRA~1/MATLAB/R2015b/toolbox/target/codertarget/rtos/src/linuxinitialize.c"
In file included from c:\matlab\supportpackages\r2015b\beaglebone\toolbox\target\supportpackages\beaglebone\libc\usr\include\endian.h:60:0,
from c:\matlab\supportpackages\r2015b\beaglebone\toolbox\target\supportpackages\beaglebone\libc\usr\include\bits\waitstatus.h:64,
from c:\matlab\supportpackages\r2015b\beaglebone\toolbox\target\supportpackages\beaglebone\libc\usr\include\stdlib.h:42,
from C:/PROGRA~1/MATLAB/R2015b/toolbox/target/codertarget/rtos/inc/linuxinitialize.h:6,
from C:/PROGRA~1/MATLAB/R2015b/toolbox/target/codertarget/rtos/src/linuxinitialize.c:8:
c:\matlab\supportpackages\r2015b\beaglebone\toolbox\target\supportpackages\beaglebone\libc\usr\include\bits\byteswap.h:75:1: error: unknown type name '__uint64_t'
__bswap_64 (__uint64_t __bsx)
c:\matlab\supportpackages\r2015b\beaglebone\toolbox\target\supportpackages\beaglebone\libc\usr\include\bits\byteswap.h:75:13: error: unknown type name '__uint64_t'
__bswap_64 (__uint64_t __bsx)
In file included from C:/PROGRA~1/MATLAB/R2015b/toolbox/target/codertarget/rtos/inc/linuxinitialize.h:6:0,
from C:/PROGRA~1/MATLAB/R2015b/toolbox/target/codertarget/rtos/src/linuxinitialize.c:8:
c:\matlab\supportpackages\r2015b\beaglebone\toolbox\target\supportpackages\beaglebone\libc\usr\include\stdlib.h:510:35: error: expected ',' or ';' before '__attribute_alloc_size__'
__THROW __attribute_malloc__ __attribute_alloc_size__ ((2)) __wur;
gmake: *** [linuxinitialize.c.o] Error 1
### Build procedure for model: 'beaglebone_gettingstarted' aborted due to an error.
Error(s) encountered while building "beaglebone_gettingstarted":
### Failed to generate all binary outputs.
Any idea how to fix it?
Thanks and best regards,


Venkatachala Sarma
Venkatachala Sarma 2016년 3월 8일
This issue is caused by an incompatibility between the Linaro Toolchain 4.8 (which uses GCC 4.8) and the Debian 8.3 image which was built using GCC 4.9. To resolve this issue, you can download the previous version of the firmware (Debian 7.9) to your BeagleBone Black. The image can be downloaded from the link below:
You can then follow the instructions listed on the BeagleBone Black "Getting Started" page (linked below) to create a microSD card that contains the Debian 7.9 image.
You can then boot the BeagleBone Black with this image. Following the boot, you will need to run the "targetupdater" function in MATLAB. To do this, you can execute the following in the MATLAB Command Window:
>> targetupdater
This will open the "Support Package Installer" target updater. Inside this window, please select the "BeagleBone Black" hardware. You can then follow the instructions to set up the support package. After the target updater completes, you can test your demo model again (link below):
This should compile and run successfully now. Hope this helps.
  댓글 수: 2
Mayuresh Maradkar
Mayuresh Maradkar 2016년 10월 17일
It could be because of the partition of the card. Download SD formatter, and format the card. After that card will work fine.

댓글을 달려면 로그인하십시오.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by