Everything works fine now, I figured out I forgot to comment some lines that declared some variables of types defined in modules. In this way the main application had all the module classes on board, so that these classes were loaded instead of the module ones. Sorry for my stupid mistake.
Thank you, andrea

