Aller au contenu


Photo
- - - - -

GeekServo - vrai 360° - compatible Lego - comment le programmer


2 réponses à ce sujet

#1 Oracid

Oracid

    Pilier du forum

  • Modérateur
  • PipPipPipPipPip
  • 6 732 messages
  • Gender:Male

Posté 25 mars 2022 - 07:26

Dans cette vidéo, je montre comment programmer le vrai 360° Gray GeekServo, compatible Lego.

Ce servo est de bonne qualité et facile à mettre en oeuvre grace à sa compatibilité Lego.

Avec 2kg.cm de couple, un poids de 20g et un faible volume, il pourrait, par exemple, être utilisé pour la rotation d'une caméra ou d'un télémètre Laser.

 



#2 Oracid

Oracid

    Pilier du forum

  • Modérateur
  • PipPipPipPipPip
  • 6 732 messages
  • Gender:Male

Posté 26 novembre 2022 - 09:17

Hi Cohenkevinlori Queen
 
I think it is best to answer you here, on this forum where I am active. I invite you to join, so we can communicate better.
 
There is an important difference between a servo with continuous rotations and a servo which has a rotation amplitude of 360°.
A servo with continuous rotations makes an infinite number of revolutions, as long as it is activated. Whereas a 360° servo makes a full turn in one direction, then can return to its original position in the opposite direction.
 
To start our exchange, here is the code that you can copy/paste. He is OK.
 
Everything is free of rights and there is no money beetween us.

 

// GeekServo grey - test 0° to 360°
#include <Servo.h>
void(* resetFunc) (void) = 0;               // soft reset function
Servo srv;
void setup() {
  delay(400);                               // for reset consideration
  Serial.begin(9600);
  pinMode(12,INPUT_PULLUP);                 // start/stop/reset button attachment
  srv.attach(3,500,2500);srv.writeMicroseconds(map(0,0,360,500,2500));
  Serial.print("\n\t To start, click on the Start button");  while( digitalRead(12) );  delay(400);  Serial.print("\n\t Started");
}
 
void loop() {
  for(int i=0; i<=360; i++) { srv.writeMicroseconds(map(i,0,360,500,2500)); delay(7);} delay(600);  // from 0° to 360°
  for(int i=360; i>=0; i--) { srv.writeMicroseconds(map(i,0,360,500,2500)); delay(7);} delay(600);  // from 360° to °
  for(int i=0; i<=360; i=i+30) { srv.writeMicroseconds(map(i,0,360,500,2500)); delay(600);}         // 30° step
  for(int i=360; i>=0; i=i-30) { srv.writeMicroseconds(map(i,0,360,500,2500)); delay(600);}         // 30° step
}


#3 Oracid

Oracid

    Pilier du forum

  • Modérateur
  • PipPipPipPipPip
  • 6 732 messages
  • Gender:Male

Posté 13 juin 2023 - 06:24

Je viens de tester le couple du GeekServo Gris.

Paramétré à 180°, avec 7.4V, il soulève 180g, soit environ 1.8kg.cm, avec un palonnier d'environ 10cm (12L = 96mm).





Répondre à ce sujet



  


0 utilisateur(s) li(sen)t ce sujet

0 members, 0 guests, 0 anonymous users