modularize temperature code, delete unnecesarry files