Police told WHBQ-TV that Ferguson was asked to leave the business in November after threatening a group of people about stealing a phone.
>> Read more trending news
Once outside, Ferguson pulled out an AK-47 and aimed it at a bus filled with children, according to police.
People at the scene pleaded for Ferguson to put the gun away, but he continued to yell at the bus, authorities said.
Police said Ferguson eventually got into the driver's seat of a silver SUV and fled the scene.
Officers reportedly found Ferguson on Cordova Road fleeing the scene south of Incredible Pizza.
Police said they caught up with Ferguson in the Walmart parking lot in the 500 block North Germantown Parkway.
When police approached the vehicle, Ferguson fled the scene again at a high rate of speed, authorities said.
Ferguson eventually crashed into another vehicle at the intersection of Walnut Grove and Germantown Parkway.
Police said Ferguson fled the scene again, but several children were in the car at the time of the crash. The youngest child was only 2 years old.
Investigators also located the AK-47 and two Glock pistols inside the vehicle, police said.
Ferguson is being held on a $21,000 bond. His next court appearance is July 2 at 9 a.m.