The Coast Guard said today it had found the vessel whose crew reportedly brandished guns and flew a pirate flag Saturday, ordering divers away from the wreck site of the collier Marine Electric 30 miles offshore from this Eastern Shore island.

But it appeared late today that the letter of federal law may protect the "pirates" from legal action as the Coast Guard said it was terminating its investigation and considered the matter closed.

"According to our best information, no assault occurred," Lt. Cmdr. R.T. Tittermary, group commander of the Chincoteague Coast Guard Station, said earlier. "Firearms were displayed but not pointed. There is no law that says you can't have weapons on a vessel."

The investigation is now in the hands of the Bureau of Alcohol, Tobacco and Firearms, but Bill Clowser, special agent in charge of ATF's Wilmington, Del., office, said today that, for the moment, he has little basis on which to proceed.

"Who's to say those were illegal automatics and not legal semiautomatics?" asked Clowser, who noted that the complaining divers had charged they had been threatened with automatic rifles. "We go into court for a search warrant without certain knowledge and they can tell us to go pound sand."

According to a Coast Guard spokesmen, the mystery craft was identified Monday as the Sarah C. Conway, which Coast Guard documents describe as a 77-foot wooden vessel built in 1872 and registered in Berlin, Md., near Ocean City. In its statement announcing it was ending its investigation, the Coast Guard said it had located the vessel in Ocean City.

The Coast Guard had obtained the initial identification from Jeremiah Shastid of Waldorf, Md., one of the complaining divers who had been hired to investigate the wreck of the Marine Electric by lawyers for the families of its 31 lost crewmen. Shastid said the Conway was on the site of the Marine Electric's wreck when he and two other divers arrived Saturday afternoon.

He told the Associated Press Monday he and his companions were ordered out of the area by five men waving what looked like M16 automatic carbines.

"They had banana clips and everything," Shastid said.

Tittermary said possession of unlicensed automatic weapons might be an offense, but that such investigations are properly the province of the ATF, a branch of the U.S. Treasury Department.

Clowser said he had made no effort so far to contact the owners of the Conway, who are listed in Coast Guard documents as Ricks and Diane Savage of Berlin.

As of late today, neither the Savages nor Shastid and his fellow divers, identified by the Coast Guard as Shastid's brother, Roy, and Dave Landenburg, both of Waldorf, could be reached for comment.

The incident, which comes as platoons of lawyers prepare to sort out in court the legal complexities surrounding the sinking of the Marine Electric in a gale Feb. 12, took place in a region already rich in a tradition of freebooting.

Among the dunes and marshes of these barrier islands, pirates and piccaroons settled in America's earliest days. Though little but serenity is ever seen today in its green coves and whitewashed hamlets, where people are uniformly friendly to visitors, as late as the 1950s wars on the Shore's waters were fought between rival oystermen.

Even today, though, there are rumblings of the old ways. Last winter, Tittermary said, an oysterman was shot on his boat near Crisfield, Md., in an apparent dispute over oyster rights. Clowser said most of the complaints he investigates about firearms on boats involve one fisherman reporting another for carrying automatic weapons.

It remained unclear late today how soon Shastid and his divers would return to the wreck site. Shastid has said he needs at least two more dives to complete the measurements and photography of the Marine Electric's broken hull.

Marine Transport Corp. of New York, which owned the Marine Electric and is a defendant in negligence suits totaling more than $100 million brought by survivors and families of the deceased, has said it knows nothing of the "pirate" boat's presence in the area. But it did confirm that its divers have investigated the wreck in past months without incident.

Tittermary said he has no plans to patrol the wreck site on a regular basis, but "if we get any more calls like this, we'll be out there."