Ultimate modding, advice and suggestions needed.
I'll start off by explaining the long term goal of the project, hopefully that will answer a few possible questions.
I've made a control board using a programmable IC. the controller has two sets of IO pins, port a and port b. the program looks at port A and looks for logic high signals (currently provided by switches). when it recieves a logic high it will turn a light on. when it recieves a second logic high (on the same input pin) it will turn the light back off again. (yes it's a glorified light switch).
I have a plan to turn these lights on and off using a computer. - I'm going to make my house computer controlled.
so my questions (an requests for ideas) are.
I will make an excecutable in C to controll the hardware ports.
I have a working excecutable that can both read and write to the parallel port, but it only works under windows 95/98. because NT systems have a protection level. only DLL files that are assigned a group 0 privellage are allowed to communicate directly with the hardware.
So, Does anyone have any clues or places to start with making my own hardware controlling DLL files?
(i searched google almost constantly for a few days and turned up lots of programs that claim to do it, however most still return privellaged instruction errors when they try to access the port).
Secondly, and a way I think I'd much rather do this.
I could put the control program on my webserver and connect the switch box to my webserver, this way I could control the lights from anywhere. So, does PHP have any libraries for controlling either the parallel port?
(I know I could make the C file and CGI file and have made a load of CGI files compiled in C that generate webpages before so the first and second idea are quite closely linked.)
the third Idea, which is perhaps the easiest, but the one that is least flexible.
I make the control progamme using Visual basic...
unfortunatly this leaves me with no options for web support. and now options (aside from the making my own hardware accessing DLL) for accessing the parallel port. However VBs one saving grace is that it does already have an object for controlling the serial port.
So this is the part where I ask for help...
which one of the above ideas should I persue, one is obviously better than the others, (I'm thinking the C program). But the visual basic option is infinitly easier. PHP would be nice, but sadly I think thats a pipe dream expecting a web language to have hardware support.
Can anyone think of any other ways?
all I want to do is hold one pin of the parallel port high for a second or so. (actually 3 tenths of a second is long enough as I've used two tenths debouncing cheap switches).
if I use the serial port all I want to do is transmit a number, (I'll make an interface that will sort out the rest).
If I use the C option (thats using C not the third option), then I'll need to write a DLL for interfacing with the hardware. (so does anyone have any info on this?)
the last option, - and the one I really don't want to do. even though I could implement it today.
I use the C program I have to access the Parallel port, I compile it as an excecutable file and then setup a windows 98 machine as a server. so the question with this method is...
does windows 98 Personal web server support the use of CGI files?
is there a version of apache that can be installed on windows 98?
If no-one here is able to help, does anyone know any places where i'd be able to get help? (Other than a mental institute!)