Most modeling and simulation (M&S) questions about cyber-physical systems (CPS) require expert skills belonging to different scientific fields. The challenges are then to integrate each domain's tools (formalism and simulation software) within the rigorous framework of M&S process. To answer this issue, we give the specifications of the MECSYCO co-simulation middleware which enables to interconnect several pre-existing and heterogeneous M&S tools, so they can simulate a whole CPS together. The middleware performs the cosimulation in a parallel, decentralized and distributable fashion thanks to its modular multi-agent architecture. In order to rigorously integrate tools which use different formalisms, the co-simulation engine of MECSYCO is based on DEVS. The central idea of MECSYCO is to use a DEVS wrapping strategy to integrate each tool into the middleware. Thus, heterogeneous tools can be homogeneously co-simulated in the form of a DEVS system. By using DEVS, MECSYCO benefits from the numerous scientific works which have demonstrated the integrative power of this formalism and gives crucial guidelines to rigorously design wrappers. We demonstrate that our discrete framework can integrate a vast amount of continuous M&S tools by wrapping the FMI standard. To this end, we take advantage of DEVS efforts of the literature (namely, the DEV&DESS hybrid formalism and QSS solvers) to design DEVS wrappers for FMU components. As a side-effect, this wrapping is not restricted to MECSYCO but can be applied in any DEVS-based platform. We evaluate MECSYCO with the proof of concept of a smart-heating use-case, where we co-simulate non DEVS-centric M&S tools.