I have G-code generated for a 5 axis CNC machine, with a rotating and tilting table. I would like to run this code on my robotic arm and therefore thought about converting it to a rotating and tilting head movement. For better understanding, I will attach an image. This should be possible (right?), but I do not get the mathematics behind it. My aim is then to write a small script to convert the G-code.
Setup of desired G-code (left), setup of provided G-code (right):
Provided G-code example:
G1 X0.08 Y-19.33 Z88.81 B-9.96 C-13.14
G1 X0.26 Y-19.25 Z88.83 B-9.90 C-11.68
G1 X0.45 Y-19.19 Z88.85 B-9.84 C-10.22
G1 X0.63 Y-19.14 Z88.86 B-9.79 C-8.77
G1 X0.81 Y-19.10 Z88.88 B-9.73 C-7.31
G1 X0.91 Y-19.06 Z88.89 B-9.72 C-6.02