Remove the cover of the thermostat to expose the black and white wires as well as the green ground screw.
Install attic fan thermostat switch.
Make one of your wires from the 12 2 either red or black a direct power to your thermostat.
Run nm cable from the attic fan thermostat to the attic light.
Ideally the thermostat should be mounted to a rafter along the wiring path and away from the draft of the fan.
Leave enough cable at each end to work with.
Run a 12 3 w ground from switch box to fan thermostat box.
Place it so it s facing in the direction of the air that s being drawn out of the attic by the fan.
The fan s thermostat is already mounted in a box that s attached to the fan by a flexible conduit.
Staple the cable within 8 inches of both the attic light box and the thermostat box.
Step 1 secure the switch.
Use the hammer and staples to secure the cable to the joists at 12 inch intervals.