about // port interfacing

Status
Not open for further replies.

halt

Junior Member level 2
Joined
May 30, 2005
Messages
20
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,442
hi everybody i have just a lil question about parallel port interfacing
how can i do to control only one desired data bit in parallel port
so with outb/inb (0x378,n); (in c language) we can control all outputs or inputs
together but what i want to do is for example set the 3rd bit like in input and a 5th
as in output so every bit can be controlled separatly.

in reality i wanna create my own eeprom programmer . thx
 

Hi,

As far as I am aware, you can't do this, at least in standard mode. There are quite a few simple parallel port EPROM programmers on the internet and none of them do this.

Have you read these two documents?





Some more good stuff:

https://www.epanorama.net/circuits/parallel_output.html


Cheers,
FoxyRick.
 

you can access a single bit in any port by masking the other bits using the bitwise XOR operator (^)
example
outport(0x378,0x05^0x6)
the follwoing configuration (0101 XOR 0110) will be output to port 0x378
 

Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…