A CPS-based simulation platform for long production factories