The US-flagged Harriette cargo vessel was attacked first by two small skiffs.
"The pirates opened fire with automatic weapons. Rocket Propelled grenades were also seen by the crew," the EU naval force said in a statement.
The pirates tried to get onboard the vessel with a ladder but the Harriette'a captain "made evasive maneuvers and succeeded in keeping the pirates off his ships," the statement added.
Soon after that the Dutch-flagged tanker Jo Cedar came under attack by three of the fast attack skiffs and also came under automatic weapons fire.
"With evasive manoeuvres and speed this vessel also escaped the clutches of the pirates," Atalanta said.
Nobody was reported injured in either incident.
The Seychelles-based EU force launched an investigation in the area with the German warship FGS Karlsruhe ordered "to search and neutralise the pirate attack group."
Since last year a flotilla of foreign warships has been patrolling the piracy-plagued Gulf of Aden, one of the globe's busiest maritime trade routes.
Pirates have since redeployed to the Indian Ocean, a much wider area very difficult for naval forces to patrol effectively.
Since the start of October, subsiding monsoon winds have allowed pirates with small skiffs to resume their operations in earnest after a lull that had seen the number of hijacked vessels drop.
Among their latest catches are a British couple seized from their yacht, an Indian cargo ship, a Spanish trawler with a crew of 36, a Singapore container ship with 21 crew members and a Chinese bulk carrier with a crew of 25.