I wonder if a state machine is just the state pattern at work or if there is actually a difference between those two?
I found this article with the
A state machine can be designed and implemented in several ways. One way is to use the state pattern described in the book by the Gang of Four. But there are other patterns to implement a state machine.
For example, you may want to have a look at the research of Miro Samek by reading the book Practical UML statecharts in C/C++, 2nd ed. (Event-Driven Programming for Embedded Systems)
You may also find interesting this question.