F.L.
I do not recommend taking any medication before you take him to see the doctor. My son was a stubborn baby too and now he's 4. When he was around your son's age, he sometimes woke up in the middle of the night and kicking on the bed angrily. He probably still wanted to sleep but he couldn't so that he was frustrating. I had to be very firm asking him to calm down before taking him up. If he continued to kick, I will leave the room. I also encourage him to tell me what had happened and why he's doing this. Once he calmed down, I would hold him for a couple minutes. After a few times, he learnt how to deal with the bad feeling. He then never woke up with the angry temper again.
Sometimes toddlers wake up in the middle of the night with angry temper because they do not feel well or they just had a bad dream. All we need to do is to help them to learn how to deal with it. Hope my experience would help.