Sign in with
Sign up | Sign in
Your question

windows = realtime?

Last response: in Windows XP
Share
Anonymous
a b \ Driver
June 20, 2004 3:51:55 AM

Archived from groups: comp.os.ms-windows.programmer.nt.kernel-mode,microsoft.public.development.device.drivers,microsoft.public.win32.programmer.kernel,microsoft.public.windowsxp.device_driver.dev (More info?)

Hello,

I have posted similar topic some weeks ago and now I want to discuss it
further. I'm searching for operating system to meet real-time constraints. I
know that windows is not true real time system, but I have found some papers
complaining that Windows NT can be used as real time system. It complains
that total interrupt latency of NT is about 30 microseconds. That sounds
good for me. I found nothing about Win 2000 and XP interrupt latency. Maybe
someone knows? I think if I write my apps in Ring0 as kernel mode drivers,
then I will have latency as system interrupt latency. So why Windows cant be
used as real-time system? Maybe someone have good ideas or links about that.
I found it very interesting topic. I have searched through internet and
found lots of add-on for linux kernels, but they can guarantee about 30
microseconds latency. Developers complain that these add-ons is real time.
So why windows with 30 us latency can't be real time?
Thank you for any thoughts.

alpha

More about : windows realtime

Anonymous
a b \ Driver
June 20, 2004 3:51:56 AM

Archived from groups: comp.os.ms-windows.programmer.nt.kernel-mode,microsoft.public.development.device.drivers,microsoft.public.win32.programmer.kernel,microsoft.public.windowsxp.device_driver.dev (More info?)

"alpha" <alpha_byte@SAFe-mail.net> wrote in message
news:cb2913$rl4$1@news.wplus.net...
> Hello,
>
> I have posted similar topic some weeks ago and now I want to discuss it
> further. I'm searching for operating system to meet real-time constraints.
I
> know that windows is not true real time system, but I have found some
papers
> complaining that Windows NT can be used as real time system. It complains
> that total interrupt latency of NT is about 30 microseconds. That sounds
> good for me. I found nothing about Win 2000 and XP interrupt latency.
Maybe
> someone knows? I think if I write my apps in Ring0 as kernel mode drivers,
> then I will have latency as system interrupt latency. So why Windows cant
be
> used as real-time system? Maybe someone have good ideas or links about
that.
> I found it very interesting topic. I have searched through internet and
> found lots of add-on for linux kernels, but they can guarantee about 30
> microseconds latency. Developers complain that these add-ons is real time.
> So why windows with 30 us latency can't be real time?

I highly doubt that 30 us is the worst case latency for Windows. Even
if it is, Windows has no control over what additional latency might be
introduced by third party device drivers. I think the real worst case would
be measured in ms not us.

--
-GJC [MS Windows SDK MVP]
-Software Consultant (Embedded systems and Real Time Controls)
- http://www.mvps.org/ArcaneIncantations/consulting.htm
-gchanson@mvps.org
Anonymous
a b \ Driver
June 20, 2004 4:16:31 AM

Archived from groups: microsoft.public.development.device.drivers,microsoft.public.win32.programmer.kernel,microsoft.public.windowsxp.device_driver.dev (More info?)

Posted in too many newsgroups, except of one where it really belongs -
microsoft.public.windowsxp.embedded

Even if the HAL gives 30 mks interrupt latency, the real latency you'll see is DPC latency.
And it depends on too many details. Moreover, latency probably isn't the main criterium
to choose a RT platform. Can you tell more about your application?

--PA


"alpha" <alpha_byte@SAFe-mail.net> wrote in message news:cb2913$rl4$1@news.wplus.net...
> Hello,
>
> I have posted similar topic some weeks ago and now I want to discuss it
> further. I'm searching for operating system to meet real-time constraints. I
> know that windows is not true real time system, but I have found some papers
> complaining that Windows NT can be used as real time system. It complains
> that total interrupt latency of NT is about 30 microseconds. That sounds
> good for me. I found nothing about Win 2000 and XP interrupt latency. Maybe
> someone knows? I think if I write my apps in Ring0 as kernel mode drivers,
> then I will have latency as system interrupt latency. So why Windows cant be
> used as real-time system? Maybe someone have good ideas or links about that.
> I found it very interesting topic. I have searched through internet and
> found lots of add-on for linux kernels, but they can guarantee about 30
> microseconds latency. Developers complain that these add-ons is real time.
> So why windows with 30 us latency can't be real time?
> Thank you for any thoughts.
>
> alpha
>
>
Related resources
June 20, 2004 11:21:06 AM

