history of the electric telegraph in military