Is there a way to detect changes in the serial portr control leads CTS DSR
DCD RI?
I’m fairly certain that most serial chips can be set to generate an
interrupt on some or all of the lead changes, and thus there should be a way
to do this in library functions… (Wishful thinking???)
I was hoping to set up a proxy that would be activated when any of the leads
on the port change state.
Paul
paul@jenosys.com
Paul Russell <paul@jenosys.com> wrote:
Is there a way to detect changes in the serial portr control leads CTS DSR
DCD RI?
I’m fairly certain that most serial chips can be set to generate an
interrupt on some or all of the lead changes, and thus there should be a way
to do this in library functions… (Wishful thinking???)
I was hoping to set up a proxy that would be activated when any of the leads
on the port change state.
You can look at the source to Dev.ser and see what it is
doing. I’m sure it interrupts on changes when it needs
to, that is if Hardware Flow control is turned on.
From there I can suggest two approaches.
-
Attach yourself to the interrupt and check
the state on each interrupt.
-
Create a custom IOCTL call to the driver.
Use it to pass the driver a proxy-id. Modify
the driver code so that when a change occurs
it will trigger your proxy.
Mitchell Schoenbrun --------- maschoen@pobox.com
These “leads” can be monitored thru IOCTL calls, you would have to poll,
looking for a change of state. I don’t know of anyway to avoid the polling.
I/we could send you some source if you’d like.
Karl
–
Karl A. Morant | TEL 519 836 1291 | karl@connecttech.com
Connect Tech Inc | FAX 519 836 4878 | http://www.connecttech.com
Connect Tech Inc. is a leading manufacturer of multi-port serial
adapters since 1985.
“Paul Russell” <paul@jenosys.com> wrote in message
news:sn6hj6hno5360@corp.supernews.com…
Is there a way to detect changes in the serial portr control leads CTS DSR
DCD RI?
I’m fairly certain that most serial chips can be set to generate an
interrupt on some or all of the lead changes, and thus there should be a
way
to do this in library functions… (Wishful thinking???)
I was hoping to set up a proxy that would be activated when any of the
leads
on the port change state.
Paul
paul@jenosys.com
Have a look to dev_arm. You will be able to receive a proxy or a signal on
hangup (DCD 1->0). AFAIK not possible in the othe way (0->1) and for other
leads.
–
Arnauld Disableu
arnauld@disableu.net
http://www.disableu.net
Compatible an 2000
“Paul Russell” <paul@jenosys.com> a écrit dans le message news:
sn6hj6hno5360@corp.supernews.com…
Is there a way to detect changes in the serial portr control leads CTS DSR
DCD RI?
I’m fairly certain that most serial chips can be set to generate an
interrupt on some or all of the lead changes, and thus there should be a
way
to do this in library functions… (Wishful thinking???)
I was hoping to set up a proxy that would be activated when any of the
leads
on the port change state.
Paul
paul@jenosys.com