Archived from groups: comp.os.ms-windows.programmer.nt.kernel-mode,microsoft.public.development.device.drivers,microsoft.public.win32.programmer.kernel,microsoft.public.windowsxp.device_driver.dev (More info?)

alpha wrote:

> Hello,

> I have posted similar topic some weeks ago and now I want to discuss it
> further. I'm searching for operating system to meet real-time constraints. I
> know that windows is not true real time system, but I have found some papers
> complaining that Windows NT can be used as real time system. It complains
> that total interrupt latency of NT is about 30 microseconds. That sounds
That's wrong for the Windows NT family shipped by Microsoft with the
possible exception of embedded versions ( which i do not know ) and
realtime extensions.
Basically you can not even be sure that any response time is
guaranteed(!) under windows nt/w2k/xp.
Where can we find the papers mentioned above?
> alpha
beta
Anonymous
a b \ Driver
June 20, 2004 4:29:39 PM

Archived from groups: comp.os.ms-windows.programmer.nt.kernel-mode,microsoft.public.development.device.drivers,microsoft.public.win32.programmer.kernel,microsoft.public.windowsxp.device_driver.dev (More info?)

Hello,

> Where can we find the papers mentioned above?

I found these:
http://www.theragens.com/misc/MR%20-%20Windows%20NT%20R...
http://www.omimo.be/magazine/98q3/index983.htm
http://msdn.microsoft.com/library/default.asp?url=/libr...

It is OT but similary linux and its real-time extensions can't guarantee
exact latency also? So we must use only real time systems like Qnx? I
thought it would be great to use windows as real time system.

alpha
Anonymous
a b \ Driver
June 20, 2004 4:29:40 PM

Archived from groups: comp.os.ms-windows.programmer.nt.kernel-mode,microsoft.public.development.device.drivers,microsoft.public.win32.programmer.kernel,microsoft.public.windowsxp.device_driver.dev (More info?)

In general, as this has been discussed ad nauseum, the consensus is that if
you have 'hard' real time constraints NT is the wrong OS. For example you
cannot strictly control interrupt priority, so even your 30us latency is
really 30us best case not 30us worst case. As others have mentioned, it
isn't even ISR latency that is the big problem, DPC latency is even harder
to quantify. If you can strictly control hardware and software deployment
you can use NT, either embedded or standard versions, as long as your
requirements are loose enough to fit within what NT can give you, but as
'what NT can give you' is not documented or guaranteed, you will have to
experimentally determine if it is suitable. Otherwise, for RT requirements
use an RTOS.


--

=====================
Mark Roddy
Windows 2003/XP/2000 Consulting
Hollis Technology Solutions 603-321-1032
www.hollistech.com
markr@hollistech.com


"alpha" <alpha_byte@SAFe-mail.net> wrote in message
news:cb3ldr$1srm$1@news.wplus.net...
> Hello,
>
> > Where can we find the papers mentioned above?
>
> I found these:
> http://www.theragens.com/misc/MR%20-%20Windows%20NT%20R...
> http://www.omimo.be/magazine/98q3/index983.htm
>
http://msdn.microsoft.com/library/default.asp?url=/libr...
>
> It is OT but similary linux and its real-time extensions can't guarantee
> exact latency also? So we must use only real time systems like Qnx? I
> thought it would be great to use windows as real time system.
>
> alpha
>
>
Anonymous
a b \ Driver
June 20, 2004 4:31:51 PM

Archived from groups: microsoft.public.development.device.drivers,microsoft.public.win32.programmer.kernel,microsoft.public.windowsxp.device_driver.dev (More info?)

Hello,

> Even if the HAL gives 30 mks interrupt latency, the real latency you'll
see is DPC latency.
> And it depends on too many details. Moreover, latency probably isn't the
main criterium
> to choose a RT platform. Can you tell more about your application?

Mostly high speed data acquisition and visualization on industrial
computers.

alpha
Anonymous
a b \ Driver
June 20, 2004 9:36:27 PM

