This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Sub classes in NDATA class

Problem:
Is there a way to define groups of variables in different modules and then to force the linker to locate all these in one contiguous memory region. This would be helpful for parameter-variables, which are to be read out from a serial EEPROM. Each module can define its parameter variables, the linker arranges them all together into one contiguous memory area and an other routine can read them all out from the EEPROM in one step.

The RENAMECLASS control seems to be only able to do that for all variables in a module. I'd like to have these feature for individual variables too.

Parents
  • I'm not good at English either :)) I got the idea from your first message.
    The reason why I wrote about structures is because struct is a way of putting a set of variables in a contiguous block of memory. On the other hand, it may seem a bit awkward - having to access your global variables via a structure.
    Since it's possible to place all global variables in a module where you want them, why not put all definitions of global variables in that single module? The modules that use those variables would use declarations to make those variables visible to them.

    - Mike

Reply
  • I'm not good at English either :)) I got the idea from your first message.
    The reason why I wrote about structures is because struct is a way of putting a set of variables in a contiguous block of memory. On the other hand, it may seem a bit awkward - having to access your global variables via a structure.
    Since it's possible to place all global variables in a module where you want them, why not put all definitions of global variables in that single module? The modules that use those variables would use declarations to make those variables visible to them.

    - Mike

Children