Monday, May 24, 2010

HELP me OUT!!?

I need advice.. quick!


I have got a simple circuit to control an LED via the parallel port (thru a Turbo C 3.0 program) but i somehow cant manage it...!





the outportb(PORT, value) command doesnt seem to work!!





i connected the +ve leg of the LED to the D5 connector and the -ve leg to the ground (hole 18) of the parallel port... used the outportb() function but nothing happened!!!





what could be the problem? am i connecting the LED in a wrong way??





PS: ALSO LEMME KNOW OF SOME COOL PARALLEL PORT INTERFACING PROGRAMS USING TC 3.0!!! I'M A STUDENT OF BS

HELP me OUT!!?
Ok, as for the harware connections on a parallel port, I've got no clue. However, TC3.0 is a DOS version, if I remember correctly. You don't say what os you're trying to run the program under, either. So, given that here are potential problems I see for the program.





1). Trying to run a DOS port control program under Windows. This is almost invariably a problem someone will hit these days. In Win9x, this isn't usually a problem. In any Windows Someflavor other than that, Windows wants your program to know the secret handshake before it will give up the hardware to your program's control. Quick Dirty Fix: Use DOS from MS-DOS or Win9x on a bootable diskette to run your software.





2). You're not sending the right value to the parallel port to make the LED work. The value doesn't set the bit that the +pin is connected to. Change the value so it does!





3). You've got everything working, but the LED isn't lighting. Well either it's A. the LED isn't any good (test it!) or B. the pulse width coming from the parallel port isn't wide enough to light the LED for an observable time. Send more pulses coming fast and see what happens.





4). Re-check all standard parameters, like the port number of the LPT one final time and cross all fingers and toes!





5). If all else has failed and you suspect the code is at fault, then try the URL below for examples.








This is what I know from experience in programming communications ports and what little electronics I know. I hope you find your answer here. Good luck!
Reply:i'm a student of bs... he he he he
Reply:Everybody asking a question here wants help - it goes without saying - so why not use the "subject" part of the question to give everyone a chance of seeing the _subject_ of your question instead of just stating the obvious?





Rawlyn.


No comments:

Post a Comment