Click here to Skip to main content
15,919,613 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Maximum ARRAY SIZE? Pin
Bob Stanneveld10-May-04 8:23
Bob Stanneveld10-May-04 8:23 
GeneralRe: Bob - Maximum ARRAY SIZE? Pin
zaferaslan10-May-04 20:15
zaferaslan10-May-04 20:15 
GeneralRe: Bob - Maximum ARRAY SIZE? Pin
Bob Stanneveld11-May-04 0:52
Bob Stanneveld11-May-04 0:52 
GeneralRe: Bob - Maximum ARRAY SIZE? Thanks Pin
zaferaslan11-May-04 4:59
zaferaslan11-May-04 4:59 
GeneralCCryptMD5Hash Pin
Ni@m9-May-04 23:56
Ni@m9-May-04 23:56 
GeneralRe: CCryptMD5Hash Pin
Garth J Lancaster10-May-04 0:13
professionalGarth J Lancaster10-May-04 0:13 
GeneralSerial Communication Timing Problem Pin
louis9-May-04 23:54
louis9-May-04 23:54 
GeneralRe: Serial Communication Timing Problem Pin
Andrew Walker10-May-04 1:37
Andrew Walker10-May-04 1:37 
Timers under windows and external hardware aren't things that play particularly nicely from my experience. Some fairly obvious suggestions are:

Make sure that you are using a high resolution timer QueryPerformanceCounter() rather than timeGetTime(). timeGetTime() only has a resolution of 10ms, but it can be even worse than that in some situations.

If you are sleeping in you polling thread, don't expect to wake up on time if you call Sleep(), delays can be out by huge ammount from a hardware perspective - 200ms for a sleep of 10ms is quite likely.

If you aren't sleeping, check to make sure that the CPU isn't being choked by your polling thread or another thread being a hog. It might not cause problems now, but it may down the track.

Solutions depend on the application - how time critical is time critical? Is it better to lose data and stay on time? Or do you always need to get every byte? One of the projects I'm working on at the moment is using MaRTE[^] a real time embedded operating system. In the past we have designed custom hardware to cache data to ensure that the PC always keeps up. It's a case of requirement specifications dictatating software design very tightly Smile | :)


If you can keep you head when all about you
Are losing theirs and blaming it on you;
If you can dream - and not make dreams your master;
If you can think - and not make thoughts you aim;
Yours is the Earth and everything that's in it.

Rudyard Kipling

GeneralRe: Serial Communication Timing Problem Pin
louis10-May-04 23:45
louis10-May-04 23:45 
GeneralAGP Detection Pin
anyata9-May-04 23:41
anyata9-May-04 23:41 
Generalmemory mapped files Pin
flabster9-May-04 22:33
flabster9-May-04 22:33 
GeneralRe: memory mapped files Pin
flabster10-May-04 17:59
flabster10-May-04 17:59 
General830221 - weird! Pin
ilostmyid29-May-04 21:37
professionalilostmyid29-May-04 21:37 
GeneralRe: 830221 - weird! Pin
V.10-May-04 2:40
professionalV.10-May-04 2:40 
GeneralPROGGRAMMING USING DIALOGUE BOXES INSTEAD OF DOCUMENT FORMS Pin
Wisdom20049-May-04 21:29
Wisdom20049-May-04 21:29 
GeneralRe: PROGGRAMMING USING DIALOGUE BOXES INSTEAD OF DOCUMENT FORMS Pin
David Crow10-May-04 2:52
David Crow10-May-04 2:52 
QuestionHow to compile the source code of ms windows 2000? Pin
fat8889-May-04 21:20
fat8889-May-04 21:20 
AnswerRe: How to compile the source code of ms windows 2000? Pin
Maxwell Chen9-May-04 21:22
Maxwell Chen9-May-04 21:22 
GeneralRe: How to compile the source code of ms windows 2000? Pin
Steve S9-May-04 21:39
Steve S9-May-04 21:39 
AnswerRe: How to compile the source code of ms windows 2000? Pin
nguyenvhn10-May-04 0:25
nguyenvhn10-May-04 0:25 
AnswerRe: How to compile the source code of ms windows 2000? Pin
toxcct10-May-04 0:43
toxcct10-May-04 0:43 
AnswerRe: How to compile the source code of ms windows 2000? Pin
Antony M Kancidrowski10-May-04 1:32
Antony M Kancidrowski10-May-04 1:32 
QuestionWhy is the window destroyed with an error? Pin
sinbaski9-May-04 21:17
sinbaski9-May-04 21:17 
AnswerRe: Why is the window destroyed with an error? Pin
nguyenvhn10-May-04 0:33
nguyenvhn10-May-04 0:33 
QuestionHow to find memory allocated to a linked lists Pin
jani_the_great9-May-04 20:46
jani_the_great9-May-04 20:46 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.