How to set rotation of an object with reference to the angles between another object

I've a set up like this. image

I know the angles a,b,c which are the angles from the center pole to my stick. But I can't figure out how to apply the rotation to achieve this angle.

For e.g. a,b,c can be 90,90,0 which means my stick x axis is 90deg from the center pole, y 90 degree and z 0 which means my stick z axis is in parallel with the center pole.

These angles a,b,c I got are not the rotation angles that I can apply to my transform.

I'm stuck at how to rotate my object so that it maintains a particular angle with a reference object.

Any help is greatly appreciated. Thanks.

i'm not quite sure what you looking for exactly but you might want to try and use Transform.RotateAround to rotate around a point such as Vector3(0, 0, 0), on the y axis Vector3(0, 1, 0) at 20 degrees per second:

transform.RotateAround (Vector3.zero, Vector3.up, 20 * Time.deltaTime)

If I understand correct, you can apply the rotation of other object this way:

var targetObject = Transform;

function Update (){ gameObject.transform.rotation = targetObject; }