Error: undefined reference to `softPwmStop': MPU6050 Interfacing with Raspberry Pi

5 views (last 30 days)
Farhan Ahamed
Farhan Ahamed on 18 Sep 2021
I'm trying to Interface MPU6050 with raspberry pi via simulink. I'm using the following library:
and when I build and deploy, I'm getting the following error:
Error executing command "touch -c /home/pi/MATLAB_ws/R2021a/C/Users/Farhan/Documents/MATLAB/Add-Ons/Simulink_Models/Raspberry_Pi_MPU6050_SFunction_with_I2C_Communication_using_WiringPiI2C/MPU6050_Gyro_Accel_ert_rtw/*.*;make -f MPU6050_Gyro_Accel.mk all MATLAB_WORKSPACE="/home/pi/MATLAB_ws/R2021a" -C /home/pi/MATLAB_ws/R2021a/C/Users/Farhan/Documents/MATLAB/Add-Ons/Simulink_Models/Raspberry_Pi_MPU6050_SFunction_with_I2C_Communication_using_WiringPiI2C/MPU6050_Gyro_Accel_ert_rtw". Details:
STDERR: /usr/bin/ld: sf_MPU6050_wrapper.c.o: in function `pinMode':
sf_MPU6050_wrapper.c:(.text+0x2374): undefined reference to `softPwmStop'
/usr/bin/ld: sf_MPU6050_wrapper.c:(.text+0x237c): undefined reference to `softToneStop'
/usr/bin/ld: sf_MPU6050_wrapper.c:(.text+0x24d8): undefined reference to `softPwmCreate'
/usr/bin/ld: sf_MPU6050_wrapper.c:(.text+0x2548): undefined reference to `softToneCreate'
collect2: error: ld returned 1 exit status
make: *** [MPU6050_Gyro_Accel.mk:322: ../MPU6050_Gyro_Accel.elf] Error 1
我不知道如何解决这个问题。我用电线Pi library in raspberry pi. Kindly guide me. Thanks in advance...

Answers (0)

Community Treasure Hunt

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

Start Hunting!