% ------------------------------------------------------------------------------
% Copyright (c) 2019, 2026 Contributors to the Eclipse Foundation
%
% See the NOTICE file(s) distributed with this work for additional
% information regarding copyright ownership.
%
% This program and the accompanying materials are made available under the terms
% of the MIT License which is available at https://opensource.org/licenses/MIT
%
% SPDX-License-Identifier: MIT
% ------------------------------------------------------------------------------
\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{arrows.meta, arrows, automata, calc, positioning, shapes, shapes.misc}
\usepackage[paperwidth=40in, paperheight=20in]{geometry}

\begin{document}
\pagestyle{empty}

\begin{tikzpicture}[
    auto,
    ->,
    node distance=4cm,
    every state/.style={ellipse, semithick, fill=black!5, minimum size=1.5cm, font=\Large},
    initial distance=1.2cm,
    every initial by arrow/.style={-{Stealth[scale=1.4]}},
    initial text=,
    transform shape,
    double distance=2pt,
    every loop/.style={min distance=10mm}
]

\node[state, initial, accepting] (A) {\emph{A}};
\node[state, right=3.0cm of A]   (B) {\emph{B}};
\node[state, right=3.0cm of B]   (C) {\emph{C}};
\node[state, below=1.5cm of A]   (D) {\emph{D}};
\node[state, below=1.5cm of B]   (E) {\emph{E}};
\node[state, below=1.5cm of C]   (F) {\emph{F}};

\path[-{Stealth[scale=1.4]}]
    (B) edge[loop above, dashed]       node[align=center] {\texttt{push\_start}}                      (B)
    (A) edge[loop above, dashed]       node[align=center] {\texttt{push\_stop}}                       (A)
    (C) edge[loop above, dashed]       node[align=center] {\texttt{push\_start}\\\texttt{push\_stop}} (C)
    (D) edge[loop below, dashed]       node[align=center] {\texttt{push\_stop}\\\texttt{push\_start}} (D)
    (E) edge[loop below, dashed]       node[align=center] {\texttt{push\_stop}}                       (E)
    (F) edge[loop below, dashed]       node[align=center] {\texttt{push\_start}}                      (F)
    (A) edge[bend left, above, dashed] node[align=center] {\texttt{push\_start}}                      (B)
    (B) edge[bend left, below, dashed] node[align=center] {\texttt{push\_stop}}                       (A)
    (E) edge[bend left, above, dashed] node[align=center] {\texttt{push\_start}}                      (F)
    (F) edge[bend left, below, dashed] node[align=center] {\texttt{push\_stop}}                       (E)
    (B) edge[above]                    node[align=center] {\texttt{start\_machine}}                   (C)
    (E) edge[above]                    node[align=center] {\texttt{stop\_machine}}                    (D)
    (D) edge[left, dashed]             node[align=center] {\texttt{turn\_off}}                        (A)
    (C) edge[left, dashed, pos=0.3]    node[align=center] {\texttt{turn\_on}}                         (F)
;

\end{tikzpicture}
\end{document}
