A U.S. citizen who was wrongly deported in May was found at a border crossing and could be reunited with his family soon, an American Civil Liberties Union spokesman said Tuesday.

Superior Court Judge Carlos Chung ordered Pedro Guzman's release at a hearing Tuesday in Lancaster. Guzman, 29, was expected to rejoin his family later in the day, according to ACLU Southern California spokesman Michael Soller.

Guzman was jailed on a misdemeanor trespassing violation and deported to Mexico on May 11, according to authorities, after he allegedly told immigration and sheriff's officials that he was an illegal immigrant.

Guzman's family is suing federal and county officials over the deportation. In the lawsuit, the family claims Guzman is mentally disabled and was asked about his immigration status in jail and responded that he was born in California.

The ACLU, which helped file the lawsuit, has said it has a copy of Guzman's birth certificate showing he was born at Los Angeles County-USC Medical Center.

U.S. State Department officials have denied the family's claim that Guzman was mentally disabled, and federal and county officials have maintained they acted properly.

Guzman's family said he called them soon after he was deported to tell them what happened but couldn't say exactly where he was. After that they lost touch with him.

They said they spent weeks frantically searching in Mexico for him.