Added pid loader to create_fsm
Added code for better handling uplods to leofs