There is no noise issue on the recording. I am assuming that at the end of the recording, the OBi had not yet hung up the Line port.
The two clicks 400 ms apart sure smell like a CPC to me. Is there a PBX or other device between PSTN and OBi that might be blocking it? Confirm (by logging into the OBi directly) that for the Line port, DetectCPC
is enabled and CPCTimeThreshold is set to 200.
Next, I don't know why the disconnect tone (which is indeed 400 Hz and lasts 6 seconds) is not being seen. For DisconnectTonePattern, you might try 400-30;8;(6+4) or 400-30;5;(6+4) If it still isn't detected, perhaps Obihai support could tell you how to make the device detect a steady disconnect tone, if it's possible at all.
Finally, you might try setting CPCTimeThreshold really low, perhaps to 50 -- this may cause issues on outbound calls or upon anwering, but maybe you'll be lucky and it will work.