Files
bouwhuim.nikhef.nl dee2668a61 newest version WRPC
2013-09-10 08:08:59 +00:00

27 lines
457 B
C

/* Command: ptp
Arguments: one [start/stop]
Description: (re)starts/stops the PTP session. */
#include <errno.h>
#include <string.h>
#include "wrc_ptp.h"
#include "shell.h"
static int cmd_ptp(const char *args[])
{
if (!strcasecmp(args[0], "start"))
return wrc_ptp_start();
else if (!strcasecmp(args[0], "stop"))
return wrc_ptp_stop();
else
return -EINVAL;
return 0;
}
DEFINE_WRC_COMMAND(ptp) = {
.name = "ptp",
.exec = cmd_ptp,
};