Permalink
Browse files

Update c++ host to work with modern compilers.

  • Loading branch information...
1 parent 9ce25e5 commit 5b4dcb42a5b02b7aac1241e7237381b464cc9f01 @cibomahto cibomahto committed May 24, 2012
Showing with 5 additions and 2 deletions.
  1. +5 −2 c++_host/host.cpp
View
7 c++_host/host.cpp
@@ -1,6 +1,8 @@
#include <iostream>
-#include <String>
+#include <string>
+#include <cstdio>
+#include <cstdlib>
// First, try to send data to the usb port
#include <fcntl.h> /* File control definitions */
@@ -83,7 +85,7 @@ void LedStrip::SendBytes64(char* data) {
}
while (return_code < 0);
if (count > 0) {
- std::cout << "index=" << index << ", count=" << count << std::endl;
+ std::cout << "count=" << count << std::endl;
}
}
@@ -115,6 +117,7 @@ int main( int argc, const char* argv[] ) {
std::cout << "Connecting!" << std::endl;
LedStrip test(24,160,0);
test.Connect("/dev/cu.usbmodem12341");
+// test.Connect("/dev/ttyACM0");
// Black test frame
char data_off[24*160*3];

0 comments on commit 5b4dcb4

Please sign in to comment.