Hi,
We can provide with a suitable C script to measure CPU temperature. But we need to know the type of OS which you need this code for, i.e Windows or Linux. If you provide us with the details, we will prepare the script, test it and deliver.
Thank You