Shows Schedule Inside Revision3 Store

Go Back   Revision3 Forums > Shows > HAK5

Thread Tools Search this Thread Display Modes

Old 04-20-2009, 11:39 PM
blackcow's Avatar
Join Date: Jan 2007
Posts: 6
Status: Offline
Default Remote control RC car with a Linux server.

So I remember hearing that Hak5 is working on a net controlled RC tank so I thought I would share how I did it using a parallel port on my Linux server and some C and PHP. I wrote the client in flash action script. I am sure it is pretty easy to do the same in JavaScript.

I wrote up an article about it and provide all the code and instructions to control the parallel port from the web.

I will be interested to see how Hak5 does it.

Last edited by blackcow : 04-20-2009 at 11:40 PM.
Reply With Quote
Old 04-21-2009, 01:00 AM
Posts: n/a
Reply With Quote
Old 05-06-2009, 04:27 PM
Join Date: May 2009
Posts: 7
Status: Offline

I recently started a similar project, I'm also using Linux and PHP. Here's a link to my project

Last edited by jimlovell777 : 05-06-2009 at 04:28 PM.
Reply With Quote
Old 10-28-2010, 08:00 PM
Posts: n/a

I had forgotten all about this. I have been playing with parallel port interfacing. Wrote my own server software independent of this project. Will go back and look at it again.

Used :
#include <asm/io.h>
instead of
#include <sys/io.h>

Last link no longer works.

#include <stdio.h>
#include <unistd.h>
#include <sys/ioctl.h>
#include <sys/io.h>  // should be asm/io.h for some linux variations.

//#include <asm/io.h>
// Didn't work, replaced with sys/io.h

char *binprint( unsigned char x, char *buf )
int i;
for( i=0; i<8; i++ )
return buf;

int main( int argc, char *argv[] )
char c;
unsigned char val;
char buf[9];
int x;
if( argc<2 )
printf("Example usage: ppp 1l 2l 3h 5h 8l\n");
return 2;
if( ioperm(888,1,1) )
printf("Couldn't find parallel port (888)\n");
return 1;
val = inb(888);
printf("old = %s\n",binprint(val,buf));
for( x=1; x<argc; x++ )
if( argv[x][1]!='h' )
val &= ~(1<<(argv[x][0]-'1'));
val |= 1<<(argv[x][0]-'1');
printf("new = %s\n",binprint(val,buf));
return 0;

Last edited by computoman : 10-28-2010 at 08:06 PM.
Reply With Quote

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

All times are GMT. The time now is 06:20 PM.

Rev3 Forum RSS

© 2005-2010 Revision3 Corporation