The American Bar Association today repealed its long-standing prohibition on the use of television, still cameras and tape recording in courtrooms.

In its place, the association's House of Delegates said that judges should be able to authorize "unobtrusive" use under carefully prescribed rules.

The organization's canon, enacted in 1937, has been largely ignored by the 38 states that permit some form of cameras in criminal trials, but the remaining states have cited it as a reason for not allowing their use. The Supreme Court has ruled that the states may experiment with cameras in the courtroom.

Today's action, by a vote of 162 to 112, was opposed strenuously by some leading lawyers.

Erwin Griswold, former U.S. solicitor general and dean of the Harvard Law School, expressed the view of many opponents in the debate today. The cameras, he said, "inevitably interfere with the administration of justice," and because the coverage is largely managed "by a motley crew of radio and TV people who sensationalize" coverage, the public gets a bad impression of the trial process.

U.S. District Court Judge Norman P. Ramsey of Maryland called the rule "an intellectual dinosaur roaming the scene. It's unrealistic. It's anachronism. It needs to be changed."

The ABA today also backed off from its position that sex and race discrimination should be illegal in many private clubs.

By a 178-to-130 vote, the organization's policy-making House of Delegates repealed a resolution it passed last winter that urged Congress to include in the anti-discrimination laws governing public accommodations a ban on bias by clubs that are supported by dues from businesses and law firms or by business tax deductions.

Exclusion of blacks and women, proponents argued then, seriously damage their ability to compete with white males who transact business over lunch and drinks in such clubs.

The winter action prompted a massive lobbying campaign by clubs around the country who said it unconstitutionally threatened their rights as well as their treasuries.

The repeal yesterday was a defeat for women, who have been playing an increasing role in the ABA. But Brooksley Born, a partner in the Washington law firm of Arnold and Porter and one of the major sponsors of last winter's resolution, said yesterday it was more than a symbolic matter.

"It is not a minor problem," she said. "It matters a great deal to women and minorities who practice in areas where their male colleagues do a lot of work in clubs."

Jane Barrett, a Los Angeles lawyer and the first and only woman member of the association's Board of Governors, questioned whether women will "now have to wait 30 more years before this association will see that the doors of these business clubs are open to them."

The argument that such a ban, which would be an amendment to the Civil Rights Act of 1964, would be overly intrusive won out today, however.

"The Civil Rights Act does not belong in the kitchen or in private clubs," said John Feirich, of Carbondale, Ill.

Joe Stamper, of Antlers, Okla., said that, in his town, "This is not a hotly contested issue. The men go to the Lions Club and the lodge and the women go to study clubs and garden clubs."

In other activity at the convention here, the ABA's new president, Morris Harrell, predicted that the ABA would finally act on a new code of ethics for lawyers this winter. His comments were a reaction to a decision by the House of Delegates Tuesday to defer action on the code once again.

The proposed code is controversial in part because it would require lawyers to break confidentiality with clients, under some circumstances, to report criminal behavior. The association has been considering it for nearly three years.

Secretary of Defense Caspar W. Weinberger addressed the delegates today, delivering a critique of nuclear freeze proposals such as California's ballot proposition calling for a freeze.

Nuclear freeze proposals, he said "could well place restraints on the strength of the United States, freezing us into a position of permanent inferiority to the Soviets, without limiting the expansion of Soviet strength."