@wandelbots/nova-js 3.3.0 → 3.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -87,6 +87,28 @@ var MockNovaInstance = class {
87
87
  }
88
88
  async handleAPIRequest(config) {
89
89
  const apiHandlers = [
90
+ {
91
+ method: "GET",
92
+ path: "/cells/:cellId/controllers",
93
+ handle() {
94
+ return ["mock-ur5e"];
95
+ }
96
+ },
97
+ {
98
+ method: "GET",
99
+ path: "/cells/:cellId/controllers/:controllerId",
100
+ handle() {
101
+ return {
102
+ configuration: {
103
+ initial_joint_position: "[0,-1.571,-1.571,-1.571,1.571,-1.571,0]",
104
+ kind: "VirtualController",
105
+ manufacturer: "universalrobots",
106
+ type: "universalrobots-ur5e"
107
+ },
108
+ name: "mock-ur5"
109
+ };
110
+ }
111
+ },
90
112
  {
91
113
  method: "GET",
92
114
  path: "/cells/:cellId/controllers/:controllerId/state",
@@ -162,43 +184,6 @@ var MockNovaInstance = class {
162
184
  };
163
185
  }
164
186
  },
165
- {
166
- method: "GET",
167
- path: "/cells/:cellId/controllers/:controllerId/coordinate-systems",
168
- handle() {
169
- return [{
170
- coordinate_system: "",
171
- name: "world",
172
- reference_coordinate_system: "",
173
- position: [
174
- 0,
175
- 0,
176
- 0
177
- ],
178
- orientation: [
179
- 0,
180
- 0,
181
- 0
182
- ],
183
- orientation_type: "ROTATION_VECTOR"
184
- }, {
185
- coordinate_system: "CS-0",
186
- name: "Default-CS",
187
- reference_coordinate_system: "",
188
- position: [
189
- 0,
190
- 0,
191
- 0
192
- ],
193
- orientation: [
194
- 0,
195
- 0,
196
- 0
197
- ],
198
- orientation_type: "ROTATION_VECTOR"
199
- }];
200
- }
201
- },
202
187
  {
203
188
  method: "GET",
204
189
  path: "/cells/:cellId/controllers/:controllerId/motion-groups/:motionGroupId/description",
@@ -217,68 +202,21 @@ var MockNovaInstance = class {
217
202
  0
218
203
  ]
219
204
  },
220
- tcps: {
221
- Flange: {
222
- name: "Default-Flange",
223
- pose: {
224
- position: [
225
- 0,
226
- 0,
227
- 0
228
- ],
229
- orientation: [
230
- 0,
231
- 0,
232
- 0
233
- ]
234
- }
235
- },
236
- "complex-tcp-position": {
237
- name: "Complex TCP Position",
238
- pose: {
239
- position: [
240
- -200,
241
- 300,
242
- 150
243
- ],
244
- orientation: [
245
- -.12139440409113832,
246
- -.06356210998212003,
247
- -.2023240068185639
248
- ]
249
- }
250
- },
251
- "offset-150mm-xy": {
252
- name: "-150mm XY Offset",
253
- pose: {
254
- position: [
255
- -150,
256
- -150,
257
- 0
258
- ],
259
- orientation: [
260
- 0,
261
- 0,
262
- 0
263
- ]
264
- }
265
- },
266
- "rotated-90deg-z": {
267
- name: "90° Z Axis Rotation",
268
- pose: {
269
- position: [
270
- 0,
271
- 0,
272
- 0
273
- ],
274
- orientation: [
275
- 0,
276
- 0,
277
- 1.5708
278
- ]
279
- }
205
+ tcps: { Flange: {
206
+ name: "Default-Flange",
207
+ pose: {
208
+ position: [
209
+ 0,
210
+ 0,
211
+ 0
212
+ ],
213
+ orientation: [
214
+ 0,
215
+ 0,
216
+ 0
217
+ ]
280
218
  }
281
- },
219
+ } },
282
220
  payloads: { "FPay-0": {
283
221
  name: "FPay-0",
284
222
  payload: 0,
@@ -557,861 +495,39 @@ var MockNovaInstance = class {
557
495
  },
558
496
  {
559
497
  method: "GET",
560
- path: "/cells/:cellId/controllers",
561
- handle() {
562
- return { controllers: [{
563
- controller: "mock-ur5e",
564
- model_name: "UniversalRobots::Controller",
565
- host: "mock-ur5e",
566
- allow_software_install_on_controller: true,
567
- motion_groups: [{
568
- motion_group: "0@mock-ur5e",
569
- name_from_controller: "UR5e",
570
- active: false,
571
- model_from_controller: "UniversalRobots_UR5e"
572
- }],
573
- has_error: false,
574
- error_details: ""
575
- }] };
576
- }
577
- },
578
- {
579
- method: "GET",
580
- path: "/cells/:cellId/controllers/:controllerId",
581
- handle() {
582
- return {
583
- configuration: {
584
- kind: "VirtualController",
585
- manufacturer: "universalrobots",
586
- type: "universalrobots-ur5e"
587
- },
588
- name: "mock-ur5"
589
- };
590
- }
591
- },
592
- {
593
- method: "GET",
594
- path: "/cells/:cellId/motion-groups/:motionGroupId/specification",
595
- handle() {
596
- return {
597
- dh_parameters: [
598
- {
599
- alpha: 1.5707963267948966,
600
- theta: 0,
601
- a: 0,
602
- d: 162.25,
603
- reverse_rotation_direction: false
604
- },
605
- {
606
- alpha: 0,
607
- theta: 0,
608
- a: -425,
609
- d: 0,
610
- reverse_rotation_direction: false
611
- },
612
- {
613
- alpha: 0,
614
- theta: 0,
615
- a: -392.2,
616
- d: 0,
617
- reverse_rotation_direction: false
618
- },
619
- {
620
- alpha: 1.5707963267948966,
621
- theta: 0,
622
- a: 0,
623
- d: 133.3,
624
- reverse_rotation_direction: false
625
- },
626
- {
627
- alpha: -1.5707963267948966,
628
- theta: 0,
629
- a: 0,
630
- d: 99.7,
631
- reverse_rotation_direction: false
632
- },
633
- {
634
- alpha: 0,
635
- theta: 0,
636
- a: 0,
637
- d: 99.6,
638
- reverse_rotation_direction: false
639
- }
640
- ],
641
- mechanical_joint_limits: [
642
- {
643
- joint: "JOINTNAME_AXIS_1",
644
- lower_limit: -6.335545063018799,
645
- upper_limit: 6.335545063018799,
646
- unlimited: false
647
- },
648
- {
649
- joint: "JOINTNAME_AXIS_2",
650
- lower_limit: -6.335545063018799,
651
- upper_limit: 6.335545063018799,
652
- unlimited: false
653
- },
654
- {
655
- joint: "JOINTNAME_AXIS_3",
656
- lower_limit: -6.335545063018799,
657
- upper_limit: 6.335545063018799,
658
- unlimited: false
659
- },
660
- {
661
- joint: "JOINTNAME_AXIS_4",
662
- lower_limit: -6.335545063018799,
663
- upper_limit: 6.335545063018799,
664
- unlimited: false
665
- },
666
- {
667
- joint: "JOINTNAME_AXIS_5",
668
- lower_limit: -6.335545063018799,
669
- upper_limit: 6.335545063018799,
670
- unlimited: false
671
- },
672
- {
673
- joint: "JOINTNAME_AXIS_6",
674
- lower_limit: -6.335545063018799,
675
- upper_limit: 6.335545063018799,
676
- unlimited: false
677
- }
678
- ]
679
- };
680
- }
681
- },
682
- {
683
- method: "GET",
684
- path: "/cells/:cellId/motion-groups/:motionGroupId/safety-setup",
685
- handle() {
686
- return {
687
- safety_settings: [{
688
- safety_state: "SAFETY_NORMAL",
689
- settings: {
690
- joint_position_limits: [
691
- {
692
- joint: "JOINTNAME_AXIS_1",
693
- lower_limit: -2.96705961227417,
694
- upper_limit: 2.96705961227417,
695
- unlimited: false
696
- },
697
- {
698
- joint: "JOINTNAME_AXIS_2",
699
- lower_limit: -1.7453292608261108,
700
- upper_limit: 2.7925267219543457,
701
- unlimited: false
702
- },
703
- {
704
- joint: "JOINTNAME_AXIS_3",
705
- lower_limit: -3.3161256313323975,
706
- upper_limit: .40142571926116943,
707
- unlimited: false
708
- },
709
- {
710
- joint: "JOINTNAME_AXIS_4",
711
- lower_limit: -3.4906585216522217,
712
- upper_limit: 3.4906585216522217,
713
- unlimited: false
714
- },
715
- {
716
- joint: "JOINTNAME_AXIS_5",
717
- lower_limit: -2.4434609413146973,
718
- upper_limit: 2.4434609413146973,
719
- unlimited: false
720
- },
721
- {
722
- joint: "JOINTNAME_AXIS_6",
723
- lower_limit: -4.71238899230957,
724
- upper_limit: 4.71238899230957,
725
- unlimited: false
726
- }
727
- ],
728
- joint_velocity_limits: [
729
- {
730
- joint: "JOINTNAME_AXIS_1",
731
- limit: 3.1415927410125732
732
- },
733
- {
734
- joint: "JOINTNAME_AXIS_2",
735
- limit: 3.1415927410125732
736
- },
737
- {
738
- joint: "JOINTNAME_AXIS_3",
739
- limit: 3.4906585216522217
740
- },
741
- {
742
- joint: "JOINTNAME_AXIS_4",
743
- limit: 6.108652591705322
744
- },
745
- {
746
- joint: "JOINTNAME_AXIS_5",
747
- limit: 6.108652591705322
748
- },
749
- {
750
- joint: "JOINTNAME_AXIS_6",
751
- limit: 6.981317043304443
752
- }
753
- ],
754
- joint_acceleration_limits: [],
755
- joint_torque_limits: [],
756
- tcp_velocity_limit: 1800
757
- }
758
- }],
759
- safety_zones: [
760
- {
761
- id: 1,
762
- priority: 0,
763
- geometry: {
764
- compound: { child_geometries: [
765
- {
766
- convex_hull: { vertices: [
767
- { vertex: [
768
- -800,
769
- -1330,
770
- -1820
771
- ] },
772
- { vertex: [
773
- 1650,
774
- -1330,
775
- -1820
776
- ] },
777
- { vertex: [
778
- 1650,
779
- 1330,
780
- -1820
781
- ] },
782
- { vertex: [
783
- -800,
784
- 1330,
785
- -1820
786
- ] }
787
- ] },
788
- init_pose: {
789
- position: [
790
- 0,
791
- 0,
792
- 0
793
- ],
794
- orientation: [
795
- 0,
796
- 0,
797
- 0,
798
- 1
799
- ]
800
- },
801
- id: "box"
802
- },
803
- {
804
- convex_hull: { vertices: [
805
- { vertex: [
806
- -800,
807
- -1330,
808
- -1820
809
- ] },
810
- { vertex: [
811
- 1650,
812
- -1330,
813
- -1820
814
- ] },
815
- { vertex: [
816
- 1650,
817
- -1330,
818
- 1500
819
- ] },
820
- { vertex: [
821
- -800,
822
- -1330,
823
- 1500
824
- ] }
825
- ] },
826
- init_pose: {
827
- position: [
828
- 0,
829
- 0,
830
- 0
831
- ],
832
- orientation: [
833
- 0,
834
- 0,
835
- 0,
836
- 1
837
- ]
838
- },
839
- id: "box"
840
- },
841
- {
842
- convex_hull: { vertices: [
843
- { vertex: [
844
- -800,
845
- -1330,
846
- -1820
847
- ] },
848
- { vertex: [
849
- -800,
850
- 1330,
851
- -1820
852
- ] },
853
- { vertex: [
854
- -800,
855
- 1330,
856
- 1500
857
- ] },
858
- { vertex: [
859
- -800,
860
- -1330,
861
- 1500
862
- ] }
863
- ] },
864
- init_pose: {
865
- position: [
866
- 0,
867
- 0,
868
- 0
869
- ],
870
- orientation: [
871
- 0,
872
- 0,
873
- 0,
874
- 1
875
- ]
876
- },
877
- id: "box"
878
- },
879
- {
880
- convex_hull: { vertices: [
881
- { vertex: [
882
- 1650,
883
- 1330,
884
- 1500
885
- ] },
886
- { vertex: [
887
- -800,
888
- 1330,
889
- 1500
890
- ] },
891
- { vertex: [
892
- -800,
893
- -1330,
894
- 1500
895
- ] },
896
- { vertex: [
897
- 1650,
898
- -1330,
899
- 1500
900
- ] }
901
- ] },
902
- init_pose: {
903
- position: [
904
- 0,
905
- 0,
906
- 0
907
- ],
908
- orientation: [
909
- 0,
910
- 0,
911
- 0,
912
- 1
913
- ]
914
- },
915
- id: "box"
916
- },
917
- {
918
- convex_hull: { vertices: [
919
- { vertex: [
920
- 1650,
921
- 1330,
922
- 1500
923
- ] },
924
- { vertex: [
925
- -800,
926
- 1330,
927
- 1500
928
- ] },
929
- { vertex: [
930
- -800,
931
- 1330,
932
- -1820
933
- ] },
934
- { vertex: [
935
- 1650,
936
- 1330,
937
- -1820
938
- ] }
939
- ] },
940
- init_pose: {
941
- position: [
942
- 0,
943
- 0,
944
- 0
945
- ],
946
- orientation: [
947
- 0,
948
- 0,
949
- 0,
950
- 1
951
- ]
952
- },
953
- id: "box"
954
- },
955
- {
956
- convex_hull: { vertices: [
957
- { vertex: [
958
- 1650,
959
- 1330,
960
- 1500
961
- ] },
962
- { vertex: [
963
- 1650,
964
- -1330,
965
- 1500
966
- ] },
967
- { vertex: [
968
- 1650,
969
- -1330,
970
- -1820
971
- ] },
972
- { vertex: [
973
- 1650,
974
- 1330,
975
- -1820
976
- ] }
977
- ] },
978
- init_pose: {
979
- position: [
980
- 0,
981
- 0,
982
- 0
983
- ],
984
- orientation: [
985
- 0,
986
- 0,
987
- 0,
988
- 1
989
- ]
990
- },
991
- id: "box"
992
- }
993
- ] },
994
- init_pose: {
995
- position: [
996
- 0,
997
- 0,
998
- 0
999
- ],
1000
- orientation: [
1001
- 0,
1002
- 0,
1003
- 0,
1004
- 1
1005
- ]
1006
- },
1007
- id: "Cell workzone"
1008
- },
1009
- motion_group_uid: 1
1010
- },
1011
- {
1012
- id: 2,
1013
- priority: 0,
1014
- geometry: {
1015
- convex_hull: { vertices: [
1016
- { vertex: [
1017
- 1650,
1018
- 1330,
1019
- -1850
1020
- ] },
1021
- { vertex: [
1022
- 865,
1023
- 1330,
1024
- -1850
1025
- ] },
1026
- { vertex: [
1027
- 865,
1028
- -720,
1029
- -1850
1030
- ] },
1031
- { vertex: [
1032
- 1650,
1033
- -720,
1034
- -1850
1035
- ] },
1036
- { vertex: [
1037
- 1650,
1038
- 1330,
1039
- -920
1040
- ] },
1041
- { vertex: [
1042
- 865,
1043
- 1330,
1044
- -920
1045
- ] },
1046
- { vertex: [
1047
- 865,
1048
- -720,
1049
- -920
1050
- ] },
1051
- { vertex: [
1052
- 1650,
1053
- -720,
1054
- -920
1055
- ] }
1056
- ] },
1057
- init_pose: {
1058
- position: [
1059
- 0,
1060
- 0,
1061
- 0
1062
- ],
1063
- orientation: [
1064
- 0,
1065
- 0,
1066
- 0,
1067
- 1
1068
- ]
1069
- },
1070
- id: "Transport"
1071
- },
1072
- motion_group_uid: 1
1073
- },
1074
- {
1075
- id: 3,
1076
- priority: 0,
1077
- geometry: {
1078
- convex_hull: { vertices: [
1079
- { vertex: [
1080
- 1650,
1081
- 1330,
1082
- -600
1083
- ] },
1084
- { vertex: [
1085
- 865,
1086
- 1330,
1087
- -600
1088
- ] },
1089
- { vertex: [
1090
- 865,
1091
- 430,
1092
- -600
1093
- ] },
1094
- { vertex: [
1095
- 1650,
1096
- 430,
1097
- -600
1098
- ] },
1099
- { vertex: [
1100
- 1650,
1101
- 1330,
1102
- -1250
1103
- ] },
1104
- { vertex: [
1105
- 865,
1106
- 1330,
1107
- -1250
1108
- ] },
1109
- { vertex: [
1110
- 865,
1111
- 430,
1112
- -1250
1113
- ] },
1114
- { vertex: [
1115
- 1650,
1116
- 430,
1117
- -1250
1118
- ] }
1119
- ] },
1120
- init_pose: {
1121
- position: [
1122
- 0,
1123
- 0,
1124
- 0
1125
- ],
1126
- orientation: [
1127
- 0,
1128
- 0,
1129
- 0,
1130
- 1
1131
- ]
1132
- },
1133
- id: "Tunel"
1134
- },
1135
- motion_group_uid: 1
1136
- },
1137
- {
1138
- id: 4,
1139
- priority: 0,
1140
- geometry: {
1141
- convex_hull: { vertices: [
1142
- { vertex: [
1143
- 1650,
1144
- -760,
1145
- -440
1146
- ] },
1147
- { vertex: [
1148
- 900,
1149
- -760,
1150
- -440
1151
- ] },
1152
- { vertex: [
1153
- 900,
1154
- -1330,
1155
- -440
1156
- ] },
1157
- { vertex: [
1158
- 1650,
1159
- -1330,
1160
- -440
1161
- ] },
1162
- { vertex: [
1163
- 1650,
1164
- -760,
1165
- -1800
1166
- ] },
1167
- { vertex: [
1168
- 900,
1169
- -760,
1170
- -1800
1171
- ] },
1172
- { vertex: [
1173
- 900,
1174
- -1330,
1175
- -1800
1176
- ] },
1177
- { vertex: [
1178
- 1650,
1179
- -1330,
1180
- -1800
1181
- ] }
1182
- ] },
1183
- init_pose: {
1184
- position: [
1185
- 0,
1186
- 0,
1187
- 0
1188
- ],
1189
- orientation: [
1190
- 0,
1191
- 0,
1192
- 0,
1193
- 1
1194
- ]
1195
- },
1196
- id: "Fanuc controller"
1197
- },
1198
- motion_group_uid: 1
1199
- },
1200
- {
1201
- id: 6,
1202
- priority: 0,
1203
- geometry: {
1204
- convex_hull: { vertices: [
1205
- { vertex: [
1206
- -200,
1207
- -200,
1208
- -1900
1209
- ] },
1210
- { vertex: [
1211
- 200,
1212
- -200,
1213
- -1900
1214
- ] },
1215
- { vertex: [
1216
- 200,
1217
- 200,
1218
- -1900
1219
- ] },
1220
- { vertex: [
1221
- -200,
1222
- 200,
1223
- -1900
1224
- ] },
1225
- { vertex: [
1226
- -200,
1227
- -200,
1228
- -350
1229
- ] },
1230
- { vertex: [
1231
- 200,
1232
- -200,
1233
- -350
1234
- ] },
1235
- { vertex: [
1236
- 200,
1237
- 200,
1238
- -350
1239
- ] },
1240
- { vertex: [
1241
- -200,
1242
- 200,
1243
- -350
1244
- ] }
1245
- ] },
1246
- init_pose: {
1247
- position: [
1248
- 0,
1249
- 0,
1250
- 0
1251
- ],
1252
- orientation: [
1253
- 0,
1254
- 0,
1255
- 0,
1256
- 1
1257
- ]
1258
- },
1259
- id: "Robot base"
1260
- },
1261
- motion_group_uid: 1
1262
- }
1263
- ],
1264
- robot_model_geometries: [
1265
- {
1266
- link_index: 1,
1267
- geometry: {
1268
- sphere: { radius: 270 },
1269
- init_pose: {
1270
- position: [
1271
- -70,
1272
- -70,
1273
- -50
1274
- ],
1275
- orientation: [
1276
- 0,
1277
- 0,
1278
- 0,
1279
- 1
1280
- ]
1281
- },
1282
- id: "link1_sphere"
1283
- }
1284
- },
1285
- {
1286
- link_index: 2,
1287
- geometry: {
1288
- capsule: {
1289
- radius: 160,
1290
- cylinder_height: 800
1291
- },
1292
- init_pose: {
1293
- position: [
1294
- -450,
1295
- 40,
1296
- 170
1297
- ],
1298
- orientation: [
1299
- 0,
1300
- -Math.SQRT1_2,
1301
- 0,
1302
- Math.SQRT1_2
1303
- ]
1304
- },
1305
- id: "link2_capsule"
1306
- }
1307
- },
1308
- {
1309
- link_index: 3,
1310
- geometry: {
1311
- sphere: { radius: 270 },
1312
- init_pose: {
1313
- position: [
1314
- -110,
1315
- 10,
1316
- -100
1317
- ],
1318
- orientation: [
1319
- 0,
1320
- 0,
1321
- 0,
1322
- 1
1323
- ]
1324
- },
1325
- id: "link3_sphere"
1326
- }
1327
- },
1328
- {
1329
- link_index: 4,
1330
- geometry: {
1331
- capsule: {
1332
- radius: 110,
1333
- cylinder_height: 600
1334
- },
1335
- init_pose: {
1336
- position: [
1337
- 0,
1338
- 300,
1339
- 40
1340
- ],
1341
- orientation: [
1342
- -Math.SQRT1_2,
1343
- 0,
1344
- 0,
1345
- Math.SQRT1_2
1346
- ]
1347
- },
1348
- id: "link4_capsule"
1349
- }
1350
- },
1351
- {
1352
- link_index: 5,
1353
- geometry: {
1354
- sphere: { radius: 75 },
1355
- init_pose: {
1356
- position: [
1357
- 0,
1358
- 0,
1359
- -50
1360
- ],
1361
- orientation: [
1362
- 0,
1363
- 0,
1364
- 0,
1365
- 1
1366
- ]
1367
- },
1368
- id: "link5_sphere"
1369
- }
1370
- }
1371
- ],
1372
- tool_geometries: []
1373
- };
1374
- }
1375
- },
1376
- {
1377
- method: "GET",
1378
- path: "/cells/:cellId/motion-groups/:motionGroupId/tcps",
498
+ path: "/cells/:cellId/controllers/:controllerId/coordinate-systems",
1379
499
  handle() {
1380
- return { tcps: [{
1381
- id: "Flange",
1382
- readable_name: "Default-Flange",
500
+ return [{
501
+ coordinate_system: "",
502
+ name: "world",
503
+ reference_coordinate_system: "",
1383
504
  position: [
1384
505
  0,
1385
506
  0,
1386
507
  0
1387
508
  ],
1388
- rotation: {
1389
- angles: [
1390
- 0,
1391
- 0,
1392
- 0,
1393
- 0
1394
- ],
1395
- type: "ROTATION_VECTOR"
1396
- }
509
+ orientation: [
510
+ 0,
511
+ 0,
512
+ 0
513
+ ],
514
+ orientation_type: "ROTATION_VECTOR"
1397
515
  }, {
1398
- id: "complex-tcp-position",
1399
- readable_name: "Complex TCP Position",
516
+ coordinate_system: "CS-0",
517
+ name: "Default-CS",
518
+ reference_coordinate_system: "",
1400
519
  position: [
1401
- -200,
1402
- 300,
1403
- 150
520
+ 0,
521
+ 0,
522
+ 0
1404
523
  ],
1405
- rotation: {
1406
- angles: [
1407
- -.12139440409113832,
1408
- -.06356210998212003,
1409
- -.2023240068185639,
1410
- 0
1411
- ],
1412
- type: "ROTATION_VECTOR"
1413
- }
1414
- }] };
524
+ orientation: [
525
+ 0,
526
+ 0,
527
+ 0
528
+ ],
529
+ orientation_type: "ROTATION_VECTOR"
530
+ }];
1415
531
  }
1416
532
  }
1417
533
  ];
@@ -1439,209 +555,9 @@ var MockNovaInstance = class {
1439
555
  socket.dispatchEvent(new Event("open"));
1440
556
  console.log("Websocket connection opened from", socket.url);
1441
557
  if (socket.url.includes("/state-stream")) socket.dispatchEvent(new MessageEvent("message", { data: JSON.stringify(defaultMotionState) }));
1442
- if (socket.url.includes("/move-joint")) socket.dispatchEvent(new MessageEvent("message", { data: JSON.stringify({ result: {
1443
- motion_group: "0@ur",
1444
- state: {
1445
- controller: "ur",
1446
- operation_mode: "OPERATION_MODE_AUTO",
1447
- safety_state: "SAFETY_STATE_NORMAL",
1448
- timestamp: "2024-09-18T12:48:26.096266444Z",
1449
- velocity_override: 100,
1450
- motion_groups: [{
1451
- motion_group: "0@ur",
1452
- controller: "ur",
1453
- joint_position: [
1454
- 1.3492152690887451,
1455
- -1.5659207105636597,
1456
- 1.6653711795806885,
1457
- -1.0991662740707397,
1458
- -1.829018235206604,
1459
- 1.264623761177063
1460
- ],
1461
- joint_velocity: { joints: [
1462
- 0,
1463
- 0,
1464
- 0,
1465
- 0,
1466
- 0,
1467
- 0
1468
- ] },
1469
- flange_pose: {
1470
- position: [
1471
- 6.437331889439328,
1472
- -628.4123774830913,
1473
- 577.0569957147832
1474
- ],
1475
- orientation: {
1476
- x: -1.683333649797158,
1477
- y: -1.9783363827298732,
1478
- z: -.4928031860165713
1479
- },
1480
- coordinate_system: ""
1481
- },
1482
- tcp_pose: {
1483
- position: [
1484
- 6.437331889439328,
1485
- -628.4123774830913,
1486
- 577.0569957147832
1487
- ],
1488
- orientation: {
1489
- x: -1.683333649797158,
1490
- y: -1.9783363827298732,
1491
- z: -.4928031860165713
1492
- },
1493
- coordinate_system: "",
1494
- tcp: "Flange"
1495
- },
1496
- velocity: {
1497
- linear: {
1498
- x: 0,
1499
- y: 0,
1500
- z: 0
1501
- },
1502
- angular: {
1503
- x: -0,
1504
- y: 0,
1505
- z: 0
1506
- },
1507
- coordinate_system: ""
1508
- },
1509
- force: {
1510
- force: {
1511
- x: 0,
1512
- y: 0,
1513
- z: 0
1514
- },
1515
- moment: {
1516
- x: 0,
1517
- y: 0,
1518
- z: 0
1519
- },
1520
- coordinate_system: ""
1521
- },
1522
- joint_limit_reached: { limit_reached: [
1523
- false,
1524
- false,
1525
- false,
1526
- false,
1527
- false,
1528
- false
1529
- ] },
1530
- joint_current: { joints: [
1531
- 0,
1532
- 0,
1533
- 0,
1534
- 0,
1535
- 0,
1536
- 0
1537
- ] },
1538
- sequence_number: "671259"
1539
- }],
1540
- sequence_number: "671259"
1541
- },
1542
- movement_state: "MOVEMENT_STATE_MOVING"
1543
- } }) }));
1544
- if (socket.url.includes("/move-tcp")) socket.dispatchEvent(new MessageEvent("message", { data: JSON.stringify({ result: {
1545
- motion_group: "0@ur",
1546
- state: {
1547
- controller: "ur",
1548
- operation_mode: "OPERATION_MODE_AUTO",
1549
- safety_state: "SAFETY_STATE_NORMAL",
1550
- timestamp: "2024-09-18T12:43:12.188335774Z",
1551
- velocity_override: 100,
1552
- motion_groups: [{
1553
- motion_group: "0@ur",
1554
- controller: "ur",
1555
- joint_position: { joints: [
1556
- 1.3352527618408203,
1557
- -1.5659207105636597,
1558
- 1.6653711795806885,
1559
- -1.110615611076355,
1560
- -1.829018235206604,
1561
- 1.264623761177063
1562
- ] },
1563
- joint_velocity: { joints: [
1564
- 0,
1565
- 0,
1566
- 0,
1567
- 0,
1568
- 0,
1569
- 0
1570
- ] },
1571
- flange_pose: {
1572
- position: [
1573
- -2.763015284002938,
1574
- -630.2151479701106,
1575
- 577.524509114342
1576
- ],
1577
- orientation: {
1578
- x: -1.704794877102097,
1579
- y: -1.9722372952861567,
1580
- z: -.4852079204210754
1581
- },
1582
- coordinate_system: ""
1583
- },
1584
- tcp_pose: {
1585
- position: [
1586
- -2.763015284002938,
1587
- -630.2151479701106,
1588
- 577.524509114342
1589
- ],
1590
- orientation: {
1591
- x: -1.704794877102097,
1592
- y: -1.9722372952861567,
1593
- z: -.4852079204210754
1594
- },
1595
- coordinate_system: "",
1596
- tcp: "Flange"
1597
- },
1598
- velocity: {
1599
- linear: {
1600
- x: 0,
1601
- y: 0,
1602
- z: 0
1603
- },
1604
- angular: {
1605
- x: -0,
1606
- y: 0,
1607
- z: 0
1608
- },
1609
- coordinate_system: ""
1610
- },
1611
- force: {
1612
- force: {
1613
- x: 0,
1614
- y: 0,
1615
- z: 0
1616
- },
1617
- moment: {
1618
- x: 0,
1619
- y: 0,
1620
- z: 0
1621
- },
1622
- coordinate_system: ""
1623
- },
1624
- joint_limit_reached: { limit_reached: [
1625
- false,
1626
- false,
1627
- false,
1628
- false,
1629
- false,
1630
- false
1631
- ] },
1632
- joint_current: { joints: [
1633
- 0,
1634
- 0,
1635
- 0,
1636
- 0,
1637
- 0,
1638
- 0
1639
- ] },
1640
- sequence_number: "627897"
1641
- }],
1642
- sequence_number: "627897"
1643
- },
1644
- movement_state: "MOVEMENT_STATE_MOVING"
558
+ if (socket.url.includes("/execution/jogging")) socket.dispatchEvent(new MessageEvent("message", { data: JSON.stringify({ result: {
559
+ message: "string",
560
+ kind: "INITIALIZE_RECEIVED"
1645
561
  } }) }));
1646
562
  }, 10);
1647
563
  }