As Evan stated, all overdrives will freewheel under 30mph. If freewheeling occurs over 30mph it could be either a internal mechanical issue or possibly an electrical issue. However when the power is applied normal operation should resume. It has been my experience that most overdrive problems are electrical. What you have is unusual as you state that it disengages under power.
That seems more mechanical to me.
The main mechanical components of an overdrive system consist of the planetary set, free-wheeling cam assembly and the blocker ring components. Any or all of the aforementioned components could cause the overdrive to malfunction.
Check the oil level, insure the cable is installed correctly and properly operates the lever, all electrical contacts are clean and tight, and all electrical components are working.
If all that checks out, the unit likely has to come out for a tear down and repair.
Fred