summaryrefslogtreecommitdiff
path: root/apps/examples/ajoystick
diff options
context:
space:
mode:
authorGregory Nutt <gnutt@nuttx.org>2014-12-14 08:55:18 -0600
committerGregory Nutt <gnutt@nuttx.org>2014-12-14 08:55:18 -0600
commitc627d15288f61aa2cbb4d1484cf06f497fd5a9c2 (patch)
treedb418294d639fcd2ac89fcff83476eac9627a597 /apps/examples/ajoystick
parentdcc19a2b10684dd6c41ab0746ed6280d161edfe6 (diff)
downloadnuttx-c627d15288f61aa2cbb4d1484cf06f497fd5a9c2.tar.gz
nuttx-c627d15288f61aa2cbb4d1484cf06f497fd5a9c2.tar.bz2
nuttx-c627d15288f61aa2cbb4d1484cf06f497fd5a9c2.zip
Traveler: Add support for analog joystick
Diffstat (limited to 'apps/examples/ajoystick')
-rw-r--r--apps/examples/ajoystick/ajoy_main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/examples/ajoystick/ajoy_main.c b/apps/examples/ajoystick/ajoy_main.c
index c65866a0d..3fb4a2b23 100644
--- a/apps/examples/ajoystick/ajoy_main.c
+++ b/apps/examples/ajoystick/ajoy_main.c
@@ -271,7 +271,7 @@ static int ajoy_waitread(int fd, FAR const struct timespec *timeout,
ret = ajoy_wait(fd, timeout);
if (ret < 0)
{
- fprintf(stderr, "ERROR: ajoy_wait() failed: %d\n", errno);
+ fprintf(stderr, "ERROR: ajoy_wait() failed: %d\n", ret);
return ret;
}
@@ -280,7 +280,7 @@ static int ajoy_waitread(int fd, FAR const struct timespec *timeout,
ret = ajoy_read(fd, sample);
if (ret < 0)
{
- fprintf(stderr, "ERROR: ajoy_read() failed: %d\n", errno);
+ fprintf(stderr, "ERROR: ajoy_read() failed: %d\n", ret);
return ret;
}