A young man threatened to kill NHS staff who revived him after he was rushed to King's Mill hospital because he was unconscious, a court heard.
Cole Eadson was treated in the rescusitation unit for about an hour, before he fell off the trolley, with his head slumped between his legs, at 8.40pm, on February 6.
When they tried to get him out of the way, he threatened to kill staff, and slit his own throat.
"He repeated himself over and over again," said prosecutor Robert Carr. "When another patient came in they needed to get him off the floor, but he began swearing."
Eadson stumbled around and went into the toilet. When staff checked to see he was all right, he waved his penis around, continued to swear, and threatened to urinate on them.
"He raised his fists and made snapping movements with his teeth," said Mr Carr. "He flailed at security staff. He had to be restrained until police arrived."
The court heard he will be recalled to prison until July 3, after he was convicted of assault occasioning actual bodily harm.
Simon King, mitigating, said Eadson had written to the court to plead guilty and request a prison sentence.
"There are some genuine attempts to put this right. He says he has no family or contacts and he might as well stay in prison," said Mr King. "It is somewhat troubling."
Eadson, 25, formerly of Forest Avenue, Mansfield, admitted using threatening words and behaviour, via videolink from HMP Lincoln, on May 1, after initially denying it on February 8.
Mansfield magistrates gave him 28 days in prison, to run concurrently with his current sentence, and ordered him to pay a £115 government surcharge.