Give one month's notice because they might need to hire or find your replacement which can take more than two weeks. Write a letter to HR and your boss or supervisor thanking them for the opportunity and explaining that it is time to move on. You can handle this with respect for the company and the boss and still use them as a reference in the future.