diff --git a/motorDriver.c b/motorDriver.c index 5dd0bf3..8bb0f64 100644 --- a/motorDriver.c +++ b/motorDriver.c @@ -61,11 +61,11 @@ const uchar MD_CS = BIT3; #define MD_CC_toff 0 // 4 bits enum bool MDStatus(){ - unsigned long stat = md_read(MD_GSTAT); + unsigned long stat = MD_read(MD_GSTAT); if(stat != 0){ if(stat == 0x1){ // only a recet has occert // restart the motor driver - md_setup(); + MDInit(); }else{ // one of the motors stopt due to short or overheated or a undervoltage in chargepump // wait a while for checking again __delay_cycles(16000000);