summaryrefslogtreecommitdiffstats
path: root/host/apps
diff options
context:
space:
mode:
Diffstat (limited to 'host/apps')
-rw-r--r--host/apps/omap_debug/usrp-e-debug-pins.c4
-rw-r--r--host/apps/omap_debug/usrp-e-i2c.c6
-rw-r--r--host/apps/omap_debug/usrp-e-spi.c7
3 files changed, 17 insertions, 0 deletions
diff --git a/host/apps/omap_debug/usrp-e-debug-pins.c b/host/apps/omap_debug/usrp-e-debug-pins.c
index d4e3f5223..d18bbf990 100644
--- a/host/apps/omap_debug/usrp-e-debug-pins.c
+++ b/host/apps/omap_debug/usrp-e-debug-pins.c
@@ -46,6 +46,10 @@ int main(int argc, char *argv[])
fp = open("/dev/usrp_e0", O_RDWR);
printf("fp = %d\n", fp);
+ if (fp < 0) {
+ perror("Open failed");
+ return -1;
+ }
if (strcmp(argv[1], "0") == 0) {
printf("Selected 0 based on %s\n", argv[1]);
diff --git a/host/apps/omap_debug/usrp-e-i2c.c b/host/apps/omap_debug/usrp-e-i2c.c
index 615dc557b..da8709ae1 100644
--- a/host/apps/omap_debug/usrp-e-i2c.c
+++ b/host/apps/omap_debug/usrp-e-i2c.c
@@ -37,6 +37,12 @@ int main(int argc, char *argv[])
fp = open("/dev/usrp_e0", O_RDWR);
printf("fp = %d\n", fp);
+ if (fp < 0) {
+ perror("Open failed");
+ return -1;
+ }
+
+// sleep(1);
if (direction) {
count = argc - 3;
diff --git a/host/apps/omap_debug/usrp-e-spi.c b/host/apps/omap_debug/usrp-e-spi.c
index d2c38e524..c353c409b 100644
--- a/host/apps/omap_debug/usrp-e-spi.c
+++ b/host/apps/omap_debug/usrp-e-spi.c
@@ -28,6 +28,13 @@ int main(int argc, char *argv[])
fp = open("/dev/usrp_e0", O_RDWR);
printf("fp = %d\n", fp);
+ if (fp < 0) {
+ perror("Open failed");
+ return -1;
+ }
+
+// sleep(1);
+
spi_dat.slave = slave;
spi_dat.data = data;