cancel
Showing results for 
Search instead for 
Did you mean: 

customization using .ftl and .extSettings not working

Curtis.Allen
Associate II

Hello,

I am using CubeMX version 4.27.0 and trying to customize the code generation. My project is configured as a Makefile project.

First I tried to use the .extSettings file to make minor modifications to the generated Makefile. Nothing worked as advertised.

  • Adding the [Groups] section to the file did not create a new group of files but rather appended the source files to the C_SOURCES list.
  • Added the [Others] section and attempted to add a new define. This was ignored. I did not try to modify the HALModule options.

Then I tried to generate a sample.h file following the instructions. This did not work. The file was stripped down to the bare bones to avoid any possible file generation issues. It still did not work. The file is attached for your reference. I also tried copying the file into the templates directory vs. the extra_templates directory. It still didn't work.

As an extra precaution, CubeMX was restarted prior to each new test.

This is a very cool feature I would like to use but it appears to be totally non-functional.

Thanks

3 REPLIES 3
Noppe.Jack
Senior

Hi Curtis. I use this feature and it works just fine. My project is SW4STM ... have you tried this for one of the non-Makefile project options? (Just to make sure the problem is unique to Makefile versus your use of this feature)

Curtis.Allen
Associate II

I thought of that as the possible answer. That is why I specified that this was a Makefile project.

The bottom line is that we are not using one of the supported IDE products. If it doesn't work for Makefile projects it doesn't work for us.

Curtis.Allen
Associate II

It turns out this is a documentation issue. I was follow the instructions in an application note that indicated you just rename sample_h_ftl to sample_h.ftl to enable generation of that file. It does not mention, that you need to go into the code generation advance preferences and select the FTL files to be generated. After doing that everything worked fine.

The .extSetting file issues are a problem for Makefile projects.