During the earlier part of his governor-generalship Joan Maurice was called upon to face a really great danger. The year 1639 was to witness what was to be the last great effort (before the Portuguese revolt) of the still undivided Spanish monarchy for supremacy at sea. Already it has been told how a great fleet sent under Antonio de Oquendo to drive the Dutch from the narrow seas was crushed by Admiral Tromp at the battle of the Downs. In the same year the most formidable armada ever sent from the Peninsula across the ocean set sail for Brazil. It consisted of no less than eighty-six vessels manned by 12,000 sailors and soldiers under the command of the Count de Torre. Unpropitious weather conditions, as so often in the case of Spanish naval undertakings, ruined the enterprise. Making for Bahia they were detained for two months in the Bay of All Saints by strong northerly winds. Meanwhile Joan Maurice, whose naval force at first was deplorably weak, had managed by energetic efforts to gather together a respectable fleet of forty vessels under Admiral Loos, which resembled the English fleet of 1588 under Effingham and Drake, in that it made up for lack of numbers and of size by superior seamanship and skill in manoeuvring. At length, the wind having shifted, the Count de Torre put to sea; and on January 12, 1640, the Dutch squadrons sighted the Spaniards, who were being driven along by a southerly gale which had sprung up. Clinging to their rear and keeping the weather-gauge, the Dutch kept up a running fight, inflicting continual losses on their enemies, and, giving them no opportunity to make for land and seek the shelter of a port, drove them northwards in disorder never to return. By this signal deliverance the hold of the Netherlanders upon their Brazilian conquests appeared to be assured; and, as has been already stated, Joan Maurice took full advantage of the opportunity that was offered to him to consolidate and extend them. A sudden change of political circumstances was, however, to bring to a rapid downfall a dominion which had never rested on a sound basis.
The revolt of Portugal in 1641 was at first hailed in the United Provinces as the entry of a new ally into the field against their ancient enemy the Spaniard. But it was soon perceived that there could be no friendship with independent Portugal, unless both the East and West India Companies withdrew from the territories they had occupied overseas entirely at the expense of the Portuguese. King Joao IV and his advisers at Lisbon, face to face as they were with the menacing Spanish power, showed willingness to make great concessions, but they could not control the spirit which animated the settlers in the colonies themselves. Everywhere the Spanish yoke was repudiated, and the Dutch garrisons in Brazil suddenly found themselves confronted in 1645 with a loyalist rising, with which they were not in a position to deal successfully. The West India Company had not proved a commercial success.