Implemented DCG terminal handling