Archived from groups: comp.os.ms-windows.programmer.nt.kernel-mode,microsoft.public.development.device.drivers,microsoft.public.win32.programmer.kernel,microsoft.public.windowsxp.device_driver.dev (More info?)

> complaining that Windows NT can be used as real time system. It complains
> that total interrupt latency of NT is about 30 microseconds.

IDE in PIO mode will easily introduce larger latency. So is serial port.

--
Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
maxim@storagecraft.com
http://www.storagecraft.com
Anonymous
a b \ Driver
June 21, 2004 8:19:26 AM

Archived from groups: comp.os.ms-windows.programmer.nt.kernel-mode,microsoft.public.development.device.drivers,microsoft.public.win32.programmer.kernel,microsoft.public.windowsxp.device_driver.dev (More info?)

If you are seeking a Real Time OS you might take a look at QNX
http://www.qnx.com

"alpha" <alpha_byte@SAFe-mail.net> wrote in message
news:cb2913$rl4$1@news.wplus.net...
> Hello,
>
> I have posted similar topic some weeks ago and now I want to discuss it
> further. I'm searching for operating system to meet real-time constraints.
I
> know that windows is not true real time system, but I have found some
papers
> complaining that Windows NT can be used as real time system. It complains
> that total interrupt latency of NT is about 30 microseconds. That sounds
> good for me. I found nothing about Win 2000 and XP interrupt latency.
Maybe
> someone knows? I think if I write my apps in Ring0 as kernel mode drivers,
> then I will have latency as system interrupt latency. So why Windows cant
be
> used as real-time system? Maybe someone have good ideas or links about
that.
> I found it very interesting topic. I have searched through internet and
> found lots of add-on for linux kernels, but they can guarantee about 30
> microseconds latency. Developers complain that these add-ons is real time.
> So why windows with 30 us latency can't be real time?
> Thank you for any thoughts.
>
> alpha
>
>
Anonymous
a b \ Driver
June 21, 2004 3:06:56 PM

Archived from groups: comp.os.ms-windows.programmer.nt.kernel-mode,microsoft.public.development.device.drivers,microsoft.public.win32.programmer.kernel,microsoft.public.windowsxp.device_driver.dev (More info?)

"alpha" <alpha_byte@SAFe-mail.net> wrote in message
news:cb3ldr$1srm$1@news.wplus.net...
> Hello,
>
> > Where can we find the papers mentioned above?
>
> I found these:
> http://www.theragens.com/misc/MR%20-%20Windows%20NT%20R...
> http://www.omimo.be/magazine/98q3/index983.htm
>
http://msdn.microsoft.com/library/default.asp?url=/libr...
>
> It is OT but similary linux and its real-time extensions can't guarantee
> exact latency also? So we must use only real time systems like Qnx? I
> thought it would be great to use windows as real time system.
>
> alpha
>
You might take a look at hyperkernel

http://www.nematron.com/Software/HyperKernel.shtml

or intime or iRMX, now at

http://www.tenasys.com/

I have seen others at the Embedded Systems Conference, but don't remember
their names at this time. Many are of the form, "We run Windows as a
task within our real-time os structure".

In my experience this means you can't guarantee response of your windows
code, but if you are controlling equipment, you can write real-time tasks
to do that. However, communication between realtime and non-realtime
tasks can be a bit of a pain...

And Microsoft themselves have embedded versions of Windows which
in some cases purport to have real-time capability.

http://msdn.microsoft.com/embedded/default.aspx


Rufus
Anonymous
a b \ Driver
June 21, 2004 9:55:25 PM

Archived from groups: comp.os.ms-windows.programmer.nt.kernel-mode,microsoft.public.development.device.drivers,microsoft.public.win32.programmer.kernel,microsoft.public.windowsxp.device_driver.dev (More info?)

"Rufus V. Smith" <nospam@nospam.com> wrote:
> I have seen others at the Embedded Systems Conference, but don't
remember
> their names at this time. Many are of the form, "We run Windows
as a
> task within our real-time os structure".
>
> In my experience this means you can't guarantee response of your
windows
> code, but if you are controlling equipment, you can write
real-time tasks
> to do that. However, communication between realtime and
non-realtime
> tasks can be a bit of a pain...

