A Gillette man has been charged in federal court with possession of and transportation of child pornography.

Tyler Neal Magnuson heard the two counts during his initial appearance before U.S. District Court Magistrate Michael Shickich in Casper on Tuesday.

If convicted on both counts, Magnuson faces between five years and 40 years of imprisonment according to federal sentencing guidelines.

He is in custody and will have a formal detention hearing on Friday.

Magnuson was represented by attorney Keith Goody, who said in a telephone conference call that his client was diagnosed as autistic at age 3, has a pervasive development disorder, and is intellectually disabled.

Goody expressed skepticism whether Magnuson was competent to participate in the initial appearance. Those developmental issues were why he had not been prosecuted before, Goody said.

Shickich told Goody to make that information available to the federal government's probation office, and proceeded with the hearing.

The case started on Feb. 15 when an agent with U.S. Immigration and Customs Enforcement Homeland Security Investigations received a lead from an agent in North Carolina about images of child pornography distributed on a KIK user's account in Wyoming, according to her criminal complaint filed on Friday.

That lead resulted from reports of a suspect in a known child pornography group within KIK, and a subsequent message in that group telling people if they wanted to remain in the group they needed to post something, according to the criminal complaint.

One of the group members soon downloaded five videos.

Investigators tracked that person's computer to a internet provider address of a computer in Gillette that was at Magnuson's physical address, according to the criminal complaint.

The agent recognized his name from a previous peer-to-peer network child pornography investigation by the Federal Bureau of Investigation and the Wyoming Division of Criminal Investigation's Internet Crimes Against Children task force in 2010 and 2011.

At that time, Magnuson was a juvenile and admitted he used peer-to-peer software to download child pornography, according to the criminal complaint. Peer-to-peer networks directly deal with other network participants without using central servers.

Last week, DCI agents executed a search warrant at Magnuson's residence where and his fiancee were inside.

Agents found a hard drive, and after a preview forensic examination found files with child pornography.

After advising Magnuson of his rights, he told investigators that he used KIK and computer and cell phone applications to distribute child pornography, according to the criminal complaint. "Magnuson stated that he has an addiction to child pornography and that he has been viewing and distributing child pornography, off and on, for the last four or five years."

The government regards child pornography as a crime of violence because it involves sometimes brutal assaults on children who cannot give consent to sexual activity.