0
$\begingroup$

I am trying to use the UR5 from my computer without having to write any script on the robot. For that, I opened a TCP socket as a client from my computer (in a C program), and the robot indeed does accept the communication.

If I write a UR script command through the TCP socket, the robot interprets it, and does the job.

However, if I send him two consecutive commands, it doesn't behave well. I would expect it to store the commands and not start one until it has finished the previous one (just as a shell would do). Instead, it tries to do both at the same time. As a result, if I tell him to write more than one text messages on the log, some of them get lost. And if I tell him to do various moves, it stops with an error:

Security Stopped
SECURITY CHECK: Torque limit violation

I could tune some parameters in my code to sleep for a few miliseconds or seconds until it should have finished, but there has to be a way to get that from the robot.


The robot does also talk though the socket, but I can't decypher that, and didn't find in the manuals what's the structure of that message. I only know that it's always 560 bytes, and I know it sends it every 10th of a second, and that when the arm is stopped, some parts of the message are constant, and when the arm moves, most of it is changing, so I'm sure it's telling me it's position, movement, and probably more useful information. I would like to be able to interpret those messages.

Here is the part of my code where the robot moves:


#define DELAY       (1000000)

int ur_command  (int ur,
             const char *restrict cmd)
{
    ssize_t n;
    ssize_t len;

    usleep(DELAY);

    len = strlen(cmd);
    n   = write(ur, cmd, len);
    if (n != len)
        goto err;

    len = strlen("\n");
    n   = write(ur, "\n", len);
    if (n != len)
        goto err;

    /* Read socket 10 times (1 second of delay each) */
    for (int k = 0; k < 10; k++) {
        char    buf[BUFSIZ];
        ssize_t m;

        memset(buf, 0, ARRAY_SIZE(buf));
        m   = read(ur, buf, ARRAY_SIZE(buf) - 1);
        buf[m]  = '\0';
        if (m < 0) {
            perrorx("read() failed");
            goto err;
        }
        for (ssize_t j = 0; j < m; j++)
            printf("%.2x ", (unsigned char)buf[j]);
        fputc('\n', stdout);
        fputc('\n', stdout);
        fputc('\n', stdout);
        printf("%s\n", buf);
        usleep(DELAY);
    }

    return  0;
err:
    if (n < 0)
        return  n;
    return  (n % INT_MAX) + 1;
}


[...]
    for (ptrdiff_t i = 0; i < 10; i++) {
        if (ur_command(ur, "movej([-0.106, -1.476, 1.346, -2.664, -2.224, -0.264])"))
            goto out;
        if (ur_command(ur, "movej([0.194, -0.699, 1.324, -2.671, -1.497, -0.264])"))
            goto out;
        if (ur_command(ur, "movej([-0.370, -1.183, 1.377, -1.696, -1.623, -0.209])"))
            goto out;
    }
[...]

And this is stdout:

