The incidents occurred at the man's home in Örnsköldsvik, northern Sweden, between 2008 and 2010. He had set up the camera to secretly photograph and film children using the bathroom without their knowledge.
His behaviour would have gone unpunished had he not handed in his computer to be fixed after it crashed. An employee at the repair firm discovered child pornography images on his hard drive and alerted the police.
The authorities then seized the computer as well as usb sticks and mobile phones. In total they found 192 images which were considered to be child pornography, four of which were considered to be particularly serious.
He claimed in court that he hadn't downloaded the images and that his computer had got a virus. However, his argument was thrown out by the judge who slapped him with a suspended sentence and ordered him to 21,850 kronor ($3,000) in daily fines.
According to the judgement, five girls were affected by the covert filming, three of whom were under 15 when the recordings took place.
"He's ashamed and does not understand how it could have happened," the man's lawyer told the Allehanda newspaper.
In addition to his suspended sentence and daily fines the man has been ordered to pay damages to the victims, ranging from 5,000 to 15,000 kronor.