cancel
Showing results for 
Search instead for 
Did you mean: 

CubeMX doesn't always generate MMTAppRegions in the IOC file

GConn
Associate II

CubeMX (6.12.0 anyway)

The IOC file created by CubeMX will be different even if you don't make any changes depending on whether you click in a defined memory region listed under Application Regions.

Without clicking on anything the IOC will contain a line that says MMTAppRegionsCount=0. But merely clicking on a defined memory region listed under Application Regions will cause the line MMTAppRegionsCount=x (where x is the number of application regions) to be written in the IOC file. There will also be numerous lines that give the parameters for those regions.

3 REPLIES 3
Imen.D
ST Employee

Hello @GConn ,

Thank you for having reported this point.

Your request is escalated internally under Ticket tracking number 188434.

(PS: Ticket tracking number 188434 is only for reference, not available outside of ST)

When your question is answered, please close this topic by clicking "Accept as Solution".
Thanks
Imen
Imen.D
ST Employee

Hi @GConn ,

After checking, the Feature MMT is working correctly and there are no build errors.

Can you please clarify the point concerning the MMTAppRegionsCount line: its effect on the correct functionality of the MMT feature?

When your question is answered, please close this topic by clicking "Accept as Solution".
Thanks
Imen

Hello Imen,

Yes, I'd be glad to expound on my topic. My post didn't suggest an error; just an unexpected behavior.

 

A bit of background may help you understand. I'm on a team with multiple developers and we're all developing for the same STM32H563 MCU on the same circuit board. Each developer has changed different aspects of the MCU's configuration according to their tasks' needs. Because there's no way to merge IOC files easily, we manually merge IOC file changes using a few different methods. One method involves generating reports for each developer's projects and using a PDF compare tool to see what configuration changes have been made. Because the generated reports don't include a signal's default level, the gpio.c files are compared. As an aside, why doesn't the generated report PDF give the default level for each signal? It provides all the other information. But it doesn't provide whether a signal defaults to a high or low level at reset like the gpio.c file does. 

 

Anyway, during a peer review of merged IOC files someone noticed that the MMTAppRegionsCount line used to be equal to 0 but was now equal to 3. A couple hours of sleuthing later we determined that merely clicking on a defined memory region listed under Application Regions will cause changed lines to be written in the IOC file. I emphasize that no change was made at all, only a click was made on the UI for the memory region. I am not aware of this behavior anywhere else in the CubeMX tool. That is, anywhere else in the UI a user can click on dropdown menus or enter new values in text boxes but as long as they restore the original value before saving, no changes will be made to the IOC file.

 

The attached image shows an IOC file's contents before merely clicking on a defined memory region on the left side. And the right side shows (in green) the changes written to the IOC file by merely clicking on a defined memory region. Again, no changes were made in the UI.