Page 2 of 2 FirstFirst 12
Results 11 to 18 of 18

Thread: Project of robotic Arm with dynamixel motors

  1. #11

    Re: Project of robotic Arm with dynamixel motors

    I tried to answer in the other thread. As I mentioned there, it was difficult to answer without additional information.

    With this thread, I will assume you have programmed the board before, so you have Arduino and hardware folder installed.

    Again check to make sure your Arduino board type is correctly set.

    Try unplugging everything from your board (except power and FTDI cable). Again assuming you are using FTDI cable to program your board and not USB AVR programmer (personally I recommend using these).

    If you have some form of Volt meter try checking to make sure you have voltages in different places. Check jumper settings.

    Do you have a different FTDI cable you can try. One of mine that came with a PhantomX failed. This one was a combination XBee and FTDI cable. I think it was one of these (http://www.trossenrobotics.com/uartsbee). I instead use one of these: http://www.trossenrobotics.com/store...-Cable-5V.aspx

    Again hard to say. But again try unplugging everything as maybe there is a short on one of the Servos, or ...

  2. Re: Project of robotic Arm with dynamixel motors

    Thank you KurtEck again!


    As I say to you in the other thread, yesterday I managed to get it working by downloading the arbotix libraries again and also downloading and updating the drivers for the cable connection.

    I do not know what the sudden error should be but it's already solved, thanks anyway!

    I will continue with my project from today!

    Urko

  3. Re: Project of robotic Arm with dynamixel motors

    Hello again!!

    I still working with the robotic arm!

    And I want to make a program in arduino that has an emergency button , (I have managed to make an interruption in the pin), and what I want now is that when I press the emergency button, i want the robot stops (that is, to stop the motors). I have tried to do it by means of the following code: (the part of the code that I teach below is the one that is inside the function of the button, that is, what happens once you press the button.)


    Code:
    ISR(PCINT1_vect) {
    interrupt_state = (PINB & 0x1E) >> 1;
    j=1;
    while (j=1) {
    Serial.println("EMERGENCY BUTTON!");
    TorqueOn(SERVO_ID[0]);
    TorqueOn(SERVO_ID[1]);
    TorqueOn(SERVO_ID[2]);
    TorqueOn(SERVO_ID[3]);
    delay(2000);
    }
    }

    And yes, it works, but what happens is that depending on what position is the robot when i press the botton, it asks for too much load in one or more motors, and that motor makes a strange noise, as of not being able to support so much load, and then it stops working and the red alarm LED goes on, so the robot does not get stop (the motor that stop working get free and this part of the arm fall down.


    Having seen this problem, and since at the moment I do not know how to solve it, I have thought about doing something different. I explain, instead of pressing the emergency button and the robot stops, I thought about making the robot go to a fixed position, at a very small speed.


    The problem now is that by putting the code "setgoalposition" to the motors, the motors go to that position as quickly as possible, so,i have been testing different codes like setting the torque, speed,... before give the order to move but... :

    Code:
    ISR(PCINT1_vect) {
    interrupt_state = (PINB & 0x1E) >> 1;
    j=1;
    while (j=1) {
    Serial.println("EMERGENCY BUTTON!");
    ax12SetRegister(SERVO_ID[0], AX_TORQUE_LIMIT_L ,50);
    ax12SetRegister(SERVO_ID[1], AX_TORQUE_LIMIT_L ,50);
    ax12SetRegister(SERVO_ID[2], AX_TORQUE_LIMIT_L ,50);
    ax12SetRegister(SERVO_ID[3], AX_TORQUE_LIMIT_L ,50);
    dxlSetGoalPosition(SERVO_ID[0], 3820);
    dxlSetGoalPosition(SERVO_ID[1], 400);
    dxlSetGoalPosition(SERVO_ID[2], 230);
    dxlSetGoalPosition(SERVO_ID[3], 2395);
    delay(2000);
    }
    }
    But they do not work for me, so if someone knew how to make the robot not ask for so much load (first problem) or if someone knew how to make the engines go at a low speed to the desired position, I would appreciate it.


    Urko

  4. #14

    Re: Project of robotic Arm with dynamixel motors

    I don't have MX servos and the GoalSpeed did not work very well on AX servos, but I thought it worked reasonably on MX servos.

    Have you tried setting it to a low number?

    http://support.robotis.com/en/produc...tor_Address_20

  5. Re: Project of robotic Arm with dynamixel motors

    Do you mean 'TorqueOff' ?

  6. Re: Project of robotic Arm with dynamixel motors

    thank you for answering!!

    Hugh, no, i mean Torqueon, my idea is that when i press the button the robot stop in the position that is at that moment, so i have to put torque on, to force the robot to stay at that position. The problem is that as the material of the robot is very heavy, when i want to stop the robot in a extreme position (with the arm lifted), the motor suffer a overload, and gets off. So, i don´t know what can i do, and in consequence, i have planed the other idea of moving the motor to the initial position.

    KurtEck, i have proved what yo say (goalspeed), and the robot do the same as before. But the clue is that i think i have other different problem, because i have beern fixing and the program neither do the println("EMERGENCY BUTTON!!"), only is printing "EM", as if it has not time to print... the program print "EM" and then the robot move fastly to the rest position, so i don´t know what problem can i have...

    Urko.

  7. #17

    Re: Project of robotic Arm with dynamixel motors

    Again sorry, it is hard to offer very much advice without additional information. Like maybe post a small program that demonstrates what you are trying to do and the failure. Sometimes it is the order things are called or maybe something else that is happening. For example are you using protocol 1 or 2... I have only used protocol 1 (AX servos).

    AX library (which one?) Do you have a link to it? If Trossen/Interbotix libraries, than they have the Bioloid part of the library with multiple servo moves with timing... So you should for example when you hit the button, be able to first do a query of the current positions, and then tell them all to go to some new position and say take 1 second or the like.

    But there could be several other possible issues, like maybe there is a power drain that happens which causes the voltage to drop too low and the board resets, or some bad call, that is resetting the program or ...

    Again hard to know without seeing much.

  8. Re: Project of robotic Arm with dynamixel motors

    You're right, I should put more information, sorry, it's my first posts here!


    Regarding the protocol, I do not know what you mean, so I can not answer you, I'm sorry.


    The library that I use is the <ax12.h>, and the link is the following:


    https://github.com/vanadiumlabs/arbo...Bioloid/ax12.h


    This morning I tried to do the following:

    Code:
    ISR(PCINT1_vect) {
      interrupt_state = (PINB & 0x1E) >> 1;
         
         Serial.println("EMERGENCY BUTTON!");
         TorqueOn(SERVO_ID[0]);
         TorqueOn(SERVO_ID[1]);
         TorqueOn(SERVO_ID[2]);
         TorqueOn(SERVO_ID[3]);
        int pos_em_1 = dxlGetPosition(SERVO_ID[0]); //Actual servo position
        int pos_em_2 = dxlGetPosition(SERVO_ID[1]);
        int pos_em_3 = dxlGetPosition(SERVO_ID[2]);
        int pos_em_4 = dxlGetPosition(SERVO_ID[3]);
        int pos2_1 = 3820; //rest position of the robot (the positions of the 4 dynamixel)
        int pos2_2 = 400;
        int pos2_3 = 230;
        int pos2_4 = 2395;
    
    
        go_position_EMERGENCY(pos_em_1, pos_em_1, pos_em_1, pos_em_1, pos2_1, pos2_2, pos2_3, pos2_4);//function
     while(1);
    }

    I think that's what you told me to do, right? I register the positions when I give the button, and then send the robot to the new position (rest position), (go_position_EMERGENCY is a funciton that moves the robot to the rest position), here is the function:

    Code:
    //The following function will move the robot to the initial position and to the resting position when you have presed the EMERGENCY BUTTON!!
    void go_position_EMERGENCY(int pos_em_1, int pos_em_2, int pos_em_3, int pos_em_4, int pos2_1, int pos2_2, int pos2_3, int pos2_4)
    {
      while (pos_em_1 != pos2_1 || pos_em_2 != pos2_2 || pos_em_3 != pos2_3 || pos_em_4 != pos2_4)
      {
        //ID1
        if (pos2_1 < pos_em_1)
        {
          dxlSetGoalPosition(SERVO_ID[0], pos_em_1);
          pos_em_1--;
          delayMicroseconds(2000);
        }
        else if (pos2_1 > pos_em_1)
        {
          dxlSetGoalPosition(SERVO_ID[0], pos_em_1);
          pos_em_1++;
          delayMicroseconds(2000);
        }
        //ID2
        if (pos2_2 < pos_em_2)
        {
          dxlSetGoalPosition(SERVO_ID[1], pos_em_2);
          pos_em_2--;
          delayMicroseconds(2000);
        }
        else if (pos2_2 > pos_em_2)
        {
          dxlSetGoalPosition(SERVO_ID[1], pos_em_2);
          pos_em_2++;
          delayMicroseconds(2000);
        }
        //ID3
        if (pos2_3 < pos_em_3)
        {
          dxlSetGoalPosition(SERVO_ID[2], pos_em_3);
          pos_em_3--;
          delayMicroseconds(2000);
        }
        else if (pos2_3 > pos_em_3)
        {
          dxlSetGoalPosition(SERVO_ID[2], pos_em_3);
          pos_em_3++;
          delayMicroseconds(2000);
        }
        //ID4
        if (pos2_4 < pos_em_4)
        {
          dxlSetGoalPosition(SERVO_ID[3], pos_em_4);
          pos_em_4--;
          delayMicroseconds(2000);
        }
        else if (pos2_4 > pos_em_4)
        {
          dxlSetGoalPosition(SERVO_ID[3], pos_em_4);
          pos_em_4++;
          delayMicroseconds(2000);
        }
      }
    }


    But the robot firstly moves very fast to other position (i don´t know why) and then it returns slowly to the rest position, so i don´t understand why the robot do that.
    Also, in this program the Serial.println("EMERGENCY BUTTON!") didn´t print at all while i press the button... other time only is printing "EM"...

    I don´t think that there is a power drain that happens which causes the voltage to drop too low and the board resets, or some bad call, that is resetting the program or, because after that the program continues running ok.


    So, i don´t know what can be the problem...

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 0
    Last Post: 07-11-2017, 07:27 AM
  2. Replies: 8
    Last Post: 06-01-2015, 06:22 PM
  3. Replies: 0
    Last Post: 05-06-2012, 10:23 PM
  4. Question(s) replacing wheelchair motors for Mutant Shopping Cart Project
    By LUCKY13 in forum Mechanics / Construction
    Replies: 4
    Last Post: 06-21-2010, 09:30 PM
  5. Project C# Dynamixel Project
    By MikeG in forum Software and Programming
    Replies: 6
    Last Post: 01-12-2010, 09:21 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •