add some new serial code.