PArallel port - Programmers Heaven

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

PArallel port

Hi,
Could someone please help me, I have an embedded system that I wish to interface with my PC running windows 98 via the parallel port. The embedded system is to control a mobile robot, which is fairly straightforward, as it will be running/controlled through another O/S (salphira). The problem that I’m having is to read data in through the parallel port. I’m only reading the five most significant bits of logic so there is no output from the PC at all. The problem is that the program must be written in Visual C++ to be able to interface with components of the system. I have searched the net for relevant code but I am unable to find any that even complies under Visual C++! Could anyone point me in the right direction or help me out here please.

Ian

Comments

  • nematodenematode Posts: 2Member
    maybe something here can help
    http://www.beyondlogic.org/spp/parallel.htm

    nema
  • anthonyanthony Posts: 36Member
    : Hi,
    : Could someone please help me, I have an embedded system that I wish to interface with my PC running windows 98 via the parallel port. The embedded system is to control a mobile robot, which is fairly straightforward, as it will be running/controlled through another O/S (salphira). The problem that I’m having is to read data in through the parallel port. I’m only reading the five most significant bits of logic so there is no output from the PC at all. The problem is that the program must be written in Visual C++ to be able to interface with components of the system. I have searched the net for relevant code but I am unable to find any that even complies under Visual C++! Could anyone point me in the right direction or help me out here please.
    :
    : Ian
    :

    Hi

    Use
    #include


    _outp(port_address,data); /*for putting data on the port.*/
    data=_inp(port_address); /*for getting data on the port.*/

    also do you know how to reverse the direction of the port for reading?

    Cheers
    Anthony
Sign In or Register to comment.