Take a look at CeWin/VxWin http://www.cewin.com from KUKA Controls.
They run VxWorks and Windows CE as realtime OS under Windows
2000/XP.
Communication can be done via:
- a virtual network
- shared memory
- Events (Can be used like Win32 Events)

So there is realy no pain...

Raphael
Anonymous
a b \ Driver
June 23, 2004 2:45:05 AM

Archived from groups: comp.os.ms-windows.programmer.nt.kernel-mode,microsoft.public.development.device.drivers,microsoft.public.win32.programmer.kernel,microsoft.public.windowsxp.device_driver.dev (More info?)

On 19 Jun 2004, "alpha" <alpha_byte@SAFe-mail.net> wrote:

> I have posted similar topic some weeks ago and now I want to
> discuss it further. I'm searching for operating system to meet
> real-time constraints. I know that windows is not true real time
> system, but I have found some papers complaining that Windows NT
> can be used as real time system. It complains that total interrupt
> latency of NT is about 30 microseconds. That sounds good for me. I
> found nothing about Win 2000 and XP interrupt latency. Maybe
> someone knows? I think if I write my apps in Ring0 as kernel mode
> drivers, then I will have latency as system interrupt latency. So
> why Windows cant be used as real-time system? Maybe someone have
> good ideas or links about that. I found it very interesting topic.
> I have searched through internet and found lots of add-on for
> linux kernels, but they can guarantee about 30 microseconds
> latency. Developers complain that these add-ons is real time. So
> why windows with 30 us latency can't be real time? Thank you for
> any thoughts.

