merging with FacScan100 code base and fixing some memory initialization issues
merging with FacScan100 code base and fixing some memory initialization issues