I want to calculate the UAV gimbal relative orientation according to ground coordinates. Actually, We can simplify this problem like two relative rotation coordinate frames steering angle(yaw, elevation). I have tried to implement two different rotation matrices and then converted them to quaternions and combined them but I failed.
If you can share an example code or equations, It would be great.
Thanks.