- cleaned up makefiles
- polished code to avoid warnings
This commit is contained in:
20
ecbdriv.c
20
ecbdriv.c
@@ -526,39 +526,39 @@ static int downloadECBParam(pECBMotDriv self){
|
||||
We assume that all parameters have useful values. It is the task of
|
||||
SetDriverPar to ensure just that!
|
||||
*/
|
||||
if(status = loadAcceleration(self) <= 0){
|
||||
if((status = loadAcceleration(self) <= 0)){
|
||||
return 0;
|
||||
}
|
||||
|
||||
if(status = loadSpeed(self,ObVal(self->driverPar,STARTSPEED),6) <= 0){
|
||||
if((status = loadSpeed(self,ObVal(self->driverPar,STARTSPEED),6) <= 0)){
|
||||
return 0;
|
||||
}
|
||||
|
||||
if(status = loadSpeed(self,ObVal(self->driverPar,MAXSPEED),5) <= 0){
|
||||
if((status = loadSpeed(self,ObVal(self->driverPar,MAXSPEED),5) <= 0)){
|
||||
return 0;
|
||||
}
|
||||
|
||||
if(status = loadSpeed(self,ObVal(self->driverPar,SLOWAUTO),4) <= 0){
|
||||
if((status = loadSpeed(self,ObVal(self->driverPar,SLOWAUTO),4) <= 0)){
|
||||
return 0;
|
||||
}
|
||||
|
||||
if(status = loadSpeed(self,ObVal(self->driverPar,SLOWMAN),10) <= 0){
|
||||
if((status = loadSpeed(self,ObVal(self->driverPar,SLOWMAN),10) <= 0)){
|
||||
return 0;
|
||||
}
|
||||
|
||||
if(status = loadDelay(self) <= 0){
|
||||
if((status = loadDelay(self) <= 0)){
|
||||
return 0;
|
||||
}
|
||||
|
||||
if(status = loadMulti(self) <= 0){
|
||||
if((status = loadMulti(self) <= 0)){
|
||||
return 0;
|
||||
}
|
||||
|
||||
if(status = ecbLoadEncoder(self->ecb) <= 0){
|
||||
if((status = ecbLoadEncoder(self->ecb) <= 0)){
|
||||
return 0;
|
||||
}
|
||||
|
||||
if(status = loadOffset(self,ObVal(self->driverPar,OFFSET)) <= 0){
|
||||
if((status = loadOffset(self,ObVal(self->driverPar,OFFSET)) <= 0)){
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -572,7 +572,7 @@ static int downloadECBParam(pECBMotDriv self){
|
||||
self->driverPar[MULT].fVal = .0;
|
||||
}
|
||||
|
||||
if(status = loadGearing(self) <= 0){
|
||||
if((status = loadGearing(self) <= 0)){
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user