finish coding and testing

Signed-off-by: yuanhuan <yuanhuan@tcl.com>