In the early stages of the American Revolutionary War, Armstrong was a brigadier general in the Pennsylvania militia. On March 1, 1776, the Continental Congress appointed him to that same rank in the Continental Army. He was sent south to begin preparations for the defense of Charleston, South Carolina. He contributed his engineering talents to the construction of defenses that enabled them to withstand the Battle of Sullivan's Island later that year. When General Charles Lee arrived to take command, he returned to his duties with the main army and with the Pennsylvania militia. Pennsylvania named him major general in charge of the state militia. This ended his service in the Continental Army, but not the war or his cooperation with General George Washington.