Former soldier accused of threatening psychiatrist granted bail