Bosch Sensortec Community

    cancel
    Showing results for 
    Search instead for 
    Did you mean: 

    BSEC library for Azure Sphere

    Community Moderator

    Re: BSEC library for Azure Sphere

    Could you please try the attached release compiled with the requested flasgs (-fPIC -mfloat-abi=hard -fno-short-enums)?

    Member

    Re: BSEC library for Azure Sphere

    Hi,

    I have tried to link against the library you provided. I can confirm the linker errors are resolved, but there are still the following warnings:

    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(bsec_interface.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(bsec_codegen_do_steps.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(bsec_codegen_get_configuration.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(bsec_codegen_get_state.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(bsec_codegen_get_version.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(bsec_codegen_init.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(bsec_codegen_reset_output.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(bsec_codegen_sensor_control.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(bsec_codegen_set_configuration.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(bsec_codegen_set_state.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(bsec_codegen_update_subscription.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(constructor_bsec.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(Bsec.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(ChannelHub.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(Entity.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(GasHumidityBaselineTracker.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(GasHumidityPreProcessor.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(HumidityTemperatureCorrector.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(IaqEstimator.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(SensorHeatCompensator.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(SensorStatusTracker.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(Serialization.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(bsec_codegen_data.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(bsec_codegen_rtwutil.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(convertHumidity.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(crcCcitt2.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(isequal.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(log.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(log10.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(polyval.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(rdivide_helper.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(sqrt.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(Channel.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(ExpSmoothing.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    /Program Files (x86)/Microsoft Azure Sphere SDK/Sysroots/3+Beta1909/tools/gcc/real-ld.exe: warning: libraries\BSEC\libalgobsec.a(ExpSmoothingBsec.o) uses variable-size enums yet the output is to use 32-bit enums; use of enum values across objects may fail
    

    I will continue testing to see if I can get meaningful numbers out of the BSEC library, but this will take me another day or two.

    Member

    Re: BSEC library for Azure Sphere

    I'm sorry to report I have been unable to have any success with the library you attached.

    There are no more linker errors (there are warnings as previously mentioned), so the build completes successfully. However when I try to run the application, I get an error.

    This error is only occurring if I am calling to the BSEC library eg. bsec_init(). If I don't call any BSEC functions, then everything is okay.

    I have lodged a question on the Azure Sphere forum to see if this is a known issue. https://social.msdn.microsoft.com/Forums/en-US/2a8354d5-9a7c-4046-9431-f10c4fbf4605/error-when-calli...

    Member

    Re: BSEC library for Azure Sphere

    Hi,

    After some discussion, I think the problem may be because the library provided was compiled with gcc-arm-none-eabi ( float unknow ) thumb.

    The Azure Sphere is Linux-based, so I need a library compiled with gcc-arm-linux-eabi-hf.

    Are you able to provide that please?

    The approach that should be guaranteed to work would be to compile the library with the Azure Sphere toolchain addon for Visual Studio https://aka.ms/AzureSphereSDKDownload

    If it's quicker for you to provide a variant of the BSEC library found in COINES (but with -fPIC and hard float) I am happy to try that, but it might have other issues.

    Member

    Re: BSEC library for Azure Sphere

    Hi, I'm not trying to nag, but I would just like to know what the chances of getting a compatible library are.

    The project I am working on is a proof of concept with a hard deadline in a couple of weeks. I'm wanting to get a measure of air quality, and also better-compensated values for temperature and humidity, so was hoping to use the BSEC library with my BME680 on the Azure Sphere board.

    The best possible result for me would be a BSEC library compiled in Visual Studio using the Azure Sphere toolchain as that would certainly be compatible.

    Alternatively your normal Linux library compiled with the options that are required to link to Azure Sphere (see my post at https://community.bosch-sensortec.com/t5/MEMS-sensors-forum/BSEC-library-for-Azure-Sphere/td-p/9840) might work.

    If it's not going to happen I will need to figure out alternative methods or sensors to get the information for my project, so would like to know as soon as possible.

    Thanks, Jeremy

    Icon--AD-black-48x48Icon--address-consumer-data-black-48x48Icon--appointment-black-48x48Icon--back-left-black-48x48Icon--calendar-black-48x48Icon--center-alignedIcon--Checkbox-checkIcon--clock-black-48x48Icon--close-black-48x48Icon--compare-black-48x48Icon--confirmation-black-48x48Icon--dealer-details-black-48x48Icon--delete-black-48x48Icon--delivery-black-48x48Icon--down-black-48x48Icon--download-black-48x48Ic-OverlayAlertIcon--externallink-black-48x48Icon-Filledforward-right_adjustedIcon--grid-view-black-48x48IC_gd_Check-Circle170821_Icons_Community170823_Bosch_Icons170823_Bosch_Icons170821_Icons_CommunityIC-logout170821_Icons_Community170825_Bosch_Icons170821_Icons_CommunityIC-shopping-cart2170821_Icons_CommunityIC-upIC_UserIcon--imageIcon--info-i-black-48x48Icon--left-alignedIcon--Less-minimize-black-48x48Icon-FilledIcon--List-Check-grennIcon--List-Check-blackIcon--List-Cross-blackIcon--list-view-mobile-black-48x48Icon--list-view-black-48x48Icon--More-Maximize-black-48x48Icon--my-product-black-48x48Icon--newsletter-black-48x48Icon--payment-black-48x48Icon--print-black-48x48Icon--promotion-black-48x48Icon--registration-black-48x48Icon--Reset-black-48x48Icon--right-alignedshare-circle1Icon--share-black-48x48Icon--shopping-bag-black-48x48Icon-shopping-cartIcon--start-play-black-48x48Icon--store-locator-black-48x48Ic-OverlayAlertIcon--summary-black-48x48tumblrIcon-FilledvineIc-OverlayAlertwhishlist