Oregon's criminal justice system will be examined in a Portland courtroom tomorrow. At issue is how the state treats defendants with mental illnesses. The lawsuit accuses Oregon of letting mentally ill people languish in jail rather than provide the health care they need at the state psychiatric hospital. Oregon Public Broadcasting's Conrad Wilson reports.

CONRAD WILSON, BYLINE: In December, Carlos Zamora-Skaar was arrested on a felony burglary charge. Court documents show he was undergoing a severe mental health crisis at the time. A few weeks after his arrest, a judge ordered a psychological evaluation at the Oregon State Hospital.

Amanda Thibeault is Zamora-Skaar's criminal defense attorney.

AMANDA THIBEAULT: January came and went. February came and went. And he was just languishing in jail, where a mentally ill person shouldn't be.

WILSON: In court, he made delirious statements during hearings, so much so that after months in jail, a judge found him unable to aid in his own defense and ordered him this time to receive treatment at the Oregon State Hospital. But for weeks, that didn't happen.

It wasn't until late last month that Zamora-Skaar was finally admitted to the state hospital. The idea is to treat his mental illness until he's able to aid in his defense. And only then, Thibeault says, can his criminal case move forward.

THIBEAULT: This is happening statewide.

WILSON: Attorneys and mental health experts say, right now, there are about 40 people like Zamora-Skaar with mental health issues who are waiting in Oregon jails to get transferred to the state hospital for treatment.

Emily Cooper is the legal director for Disability Rights Oregon, a nonprofit that sued the state nearly 20 years ago over the same issue and won.

EMILY COOPER: People with mental illness don't belong in places that are intended to punish. They should be in places that are designed to treat.

WILSON: In 2002, a federal judge found the state can't keep people in county jails for more than seven days when a state court judge has found they need to be at the state psychiatric hospital.

COOPER: It's not happening.

WILSON: For years, it was. But in the last year or so, Cooper says the state has a backlog because it's lost control of the situation.

COOPER: The problem is, nationally and here in Oregon, we haven't appropriately funded a community behavioral health system to meet the needs of those individuals. And so what's happened - again, here in Oregon and nationally - is jails have become the de facto mental health provider.

LEE EBY: And that's to a large extent very true.

WILSON: Captain Lee Eby is the jail commander in Clackamas County, Ore. He says he regularly has people in his jail who are waiting past the seven-day window to be sent to the state hospital for treatment. He says jails have become the new mental hospitals.

EBY: And that's not the way it should be. And if there's one thing I would change, it would be that - is to get away from that notion of criminalizing some of the behavior, not having the resources to deal with it.

WILSON: The state's psychiatric hospital is run by the Oregon Health Authority. Patrick Allen is the agency's director. He acknowledges it's taking longer than seven days to admit people from jails.

PATRICK ALLEN: The challenge is that this rate of sending people to us continues to accelerate.

WILSON: He says he's working to reduce the amount of time people are waiting and to speed up the discharge process for those who no longer need hospital-level care. But Allen says the hospital is also dealing with things that are outside his control.

ALLEN: Sixty percent of people referred to us on an aid and assist order were homeless at the time of their arrest. To me, that speaks volumes in terms of the nature of the kind of problem that we're struggling with.

WILSON: And while Allen says he's doing everything he can, that's of little comfort to those in a jail cell rather than a hospital bed.