test if gcode repo exists
This commit is contained in:
@@ -68,6 +68,10 @@ def pg_ok_cb(channel):
|
|||||||
|
|
||||||
def init():
|
def init():
|
||||||
''' init pins and display main menu '''
|
''' init pins and display main menu '''
|
||||||
|
if not os.path.exists(GCODE_REPO):
|
||||||
|
logging.error("Path {} doesn't exist".format(GCODE_REPO))
|
||||||
|
sys.exit(1)
|
||||||
|
|
||||||
try:
|
try:
|
||||||
GPIO.setup(PG_UP, GPIO.IN)
|
GPIO.setup(PG_UP, GPIO.IN)
|
||||||
GPIO.setup(PG_DOWN, GPIO.IN)
|
GPIO.setup(PG_DOWN, GPIO.IN)
|
||||||
|
|||||||
Reference in New Issue
Block a user