Compare commits

..

No commits in common. "5bd592dc1cb8fecfe65afbb3e6fea23382f370c0" and "eb3dc4338f317ccd29771fa028558b9f0df88962" have entirely different histories.

2 changed files with 2 additions and 16 deletions

1
.gitignore vendored
View file

@ -1 +0,0 @@
.venv/

17
main.py
View file

@ -1,9 +1,6 @@
import argparse
import sys
import bluetooth #PyBluez
version = '0.0.0'
import bluetooth
def bluetooth_scan():
print('Discovering Bluetooth Devices...')
@ -15,17 +12,7 @@ def bluetooth_scan():
print(f'{device[0]}\t{device[1]}')
def main():
argparser = argparse.ArgumentParser(description='CarPI CLI.')
# Create actions
actions = argparser.add_subparsers(title='actions', required=True)
action_list = actions.add_parser('list', help='list nearby bluetooth devices')
action_list.set_defaults(func=bluetooth_scan)
action_connect = actions.add_parser('connect', help='connect to a bluetooth device')
args = argparser.parse_args()
print(args)
args.func()
bluetooth_scan()
if (__name__ == "__main__"):
sys.exit(main())