Could be a good idea to break things up to make it easier to maintain.
Helper functions and such in apropriate files. Main in one and motor type spesific code in as many as it supports. Just include the correct header file for your motor type, and you are all set to go if you want to compile your own code.
|