At 7 a.m. yesterday, when it was still dark and wintertime chilly, police vans rolled into this muddy, barren tract on the sandy cape flats that stretch inland from Cape Town's imposing sentinel of Table Mountain.

After waking up about 400 black squatters they tore down and burned the wooden and plastic shelters donated only days before to the squatters by churches and concerned citizens groups. As the squatters looked on, dazed and angry, the authorities dug a ditch along the field to restrict access and sealed it off from visitors. They said they had been ordered to stop food from being delivered to the site.

It was the harshest police action so far in a determined and potentially explosive tug-of-war between the authorities and the blacks, most of them illiterate, a tussle that goes to the heart of the hated "pass" and migratory labor system that are the foundations of the government's apartheid policy.

"It is my considered opinion that the government has gone mad," said liberal opposition member of Parliament Helen Suzman. "It seems to me that Nyanga is under siege."

Shocked at the police action, two members of a visiting U.S. congressional delegation wept at an emotional press conference before leaving South Africa yesterday. Shirley Chisholm (D.-N.Y.) and Berkley Bedell (D.-Mich.) were visibly upset after police prevented them from entering the site. The Americans eventually approached the field from a back road.

"I have traveled about the world and I have never been so shaken before," said Bedell.

Earlier, the five-member delegation led by Howard Wolpe (D.-Mich.), who heads the House Subcommittee on Africa, had a stormy meeting with Foreign Minister Roelof Botha after which Botha angrily accused the Americans of "prejudiced animosity" to South Africa "in conflict with the attempts by the American administration to try to find a settlement that will promote political and economic stability in southern Africa."

Wolpe, whose committee has expressed reservations about the administration's policy of "constructive engagement" with South Africa, said before leaving here that "we witnessed the desperation and human tragedy which we had heard so much about but were so wanting to disbelieve. We saw the human cost of apartheid."

The Nyanga situation began July 13 when hundreds of people, like Nomvula Willeman, her husband and five children, were evicted from the nearby single men's hostel in Langa where they had been "hiding," as they put it, because they do not have the legal right to be in Cape Town.

Under South Africa's system of apartheid, blacks must have permission from the government to live outside their tribal "homelands."

The evictees went to the local authorities and asked for a site to build shacks. After being refused they came here determined to sit it out, hoping to wear down the government.

Three days later, just before dawn, police arrived. At the time Patience Mbeko, whose name describes what seems to be the predominant trait of these squatters, was attending an open-air church service. The police arrested three people. But then the others also demanded to be arrested.

"We saw there were many police and so we decided to make it easy for them and we all went into the police vans," Mbeko said. "Otherwise they would use tear gas and say we were fighting."

About 600 people were arrested that day. No accurate figures are available for the total number arrested since then.

"We were given a list of 1,162 names by the authorities, and we got a list of 2,500 from the squatters. The real figure probably lies somewhere in between," said Val West of the South African Institute of Race Relations, which is coordinating relief for the squatters from black and white groups in Cape Town.

Mbeko spent 10 days and Willeman three days in jail. They are out on $36 bail each. Both will eventually appear in one of the tiny "pass courts" where the cases of those arrested are being heard.

Charged with being illegally in Cape Town, most defendants, for whom an interpreter translates the proceedings into their native Xhosa language, are fined and ordered to return to their rural homes in the impoverished homeland of Transkei where they are unlikely to find jobs.

In times past, they might have done as they were ordered, filtering back clandestinely over the next few months. But this time, they have decided differently, encouraged by the success in 1978 of several hundred black families in the squatter settlement of Crossroads who were given permission to remain legally in Cape Town

"I want the government to give me a house and the right of staying and working in Cape Town," said Willeman.

Under South Africa's complex "influx control system," which regulates how many blacks can enter urban areas from the tribal homelands, most of the squatters are "unqualified." This means they are not allowed to establish permanent residence in Cape Town and must work there only on renewable contracts, leaving their families in Transkei.

To enforce this policy, there has been a deliberate freeze on the building of black housing in Cape Town for more than a decade, which is why families like the Mbekos and Willemans were living in a hostel built for single men.

The forces drawing these rural migrants to Cape Town are more than bright lights and good times of the city. The lure is jobs and, thus, food. One economist has calculated that a rural South African black increases his standard of living more than 100 percent by coming to a city, even if he spends three months of every year in jail for violating the pass laws.

Afrikaner urbanologist Flip Smit argues in a new book that black urbanization has become unavoidable and an overall strategy is now needed to permit controlled black migration to cities.

But that does not fit into the government's political plans to keep most blacks in the homelands, which it says will become independent states and thus allow the whites to remain a majority in "white" South Africa.

It is this idea of independent homelands, that makes blacks "foreigners" in "white" South Africa, that enables South African officials to argue that their "influx control" is the same as U.S. policies toward Mexicans working illegally in the United States.

The trouble in Nyanga has been happening not far from the all-white Parliament, which is nestled on a quiet, shady street in Cape Town on the other side of Table Mountain. Last week Prime Minister Pieter W. Botha drew jeers from the opposition when he boasted of his government's achievements in "maintaining family and community life."

When one opposition member charged that the government's action was an "offense before God," Deputy Minister of Black Affairs George Morrison said the squatters were being "incited" by whites to defy "influx control," and he criticized the "do-gooders" who brought them food and shelter.

Black Affairs Minister Pieter Koornhof, who appears determined to stop another Crossroads settlement from developing, said an "organized campaign to wreck influx control" was in progress. As evidence he cited the fact that squatters had willingly reported for arrest and were returning from the Transkei "giving the black power salute and singing freedom songs."