fix some bugs #18

hcsm-setup might work well.