02-07-2023 03:01 PM - edited 02-07-2023 03:01 PM
I adapted the pi3g library for reading the values of a sensor with a raspberry pi. To do so I changed the BSEC_SAMPLE_RATE_HIGH_PERFORMANCE to BSEC_SAMPLE_RATE_SCAN and the BSEC_OUTPUT_COMPENSATED_GAS was commented out in the switch and removed from the virtual sensor array (also shifted the last virtual sensor of 1 position because of that).
After that I installed everything following the pi3g instruction but when running the program to take samples to then pass to the bme ai studio software in goes into segmentation fault. I checked the issue on github and updated the amount of memory allocated for the process and the number of core as suggested there, but nothing seems to change.
After that i tried to check what the Raspberry Pi 400 runs and it seems that the architecture is an ARMV8, so i tried to change the configuration of the setup.py to use the PiThree_ARMV8 instead of the default PiThree_ARMV6 and now i'm stuck on this compilation problem:
/usr/bin/ld: BSEC_2.2.0.0_Generic_Release_30052022/algo/normal_version/bin/RaspberryPi/PiThree_ArmV8/libalgobsec.a(GasHumidityBaselineTracker.o)(.text+0x20e4): unresolvable R_ARM_CALL relocation against symbol `truncf@@GLIBC_2.4'
/usr/bin/ld: final link failed: symbol needs debug section which does not exist
collect2: error: ld returned 1 exit status
error: command 'arm-linux-gnueabihf-gcc' failed with exit status 1
Checking on stack overflow it seems like some flags are missing for the gcc so i'll try that, but in the meantime i'd like to know if someone faced the same issue i'm facing and was able to overcome it.
Solved! Go to Solution.
02-14-2023 03:08 AM
Hi Prop4et,
Could we know the compiler version you used?
02-15-2023 11:56 AM
Hi, sorry for the late response.
The gcc compiler is the raspbian 10.2.1-6
python interpreter 3.9.2
02-20-2023 06:53 AM
Hi Prop4et,
Thank for your feedback.
Please try BSEC library from BSEC 2.4.0.0 (BSEC2.4.0.0_Generic_Release_23012023\algo\normal_version\bin\RaspberryPi\PiFour_Armv8).
02-20-2023 05:44 PM
Hi,
i tried changin to the new version of the library, and during the compile process this is what i get
/usr/bin/ld: BSEC2.4.0.0_Generic_Release_23012023/algo/normal_version/bin/RaspberryPi/PiFour_Armv8/libalgobsec.a: error adding symbols: file format not recognized
i tried compiling with adding the bsec_interface_multi and without it but in both cases the error is the same. I don't know if i'm missing a flag or something like that that needs to be added in the seup.py file