Other Parts Discussed in Thread: MOTORWARE, CONTROLSUITE, BQ76PL455A-Q1
Hello!
I got recommended Instaspin lab 11 as a base for developing software for our own hardware. Everything is working fine with the motor running. We also would like to export some data through UART and in the recieving we would like to have floating point. As the processor we are using, TMSF28069M, have CPU+FPU I guess it would be possible to convert some motor variables, such as "gMotorVars.SpeedRef_krpm" to a float, cast to a int and send through the SCI-interface and then simply read a float in the recieving end.
I got some problems to add FPU support though. I have tried to look in "C28x IQmath Library SPRC990"
I have linked the libraries:
- rts2800_fpu32.lib
- rts2800_fpu32_fast_supplement.lib
- IQmath_fpu32.lib
- 2806xRevB_FastSpinROMSymbols_fpu32.lib
- C28x_VCU_LIB_fpu32.lib (Using CRC as well)
And I have changed "#define MATH_TYPE FLOAT_MATH"
When I try to compile I get several:
#31 expression must have integral type [...], external location: C:\ti\motorware\motorware_1_01_00_16\sw\modules\svgen\src\32b\svgen_current.h C/C++ Problem"
It seems this is occuring where a shift operator is used ( >> ) which does make sense, shifting a floating point value would result in a corrupted value. However, in for example lab 10c which also have floating point support according to the Instaspin labs, the same operation is used without any problem.
If I don't define FLOAT_MATH i get several errors regarding the libraries:
Description Resource Path Location Type
#16008-D file "../libs/IQmath_fpu32.lib<IQ24cosPU.obj>" specifies ISA [Project_name] C/C++ Problem
After I changed "Variant type" for the device in General project settings I get:
- "../libs/2806xRevB_FastSpinROMSymbols_fpu32.lib<TMS320x2806x_REVB_boot_rom_out__EST_getLs_d_H_tmp.obj>" specifies ISA revision "C28FPU32", which is not compatible with ISA revision "C2700" specified in a previous file or on the command line
- "../libs/EST_getIdq_pu.lib<EST_getIdq_pu.obj>" specifies ISA revision "C2800", which is not compatible with ISA revision "C28FPU32" specified in a previous file or on the command line"
So one error contradicts the other? One error says C28FPU32 is specified, and the other error says C28FPU32 is not specified but C2700?
Regards
Robert