Pattern repetition

Dear Community,

I’d like to create patterns seen on the image uploaded, and I would like make the the robot to draw it - but with programmed offset values.
I tried the until distance, but I did not succeed. Maybe a for cycle could work, but I am not a software developer.

Can anyone help?

Assuming you know the total amount of these patterns you could create features for each one.

Hi,

for a simple drawing application and cycles I would recommend the palitizer option.
an explanation is given here

to elaborate on this you could use the transpose function.

this is an example if i think more carefully, i would use a list but for a quick answer

bottom left is orgin and wp_1, up is X +, to the right is y +, in the screen is Z +

length_line = 20
ofset_1 = 10
Ofset_2 = 7

Wp_2 = transe_pose (wp_1, P [length_line * 1 + ofset_1 * 0, Ofset_2 * 0,0,0,0,0]
Wp_3 = transe_pose (wp_1, P [length_line * 1 + ofset_1 * 1, Ofset_2 * 0,0,0,0,0]
Wp_4 = transe_pose (wp_1, P [length_line * 2 + ofset_1 * 1, Ofset_2 * 0,0,0,0,0]

Wp_5 = transe_pose (wp_1, P [length_line * 0 + ofset_1 * 0, Ofset_2 * 1,0,0,0,0]
Wp_6 = transe_pose (wp_1, P [length_line * 1 + ofset_1 * 0, Ofset_2 * 1,0,0,0,0]
Wp_7 = transe_pose (wp_1, P [length_line * 1 + ofset_1 * 1, Ofset_2 * 1,0,0,0,0]
Wp_8 = transe_pose (wp_1, P [length_line * 2 + ofset_1 * 1, Ofset_2 * 1,0,0,0,0]

Wp_9 = transe_pose (wp_1, P [length_line * 0 + ofset_1 * 0, ofset_2 * 2,0,0,0,0]
Wp_10 = transe_pose (wp_1, P [length_line * 1 + ofset_1 * 0, Ofset_2 * 2,0,0,0,0]
Wp_11 = transe_pose (wp_1, P [length_line * 1 + ofset_1 * 1, Ofset_2 * 2,0,0,0,0]
Wp_12 = transe_pose (wp_1, P [length_line * 2 + ofset_1 * 1, Ofset_2 * 2,0,0,0,0]

Wp_13 = transe_pose (wp_1, P [length_line * 0 + ofset_1 * 0, ofset_2 * 3,0,0,0,0]
Wp_14 = transe_pose (wp_1, P [length_line * 1 + ofset_1 * 0, Ofset_2 * 3,0,0,0,0]
Wp_15 = transe_pose (wp_1, P [length_line * 1 + ofset_1 * 1, Ofset_2 * 3,0,0,0,0]
Wp_16 = transe_pose (wp_1, P [length_line * 2 + ofset_1 * 1, Ofset_2 * 3,0,0,0,0]

I hope you understood this and also understand how to do the oblique lines. and for offset Wp_x_offset = transe_pose (wp_x, P [0,0, -0.02,0,0,0]

but I would recommend using palitizer then with each item:

Wp_1 = get current tcp_pose ()
Wp_2 = transe_pose (wp_1, P [length_line, 0,0,0,0,0]

move L (wp_1_offset)
move L (wp_1)
move L (wp_1)
move L (wp_2_offset)

(for a script move you also need to add ad speed and acceleration, but don’t know this by heart, look it up in the script manual.the script I wrote I did quickly, so some errors may occur)

maybe someone will come up with a better idea, but I hope to point you in the right direction.

Regards,

Corné

Thanks for the help from everyone.

Corné, as for the scripting, I wrote none this far. I have the manual, but I do not know how to start with. This is also true for function usage. But i understand more or less the script you wrote.