eTPU2 division with Freescale C compiler

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

eTPU2 division with Freescale C compiler

872 次查看
RDH75
Contributor I

I am working on programming the eTPU2 peripheral for the MPC5644A, and I am receiving a linker error.

 

When I add a simple division statement in C (for example:  variable_a = variable_b / variable_c) I receive the following error:

 

 

#Error: could not locate symbol '__s32_div_f', required through section...

 

Looks like a runtime library is required, or something.  I cannot find any documentation on runtime libraries with the Freescale eTPU C Compiler.  If anyone knows the solution please help.  Thanks.

标签 (1)
标记 (2)
1 回复

626 次查看
stanish
NXP Employee
NXP Employee

Hello Randall,

Since eTPU doesn’t have signed division instruction, we provide signed division as a library file.

You should include the lib.c file as part of  your build.

You can find the library file from eTPU installation directory at : <CW for ETPU v10.x>\ETPU\ETPU_Tools\Command_Line_Tools\lib

Hope it helps.

Stan