user@LNV-debian:/media/user/DataNTFS/Alex-dev/git/smr-ur-cam-test$ ./client
New movement:
received 5040 bytes (showing first 560 only):
00 00 02 30 10 00 00 00 1d 00 00 00 00 00 00 10 8e 65 01 01 01 00 00 00 00 00 3f f0 00 00 00 00 00 00 00 00 00 fb 01 bf bb 21 44 d2 92 bd 40 bf bb 22 d0 e5 60 41 8a 00 00 00 00 00 00 00 00 3f 4b bc 5a 42 3e 00 00 41 d8 00 00 42 4e 66 67 fd bf f7 9d a7 e0 96 21 37 bf f7 9d b2 2d 0e 56 04 00 00 00 00 00 00 00 00 c0 20 b1 68 42 3e 00 00 41 f0 cc cd 42 57 99 9a fd 3f f5 89 39 17 c5 20 ec 3f f5 89 37 4b c6 a7 f0 00 00 00 00 00 00 00 00 c0 18 83 ce 42 3d 33 33 41 e0 00 00 42 59 33 33 fd c0 05 4f d3 c6 72 f9 89 c0 05 4f df 3b 64 5a 1d 00 00 00 00 00 00 00 00 3e 52 d2 5a 42 3e 00 00 42 08 cc cd 42 70 00 00 fd c0 01 ca b6 64 62 d4 fa c0 01 ca c0 83 12 6e 98 00 00 00 00 00 00 00 00 bb f9 dc dd 42 3e 00 00 42 10 cc cd 42 6b 99 9a fd bf d0 e5 6f a1 dc 61 c0 bf d0 e5 60 41 89 37 4c 00 00 00 00 00 00 00 00 be 00 0d fe 42 3c 66 67 42 15 33 33 42 70 00 00 fd 00 00 00 35 04 bf e0 d6 88 8c fb b6 7e bf 6c a1 f0 06 ae 39 2b 3f e4 27 77 ab c4 60 ca bf f7 e5 51 42 26 75 72 bf f1 77 6e c5 b4 32 60 3f ca e4 4f 16 17 5f bf 00 00 00 35 09 c0 23 c9 3e aa 35 ca 68 40 26 a1 b5 6f af ec 4f 40 2a 63 46 b3 6d fc 74 c0 05 6e f7 4e f2 65 88 bf 34 ec 5e 0c 8d 6f 33 3f f2 9b f1 1d 87 bd 2d 00 00 00 40 03 00 00 00 00 00 00 3f 44 01 40 14 01 40 14 3f 24 01 40 14 01 40 14 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 41 e3 33 33 42 40 00 00 3f 22 77 80 3e 10 62 4e 08 02 00 00 00 00 25 02 00 00 3f 90 bb fe 01 88 fa 1b 3f 8d a4 c9 44 8c 3e b3 42 34 00 00 00 3b c4 9b a6 42 4c 00 00 fd 00 00 00 3d 07 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 3f 6d 0c f6 b6 74 8e 85 00 00 00 07 08 00 01 
End of msg.
received 5600 bytes (showing first 560 only):
00 00 02 30 10 00 00 00 1d 00 00 00 00 00 00 10 8e d5 01 01 01 00 00 00 00 00 3f f0 00 00 00 00 00 00 00 00 00 fb 01 bf bb 21 44 d2 92 bd 40 bf bb 22 d0 e5 60 41 8a 00 00 00 00 00 00 00 00 3f 5b 3b 2d 42 3e 66 67 41 d8 00 00 42 4e 00 00 fd bf f7 9d a7 e0 96 21 37 bf f7 9d b2 2d 0e 56 04 00 00 00 00 00 00 00 00 c0 21 b2 84 42 3e 66 67 41 f0 cc cd 42 57 99 9a fd 3f f5 89 39 17 c5 20 ec 3f f5 89 37 4b c6 a7 f0 00 00 00 00 00 00 00 00 c0 18 15 9e 42 3d 33 33 41 e0 00 00 42 59 33 33 fd c0 05 4f d3 c6 72 f9 89 c0 05 4f df 3b 64 5a 1d 00 00 00 00 00 00 00 00 3d 6d 5e 9f 42 3e 66 67 42 08 cc cd 42 70 00 00 fd c0 01 ca b6 64 62 d4 fa c0 01 ca c0 83 12 6e 98 00 00 00 00 00 00 00 00 3b 95 ea eb 42 3e 00 00 42 10 cc cd 42 6b 99 9a fd bf d0 e5 6f a1 dc 61 c0 bf d0 e5 60 41 89 37 4c 00 00 00 00 00 00 00 00 bd e0 e0 60 42 3c cc cd 42 15 33 33 42 70 00 00 fd 00 00 00 35 04 bf e0 d6 88 8c fb b6 7e bf 6c a1 f0 06 ae 39 2b 3f e4 27 77 ab c4 60 ca bf f7 e5 51 42 26 75 72 bf f1 77 6e c5 b4 32 60 3f ca e4 4f 16 17 5f bf 00 00 00 35 09 c0 25 4a 7d 1e ff 78 72 40 27 07 43 3d 6d 2f 23 40 2a 37 e6 05 61 43 72 bf f4 d9 e6 22 a7 0a 09 bf bd 69 c2 a6 95 54 d1 3f f0 56 f9 2c a9 22 fc 00 00 00 40 03 00 00 00 00 00 00 3f 34 01 40 14 01 40 14 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 41 e3 33 33 42 40 00 00 3f 34 7a 00 3e 0f 5c 29 08 02 00 00 00 00 25 02 00 00 3f 90 93 31 39 98 bd 35 3f 8e 47 fc 64 4d 32 49 42 34 00 00 00 3b c4 9b a6 42 4c 00 00 fd 00 00 00 3d 07 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 3f 6d 0c f6 b6 74 8e 85 00 00 00 07 08 00 01 
End of msg.
New movement:
received 11200 bytes (showing first 560 only):
00 00 02 30 10 00 00 00 1d 00 00 00 00 00 00 10 8f 53 01 01 01 00 00 00 00 00 3f f0 00 00 00 00 00 00 00 00 00 fb 01 bf bb 21 44 d2 92 bd 40 bf bb 22 d0 e5 60 41 8a 00 00 00 00 00 00 00 00 3f 5a a8 41 42 3e 66 67 41 d8 00 00 42 4e 66 67 fd bf f7 9d a7 e0 96 21 37 bf f7 9d b2 2d 0e 56 04 00 00 00 00 00 00 00 00 c0 21 d7 3e 42 3e 66 67 41 f0 cc cd 42 57 99 9a fd 3f f5 89 39 17 c5 20 ec 3f f5 89 37 4b c6 a7 f0 00 00 00 00 00 00 00 00 c0 18 a8 89 42 3d 33 33 41 e0 00 00 42 58 cc cd fd c0 05 4f d3 c6 72 f9 89 c0 05 4f df 3b 64 5a 1d 00 00 00 00 00 00 00 00 3e 32 06 f7 42 3e 66 67 42 08 cc cd 42 70 00 00 fd c0 01 ca b6 64 62 d4 fa c0 01 ca c0 83 12 6e 98 00 00 00 00 00 00 00 00 3b f9 dc dd 42 3e 00 00 42 10 cc cd 42 6b 99 9a fd bf d0 e5 6f a1 dc 61 c0 bf d0 e5 60 41 89 37 4c 00 00 00 00 00 00 00 00 bd a2 69 29 42 3c cc cd 42 15 33 33 42 70 00 00 fd 00 00 00 35 04 bf e0 d6 88 8c fb b6 7e bf 6c a1 f0 06 ae 39 2b 3f e4 27 77 ab c4 60 ca bf f7 e5 51 42 26 75 72 bf f1 77 6e c5 b4 32 60 3f ca e4 4f 16 17 5f bf 00 00 00 35 09 c0 25 3c 38 70 01 7b 7b 40 27 15 c5 36 3f 14 1c 40 2a 71 bc 42 c7 8f 78 c0 03 0c e1 46 e2 79 8b bf c2 5f 7c 1c 5b c3 55 3f e7 9a 12 95 d7 dd 33 00 00 00 40 03 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 41 e3 33 33 42 40 00 00 3f 19 64 00 3e 11 68 73 08 02 00 00 00 00 25 02 00 00 3f 90 bb fe 01 88 fa 1b 3f 8d f6 62 d4 6c b8 7e 42 34 00 00 00 3b c4 9b a6 42 4c 00 00 fd 00 00 00 3d 07 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 3f 6d 0c f6 b6 74 8e 85 00 00 00 07 08 00 01 
End of msg.
received 5600 bytes (showing first 560 only):
00 00 02 30 10 00 00 00 1d 00 00 00 00 00 00 10 90 4d 01 01 01 00 00 00 00 00 3f f0 00 00 00 00 00 00 00 00 00 fb 01 bf bb 21 44 d2 92 bd 40 bf bb 22 d0 e5 60 41 8a 00 00 00 00 00 00 00 00 3f 54 58 24 42 3e 66 67 41 d8 00 00 42 4e 66 67 fd bf f7 9d a7 e0 96 21 37 bf f7 9d b2 2d 0e 56 04 00 00 00 00 00 00 00 00 c0 1f d5 07 42 3e 66 67 41 f0 cc cd 42 57 99 9a fd 3f f5 89 39 17 c5 20 ec 3f f5 89 37 4b c6 a7 f0 00 00 00 00 00 00 00 00 c0 18 a8 89 42 3d 99 9a 41 e0 00 00 42 58 66 67 fd c0 05 4f d3 c6 72 f9 89 c0 05 4f df 3b 64 5a 1d 00 00 00 00 00 00 00 00 3e 59 11 7a 42 3e 00 00 42 08 cc cd 42 70 00 00 fd c0 01 ca b6 64 62 d4 fa c0 01 ca c0 83 12 6e 98 00 00 00 00 00 00 00 00 ba c7 e3 e4 42 3e 00 00 42 10 cc cd 42 6b 99 9a fd bf d0 e5 b3 97 58 f7 e0 bf d0 e5 60 41 89 37 4c 00 00 00 00 00 00 00 00 bd dd c0 d1 42 3c cc cd 42 15 33 33 42 70 00 00 fd 00 00 00 35 04 bf e0 d6 88 8c fb b6 7e bf 6c a1 f0 06 ae 39 2b 3f e4 27 77 ab c4 60 ca bf f7 e5 47 83 3c e6 7d bf f1 77 7b 1d 31 c0 a0 3f ca e3 f0 5f 32 44 9c 00 00 00 35 09 c0 24 9f 44 eb 17 9c df 40 26 4a a9 9a c4 8e 74 40 2a 71 bc 42 c7 8f 78 c0 05 e3 2c 44 4a c3 3f bf ad 7e af 04 a1 e2 41 3f f0 1c e0 61 5f ad 2a 00 00 00 40 03 00 00 00 00 00 00 3f 34 01 40 14 01 40 14 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 41 e4 00 00 42 40 00 00 3f 10 50 80 3e 14 7a e2 08 02 00 00 00 00 25 02 00 00 3f 90 6a 64 71 a8 80 50 3f 8d 01 96 24 cb 4b 1d 42 34 00 00 00 3b c4 9b a6 42 4c 00 00 fd 00 00 00 3d 07 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 3f 6d 0c f6 b6 74 8e 85 00 00 00 07 08 00 01 
End of msg.
New movement:
received 11200 bytes (showing first 560 only):
00 00 02 30 10 00 00 00 1d 00 00 00 00 00 00 10 90 ca 01 01 01 00 00 01 00 00 3f f0 00 00 00 00 00 00 00 00 00 fb 01 3f c0 32 6f 88 2b 01 1a 3f c0 35 36 12 88 ec d6 3f d1 32 6b 23 43 95 b6 3e e9 01 3d 42 3e 66 67 41 d8 00 00 42 4e cc cd fd bf eb f4 b1 1c de eb 4f bf eb f3 be fd 73 40 07 3f e6 1c f0 c6 33 b8 76 c0 6b 03 74 42 3e 66 67 41 f0 cc cd 42 57 99 9a fd 3f f5 42 cf b7 72 5c e8 3f f5 43 57 8c b0 28 e0 bf 96 ff c3 75 a7 36 39 bf f7 a3 ae 42 3e 66 67 41 e0 cc cd 42 58 66 67 fd c0 05 5a ce 39 a2 24 79 c0 05 5a fd 02 85 05 99 bf 86 df ed de fc d5 13 be 41 a4 c5 42 3e 66 67 42 08 cc cd 42 70 00 00 fd bf fa 90 fe f7 2f 9d 84 bf fa 90 7c 4f ec 02 23 3f e4 50 51 69 53 ce 14 3e b5 ee 6a 42 3e 00 00 42 10 cc cd 42 6b 99 9a fd bf d0 e5 6f a1 dc 61 c0 bf d0 e5 60 41 89 37 4c 00 00 00 00 00 00 00 00 bd e3 ff f0 42 3c cc cd 42 15 33 33 42 70 00 00 fd 00 00 00 35 04 bf e7 66 54 49 f1 7b 13 bf c9 0a 85 ec 69 7a 5d 3f cd eb 1a 8c 34 3d d5 bf f7 4b 61 26 53 b4 11 c0 00 d7 4b b6 f3 5a 14 3f de 51 61 9b a4 6a 0d 00 00 00 35 09 40 02 89 5f 02 f7 b3 29 40 29 99 73 74 53 59 3d bf b7 63 9c 9c 47 2c 1e bf e6 a0 f2 4f ef 42 5a 3f c8 53 e5 15 e8 74 eb 3f f0 91 11 f7 f2 98 ce 00 00 00 40 03 00 00 00 00 00 00 3f 51 81 18 11 81 18 12 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 41 e3 33 33 42 40 00 00 3e 33 f4 00 3e 12 6e 98 08 02 00 00 00 00 25 02 00 00 3f 90 93 31 39 98 bd 35 3f 8d 53 2f b4 ab c4 e8 42 34 00 00 00 3b c4 9b a6 42 4c 00 00 fd 00 00 00 3d 07 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 3f 8a 25 15 74 f8 60 16 00 00 00 07 08 00 01 
End of msg.
received 5600 bytes (showing first 560 only):
00 00 02 30 10 00 00 00 1d 00 00 00 00 00 00 10 91 c4 01 01 01 00 00 00 00 00 3f f0 00 00 00 00 00 00 00 00 00 fb 01 3f c8 d5 87 95 e9 db 16 3f c8 d4 fd f3 b6 45 a2 3f 04 1b 2f 76 bc 6e ee 3f 21 d7 3e 42 3e 00 00 41 d8 00 00 42 4e cc cd fd bf e6 5e 57 a8 21 d3 33 bf e6 5e 35 3f 7c ed 93 00 00 00 00 00 00 00 00 c0 5f 64 57 42 3e 66 67 41 f0 cc cd 42 57 99 9a fd 3f f5 2f 34 66 5d e9 08 3f f5 2f 1a 9f be 76 c8 be fa ce e9 f3 a5 e9 3d c0 04 92 5c 42 3e 00 00 41 e0 00 00 42 58 66 67 fd c0 05 5e 41 3d 25 f9 d9 c0 05 5e 35 3f 7c ed 91 be f9 21 fb 76 a5 b8 ab be 8b c4 58 42 3e 00 00 42 08 cc cd 42 70 00 00 fd bf f7 f3 cb 58 10 9b ac bf f7 f3 b6 45 a1 ca c3 3f 09 21 fb 76 a5 b8 ab 3e af af 4b 42 3e 00 00 42 10 cc cd 42 6b 99 9a fd bf d0 e5 2b ac 5f cb b0 bf d0 e5 60 41 89 37 4c 00 00 00 00 00 00 00 00 be 00 0d fe 42 3c 66 67 42 15 33 33 42 70 00 00 fd 00 00 00 35 04 bf e7 50 73 10 9e fa f5 bf d0 ad 41 8f d0 89 77 3f ba 7b 9b c6 d6 89 4f bf f7 45 5e b0 00 25 09 c0 03 16 2e 72 94 82 5e 3f e1 2e 1b 92 fc 6e 5a 00 00 00 35 09 c0 1f 6f 51 87 91 4f fc 3f dc 45 af c5 e7 b5 75 40 26 f6 c1 90 66 e6 d4 3f f1 02 82 dc 2a 7b 41 c0 09 98 e9 65 30 a6 c6 3f f2 9b f1 1d 87 bd 2d 00 00 00 40 03 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 41 e3 33 33 42 40 00 00 3f 2b 86 80 3e 0f 5c 29 08 02 00 00 00 00 25 02 00 00 3f 90 41 97 a9 b8 43 6b 3f 8d a4 c9 44 8c 3e b3 42 34 00 00 00 3b c4 9b a6 42 4c 00 00 fd 00 00 00 3d 07 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 3f 8c 2d b4 de a0 6d ea 00 00 00 07 08 00 01 
End of msg.
New movement:
received 11200 bytes (showing first 560 only):
00 00 02 30 10 00 00 00 1d 00 00 00 00 00 00 10 92 41 01 01 01 00 00 01 00 00 3f f0 00 00 00 00 00 00 00 00 00 fb 01 bf c5 a3 d9 87 25 c1 20 bf c5 a9 ec 44 60 07 04 bf e2 bf 9e db 96 92 eb be c3 20 90 42 3d 99 9a 41 d8 00 00 42 4e cc cd fd bf f0 2b b7 7e 85 a0 47 bf f0 2b ec 7c 74 99 c9 bf df 72 39 f9 26 db 49 c0 83 10 b2 42 3d 99 9a 41 f0 cc cd 42 57 99 9a fd 3f f5 ba 90 de 71 01 58 3f f5 ba eb c9 5e 0b 8a 3f b0 59 70 6d b7 8e df bf 5f d2 87 42 3c 66 67 41 e0 00 00 42 58 00 00 fd c0 00 58 ab c1 8e b5 52 c0 00 58 27 af b9 d6 7b 3f ed e9 a1 f9 c6 5d 39 3d d7 81 b2 42 3c 66 67 42 08 cc cd 42 70 00 00 fd bf f9 40 f2 1b 89 2a 18 bf f9 40 1b 73 74 1d eb bf c0 f1 c1 21 05 ca 78 3d 47 e3 e4 42 3c 66 67 42 10 cc cd 42 6b 99 9a fd bf cd 43 28 ba 16 48 40 bf cd 42 01 ba 6c da 67 3f ac 97 e9 56 bc 0a 58 3e b1 3f 13 42 3c 66 67 42 15 33 33 42 70 00 00 fd 00 00 00 35 04 bf e6 a0 8b 80 cb 5d b9 3f 85 b4 ad 0a fe ba c1 3f cf 77 a2 4c 03 f6 4d c0 00 a2 d0 9b 1c 67 3b c0 01 a6 24 82 af 13 a6 3f b8 77 b2 0f 2f 8c 8f 00 00 00 35 09 c0 15 05 c5 d7 a1 8a fb 3f f9 6b 4f d6 2d 10 9b 3f f4 78 ef 4a a2 ec 2f 40 01 c3 8a fa c4 7b 0d bf fd 7e a4 07 61 43 32 bf ea d3 50 1f 92 27 d7 00 00 00 40 03 00 00 00 00 00 00 3f 24 01 40 14 01 40 14 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 41 e3 33 33 42 40 00 00 3f 9e 01 c0 3e 12 6e 98 08 02 00 00 00 00 25 02 00 00 3f 90 e4 ca c9 79 37 00 3f 8e 47 fc 64 4d 32 49 42 32 cc cd 00 3b c4 9b a6 42 4c 00 00 fd 00 00 00 3d 07 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 3f 89 c7 21 33 ca 11 f8 00 00 00 07 08 00 01 
End of msg.
received 5600 bytes (showing first 560 only):
00 00 02 30 10 00 00 00 1d 00 00 00 00 00 00 10 93 3b 01 01 01 00 00 01 00 00 3f f0 00 00 00 00 00 00 00 00 00 fb 01 bf d7 ae 6c a8 11 87 00 bf d7 ad e1 5e b8 e3 cf 00 00 00 00 00 00 00 00 3e 45 6c 3e 42 3e 00 00 41 d8 00 00 42 4e cc cd fd bf f2 ed 9e 26 65 68 67 bf f2 ed 9f 96 ce 61 2d 00 00 00 00 00 00 00 00 c0 29 e0 1d 42 3e 66 67 41 f0 cc cd 42 57 99 9a fd 3f f6 08 1c 59 95 ab 4c 3f f6 08 2f a6 d0 0b 3c 3e fa ce e9 f3 a5 e9 3d bf 6f 51 5a 42 3d 33 33 41 e0 00 00 42 59 33 33 fd bf fb 22 d0 53 1d 5e 64 bf fb 22 ff bf 2f f2 6c 3f 12 d9 7c 98 fc 4a 80 3c ae e7 67 42 3e 66 67 42 08 cc cd 42 70 00 00 fd bf f9 f7 be f8 5b 04 40 bf f9 f7 eb ef a8 aa ae bf 09 21 fb 76 a5 b8 ab bd 2e e7 67 42 3e 00 00 42 10 cc cd 42 6b 99 9a fd bf ca c1 19 67 4c 3b e0 bf ca c0 98 5e 2a 16 7e 3f 09 21 fb 76 a5 b8 ab 3e 62 70 28 42 3c 66 67 42 15 33 33 42 70 00 00 fd 00 00 00 35 04 bf e4 23 c5 b5 00 78 a7 3f c0 da 0f 38 21 7a 36 3f d4 62 43 48 a3 e3 35 40 02 e5 97 f1 60 13 7d 40 00 1a cd 2e 5e 0e 73 3f bf 3d ed 93 17 8a fe 00 00 00 35 09 3f e9 0d c6 15 13 50 b2 c0 0a cf ed e4 cf ca 86 c0 19 ac a9 f2 47 fc 0f c0 0b eb c4 98 e7 70 38 bf e5 b5 eb 04 84 79 4b c0 00 f9 fe c6 54 e3 fd 00 00 00 40 03 00 00 00 00 00 00 3f 34 01 40 14 01 40 14 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 41 e3 33 33 42 40 00 00 3f 34 6f 80 3e 0e 56 05 08 02 00 00 00 00 25 02 00 00 3f 90 18 ca e1 c8 06 85 3f 8d a4 c9 44 8c 3e b3 42 34 00 00 00 3b c4 9b a6 42 4c 00 00 fd 00 00 00 3d 07 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 3f 86 63 8e 22 7d 30 c0 00 00 00 07 08 00 01 
End of msg.
New movement:
received 11200 bytes (showing first 560 only):
00 00 02 30 10 00 00 00 1d 00 00 00 00 00 00 10 93 b8 01 01 01 00 00 01 00 00 3f f0 00 00 00 00 00 00 00 00 00 fb 01 bf c8 6b 41 1e 52 b3 e0 bf c8 63 d9 de 02 5e e8 3f d0 ac 96 2f 55 3f 74 3f 33 a1 be 42 3e 00 00 41 d8 00 00 42 4e 66 67 fd bf f6 1d 7a d7 d8 0e c4 bf f6 1d 59 78 b6 71 09 bf d2 34 3d 11 38 cb 4f c0 21 fb f9 42 3e 00 00 41 f0 cc cd 42 57 99 9a fd 3f f5 b1 31 65 55 d9 ec 3f f5 b1 e1 72 14 1b 08 bf a0 20 78 bc 91 ce 4f bf e2 fa 96 42 3c cc cd 41 e0 00 00 42 59 33 33 fd c0 02 d4 53 e0 cc 14 69 c0 02 d4 fa 92 cc 2b e0 bf ee 91 e7 7f 66 be c8 bf 43 fc 71 42 3d 99 9a 42 08 cc cd 42 70 00 00 fd c0 00 40 19 30 1e 5b 84 c0 00 40 91 39 13 27 92 bf e2 b9 df da b1 0e 0e be b8 46 16 42 3c 66 67 42 10 cc cd 42 6b 99 9a fd bf cf 85 b3 de d5 18 00 bf cf 89 93 8c b6 a1 a5 bf ad 57 8c 74 24 b9 f8 be 5c 31 09 42 3c 66 67 42 15 33 33 42 70 00 00 fd 00 00 00 35 04 bf e2 fe 13 7a a3 69 cb 3f a4 d7 19 10 27 f3 3b 3f e1 1b af f7 2b fa 88 bf fb 15 a9 a6 86 fa ab bf f7 6c f9 57 46 d8 e4 3f b2 63 06 26 49 56 34 00 00 00 35 09 bf ef 78 81 33 b2 bf 56 bf fe 2f c9 6c ab 22 36 c0 01 e9 b7 a0 fb 7c ea 40 05 bf 66 2c 95 8d e5 3f f4 2d 20 55 eb 67 ac 3f f3 2d d7 1b d5 31 8c 00 00 00 40 03 00 00 00 00 00 00 3f 3e 01 e0 1e 01 e0 1e 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 41 e3 33 33 42 40 00 00 3f 82 f9 00 3e 13 74 bd 08 02 00 00 00 00 25 02 00 00 3f 91 0d 97 91 69 73 e6 3f 8d 53 2f b4 ab c4 e8 42 32 cc cd 00 3b c4 9b a6 42 4c 00 00 fd 00 00 00 3d 07 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 3f 79 27 23 be cd 58 c8 00 00 00 07 08 00 01 
End of msg.
received 5600 bytes (showing first 560 only):
00 00 02 30 10 00 00 00 1d 00 00 00 00 00 00 10 94 b2 01 01 01 00 00 00 00 00 3f f0 00 00 00 00 00 00 00 00 00 fb 01 bf bb 21 44 ee 06 5d 00 bf bb 22 d0 e5 60 41 8a 00 00 00 00 00 00 00 00 3f 81 fd 39 42 3e 00 00 41 d8 00 00 42 4e 66 67 fd bf f7 9d 9d fd e3 0f 6e bf f7 9d b2 2d 0e 56 05 bf 04 1b 2f 76 bc 6e ee c0 29 96 a7 42 3e 66 67 41 f0 cc cd 42 57 99 9a fd 3f f5 89 42 fa 78 32 b4 3f f5 89 37 4b c6 a7 f0 be fa ce e9 f3 a5 e9 3d c0 17 5d f7 42 3c cc cd 41 e0 00 00 42 58 cc cd fd c0 05 4f d3 c6 72 f9 89 c0 05 4f df 3b 64 5a 1d 3f 19 21 fb 76 a5 b8 ab 3e 36 b6 4e 42 3e 00 00 42 08 cc cd 42 70 00 00 fd c0 01 ca b6 64 62 d4 fa c0 01 ca c0 83 12 6e 98 00 00 00 00 00 00 00 00 3c 79 dc dd 42 3e 00 00 42 10 cc cd 42 6b 99 9a fd bf d0 e5 2b ac 5f cb b0 bf d0 e5 60 41 89 37 4c bf 09 21 fb 76 a5 b8 ab bd f3 9d be 42 3c 66 67 42 15 33 33 42 70 00 00 fd 00 00 00 35 04 bf e0 d6 95 7d cd 91 3e bf 6c a0 8d d2 20 c9 62 3f e4 27 63 ca 81 a8 4c bf f7 e5 61 c6 4d e1 db bf f1 77 72 34 d3 f1 a2 3f ca e4 45 1b 32 99 fe 00 00 00 35 09 c0 29 3f 89 a7 70 a0 ee 40 2a 25 2f b2 85 60 dc 40 29 ef 9a 38 a1 64 6c c0 03 64 08 fe e4 bf d4 bf cb 89 ff 13 06 81 a2 3f f1 b3 8d f0 61 e5 e7 00 00 00 40 03 00 00 00 00 00 00 3f 49 01 90 19 01 90 19 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 41 e3 33 33 42 40 00 00 3f 34 6a 00 3e 0e 56 05 08 02 00 00 00 00 25 02 00 00 3f 90 bb fe 01 88 fa 1b 3f 8d f6 62 d4 6c b8 7e 42 34 00 00 00 3b c4 9b a6 42 4c 00 00 fd 00 00 00 3d 07 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 3f 6d 0d 35 98 32 b5 e6 00 00 00 07 08 00 01 
End of msg.
New movement:
received 11200 bytes (showing first 560 only):
00 00 02 30 10 00 00 00 1d 00 00 00 00 00 00 10 95 2f 01 01 01 00 00 01 00 00 3f f0 00 00 00 00 00 00 00 00 00 fb 01 3f bf 3c 76 b8 6d e3 ae 3f bf 4b 47 ea dd 45 a0 3f d2 81 bb 2d 7d 16 e6 3f 34 34 a9 42 3e 66 67 41 d8 00 00 42 4e cc cd fd bf ec 52 ff 0f 9f 7d 6d bf ec 50 b5 47 55 8d 65 3f e7 72 be ed 16 3b d4 c0 69 01 3d 42 3e 66 67 41 f0 cc cd 42 57 99 9a fd 3f f5 44 1a 33 bb b3 a4 3f f5 44 a8 76 57 70 cf bf 8e 9a b6 94 66 27 84 c0 0e 53 fd 42 3e 00 00 41 e0 00 00 42 58 66 67 fd c0 05 5a 92 c2 d5 21 26 c0 05 5a c7 68 fb dd 10 bf 73 70 48 7d c4 2c d4 be 40 14 fd 42 3e 66 67 42 08 cc cd 42 70 00 00 fd bf fa bd 33 ef f6 61 40 bf fa bb f9 be ec 9c 9c 3f e5 fb 60 d8 3d e2 0c 3e a3 31 0d 42 3e 66 67 42 10 cc cd 42 6b 99 9a fd bf d0 e5 2b ac 5f cb b0 bf d0 e5 60 41 89 37 4c be f9 21 fb 76 a5 b8 ab be 00 0d fe 42 3c cc cd 42 15 33 33 42 70 00 00 fd 00 00 00 35 04 bf e7 5f 96 35 4b 38 1d bf c8 7a 0f aa d2 b4 22 3f cf 02 81 57 5e ea 10 bf f7 4d 7d 27 d8 fa 70 c0 00 b0 af 53 c8 ed e1 3f de 06 d1 b6 5b 73 4f 00 00 00 35 09 bf e3 11 6b 09 f4 96 ec 40 29 86 97 01 b0 61 b2 40 0b f1 9d f8 d9 37 d3 bf e7 cd da e1 2f fb 05 3f e1 db 7f f6 f0 fb 9c 3f f2 9b f1 1d 87 bd 2d 00 00 00 40 03 00 00 00 00 00 00 3f 34 01 40 14 01 40 14 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 41 e3 33 33 42 40 00 00 3e 33 f4 00 3e 13 74 bd 08 02 00 00 00 00 25 02 00 00 3f 90 e4 ca c9 79 37 00 3f 8e 47 fc 64 4d 32 49 42 34 00 00 00 3b c4 9b a6 42 4c 00 00 fd 00 00 00 3d 07 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 3f 89 e8 e9 83 9f 20 af 00 00 00 07 08 00 01 
End of msg.
received 5600 bytes (showing first 560 only):
00 00 02 30 10 00 00 00 1d 00 00 00 00 00 00 10 96 2a 01 01 01 00 00 01 00 00 3f f0 00 00 00 00 00 00 00 00 00 fb 01 3f c8 cf f8 03 76 0a 3d 3f c8 c7 70 f9 05 14 1f bf 9b 83 de 9e d2 89 24 bf 18 15 9e 42 3e 66 67 41 d8 00 00 42 4e cc cd fd bf e6 5f e3 14 1c 9a 97 bf e6 61 1d 7a b7 d2 84 bf 91 72 ed 06 35 dc f0 c0 98 cd 44 42 3e 00 00 41 f0 cc cd 42 57 99 9a fd 3f f5 2f 34 66 5d e9 08 3f f5 2f 43 5f 48 d4 3e be ea ce e9 f3 a5 e9 3d bf f9 12 fa 42 3e 00 00 41 e0 00 00 42 58 66 67 fd c0 05 5d 9f d6 1e 15 66 c0 05 5c be 70 ff 66 6e 3f ac bd 9c 4f ee 02 ed 3e 40 14 fd 42 3e 00 00 42 08 cc cd 42 70 00 00 fd bf f7 f3 ed 52 ce e6 b4 bf f7 f4 17 25 24 b2 9c 3f 09 21 fb 76 a5 b8 ab 3e 52 d2 5a 42 3e 00 00 42 10 cc cd 42 6b 99 9a fd bf d0 e4 e7 b6 e3 35 a0 bf d0 e4 b7 1c cd 49 15 00 00 00 00 00 00 00 00 bd 8c 8c 3c 42 3c cc cd 42 15 33 33 42 70 00 00 fd 00 00 00 35 04 bf e7 50 b8 ab 3e 11 62 bf d0 ab 26 84 72 0c 52 3f ba 82 98 9e 4a 01 0d bf f7 46 7c be 8b 0d f3 c0 03 16 01 d6 a9 d4 ed 3f e1 2c b1 60 e3 cf 28 00 00 00 35 09 c0 01 38 da 79 ac 19 df 40 07 d9 06 b0 3a cd 42 40 25 d4 16 44 d7 3e e6 bf d4 48 5c 7e e6 65 e4 c0 05 8e 87 a5 49 76 59 3f f3 e0 ed a4 1c 56 5c 00 00 00 40 03 00 00 00 00 00 00 3f 24 01 40 14 01 40 14 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 41 e3 33 33 42 40 00 00 3f 61 a2 00 3e 13 74 bd 08 02 00 00 00 00 25 02 00 00 3f 91 0d 97 91 69 73 e6 3f 8e 47 fc 64 4d 32 49 42 34 00 00 00 3b c4 9b a6 42 4c 00 00 fd 00 00 00 3d 07 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 3f 8c 2d ad cc 03 b9 c8 00 00 00 07 08 00 01 
End of msg.
./client:
	client.c:97:
	main():
		write() succeded
	E0 -	Success
user@LNV-debian:/media/user/DataNTFS/Alex-dev/git/smr-ur-cam-test$

How can I know that the arm is stopped (and possibly its position and more useful info) so that I know that it's prepared to receive a new command through the socket?

$\endgroup$
0
$\begingroup$

https://www.universal-robots.com/how-tos-and-faqs/how-to/ur-how-tos/remote-control-via-tcpip/

There is the manual regarding connexions as TCP clients to the robot.

The frequency is "fixed" for a given interface but it varies from one interface to another, and it's the same for all UR models, only difference is that faster interfaces for e-series run at 500 Hz while for CB3 robots they run at 125Hz.

https://s3-eu-west-1.amazonaws.com/ur-support-site/16496/Client_Interface_V3.12andV5.6.xlsx

That file details the contents of the messages sent by the robot (I didn't find that for version 1.8). (If this link breaks, I got it from the first link).

| improve this answer | |
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.