comparison core/I2c_Codec.cpp @ 476:838a4a4a8580 prerelease

Removed warnings, now libpd_render can compile with Clang as well
author Giulio Moro <giuliomoro@yahoo.it>
date Mon, 20 Jun 2016 21:20:28 +0100
parents 869f5e703844
children
comparison
equal deleted inserted replaced
475:faa5f58c71af 476:838a4a4a8580
164 return 0; 164 return 0;
165 } 165 }
166 166
167 //set fractional part(between 0 and 9999) of the numerator mutliplier of the PLL 167 //set fractional part(between 0 and 9999) of the numerator mutliplier of the PLL
168 int I2c_Codec::setPllD(unsigned int d){ 168 int I2c_Codec::setPllD(unsigned int d){
169 if(d<0 || d>9999) 169 if(d >9999)
170 return 1; 170 return 1;
171 if(writeRegister(0x05, (d>>6)&255)){ // PLL register C: part 1 : 8 most significant bytes of a 14bit integer 171 if(writeRegister(0x05, (d>>6)&255)){ // PLL register C: part 1 : 8 most significant bytes of a 14bit integer
172 printf("I2C error while writing PLL d part 1 : %d", d); 172 printf("I2C error while writing PLL d part 1 : %d", d);
173 return 1; 173 return 1;
174 } 174 }