daily pastebin goal
38%
SHARE
TWEET

Untitled

a guest Aug 10th, 2018 64 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. void read_sensors(void){
  2.     uint8_t i=0,ii=0;
  3.     float tmp;
  4.     uint8_t samples=200;
  5.     while(i<8){
  6.         tmp=0;
  7.         while(ii<samples){
  8.             tmp = tmp + convertanalog(i);
  9.             ii++;
  10.         }
  11.         ii=0;
  12.         tmp = ((((tmp / samples) / 1024)*900)+32);
  13.         sensor_data[i] = tmp;
  14.         i++;
  15.     }
  16. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top