SyncStitch:Train Gate Controll ref: http://qiita.com/kencoba/items/82a0ff70737a6c150148