This document proposes a model-driven architecture approach to transforming UML state diagrams into a platform-independent model (PIM) using extended automata. The approach defines a Parallel Hierarchical Statechart Automaton (PHSA) that can represent state diagrams in a way that separates platform-independent and platform-specific aspects. The PHSA model decomposes state diagrams into components including a Moore automaton to represent states and transitions, a memory to store variables, a calculator to evaluate guards and actions, and input/output. This representation facilitates further transformations from the PIM to specific platform models.