Lab 8: IQmath FIR Filter
8 - 36
C2000 Microcontroller Workshop - Numerical Concepts
Adc.c
Filter.c
CodeStartBranch.asm
Gpio.c
DefaultIsr_8.c
Lab.h
DelayUs.asm
Lab_8.cmd
ECap_7_8_9_10_12.c
Main_8.c
EPwm_7_8_9_10_12.c
PieCtrl.c
F2806x_DefaultIsr.h
PieVect.c
F2806x_GlobalVariableDefs.c
SysCtrl.c
F2806x_Headers_nonBIOS.cmd
Watchdog.c
Project Build Options
2.
To configure the build options, right-click on
Lab8
in the
Project Explorer
window and select
Properties
. We need to setup the include search path to include
the IQmath header file. Under “C2000 Compiler” select “
Include Options
”. In the
lower box that opens (“
Add dir to #include search path
”) click the
Add
icon (first icon with green plus sign). Then in the “Add directory path” window type:
${PROJECT_ROOT}/../../IQmath/include
Click
OK
to include the search path.
3.
Next, we need to setup the library search path to include the IQmath library. Under
“C2000 Linker” select “
File Search Path
”. In the top box (“
Include
library file or command file as input
”) click the
Add
icon. Then in the
“Add file path” window type:
IQmath.lib
Click
OK
to include the library file.
In the bottom box (“
Add <dir> to library search path
”) click the
Add
icon. In the “Add directory path” window type:
${PROJECT_ROOT}/../../IQmath/lib
Click
OK
to include the library search path.
Finally, select
OK
to save and close the Properties window.
Include IQmathLib.h
4.
In the
Project Explorer
window edit
Lab.h
and
uncomment
the line that includes
the
IQmathLib.h
header file. Next, in the Function Prototypes section,
uncomment
the function prototype for IQssfir(), the IQ math single-sample FIR filter function. In the
Global Variable References section
uncomment
the four _iq references. Save the changes
and close the file.
Inspect Lab_8.cmd
5.
Open and inspect
Lab_8.cmd
. First, notice that a section called “
IQmath
” is being
linked to
L4SARAM
. The IQmath section contains the IQmath library functions (code).
Second, notice that a section called “
IQmathTables
” is being linked to the
Summary of Contents for C2000 Piccolo LaunchPad
Page 74: ...Interrupts 4 18 C2000 Microcontroller Workshop Reset and Interrupts ...
Page 100: ...Lab 5 System Initialization 5 26 C2000 Microcontroller Workshop System Initialization ...
Page 218: ...Lab 8 IQmath FIR Filter 8 42 C2000 Microcontroller Workshop Numerical Concepts ...
Page 334: ...F28069 controlCARD A 4 C2000 Microcontroller Workshop Appendix A Experimenter s Kit SW2 ...
Page 336: ...F28035 controlCARD A 6 C2000 Microcontroller Workshop Appendix A Experimenter s Kit SW2 SW3 ...