Re: Parallel port and Visual Basic?



Zucker wrote:
I am in the process of building a circuit that will monitor the start and
finish times for pine box derby cars. I would like to be able to catch these
events by feeding signals, through the parallel port, to a Visual Basic
program. I was thinking of using the eight data pins from the parallel port
to monitor eight lanes.

The electronics are good to go. My problem is with Visual Basic.

Does anyone know how to access and capture bit patterns from the parallel
port using Visual Basic?

Steve

PS...I have asked this same question in several programming newsgroups, but
I have not recieved any responses.



You have several problems. The operating system may prohibit you from accessing the parallel port. You may need a driver to enable this. Visual Basic prohibits you access to the parallel port. You may need a dll/driver/ocx etc to gain access. You need some way to time the event.

Variable program latencies.

All these layers of software mean that you can't get an accurate or even
repeatable time measurement.  The newer the OS, the greater the uncertainty.

Suggestion 1:
Do the sense/calculate in a microcontroller and send the answer to VB via RS232 port.


Suggestion 2:
Ditch VB. Run pure DOS. Use the hardware timer in the 8253 emulation...it's the timer that normally runs the beeper.
Program it in something compiled and determinate like assembler or C.
This should give you guraranteed sub-second repeatability.


mike

--
Return address is VALID but some sites block emails
with links.  Delete this sig when replying.
..
Wanted, PCMCIA SCSI Card for HP m820 CDRW.
FS 500MHz Tek DSOscilloscope TDS540 Make Offer
Wanted, 12.1" LCD for Gateway Solo 5300. Samsung LT121SU-121
Wanted 12" LCD for Compaq Armada 7770MT.
Bunch of stuff For Sale and Wanted at the link below.
MAKE THE OBVIOUS CHANGES TO THE LINK
ht<removethis>tp://www.geocities.com/SiliconValley/Monitor/4710/

.



Relevant Pages

  • Re: LCD module - PC Parallel port
    ... > and the center of the pot to pin 3 of the LCD. ... Have you used the circuit with the pot (incorrectly ... to your parallel port 0V and you have connected the parallel port 0V to your ... 5V supplys 0V? ...
    (comp.arch.embedded)
  • Re: What voltage and current to control 1 segment of LCD ?
    ... > What you may not know is that in order to capture the LCD drive ... > properly there are two signals you need to consider, ... You do not need to mess with the LCD or its drivers. ... I have allready connected it to the pin 13 of the parallel port. ...
    (sci.electronics.misc)
  • Re: LCD module - PC Parallel port
    ... I've wired up the LCD module to the Parallel Port of PC as shown here: http://www.codeproject.com/csharp/cspplcds.asp ... Signals on Parallel port is working fine. ... on pin 3 of the LCD should be a 10k pot, ...
    (comp.arch.embedded)