The interrelations between Muscovy and Crimean Khanate, in particular Russians (Muscovians) with Crimean Tatars go back to the ancient times. To be more precise, one could definitely say that from the very first days of existence of these two states - Muscovy and Crimean Khanate they had the closest diplomatic relationships, which were first of all resulted from their origin from one single state-empire. You see, Muscovy and Crimea (along with their trans-black sea region territories) in the middle of the second millennium were the provinces of the Great Tatariya founded by Chingiz Khan in the beginning of the 13th century. These provinces were governed by the local rulers properly paying their tribute to metropolis. The role of such metropolis for Crimea and Russian dukedoms played the town of Saray along with the neighboring territories. From there the descendants of Chingiz Khan's elder son (Dzhuchies) governed by that part of the huge empire that Dzhuchy Chingizids inherited after the Great Tatariya was divided into four parts. In the course of time the Dzhuchy part started referring to as Golden Horde. The both states we are interested in - Muscovite Russia and Crimean Khanate came from this very Golden Horde.
By the end of the 14th century as a result of the endless internal conflicts between Chingizids for the right to govern the state the central authorities weakened to such extent that the provinces appeared to be stronger than the metropolis. This last reason allowed them not only leaving themselves the tribute gathered for metropolis, but manipulating by the Emperors, appointing to Saray throne the ruler they were pleased with. One of the most successful in this skill was Crimean governor Mamai, though the Grand Dukes of more northern provinces tried not to be inferior in this fight for the influence on metropolis. Russian chroniclers called the period of Golden Horde history between 1361 and 1380 years "Great Zamyatnya". The coup d'etats followed one another. More than a couple of tens of Khans replaced one another within twenty years. Hardly any Tsar (Khan) occupied the throne longer then one year. One should take into consideration that only Chingizid could govern the Empire. Neither Mamai, nor even any Grand Duke could claim to the throne if he wasn't Chingiz Khan's descendant. However, they not only had the possibility to enthrone the khans pleasing to them, but practiced this quite successfully supporting first one, then another claimant. Thus, long before the collapse of Golden Horde Crimea and Duchy of Moscow by that time becoming the most powerful among all Russian dukedoms competed with each other for the influence on Saray.
The outcome of "Great Zamyatnya" appeared to be disastrous for White Horde. Khyzr - the khan of Blue Horde with his Siberian army conquered Volga region. It seemed like the merging of Blue and White (Golden) Horde had to lead to the strengthening of Dzhuchy Ulughghghs, but in practice it didn't happen, because the number of Chingizids claiming to the throne increased to an incredible extent. Moreover, as Gumilev L.N. noted, there were also principal political disagreements: there were two parties in the empire. These were Western party headed by Mamai who longed for closer relationships with the West - Genoese and Lithuania, and the party of the opponents of this idea, because the strengthening Lithuania claimed to a range of Russian dukedoms and Moscow couldn't stand it. And it was supported by so called party of supporters of Muscovite Russia headed by Khyzr's successor khan Tokhtamysh. By the way Tokhtamysh himself occupied Saray throne only due to the assistance of the army of the legendary Iron Lame - Timur. After he became the sovereign governor of the united empire he decided first of all finishing off with his ideological enemy Mamai who could be overcame only by force. So, he started preparing to war.
Understanding the situation, Mamai - the successful governor of Crimea, at the period of whose governance Crimea reached such mighty that could easily separated from the empire and became an independent state. He demonstrated it in practice carrying out independent from metropolis external policy (there preserved the correspondence with the chancellery of Sultan of Egypt dated 1371), and he also started preparing to war. Being one of the mightiest Golden Horde emirs Mamai, nevertheless didn't think of separation from the empire. He wanted to govern the whole empire, but only behind the poppet-governor's back. Tokhtamysh belonged to another camp. Mamai failed subjecting him to his authority, so he had to get rid of him. However, in order to dethrone the disagreeable khan he needed the big army. "In order to maintain such army one needed big money" - Gumilev writes. - Mamai hadn't such money on himself. At that time he could obtain financial support only from his friends - Genoeses. They promised to help. But in respond they demanded the concession on production of fur and trade in Great Ustug region to the north of Russia. Mamai tried to reach agreement with Dmitriy - the duke of Muscovy and some Russian boyars that in exchange for the concession he would assist in arranging their private businesses and give the young duke Dmitriy the right to great reign".
This Mamai's proposal seemed profitable to the majority in Moscow and the deal would have been accomplished, unless the intrusion of the church. The Reverend Sergey Radonezhsky declared that there couldn't be any business with Latinians: one must not allow the Catholic merchants coming to the Saint Russian land because it's a sin. Sergey's authority was so indisputable that Moscow rejected the profitable proposal of Mamai, thus showing the allegiance to the union with the legal heir of Golden Horde khans - Tokhtamysh, the leader of Volga and Siberian Tatars.
Despite of the refusal Mamai until the last moment didn't leave the hope convincing Moscow in the great advantage of the bargain with the Latinians, knowing well that many in Moscow, including the duke were negative about the flat position of the Church. However, in order to reach its goal the Church in its fanatic pertinacity went beyond all the allowed measures, first killing the claimant to metropolitan klobuk - Mityay - Duke Dmitriy's confessor, who was ready to fix this issue in favor of Mamai and Dmitriy. Then it arranged the bloody massacre against Mamai's ambassadors in Nizhniy Novgorod. It exasperated Mamai and the war became inevitable. Understanding this, duke Dmitriy had to use all-Russian authority of Sergey Radonezhsky. The Reverent blessed this war, and all Orthodox population regarded it as their duty to defend Russian lands from basurmans and Latinians", - writes Gumilev. However, they didn't consider Tokhtamysh for basurman regarding him one of them, though he wasn't Orthodox.
Nevertheless, Genoeses gave Mamai money for the military campaign, considering that the victory would cover the expenses. Though, this time he had to overcome Russian dukes first, then Siberian Tatars of Tokhtamysh. The ranks of Mamai army joined Circassians, Alanians, Polovets who at that time were already called Tatars, and Genoeses. Moreover, Lithuanian duke Yagaylo also set to help Mamai. In order to prevent uniting of the armies duke Dmitriy Ivanovich hurried towards Mamai and reached his goal: Yagaylo was late to the beginning of the battle.
Dmirty's army consisted of Russian dukedoms' retinues, numerous irregulars and cavalry consisted of baptized Tatars, Lithuanians and Russians, trained in Tatar cavalry. These very cavalrymen decided the destiny of the Battle of Kulikov when they attacked in the rear Tatar cavalry that already celebrated the victory and lost its order.
The victory was gained, but Russian losses appeared to be disastrous: of 150 thousand only 30 thousand warriors survived. 120 thousand people were died or injured. "In no way decreasing the heroism of Russians in the Battle of Kulikov, one should note that the absence of eighty thousand Lithuanian army in the battle played its role in the victory", - notes the historian Gumilev. When Yagaylo arrived at the battle field he chased after Dmitriy. When he came up with the carts he killed all the injured men. It was incomprehensible and unexplainable cruelty, especially taking into consideration that the majority of Yagaylo's army was made up of Russians originated from Minsk, Polotsk, Grodno.
However, not only Yagaylo hurried at the battle field. Tokhtamysh hurried to help Dmitriy as well. However, his Siberian Tatars by no means had time to get to the beginning of the Battle of Kulikov. That is why Tokhtamysh went directly to Crimea having his aim to finish with his bitterest enemy in his very den where Mamai hided healing his wounds.
Mamai had little time. However, in the face of the severe danger the population of Crimean get quickly organized and set towards the conqueror with large army. In autumn 1380 in the Battle of Kalka (next to Perekop), that was even more bloody than the Kulikov one, Crimeans suffered the defeat. This determined Mamai's fate. Unwilling to let the devastation of Crimea Genoeses hatched a plot and at night killed Mamai in Kafe (Feodosiya) and met Tokhtamysh with the petition and the head of the intractable governor of Crimea.
Thus, Crimea escaped just another massacre.
However, Tokhtamysh showed Moscow no mercy. In 1382 he reduced it to ashes slaughtering almost the whole its population. Though, the duke and its retinue were not in the city: when Dmitriy Donskoy found out about the coming of Tatars he reasonably left the capital.
It's hard to tell why Dmitriy Ivanovich's overlord got mad at him. However, it was the fact.
As far as the future fate of Dmitriy Donskoy concerns he left the political scene. He died in 1389 being the obedient vassal of Holden Horde Empire. He didn't even thought about the overthrowing of so called "Tatar Yoke". There even wasn't such idea at those times. It appeared only in the time of Catherine II. Though, at those times the rule of Saray was a great benefit for Russian lands. Every Russian dukedom understood this. Let's recall Alexander Newsy who came to Saray ten years after the famous raid of Batyj on some Slav dukedoms. There wasn't Newsky's patrimony among them. Understanding well all its benefits he asked vassal dependence of all Russian lands from Golden Horde. By bringing a small Tatar garrison leaded by Nevruy - noyon of Batu khan to Novgorod the Grand Duke discouraged the Teutonic order from claiming to the lands of Russian dukedoms forever. "Independent Smolensk (also) asked to be part of Dzhuchiev Ulus in order to receive help to oppose the infringement of Lithuania" (L. N. Gumilev). However, one of the best statements about the benefit of Holden Horde for Russian lands was made by the historian V. Kluchevsky. "If they (Russian dukes) we left on their own, they would scattered their native Russia into the rambling, ever fighting among each other appanage rags… The threat of khan's anger held these roughnecks in check; the khan's mercy, in other words, khan's tyranny more than once prevented or stopped the devastating intestine war".
As we can see, Dmitriy Donskoy knew well enough the necessity of the firmness of Golden Horde Empire. He never thought of overthrowing any "yoke", the post Catherine and the Soviet historians were repeatedly talking about. As any other vassal he, first of all was interested in the mighty overlord, second, he wanted and strived for only one thing - to derive more benefit for himself from the existing and ever changing political and other situation.
Though, one couldn't say the same about Crimea, because Crimea at those times on economic and military power exceeded all Russian dukedoms taken together. That is why if Mamai had wanted the separation from the empire he could solve this problem. However, he didn't have such goal.