diff options
author | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2011-08-30 17:20:46 +0000 |
---|---|---|
committer | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2011-08-30 17:20:46 +0000 |
commit | 7b01904121be6cb88d28005a77da9c1815593925 (patch) | |
tree | 934fbe483e0599843e1be72fe93882b90cde810b /apps/system/i2c/i2c_common.c | |
parent | f62cc877bdb5e731e099aa45c8774c5d5892c672 (diff) | |
download | px4-nuttx-7b01904121be6cb88d28005a77da9c1815593925.tar.gz px4-nuttx-7b01904121be6cb88d28005a77da9c1815593925.tar.bz2 px4-nuttx-7b01904121be6cb88d28005a77da9c1815593925.zip |
Initial debug changes to the I2C tool
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@3929 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'apps/system/i2c/i2c_common.c')
-rw-r--r-- | apps/system/i2c/i2c_common.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/apps/system/i2c/i2c_common.c b/apps/system/i2c/i2c_common.c index 1a97e40b6..a04f7769a 100644 --- a/apps/system/i2c/i2c_common.c +++ b/apps/system/i2c/i2c_common.c @@ -86,7 +86,7 @@ int common_args(FAR struct i2ctool_s *i2ctool, FAR char **arg) goto invalid_argument; } - switch (ptr[0]) + switch (ptr[1]) { case 'a': ret = arg_hex(arg, &value); @@ -151,11 +151,11 @@ int common_args(FAR struct i2ctool_s *i2ctool, FAR char **arg) } invalid_argument: - i2ctool_printf(i2ctool, g_i2carginvalid, arg); + i2ctool_printf(i2ctool, g_i2carginvalid, ptr); return ERROR; out_of_range: - i2ctool_printf(i2ctool, g_i2cargrange, arg); + i2ctool_printf(i2ctool, g_i2cargrange, ptr); return ERROR; } |