third commit after putting together CardIO and HCE with update polishing the code