State television broadcast patriotic songs as it announced the coup attempt and urged “the people to confront it”.