Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
BLDC kontroler
#7
Taman sam prije 20 min iskopao 2 nova IR2110, kupim jos jedan i imam za trofazni most. Preostaje jedino odabir MOSFET-a, moram vidjet kakvu ponudu imaju u dućanu.


Evo i prve verzije koda, isprobao bi to sa motorom nekog cdroma
Code:
const int AH = 1;
const int AL = 2;
const int BH = 3;
const int BL = 4;
const int CH = 5;
const int CL = 6;
const int pot = A0;

int brzina = 0;
int deadtime = 4;

void setup(){
   pinMode(AH, OUTPUT);
   pinMode(AL, OUTPUT);
   pinMode(BH, OUTPUT);
   pinMode(BL, OUTPUT);
   pinMode(CH, OUTPUT);
   pinMode(CL, OUTPUT);
}

void loop(){
   brzina = analogRead(pot);
   digitalWrite(AH, HIGH);
   digitalWrite(BL, HIGH);
   delay(brzina);
   digitalWrite(AH, LOW);
   digitalWrite(BL, LOW);
   delayMicroseconds(deadtime);
   digitalWrite(BH, HIGH);
   digitalWrite(CL, HIGH);
   delay(brzina);
   digitalWrite(BH, LOW);
   digitalWrite(CL, LOW);
   delayMicroseconds(deadtime);
   digitalWrite(CH, HIGH);
   digitalWrite(AL, HIGH);
   delay(brzina);
   digitalWrite(CH, LOW);
   digitalWrite(AL, LOW);
   delayMicroseconds(deadtime);
}
Reply


Messages In This Thread
BLDC kontroler - by gigabyte091 - 12-06-2014, 11:12 AM
RE: BLDC kontroler - by npejcic - 12-06-2014, 11:29 AM
RE: BLDC kontroler - by Gosha - 12-06-2014, 11:54 AM
RE: BLDC kontroler - by gigabyte091 - 12-06-2014, 02:12 PM
RE: BLDC kontroler - by gigabyte091 - 12-06-2014, 04:40 PM
RE: BLDC kontroler - by mikikg - 12-06-2014, 04:53 PM
RE: BLDC kontroler - by gigabyte091 - 12-06-2014, 06:15 PM
RE: BLDC kontroler - by mikikg - 12-06-2014, 08:09 PM
RE: BLDC kontroler - by gigabyte091 - 12-07-2014, 08:12 PM
RE: BLDC kontroler - by Gosha - 12-07-2014, 09:32 PM
RE: BLDC kontroler - by mikikg - 12-07-2014, 11:31 PM
RE: BLDC kontroler - by gigabyte091 - 12-08-2014, 11:38 AM
RE: BLDC kontroler - by mikikg - 12-08-2014, 04:25 PM
RE: BLDC kontroler - by gigabyte091 - 12-08-2014, 09:22 PM
RE: BLDC kontroler - by gigabyte091 - 12-09-2014, 07:38 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)