Fixed one bug for Serial Scan by key code + changed map/unmap code + som...

...e offset test cases