Data Logging is simply when you record information. Read this tutorial about data logging
You would output data from your sensors, important formulas, and your gains. I would output the data in a comma separated value format. Each line would then end up looking something like this (values are made up):
P, 1.5, I, 1, D, 0.15, Accel, 113, Gyro, 28, Tilt est, 13
With this information you can see what your robot is actually doing. It should really help solving your problem. For example if you see the change in P continuously increasing, then it is likely the source of your oscillations.