initial code for HStage