资源描述:
《QNX_Getting Started with QNX Neutrino.pdf》由会员上传分享,免费在线阅读,更多相关内容在学术论文-天天文库。
1、QNXNeutrinoRTOSGettingStartedwithQNXNeutrino:AGuideforRealtimeProgrammersByRobKrten;updatedbyQNXSoftwareSystems©2012,QNXSoftwareSystemsLimited©1999,2001,20052012,QNXSoftwareSystemsLimited.Allrightsreserved.QNXSoftwareSystemsLimited1001FarrarRoadKanata,OntarioCanadaK2K0
2、B3Voice:+1613591-0931Fax:+1613591-3579Email:info@qnx.comWeb:http://www.qnx.com/Electroniceditionpublished2012.QNX,Momentics,Neutrino,Aviage,Photon,PhotonmicroGUI,andFoundry27aretrademarksofQNXSoftwareSystemsLimited,whichareregisteredtrademarksand/orusedincertainjurisdi
3、ctions.Allothertrademarksbelongtotheirrespectiveowners.ContentsAboutThisGuidexiWhatyoullfindinthisguidexiiiTypographicalconventionsxiiiNotetoWindowsusersxivTechnicalsupportxvForewordtotheFirstEditionbyPetervanderVeen1PrefacetotheFirstEditionbyRobKrten5Alittlehistory8Who
4、thisbookisfor8Whatsinthisbook?8ProcessesandThreads9MessagePassing9Clocks,Timers,andGettingaKickEverySoOften9Interrupts9ResourceManagers9QNX4toQNXNeutrino9Calling91110Glossary10Index10Otherreferences10AboutRobKrten10Acknowledgments101ProcessesandThreads13Processandthrea
5、dfundamentals15Aprocessasahouse15Theoccupantsasthreads15Backtoprocessesandthreads15Mutualexclusion16Priorities17Semaphores17Asemaphoreasamutex18Thekernelsrole19June14,2012Contentsiii©2012,QNXSoftwareSystemsLimitedSingleCPU19MultipleCPU(SMP)19Thekernelasarbiter19Kernels
6、tates24Threadsandprocesses26Whyprocesses?26Startingaprocess27Startingathread36Moreonsynchronization57Readers/writerlocks57Sleeponlocks59Conditionvariables63AdditionalNeutrinoservices68Poolsofthreads69Schedulingandtherealworld76Reschedulinghardwareinterrupts77Rescheduli
7、ngkernelcalls77Reschedulingexceptions77Summary782MessagePassing79Messagingfundamentals81Asmallmicrokernelandmessagepassing81Messagepassingandclient/server82Network-distributedmessagepassing85Whatitmeansforyou85ThephilosophyofNeutrino86Multiplethreads86Server/subserver8
8、7Someexamples89Usingmessagepassing90Architecture&structure91Theclient91Theserver93Thesend-hierarchy97ReceiveIDs,chann