Pilotage moteur de disque dur

Pascal
Messages : 482
Inscription : 13 oct. 2014, 21:45

Re: Pilotage moteur de disque dur

Message par Pascal »

Au moins ça en amuse un !!!
photo-4.JPG
photo-4.JPG (138.22 Kio) Consulté 11655 fois
photo 2.JPG
photo 2.JPG (129.52 Kio) Consulté 11655 fois
photo 1.JPG
photo 1.JPG (132.03 Kio) Consulté 11655 fois
PMorel
Messages : 3748
Inscription : 04 déc. 2013, 22:44
Localisation : Yutz

Re: Pilotage moteur de disque dur

Message par PMorel »

Pauvre Pascal obligé de rattraper le repassage qu'il n'a pas fait mardi et de bricoler ses circuits en douce entre deux serviettes ;-) ;-)
Gérard
Messages : 69
Inscription : 14 mars 2015, 23:36

Re: Pilotage moteur de disque dur

Message par Gérard »

Pascal, si tu ne trouves pas la solution ... donne ta langue au chat !! :D
Gérard
Messages : 69
Inscription : 14 mars 2015, 23:36

Re: Pilotage moteur de disque dur

Message par Gérard »

Plus sérieusement une autre piste pour ton moteur 3 phases...http://elabz.com/bldc-motor-with-arduin ... -software/
Pascal
Messages : 482
Inscription : 13 oct. 2014, 21:45

Re: Pilotage moteur de disque dur

Message par Pascal »

@PMorel

Ouai, je suis un homme battu ;) avec un chat technophile :lol:

@Gérard, oui merci je l'avais trouvé aussi celui-là.
Je cherche à adapter le principe à base de la PWM avec mes ponts on/off.

Un truc fun, à un moment le moteur a tourné super bien, vite et sans à-coups, mais à l'envers !!!!
Là, j'ai vraiment pas compris.
ntrs
Messages : 1628
Inscription : 20 févr. 2014, 14:15
Localisation : rond point merlin,Thionville
Contact :

Re: Pilotage moteur de disque dur

Message par ntrs »

le chat et ses amis ? 8-)
Gérard
Messages : 69
Inscription : 14 mars 2015, 23:36

Re: Pilotage moteur de disque dur

Message par Gérard »

BDLC 3 phases pilotage avec arduino et 3 transistors NPN https://www.youtube.com/watch?v=SRmipUHZe_A
Gérard
Messages : 69
Inscription : 14 mars 2015, 23:36

Re: Pilotage moteur de disque dur

Message par Gérard »

Bonjour,
J'ai trouvé un site polonais qui vend du matériel qui peut nous intéresser http://www.tme.eu/fr/katalog/ qqun connait ?
Autre point la réalisation de ces supports pour moteur (jaune) est-elle envisageable avec une 3D (le DT est en fin de document)
http://www.tme.eu/fr/Document/40e254d24 ... U-2670.pdf
et
http://www.tme.eu/fr/Document/102b25bc1 ... U-2671.pdf

pour info dans les 3€ la paire de supports en alu
Gérard
Messages : 69
Inscription : 14 mars 2015, 23:36

Re: Pilotage moteur de disque dur

Message par Gérard »

@Pascal &Co...

Brushless DC (BLDC) motor with Arduino – Part 2. Circuit and Software
le TEXAS INSTRUMENTS SN754410NE = 1.53€ HT
Sources : http://elabz.com/bldc-motor-with-arduin ... -software/
ce prg diffère

Code : Tout sélectionner

/* 
Driving a three-phase motor from a DVD drive spindle for the stroboscope project
 
This example code is in the public domain. Based on several Arduino code samples
 
http://elabz.com/
 
 */

// constants won't change. They're used here to 
// set pin numbers:
const int buttonPin = 8;// the number of the direction pushbutton pin
const int ledPin =  7;  // the number of the status LED pin (not the flash LED)
const int potPin = 0;  // pot controls the RPM speed
const int potPinFlash = 1;  // pot controls the flash speed
const int motorPin1 =9;
const int motorPin2 =10;
const int motorPin3 =11;
const int motorPins[]={9,10,11};

const int motorPinSteps[3][6]={
{1,1,1,0,0,0},
{1,0,0,0,1,1},
{0,0,1,1,1,0}};

// A different, more illustrative, way of writing the same values below:
//const int motorPinSteps[3][9]={
//{HIGH,HIGH,HIGH,HIGH,LOW,LOW,LOW,LOW,LOW},
//{HIGH,LOW,LOW,LOW,LOW,LOW,HIGH,HIGH,HIGH},
//{LOW,LOW,LOW,HIGH,HIGH,HIGH,HIGH,LOW,LOW}};


const int flashPin =12;
const int motorDelay=500; // together with pot controls the RPM
const int flashDelay=2; // controls duration of flash
const int frames=12; // has to be divisible by 3 in this version
const int serialDelay = 2000; //debug only
long serialLast =0; //debug only
// Variables will change:
boolean ledState = false; // the current state of the status LED output pin
int buttonState;    // the current reading from the direction input pin
int potState;       // the current reading from the RPM speed potentiometer
int potStateFlash; // the current reading from the flash rate potentiometer
int lastButtonState = LOW; 
int debounceDelay = 50;    // the debounce time; increase if the output flickers
boolean direct = true; // direction true=forward, false=backward

