From 64d7ae4747041352edeb9cbf5418b0ab274da5e1 Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Wed, 6 Feb 2013 00:54:15 +0000 Subject: added open and close command git-svn-id: https://svn.spreadspace.org/avr/trunk@123 aa12f405-d877-488e-9caf-2d797e2a1cc7 --- usb-i2c-sl018/tuer-rfid.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'usb-i2c-sl018/tuer-rfid.c') diff --git a/usb-i2c-sl018/tuer-rfid.c b/usb-i2c-sl018/tuer-rfid.c index 1817239..7fa7d14 100644 --- a/usb-i2c-sl018/tuer-rfid.c +++ b/usb-i2c-sl018/tuer-rfid.c @@ -344,6 +344,18 @@ void handle_stdio(uint8_t cmd) case 'd': //dump eeprom - this breaks security! dump_keystore_to_stdio(); break; + case 'o': + if(start_stepper(dir_open)) + fprintf(stdio, "ok\n\r"); + else + fprintf(stdio, "error: already in progress\n\r"); + break; + case 'c': + if(start_stepper(dir_close)) + fprintf(stdio, "ok\n\r"); + else + fprintf(stdio, "error: already in progress\n\r"); + break; default: fprintf(stdio, "error, unknown command %02X '%c'\n\r",cmd, cmd); return; } } -- cgit v1.2.3