Rework code organization
Merge pull request #1 from kavu/master

Rework code organization