A. Start by finding applicable Virtual Device Type Handlers (from the Templates, or from the SmartThings GitHub (https://github.com/SmartThingsCommunity/SmartThingsPublic) or from a Community post; for Temperature and Contact Sensor.
B. Make sure each vDTH has added Commands to set the desired Attribute values (temperature, contact); since normally Attributes are set by the physical device and are not exposed to “external setters”.
C. Create two very simple SmartApps (or use CoRE) that
subscribes() to the “real” devices, and issues the attribute update Commands to the Virtual Devices.