A few errors when porting VisSim project into CCS

I ported the VisSim project DRV8312-pmsm-28M35H52 into CCSv5 using the instructions given in this previous post. I'm only getting 6 curious errors during compilation. The following:

#20 identifier "ADC2CTL1" is undefined
#20 identifier "ADC2SOC1CTL" is undefined
#20 identifier "ADC2SOC1CTL" is undefined
#20 identifier "GPEMUX1" is undefined
#20 identifier "TRIG1SEL" is undefined
#20 identifier "TRIG2SEL" is undefined

All but the "GPEMUX1" variables are related to the A/D converter. Am I missing a header file or something? It's strange that the "ADC2CTL1" variables throws an error but the "ADC2CTL2" variable does not.

Any assistance is greatly appreciated. Thanks.

Thanks. Are there other

Thanks. Are there other directions for porting VisSim generated C code into CCS that is specific to this Concerto project? I still have issues with compilation.

As the C28x Concerto core has

As the C28x Concerto core has an FPU you will need to link with lib\ii_F280x_fpusr.lib if you checked "Minimize RAM usage" or lib\ii_F280x_fpu.lib if you didn't.
What issues are you having?

It looks like I need to link

It looks like I need to link a different library. I get an "unresolved symbols remain" and a list of 3 symbols:

unresolved symbol _IQ24atan2PU, first referenced in /vissim80/cg/ii_F280X_fpu.lib unresolved symbol _rampgen_calc, first referenced in ./DRV8312EVM-pmsm-28M35H52 unresolved symbol _svgendq_calc, first referenced in ./DRV8312EVM-pmsm-28M35H52

I also don't understand why the VisSim model imported an IQ24 function since Concerto supports floating point. I did not check the "minimize RAM" option, just for your information.

Thanks for your assistance.

No, that library is correct.

No, that library is correct. It looks like you are missing the VisSim80/cg/lib/F28M35H52lnk.cmd in your project. It will pull in a number of additional libraries. It will also include some object files that will need to be included directly as CCS doesn't like them in the .cmd file. These are:

  • lib\f28xxFLASHboot_fpu.obj
  • lib\initFlash_fpu.obj
  • lib\F28M35x_GlobalVariableDefs.obj

Be sure to make a copy of the .cmd file before editing to remove the .obj references otherwise you won't be able to build from VisSim

Thanks. Unfortunately, this

Thanks. Unfortunately, this did not fix the problem. I'm actually getting more errors on top of the previously mentioned errors. I attached a screen shot of the errors I'm getting. I hate to keep asking about this on the forum - is there a document that describes how this should be done somewhere?

Here is a CCS project that

I can see from the name of

I can see from the name of your undefined registers (ADC2CTL1), that you are using Concerto with 2 ADC units. You must define the preprocessor name "_CONCERTO_" in this case, as Concerto uses certain hardware registers in an incompatible way with previous Piccolo parts.