As others have said, I don't think you'll find any guarantees from MS
about worst case interrupt latency or any guarantee about worst case
task scheduling delay. There are all sorts of things that can play
havoc with timing on any general purpose OS such as NT. But for what
it's worth, I was recently involved in a project that used a product
called RTX from VentureCom (http://www.vci.com/) which provides a
hard real-time subsystem for NT. If you need this capability, you
might want to check it out. It's not free :-(

Note: I am not connected in any way with VentureCom and I'm not
recommending (and I'm not *not* recommending) their product. I just
thought you might be interested.

Dave

--
D.a.v.i.d T.i.k.t.i.n
t.i.k.t.i.n [at] a.d.v.a.n.c.e.d.r.e.l.a.y [dot] c.o.m
Anonymous
a b \ Driver
July 9, 2004 5:48:17 AM

Archived from groups: comp.os.ms-windows.programmer.nt.kernel-mode,microsoft.public.development.device.drivers,microsoft.public.win32.programmer.kernel,microsoft.public.windowsxp.device_driver.dev (More info?)

I'm experiencing interrupts latencies of 20 milliseconds on
some machines. More often than not you should be able to go
sub-millisecond, but there are no guarantees on this OS.
Some vendors just get their device drivers working and don't
worry about the huge latency problems.

alpha wrote:

> Hello,
>
> I have posted similar topic some weeks ago and now I want to discuss it
> further. I'm searching for operating system to meet real-time constraints. I
> know that windows is not true real time system, but I have found some papers
> complaining that Windows NT can be used as real time system. It complains
> that total interrupt latency of NT is about 30 microseconds. That sounds
> good for me. I found nothing about Win 2000 and XP interrupt latency. Maybe
> someone knows? I think if I write my apps in Ring0 as kernel mode drivers,
> then I will have latency as system interrupt latency. So why Windows cant be
> used as real-time system? Maybe someone have good ideas or links about that.
> I found it very interesting topic. I have searched through internet and
> found lots of add-on for linux kernels, but they can guarantee about 30
> microseconds latency. Developers complain that these add-ons is real time.
> So why windows with 30 us latency can't be real time?
> Thank you for any thoughts.
>
> alpha
>
>
Anonymous
a b \ Driver
July 9, 2004 5:48:18 AM

Archived from groups: comp.os.ms-windows.programmer.nt.kernel-mode,microsoft.public.development.device.drivers,microsoft.public.win32.programmer.kernel,microsoft.public.windowsxp.device_driver.dev (More info?)

If your thread has "normal" priority, it's normal latency, because it may
have to wait until another thread's time slice expires. To reduce it, you
have to use higher priority threads.

"Pat B" <spam@ftc.gov> wrote in message
news:BPmHc.10071$oD3.2492@newsread1.news.pas.earthlink.net...
> I'm experiencing interrupts latencies of 20 milliseconds on
> some machines. More often than not you should be able to go
> sub-millisecond, but there are no guarantees on this OS.
> Some vendors just get their device drivers working and don't
> worry about the huge latency problems.
>
> alpha wrote:
>
> > Hello,
> >
> > I have posted similar topic some weeks ago and now I want to discuss it
> > further. I'm searching for operating system to meet real-time
constraints. I
> > know that windows is not true real time system, but I have found some
papers
> > complaining that Windows NT can be used as real time system. It
complains
> > that total interrupt latency of NT is about 30 microseconds. That sounds
> > good for me. I found nothing about Win 2000 and XP interrupt latency.
Maybe
> > someone knows? I think if I write my apps in Ring0 as kernel mode
drivers,
> > then I will have latency as system interrupt latency. So why Windows
cant be
> > used as real-time system? Maybe someone have good ideas or links about
that.
> > I found it very interesting topic. I have searched through internet and
> > found lots of add-on for linux kernels, but they can guarantee about 30
> > microseconds latency. Developers complain that these add-ons is real
time.
> > So why windows with 30 us latency can't be real time?
> > Thank you for any thoughts.
> >
> > alpha
> >
> >
Anonymous
a b \ Driver
July 9, 2004 8:36:11 AM

Archived from groups: comp.os.ms-windows.programmer.nt.kernel-mode,microsoft.public.development.device.drivers,microsoft.public.win32.programmer.kernel,microsoft.public.windowsxp.device_driver.dev (More info?)

Nope, these are _interrupt_ latencies. To my device drivers
ISR(). Something else in the system held off interrupts to
my PCI device for 20-24 millseconds about four times a day.

Alexander Grigoriev wrote:

> If your thread has "normal" priority, it's normal latency, because it may
> have to wait until another thread's time slice expires. To reduce it, you
> have to use higher priority threads.
>
> "Pat B" <spam@ftc.gov> wrote in message
> news:BPmHc.10071$oD3.2492@newsread1.news.pas.earthlink.net...
>
>>I'm experiencing interrupts latencies of 20 milliseconds on
>>some machines. More often than not you should be able to go
>>sub-millisecond, but there are no guarantees on this OS.
>>Some vendors just get their device drivers working and don't
>>worry about the huge latency problems.
>>
>>alpha wrote:
>>
>>
>>>Hello,
>>>
>>>I have posted similar topic some weeks ago and now I want to discuss it
>>>further. I'm searching for operating system to meet real-time
>
> constraints. I
>
>>>know that windows is not true real time system, but I have found some
>
> papers
>
>>>complaining that Windows NT can be used as real time system. It
>
> complains
>
>>>that total interrupt latency of NT is about 30 microseconds. That sounds
>>>good for me. I found nothing about Win 2000 and XP interrupt latency.
>
> Maybe
>
>>>someone knows? I think if I write my apps in Ring0 as kernel mode
>
> drivers,
>
>>>then I will have latency as system interrupt latency. So why Windows
>
> cant be
>
>>>used as real-time system? Maybe someone have good ideas or links about
>
> that.
>
>>>I found it very interesting topic. I have searched through internet and
>>>found lots of add-on for linux kernels, but they can guarantee about 30
>>>microseconds latency. Developers complain that these add-ons is real
>
> time.
>
>>>So why windows with 30 us latency can't be real time?
>>>Thank you for any thoughts.
>>>
>>>alpha
>>>
>>>
>
>
>
Anonymous
a b \ Driver
July 9, 2004 12:06:35 PM

Archived from groups: comp.os.ms-windows.programmer.nt.kernel-mode,microsoft.public.development.device.drivers,microsoft.public.win32.programmer.kernel,microsoft.public.windowsxp.device_driver.dev (More info?)

The physical interrupts are prioritized. If you get two or more
interrupts at the same time, one will be handled first.

Pat B wrote:

> Nope, these are _interrupt_ latencies. To my device drivers ISR().
> Something else in the system held off interrupts to my PCI device for
> 20-24 millseconds about four times a day.
>
> Alexander Grigoriev wrote:
>
>> If your thread has "normal" priority, it's normal latency, because it may
>> have to wait until another thread's time slice expires. To reduce it, you
>> have to use higher priority threads.
>>
>> "Pat B" <spam@ftc.gov> wrote in message
>> news:BPmHc.10071$oD3.2492@newsread1.news.pas.earthlink.net...
>>
>>> I'm experiencing interrupts latencies of 20 milliseconds on
>>> some machines. More often than not you should be able to go
>>> sub-millisecond, but there are no guarantees on this OS.
>>> Some vendors just get their device drivers working and don't
>>> worry about the huge latency problems.
>>>
>>> alpha wrote:
>>>
>>>
>>>> Hello,
>>>>
>>>> I have posted similar topic some weeks ago and now I want to discuss it
>>>> further. I'm searching for operating system to meet real-time
>>
>>
>> constraints. I
>>
>>>> know that windows is not true real time system, but I have found some
>>
>>
>> papers
>>
>>>> complaining that Windows NT can be used as real time system. It
>>
>>
>> complains
>>
>>>> that total interrupt latency of NT is about 30 microseconds. That
>>>> sounds
>>>> good for me. I found nothing about Win 2000 and XP interrupt latency.
>>
>>
>> Maybe
>>
>>>> someone knows? I think if I write my apps in Ring0 as kernel mode
>>
>>
>> drivers,
>>
>>>> then I will have latency as system interrupt latency. So why Windows
>>
>>
>> cant be
>>
>>>> used as real-time system? Maybe someone have good ideas or links about
>>
>>
>> that.
>>
>>>> I found it very interesting topic. I have searched through internet and
>>>> found lots of add-on for linux kernels, but they can guarantee about 30
>>>> microseconds latency. Developers complain that these add-ons is real
>>
>>
>> time.
>>
>>>> So why windows with 30 us latency can't be real time?
>>>> Thank you for any thoughts.
>>>>
>>>> alpha
>>>>
>>>>
>>
>>
>>
Anonymous
a b \ Driver
July 10, 2004 9:08:26 AM

Archived from groups: comp.os.ms-windows.programmer.nt.kernel-mode,microsoft.public.development.device.drivers,microsoft.public.win32.programmer.kernel,microsoft.public.windowsxp.device_driver.dev (More info?)

but 20 milliseconds! that's insanely bad.

Mike Powers wrote:
> The physical interrupts are prioritized. If you get two or more
> interrupts at the same time, one will be handled first.
>
> Pat B wrote:
>
>> Nope, these are _interrupt_ latencies. To my device drivers ISR().
>> Something else in the system held off interrupts to my PCI device for
>> 20-24 millseconds about four times a day.
>>
>>>> I'm experiencing interrupts latencies of 20 milliseconds on
>>>> some machines. More often than not you should be able to go
>>>> sub-millisecond, but there are no guarantees on this OS.
>>>> Some vendors just get their device drivers working and don't
>>>> worry about the huge latency problems.
>>>>
July 10, 2004 6:25:05 PM

Archived from groups: comp.os.ms-windows.programmer.nt.kernel-mode,microsoft.public.development.device.drivers,microsoft.public.win32.programmer.kernel,microsoft.public.windowsxp.device_driver.dev (More info?)

On Sat, 10 Jul 2004 05:08:26 GMT, Pat B <spam@ftc.gov> wrote:

>Mike Powers wrote:
>>
>> Pat B wrote:
>>
>>>>> I'm experiencing interrupts latencies of 20 milliseconds on
>>>>> some machines. More often than not you should be able to go
>>>>> sub-millisecond, but there are no guarantees on this OS.
>>>>> Some vendors just get their device drivers working and don't
>>>>> worry about the huge latency problems.
>>>>>
>>> Nope, these are _interrupt_ latencies. To my device drivers ISR().
>>> Something else in the system held off interrupts to my PCI device for
>>> 20-24 millseconds about four times a day.
>>>
>> The physical interrupts are prioritized. If you get two or more
>> interrupts at the same time, one will be handled first.
>
>but 20 milliseconds! that's insanely bad.

Yes. Only 4 times a day, though: some 'rogue' driver is jamming things
for far too long. Is there any pattern to it, like a burst of disk
activity which happens every 6 hours (updating some index, perhaps)?


James.
!