Code (C):
- void fnCalc_Disp_pH (int itempe)
- {
- // Now Calc ph !
- fnADCInit(5,'h');
- float fpHread=0;
- for(char k=0;k<8;k++)
- {
- fpHread=fpHread+fnADCConv1024Avg();
- // before going any further,check if the mode flag was raised
- // if yes,then just return to the calling function
- if(cModeFlag==1)
- {
- cModeFlag=0; // reset flag for future use...