Thread: Adding new modules using C

  1. #1
    Registered User
    Join Date
    Feb 2012
    Posts
    347

    Adding new modules using C

    I have this question suppose if i develop some modules say A, B, C. And I am confident of modules A, B, C and freeze the development. I start development of module D and i want to keep modules A, B, C completely unaffected by this new development. Is it possible? If I want to do such kind of development is it possible? I can think of creating lib files but never tried. Can I achieve it?
    b. In embedded programming for micro controllers when ever new module is added does all the old module Flash addresses keeps changing?
    In case if it is changing the modules for which the development is freezes, can I fix their addresses and the remaining modules can always begin after that address. I am thinking something like absolute addresses. How far it is feasible?

    I am asking these questions as i want to concentrate only on my new features without worrying about the old features getting affected.

  2. #2
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,659
    > In embedded programming for micro controllers when ever new module is added does all the old module Flash addresses keeps changing?
    They might, it depends on your development environment. Is that important to you?

    First, learn about the difference between a linker and a locator.
    Embedded Systems Glossary: L | Embedded Systems Experts
    The linker's job is to combine all the object files and libraries to produce an image with no unresolved symbols.
    The locator's job is to position the code/data/etc sections at specific points in the memory map so the physical machine can run the code.

    These tools (for embedded systems) usually provide plenty of configuration options to give you fine grain control over where individual parts go in memory. gcc for example allows you to create your own section names for code and data, which then allows the linker/locator to position that wherever you want.

    In short, read the manual!
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Modules
    By qwes3r in forum C Programming
    Replies: 9
    Last Post: 03-27-2015, 09:51 PM
  2. Help with modules
    By Jacob Boyd in forum C++ Programming
    Replies: 3
    Last Post: 10-23-2012, 10:08 AM
  3. modules in C++
    By jamort in forum C++ Programming
    Replies: 1
    Last Post: 06-03-2009, 02:07 AM
  4. Modules
    By Hakim in forum C++ Programming
    Replies: 2
    Last Post: 04-22-2006, 04:53 PM
  5. Modules
    By tim545666 in forum C++ Programming
    Replies: 0
    Last Post: 04-10-2002, 11:44 PM