test_ctp.py: added unittests for most functions

Added tests for the following functions:
* _is_keyword
* _is_pin
* _pins_to_arg
* _get_pin_vals
* _cmd_check
* _cmd_set
* _cmd_gnd
* _cmd_vin
* _cmd_delay
ctp.py: corrected errors found with the unittest
.gitignore: made sure git ignores __pycache__