Sometimes in movies and cartoons, a character will have some kind of electronic gizmo or she'll be riding in a plane or car, and there will be a "little red button." You don't know what the little red button does, but you know it's going to be big, and probably loud. The character knows – don't push the red button – but, in the end, curiosity gets the best of her and she has to do it. Needless to say, she always regrets pushing that little red button.
The speaker of this poem feels he has the ultimate little red button at his disposal: angels who blow trumpets at the end of time, as prophesied in the Book of Revelation. He can initiate the Last Judgment. When he orders the angels, "Blow your trumpets!", he starts a process where all the dead rise up to find their bodies and go to be judged. But, as always, there's a complication he hasn't foreseen – his sins will be judged, too. Why, oh, why did he push that button!
The whole ordering-angels-to-start-the-Apocalypse idea is right there on the surface of the poem. But once we read to the end, we wonder if the speaker has been aware the whole time of his need to repent of his sins. Maybe the poem itself is an act of repentance, in which he displays his arrogance and presumptuous in the beginning and then asks for grace at the end.
In that case, "Teach me how to repent" could mean, "Teach me how to write this poem I'm writing." The speaker is humble before God, but he is also aware of his own cleverness and wants to make use of it as a man of faith. This speaker clings to his faith and maintains his own intelligence. Even when he feels burdened by his own sins, he never loses his cool or his impressive control of language.