I gave a cursory review of this thread. If the hard drive is working fine then I doubt it is the motherboard. The hard drive and optical drive are both controlled by the same chip.
My guess is the connections between the back of the optical drive and the motherboard are the problem. I am not familiar with those connections as I have not gotten inside any laptops.
I have a similar model HP laptop, model Dv7. Under help and support you can troubleshoot the optical drive. This may help diagnose the problem. Of course, if the optical drive does not show in the troubleshoot area then you are back to a hardware problem.