hello everyone!

i'm working on a hermle c-30 heidenhain control and i would like to set datum automaticly using a program (i would like to be at a certain coordinate and "save" it in the preset table- the values of x,y,z,c,a)
can anyone help me