Solution 1:

When the English settlers landed in the New World, they didn't have a word for maize. Maize is a New World crop which was unknown in Europe. The word "maize" was originally Spanish, and comes from the word "mahiz" in the Arawak language of Haiti, and in the early 1600s it was not yet a common word in England. The settlers called it "Indian corn", which soon got shortened to just "corn".

EDIT: In the comments, some people are questioning whether "Indian corn" and "maize" refer to the same thing. They certainly don't today; in the U.S. Indian corn usually means ears of maize with multicolored kernels which are grown primarily for decoration. However, both terms were used and appear to have been treated as synonyms in the U.S. during and before the 18th century. From a section of An Universal History (London, 1763) discussing New England:

We have already observed that the country is fruitful in all kinds of esculent plants, pulse, and corn; but Indian corn, or maiz, which the natives call Weachin, is the most cultivated, and was alone known here on the first arrival of the Europeans. The following is the account of it communicated to the royal society by Mr. Winstrop ... "The ear is a span long, composed of eight or more rows of grain, according to the quality of the soil, and about thirty grains in each row, so that each ear at a medium produces about two hundred and forty grains, which is an astonishing increase. It is of various colours, red, white, yellow, black, green, &c, and the diversity frequently appears not only in the same field, but in the very same ear of corn, though yellow and white be the most common. ... It is observable, that the maize dwindles the farther you advance to the northward ... sufficiently evince the Indian corn to be a native of the more southern latitudes ... "

Solution 2:

Corn as a synonym for maize or any other grain depends on the region you look at. I once heard as explanation for this, that people tend to name the most common crop corn.

So in regions with a dominant maize production corn refers to maize. In regions with a dominant grain production corn typically means grain.

In my region, when people speak of corn, they mean rye. So I definitely think the reason is historical.

Solution 3:

Corn is a generic term for grain.

From OED – 

corn, n.1

Etymology: Common Germanic: Old English corn corresponds to Old Frisian korn (East Frisian kôrn, kôren)

I. gen. A grain, a seed.

Whereas maize is a particular type of grain.

From OED –

maize, n. (and adj.)

Etymology: < Spanish †mahiz (now maíz ; first attested 1500 in Columbus's diary, although slightly earlier in post-classical Latin as maizium )

a. A cereal grass of Central American origin, Zea mays, having a terminal male inflorescence (the tassel) and axillary female flowers that form starchy grains (caryopses) embedded in rows in a central core (the cob);

So in regions where maize is the predominant grain people will use corn as the terminology to describe it.

Corn on the cob, is simply grains on the cob of maize, but corn has become synonymous with maize.

Solution 4:

The Taino people of the Caribbean islands called corn (what we now call corn), "mahiz." The Spanish became the dominant culture on these islands, but took up the word "mahiz" which became "maize." (According to Wikipedia, as the first language encountered by Europeans in the New world, Taino became a source of many new words for the Europeans.) The Spanish took the word and applied it to the corn that they found growing in Mexico and Central America.

Columbus and other Spanish explorers brought this plant back to Spain. Then it was planted in France, where it is now called maïs. But its old Occitan name (in southern France) is "lou blaou d'Espagne" or "blé d'Espagne"(in French), which translates to "the wheat of Spain."

Later, English colonists found this odd grain grown by the indigenous people of the northeastern part of America, and applied their word "corn." Hence, we have two different roots for the two words, corn and maize.