Add macros or #define statments instead of magic numbers
The line
when (dtlOperationalCode_Command == 606) {
exists in dtl 01. The 606 should be a constant or a macro. (etc. etc.)
The line
when (dtlOperationalCode_Command == 606) {
exists in dtl 01. The 606 should be a constant or a macro. (etc. etc.)