A Chinese computer expert at the University of Texas was hauled before a federal judge in Brooklyn Wednesday for allegedly stealing state-of-the art technology from a Silicon Valley startup.

Bo Mao, 36, was allegedly secretly working for the Chinese company Huawei — which was indicted last year on charges of stealing T-Mobile technology and violating sanctions on Iran — when he arranged to get his hands on a computer circuit board with a proprietary “open-channel” software-development kit from CNEX Labs in February 2017.

At the time, he was working at a research university in China and claimed he wanted to “build an experimental platform and conduct storage-system research,” according to a federal criminal complaint filed against him last month in Fort Worth, Texas.

Several weeks after getting the board, Mao told CNEX it had been damaged by a student who mishandled it and sent photos “which showed that a connector to the proprietary chip had been detached from the board,” according to the complaint.

But an “experienced professional in the technology sector” told the FBI it’s almost impossible to break a computer board that way, according to the complaint.

In the fall of 2018, Mao began working as a visiting professor at the University of Texas at Arlington, and the company asked for and got back its board early last year.

An expert who examined the board told the FBI resistors had been carefully removed from the connector — contradicting the claim it was accidentally broken, according to the complaint.

In addition, the fact that it was returned with wires attached to the connector indicated that someone “attempted a hack of the SDK board,” according to the complaint.

Mao was arrested and charged with conspiracy to commit wire fraud following a civil trial at which Huawei and CNEX accused each other of stealing each other’s intellectual property.

A jury sided with CNEX on July 27 but didn’t award the company any damages.

In an email, Mao wrote, “We learned from the law case and hope it does not disturb us anymore,” according to the criminal complaint.

The case against Mao, who has pleaded not guilty and is free on $100,000 bond, was transferred late last month to Brooklyn federal court, where prosecutors filed the Iran sanctions indictment in January.

That case led to the arrest of Huawei exec Wanzhou Meng in Canada, where she’s fighting extradition to the US.

During Wednesday’s hearing, defense lawyer Richard Roper demanded to know why the case had been transferred to Brooklyn, where it’s being overseen by the same judge who’s handling the Huawei case.

The Trump administration in May placed a ban on US companies doing business with Huawei — accusing the Chinese telecom firm of posing a risk to national security.