Congress Tuesday threatened to impose a settlement to the confrontation between Consolidated Rail Corp. and the CP Rail unit of Canadian Pacific Ltd. that threatens the survival of the Delaware & Hudson Railway.

Most view the threat as an attempt to force Conrail to start talking with CP to see if the dispute can be resolved.It may give a good indication, however, of how much freedom from government intervention Conrail, created by Congress from the wreckage of the Penn Central and other Northeast railroads, has now that it is in the private sector.

Legislation scheduled to be introduced in both houses of Congress calls for the Interstate Commerce Commission, within five days after the bill is signed into law, to in effect order Conrail to give CP Rail trackage rights it demands as a condition of its $35 million acquisition of the bankrupt D&H.

CP wants rights between Harrisburg, Pa., and Hagerstown, Md., as part of its acquisition of the D&H, which operates about 1,600 miles of track in the Northeast.

Conrail refused to grant the rights on grounds it was allowing a major competitor to enter its territory without receiving anything of value in return. This prompted CP to withdraw its offer, which, for a time, forced the trustee to quit operating over most of the railroad's system.

The railroad resumed operations Wednesday morning while the search continued for a buyer.

Liquidation will begin if a buyer is not found within 30 days, said Francis P. DiCello, the trustee overseeing the railroad's reorganization under Chapter 11 of the federal bankruptcy laws.

The legislation was scheduled to be introduced by Sen. Alfonse D'Amato, R- N.Y., in the Senate and by Rep. Norman Lent, R-N.Y., and others, in the House.

Conrail has been under a lot of pressure to turn over the Harrisburg- Hagerst own trackage rights to CP, one industry lobbyist said, and it has yet to flinch.

He doubts any legislation will clear Congress so long as the administration opposes it. Transportation Secretary Samuel K. Skinner and other administration transportation officials are on record as opposing government intervention.

"The key to the bill's prospects is if there is any softening by the White House," the lobbyist said.

The issue also is being perceived as being of interest only to the states of New York and Pennsylvania. If New England members get interested in the bill, he said, its prospects would improve a bit.

Although Congress is concerned about the dispute and its impact on the D&H and will get involved if it must, several staffers following the issue said, a negotiated settlement between CP Rail and Conrail is far preferable.

Conrail has a point, they said, in being reluctant about giving something up without receiving anything in return.

"CP has contacts and markets in Canada and they should be able to address Conrail's concerns," one staffer, who asked to remain nameless, said.

"CP must have some things to trade off to Conrail," he added.

One possibility is for CP to give Conrail trackage rights between Albany, N.Y., and Montreal, Quebec, in exchange for the Harrisburg-Hagerstown rights. This would give Conrail a far more direct access to Montreal than what it has now.

There have also been reports that CP offered Conrail a substantial increase in traffic interchanges if it agreed to give CP the Hagerstown- Harrisbu rg trackage rights.

Neither CP nor Conrail would comment on the report.

CP officials did say that traffic interchanges, running rights and trackage rights rates may have come up in earlier discussions with Conrail officials.

Conrail has also had its share of help from the government, the staffers said, including over $6 billion in federal funds to operate and rebuild the company's track, equipment and facilities.

The railroad probably will come back to Congress again and the handling of the D&H situation may create some problems, one staffer predicted.