Welton Townsend of Williamsville has been charged with reckless endangerment and disorderly conduct.
Police responded to Townsend's home at about 6:10 p.m. Wednesday. They said a man later identified as Townsend left the home and threatened troopers with a "shootout."
Police surrounded the home and tried to convince him to speak to them. The man began to fire rounds from a handgun into the air. Police did not fire back and the man stopped firing shots.