The Carmen Electra fan who told police he was engaged to her, was caught sitting outside her home with a notebook filled with all sorts of personal info ... on her and the people closest to her.

TMZ broke story ... Daniel Leblanc was spotted outside her house in June, but now we have the full picture. According to docs, Carmen's assistant first approached Leblanc while he was sitting in his car. Leblanc asked her if this was Carmen's house, and the assistant -- hoping to throw him off -- said, no. Leblanc creepily responded, "We'll see about that" ... according to the assistant.

That was enough for the assistant to call police. Leblanc told officers he was Carmen's husband, but then downgraded himself to fiance. Cops say Leblanc had a notebook in which he'd gathered a ton of data -- phone numbers, addresses, dates of birth, license plates, emails and more ... all for Carmen, her family members and staffers.

Leblanc told cops he'd paid for some of the info, and he was "madly in love" and would return to marry her. Police put him on a 72-hour hold for psychiatric evaluation.

Carmen requested, and was granted, a restraining order on Thursday. Leblanc must stay 100 yards away from her and cease all contact or harassment.