In 500 AD, under King Fergus the Scots invaded Argyll and established the realm known as Dál Riata (a.k.a Dalriada) in the Pictish lands, known as Caledonian by the Romans. However, the relationship between these two peoples begins earlier: around 300 AD when the Romans recorded almost 300 frontier attacks by two peoples: the "Picti" and the "Scotti".
While the Romans represented a common enemy the Picts and Scots supported each other, however, with the Romans' departure the two sides were left to compete with each other for power and territory. Wars between Caledonia and Dalriada were numerous between 300 AD and 840 AD - the Picts frequently coming out on top; Dalriada often being ruled by the Picts.
In the early 9th century, when the Vikings started plundering along the coastline of Caledonia and neighbouring countries the Pictish kingdom found itself facing enemies on two fronts. After successfully defeating the Scots, the Picts strength was severely weakened by a major battle with the Vikings in 839. Caledonia went on to suffer several quick successions of Kings.
After the death of the king of Dalriada, Alpin Mac Eochaid, his son Ciniod Mac Alpin, Kenneth I in 843, laid claim to the throne of Caledonia through maternal bloodlines, and thereby united both kingdoms, becoming King of Alba.
See also: MacAlpin's Treason