int increment;
int flashIncrement = 0;
int currentFlash=0;
int currentStepA=0;
// the following variables are long's because the time, measured in miliseconds,
// will quickly become a bigger number than can be stored in an int.
long lastDebounceTime = 0;  // the last time the output pin was toggled
long motorDelayActual = 0;  // the actual delay, based on pot value and motor delay set above
long flashDelayActual = 0;
long flashDelayPerCycle = 0;
long lastMotorDelayTime = 0;
long flashTime = 0; // how long has flash been ON 
long flashTimeOFF = 0; // how long has flash been OFF 

void setup() {

  pinMode(buttonPin, INPUT);
  pinMode(potPin, INPUT);
  pinMode(potPinFlash, INPUT);
  pinMode(ledPin, OUTPUT);
  pinMode(motorPin1, OUTPUT);
  pinMode(motorPin2, OUTPUT);
  pinMode(motorPin3, OUTPUT);
  pinMode(flashPin, OUTPUT);
  digitalWrite(flashPin, LOW);
}

void loop() {
  // read the state of the switch into a local variable:
  int reading = digitalRead(buttonPin);

  // check to see if you just pressed the button 
  // (i.e. the input went from LOW to HIGH),  and you've waited 
  // long enough since the last press to ignore any noise:  

  // If the switch changed, due to noise or pressing:
  if (reading != lastButtonState) {
    // reset the debouncing timer
    lastDebounceTime = millis();
  } 
  
  if ((millis() - lastDebounceTime) > debounceDelay) {
    // whatever the reading is at, it's been there for longer
    // than the debounce delay, so take it as the actual current state:
    buttonState = reading;
    direct = !direct;
    ledState = !ledState;
    lastButtonState = reading;
  }
  
  // set the LED using the state of the button:
  digitalWrite(ledPin, ledState);

  // save the reading.  Next time through the loop,
  // it'll be the lastButtonState:

 potStateFlash = analogRead(potPinFlash);
 potState = analogRead(potPin);
motorDelayActual = potState * motorDelay / 100; 
flashDelayActual = flashDelay + potStateFlash/100; 

move();

}
void move()
{
if((millis() - flashTime) >  flashDelayActual)
{
  digitalWrite(flashPin, HIGH);
  
} 
  
if((millis() - lastMotorDelayTime) >  motorDelayActual)
{ // delay time passed, move one step 

if (direct==true)
{
  increment = 1;
} else {
  increment = -1;  
} 
  
  lastMotorDelayTime = millis();
  currentFlash = currentFlash + 1;
if(currentFlash>8)
  { 

    digitalWrite(flashPin, LOW);
    currentFlash=0;
    flashTime = millis();
    flashDelayActual = millis();

  }
  currentStepA = currentStepA + increment;
  if(currentStepA > 5) currentStepA = 0;

for(int x=0;x<=2;x++) {
digitalWrite(motorPins[x],motorPinSteps[x][currentStepA]); 
}

}
 
}
Pascal
Messages : 482
Inscription : 13 oct. 2014, 21:45

Re: Pilotage moteur de disque dur

Message par Pascal »

Gérard a écrit :Bonjour,
Autre point la réalisation de ces supports pour moteur (jaune) est-elle envisageable avec une 3D (le DT est en fin de document)
http://www.tme.eu/fr/Document/40e254d24 ... U-2670.pdf
....
J'ai réalisé un premier essai de modèle 3D, en openscad, à base du DT (j'ai fait bourrin).
A vérifier et à tester.

J'attache aussi le STL.

====
//
// Les unités sont en mm
//
$fn=180;
ep=1.5;


module fixation_chassis() {

difference() {
union() {
cube([22, 6, ep]);
translate([5.5, 6, 0])
cube([11, 3.5, ep]);
};

translate([3, 3, 0])
cylinder(h=ep+1, r=1.5);

translate([22-3, 3, 0])
cylinder(h=ep+1, r=1.5);

union() {
translate([11, 3, 0])
cylinder(h=ep+1, r=1.5);
translate([11, 6, 0])
cylinder(h=ep+1, r=1.5);
translate([11-1.5, 3, 0])
cube([3,3,ep+1]);
};
};
};

module fixation_moteur() {
difference() {
cube([22,22.7,ep]);

translate([1+1.5, 1+1.5, 0])
cylinder(h=ep+1, r=1.5);

translate([22-(1+1.5), 1+1.5, 0])
cylinder(h=ep+1, r=1.5);

translate([1+1.5, 22.7-(1+1.5), 0])
cylinder(h=ep+1, r=1.5);

translate([22-(1+1.5), 22.7-(1+1.5), 0])
cylinder(h=ep+1, r=1.5);


translate([0, 22.7/2, 0])
cylinder(h=ep+1, r=5);

translate([11, 22.7/2, 0])
cylinder(h=ep+1, r=5);

translate([22, 22.7/2, 0])
cylinder(h=ep+1, r=5);
};
};

union() {
rotate([270, 0, 0])
translate([0, -9.5, 0])
fixation_chassis();
//translate([0, 9.5, 0])
translate([0, ep, 0])
//rotate([90, 0, 0])
fixation_moteur();
};

====

export1.stl
(1.05 Mio) Téléchargé 560 fois
Répondre