(CNN) -- Islamist militants launched a massive assault on African Union peacekeepers in the Somali capital Wednesday, sparking battles that killed at least 17 civilians, according to witnesses and journalists in Mogadishu.
Nurses attend a man wounded Tuesday in a mortar attack in Somalia's capital, Mogadishu.
"The fighting was so heavy, it shook the ground under our feet," Somali cameraman Hassan Ahmed Hagi said. "Both sides were using heavy artillery -- including tanks used by the AU."
Dozens of civilians have been killed in Mogadishu this week after Al-Shaabab Islamic militia members doubled their attacks on AU forces following the militia's closure of the city's only airport, which also houses AU forces.
At least 33 civilians were killed in the crossfire of Monday's battles. Watch aftermath of violence in Mogadishu »
AMISOM -- the African Union Mission in Somalia -- said this week's attacks are "intended to draw AMISOM into direct armed confrontation with the opposition forces, and therefore appear to be involved directly in the conflict."
"They were also intended to reflect AMISOM as partisan so that its troops could easily become a target and subject of attacks," spokesman Maj. Barigye Ba-Hoku said in a written statement.
He noted that AMISOM forces are in Somalia not to fight, but to establish peace, and fire only in self-defense.
"We refuse to be drawn into this senseless war," Ba-Hoku said.
Hagi described Wednesday's violence as the heaviest fighting he had ever witnessed between Al-Shaabab and AU forces.
The fighting started when Al-Shaabab fighters attacked K4 square, where AU peacekeepers from Uganda are stationed.
Heavy artillery struck a school near the square where civilians displaced by the violence were being sheltered. Four civilians were killed, according to a young woman at the shelter.
"We are fleeing this morning, using every transport available, including donkey carts," Nasteho Mohamed Abdi said. "I am so scared to venture out of the camp because AU forces are taking positions all over the area, but I have to leave."
Three people -- including a 6-year-old boy -- were shot dead by Somali government forces taking positions near K4 square, a local journalist said. An artillery shell killed a group of five people running for cover, the reporter said.
At least 24 people were wounded in the fighting and taken to Medina Hospital, a hospital official said.
Al-Shaabab is an Islamic militia that has launched a bloody battle to seize control of Somalia and oust Ethiopian troops, who are helping Somali government forces try to rout the Islamic fighters.
It is a splinter group of the Islamic Courts Union, which pushed out Somalia's transitional government in 2006. The ICU was deposed in December of that year following Ethiopia's military intervention.
Last week, Al-Shaabab warned all airlines to stop flying into Mogadishu's only airport or possibly face a military assault.
In its statement, Al-Shaabab said it shut down the airport because the facility is being used by "infidel forces," including those of Ethiopia, Burundi and Uganda. Burundi and Ugandan forces make up the bulk of the AU mission in Somalia.
Fighting in Mogadishu continues unabated more than three months after a United Nations-brokered peace deal was signed in the neighboring country of Djibouti by Somalia's transitional government and an alliance of armed opposition forces.
Somalia has been mired in chaos since 1991, when warlords overthrew dictator Mohamed Siad Barre, sparking brutal clan infighting. Somalia's transitional government is trying to maintain control of the capital, with the help of the better-equipped Ethiopian forces.
The lawlessness has extended to the country's waters, where international vessels are routinely hijacked by suspected Somali pirates who demand large ransom payments.
Ethiopia invaded Somalia in December 2006 to install the transitional government in Mogadishu after a decade and a half of near-anarchy. The invasion had the blessing of the United States, which accused Islamists of harboring fugitives from the al Qaeda terrorist movement.
But the Ethiopian troops quickly became embroiled in an insurgency led by the Islamists. As guerrilla attacks mounted, efforts to replace the Ethiopians with an African Union-led peacekeeping mission faltered. The conflict displaced hundreds of thousands of Somalis, further worsening a humanitarian crisis that dates back to the collapse of the country's last government in 1991.
The situation has been exacerbated by drought, continual armed conflicts in central and southern Somalia, and high inflation of food and fuel prices.
The peace agreement, signed June 9 in Djibouti, calls for a cease-fire between Somalia's U.N.-backed transitional government and the Alliance for the Re-liberation of Somalia. If followed, it would pave the way for a withdrawal of Ethiopian troops.
The agreement calls on the Alliance to disassociate itself from any armed groups still fighting the government and for all sides to allow "unhindered humanitarian access and assistance" to all Somalis. A joint committee led by U.N. officials has been appointed to monitor the agreement's implementation.