 He resigned in 1873 to raise and command a body of Indian troops to restore order in Larut, a mining district in the Malayan state of Perak, for the Mentri (Chief Minister) Ngah Ibrahim.In 1874, Speedy was appointed assistant British resident of Larut and established and named Malaysia's oldest town, ‘Thaipeng’, meaning ‘Heavenly Peace’.He remained there until 1877.