A Canberra foster father told police he suffered from erectile dysfunction and could not have had sex with the teenage girl in his care.
The 35-year-old man, who cannot be named, is facing 12 charges relating to an alleged sexual relationship with his foster daughter when she was aged 14 and 15.
The Crown alleges the pair began having sex while the foster mother was away from the house.
The girl told police they were having sex almost daily at one point.
She claims he emotionally blackmailed her, telling her he would kill himself if she ever told anyone.
She told police he told her to ''deny, deny, deny'' if anyone ever found out about the sex.
But the father, in a record of interview with ACT Policing detectives, denied the allegations.
He said he suffered from erectile dysfunction and needed medication.
The man said he hadn't taken the medication since the beginning of 2010, and would not have been able to maintain an erection.
''It's quite embarrassing because I'm 34 and I've been living with it for a few years, and I don't think many guys would go and talk about it,'' he told police.
''So that's the reason why this is not possible, because of my erectile dysfunction.''
He told police he had records from a medical institute showing he had paid for a treatment of mouth lozenges and nasal spray, and also a doctor's prescription for Viagra.
He said he and his partner were forced to use IVF to have a baby.
The man told police the period after he was first made aware of the girl's allegations was ''horrible''.
''It is the reason I am never going to foster or work with young people again because going through something like this is not pleasant,'' he said.
He said the foster daughter had threatened him before when she was extremely angry, but that he ''didn't think it would go this far''.
''When she gets like that, she always says that she blacks out and she can't stop herself.''
The trial continues on Thursday before Justice Richard Refshauge in the ACT Supreme Court.