aboutsummaryrefslogtreecommitdiffstats
path: root/host/apps/omap_debug/usrp1-e-write.c
diff options
context:
space:
mode:
Diffstat (limited to 'host/apps/omap_debug/usrp1-e-write.c')
-rw-r--r--host/apps/omap_debug/usrp1-e-write.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/host/apps/omap_debug/usrp1-e-write.c b/host/apps/omap_debug/usrp1-e-write.c
new file mode 100644
index 000000000..f29cc7032
--- /dev/null
+++ b/host/apps/omap_debug/usrp1-e-write.c
@@ -0,0 +1,21 @@
+#include <stdio.h>
+#include <sys/types.h>
+#include <fcntl.h>
+
+int main(int rgc, char *argv[])
+{
+ int fp, i, cnt;
+ short buf[1024];
+
+ fp = open("/dev/usrp1_e0", O_WRONLY);
+ printf("fp = %d\n", fp);
+
+ for (i=0; i<1024; i++) {
+ buf[i] = i;
+ }
+
+ do {
+ cnt = write(fp, buf, 2048);
+ printf("Bytes written - %d\n", cnt);
+ } while (1);
+}