How to Get Quaternion from 6-Axis Serial IMU

Dear all member and experts,
I am using Serial 6-Axis Accelerometer Module from DFRobot. This sensor outputs Accelerometer, Gyroscope, and Angles data only. I need Quaternion data to make rotation matrix. Then, I put them into homogeneous transformation matrix. How to get quaternion data from these data? or Is there any library that processing quaternion from IMU?
Best regards and thanks,
Octarudin
Robotics ProjectsRobotics TutorialsRobotics ProductsView Arduino ProductsMore Arduino Related ProjectsArduino Tutorials