SlideShare ist ein Scribd-Unternehmen logo
1 von 28
Downloaden Sie, um offline zu lesen
Development with Qt
for Windows CE
                      10/11/09
Agenda

• Introduction to Windows CE

• How to build Qt for Windows CE
• Windows CE 5 memory model
• Ways to more memory
• Demonstration
What is Windows CE?

• OS for embedded devices
• not derived from desktop Windows
• monolithic kernel
• highly configurable using Platform Builder
• runs on x86, ARM, SH4 and MIPS




                                               3
The world of Windows CE

• Windows CE 5.2
  – Windows mobile 5, 6, 6.1, 6.5
     • SmartPhone (standard)
     • PocketPC (classic / professional)
• Windows CE 6.0 R2
  – Microsoft Auto
  – Windows mobile 7?




                                           4
Desktop Windows vs. Windows CE

• UTF16 string representation
•   No NTFS support → no file security model
•   No file drives
•   No current directory
•   Only 32 processes
•   Only 32 MB memory per process (CE < 6)




                                               5
Desktop Windows vs. Windows CE

• Number of threads limited to system resources
  – no more free memory → no more threads
• API is a Win32 API subset
  – no *A functions
  – no asynchronous file I/O or network
  – incomplete standard C libs




                                                  6
Desktop Windows vs. Windows CE

• Situation gets better with Windows CE 6
  – Up to 1 GB process memory
  – More than 32K processes
  – Improved system call performance
  – New product name:
     Windows embedded CE




                                            7
What do you need for development?

• Visual Studio 2005 Standard or
  Visual Studio 2008 Professional
• Windows CE SDK for your device
• Qt for Windows CE from qt.nokia.com
• Perl for using out-of-source builds
• Qt Visual Studio Add-in from qt.nokia.com




                                              8
Development work flow

• Prototype on Desktop Windows
• Switch to a Windows CE Qt build
• Build, deploy and run


  – Not everybody in the team needs a
    Windows CE development environment.




                                          9
How to build Qt for Windows CE?

• Use shadow builds.

 C:Qt4.6.0qtsource
               win32
               wincewm60professional
               wince50standard-x86




                                        10
How to build Qt for Windows CE?
Open a Visual Studio command prompt.
Add C:Qt4.6.0wincewm60professionalbin to PATH.

cd C:Qt4.6.0wincewm60professional
.qtsourcesconfigure
          -xplatform wincewm60professional-msvc2008
          -signature mysignature.pfx


Creates Qt configuration and builds the host tools:
• qmake, moc, uic, rcc
• setcepaths / checksdk
• cetest (if Remote API is in INCLUDE, LIBS)



                                                      11
How to build Qt for Windows CE?

...only two steps left...


setcepaths wincewm60professional-msvc2008


nmake




                                            12
Qt DLL sizes
Library sizes of Qt 4.5.2 on Windows mobile 6 professional:
      Qt library            Size in MB

      QtCore4.dll            1.67 MB
      QtGui4.dll             5.67 MB
      QtNetwork4.dll         0.53 MB
      QtWebKit4.dll          6.86 MB
      qjpeg4.dll             0.12 MB
      sum                   14.85 MB



                                                              13
The Windows CE 5.0 memory model
Slot 63 Resource only DLLs        • only 32 MB per slot
                                  • Application stack & heap grow
       large memory area
                                   from slot's bottom
Slot 32            Process 32
                                  • DLLs are loaded into process
                                   slots top-down
 ...                              • DLLs are guaranteed to have
Slot 3
                                   the same address in every slot
                   Process 2
Slot 2             Process 1
Slot 1           bundled DLLs
Slot 0          current process




                                                                14
The Windows CE 5.0 memory model



Bundled DLLs



Load address
for new DLLs




                                   15
The Windows CE 5.0 memory model




                              Qt
                              DLLs




                              Stack &
                              heap



                                        16
Ways to more Virtual Memory

•   Reduce the DLL size
•   Use static linking
•   Load small DLLs first
•   Switch to Windows mobile 6.1




                                   17
Reducing Qt DLL sizes

• Exclude the features you don't need
• “feature” = set of classes (e.g.
  GraphicsView)
• define QT_NO_FEATURENAME
  configure -D QT_NO_FEATURENAME
• add this define to your application .pro file
  DEFINES += QT_NO_FEATURENAME
• Tedious stuff! Is there no easier way to do
  this?

                                                  18
Reducing Qt DLL sizes using qconfig
Reducing Qt DLL sizes using qconfig

In your desktop Windows Qt build directory:
md toolsqconfig
cd toolsqconfig
qmake ......toolsqconfigqconfig.pro
nmake release
releaseqconfig.exe




                                              20
Reducing Qt DLL sizes using qconfig

Good candiates for exclusion:
• Standard dialogs (color, font, input, wizard, …)
• Convenience widgets (QCalendarWidget, ...)
• Clipboard, drag and drop, shortcuts
• QtConcurrent, FTP, QSystemTrayIcon
• GraphicsView for QWidget only applications
• MDI


                                                     21
Reducing Qt DLL sizes using qconfig

• Open the features description file in
srccorelibglobalqfeatures.txt

• Unselect unwanted features
• Save the result in
srccorelibglobalqconfig-myfeatures.h

• Reconfigure Qt
configure -qconfig myfeatures ...



                                          22
Reducing Qt DLL sizes

                           2.43
 minimal
                   1.42


                                      4.18
                                                    QtCore
   small
                    1.67                            QtGui



                                             5.67
standard
                    1.67

           0   1    2       3     4     5    6




                                                             23
Accessing the Large Memory Area

•   just 32 MB? Are you serious?
•   there's more behind slot 32
•   use memory mapped files
•   use the VirtualAlloc API




                                   24
Accessing the Large Memory Area

Using memory mapped files:
• acquire memory at 64 K boundaries
   QFile memfile("myfile.bin");
   memfile.open(QIODevice::ReadWrite);
   memfile.resize(1024*1024*2);
   uchar* buf = memfile.map(0, 1024*1024*2);
   ...
   memfile.unmap(buf);
   memfile.remove();




                                               25
Accessing the Large Memory Area

Using VirtualAlloc:
• Reserve memory at 64 K boundaries or
  commit reserved memory at 4 K
  boundaries
void* ptrBase = VirtualAlloc(0, dwSize,
                         MEM_RESERVE, PAGE_NOACCESS);
buffer = VirtualAlloc(ptrBase, dwSize,
                         MEM_COMMIT, PAGE_READWRITE);
...
VirtualFree(ptr, dwSize, MEM_DECOMMIT);
VirtualFree(ptr, 0, MEM_RELEASE);


                                                        26
Demonstration
Questions and Answers

Weitere ähnliche Inhalte

Was ist angesagt?

Introduction to Qt Creator
Introduction to Qt CreatorIntroduction to Qt Creator
Introduction to Qt CreatorQt
 
Qt 6.2 lts vs. qt 5.15 the big feature parity comparison
Qt 6.2 lts vs. qt 5.15 the big feature parity comparisonQt 6.2 lts vs. qt 5.15 the big feature parity comparison
Qt 6.2 lts vs. qt 5.15 the big feature parity comparisonQt
 
Contributions to an open source project: Igalia and the Chromium project
Contributions to an open source project: Igalia and the Chromium projectContributions to an open source project: Igalia and the Chromium project
Contributions to an open source project: Igalia and the Chromium projectIgalia
 
Migrating from Photon to Qt
Migrating from Photon to QtMigrating from Photon to Qt
Migrating from Photon to QtJanel Heilbrunn
 
Network-Connected Development with ZeroMQ
Network-Connected Development with ZeroMQNetwork-Connected Development with ZeroMQ
Network-Connected Development with ZeroMQICS
 
Creating Slick User Interfaces With Qt
Creating Slick User Interfaces With QtCreating Slick User Interfaces With Qt
Creating Slick User Interfaces With QtEspen Riskedal
 
Qt for beginners part 5 ask the experts
Qt for beginners part 5   ask the expertsQt for beginners part 5   ask the experts
Qt for beginners part 5 ask the expertsICS
 
Knowit study group örnsköldsvik - introduction to qt & qt creator
Knowit   study group örnsköldsvik - introduction to qt & qt creatorKnowit   study group örnsköldsvik - introduction to qt & qt creator
Knowit study group örnsköldsvik - introduction to qt & qt creatorMathias Westin
 
Qt for beginners part 1 overview and key concepts
Qt for beginners part 1   overview and key conceptsQt for beginners part 1   overview and key concepts
Qt for beginners part 1 overview and key conceptsICS
 
Creating Advanced GUIs for Low-power MCUs with Qt
Creating Advanced GUIs for Low-power MCUs with QtCreating Advanced GUIs for Low-power MCUs with Qt
Creating Advanced GUIs for Low-power MCUs with QtICS
 
So I Downloaded Qt, Now What?
So I Downloaded Qt, Now What?So I Downloaded Qt, Now What?
So I Downloaded Qt, Now What?Janel Heilbrunn
 
[Webinar] QtSerialBus: Using Modbus and CAN bus with Qt
[Webinar] QtSerialBus: Using Modbus and CAN bus with Qt[Webinar] QtSerialBus: Using Modbus and CAN bus with Qt
[Webinar] QtSerialBus: Using Modbus and CAN bus with QtICS
 
Convert Your Legacy OpenGL Code to Modern OpenGL with Qt
Convert Your Legacy OpenGL Code to Modern OpenGL with QtConvert Your Legacy OpenGL Code to Modern OpenGL with Qt
Convert Your Legacy OpenGL Code to Modern OpenGL with QtICS
 
Meet Qt 6.0
Meet Qt 6.0 Meet Qt 6.0
Meet Qt 6.0 Qt
 
How to Make Your Qt App Look Native
How to Make Your Qt App Look NativeHow to Make Your Qt App Look Native
How to Make Your Qt App Look Nativeaccount inactive
 
Qt App Development - Cross-Platform Development for Android, iOS, Windows Pho...
Qt App Development - Cross-Platform Development for Android, iOS, Windows Pho...Qt App Development - Cross-Platform Development for Android, iOS, Windows Pho...
Qt App Development - Cross-Platform Development for Android, iOS, Windows Pho...Andreas Jakl
 
Chromium on Wayland Desktop (BlinkOn 7)
Chromium on Wayland Desktop (BlinkOn 7)Chromium on Wayland Desktop (BlinkOn 7)
Chromium on Wayland Desktop (BlinkOn 7)Igalia
 

Was ist angesagt? (20)

了解 Qt
了解 Qt了解 Qt
了解 Qt
 
Introduction to Qt Creator
Introduction to Qt CreatorIntroduction to Qt Creator
Introduction to Qt Creator
 
Qt 6.2 lts vs. qt 5.15 the big feature parity comparison
Qt 6.2 lts vs. qt 5.15 the big feature parity comparisonQt 6.2 lts vs. qt 5.15 the big feature parity comparison
Qt 6.2 lts vs. qt 5.15 the big feature parity comparison
 
Contributions to an open source project: Igalia and the Chromium project
Contributions to an open source project: Igalia and the Chromium projectContributions to an open source project: Igalia and the Chromium project
Contributions to an open source project: Igalia and the Chromium project
 
Migrating from Photon to Qt
Migrating from Photon to QtMigrating from Photon to Qt
Migrating from Photon to Qt
 
Network-Connected Development with ZeroMQ
Network-Connected Development with ZeroMQNetwork-Connected Development with ZeroMQ
Network-Connected Development with ZeroMQ
 
Creating Slick User Interfaces With Qt
Creating Slick User Interfaces With QtCreating Slick User Interfaces With Qt
Creating Slick User Interfaces With Qt
 
Qt for beginners part 5 ask the experts
Qt for beginners part 5   ask the expertsQt for beginners part 5   ask the experts
Qt for beginners part 5 ask the experts
 
Meet Qt
Meet QtMeet Qt
Meet Qt
 
Qt 5 - C++ and Widgets
Qt 5 - C++ and WidgetsQt 5 - C++ and Widgets
Qt 5 - C++ and Widgets
 
Knowit study group örnsköldsvik - introduction to qt & qt creator
Knowit   study group örnsköldsvik - introduction to qt & qt creatorKnowit   study group örnsköldsvik - introduction to qt & qt creator
Knowit study group örnsköldsvik - introduction to qt & qt creator
 
Qt for beginners part 1 overview and key concepts
Qt for beginners part 1   overview and key conceptsQt for beginners part 1   overview and key concepts
Qt for beginners part 1 overview and key concepts
 
Creating Advanced GUIs for Low-power MCUs with Qt
Creating Advanced GUIs for Low-power MCUs with QtCreating Advanced GUIs for Low-power MCUs with Qt
Creating Advanced GUIs for Low-power MCUs with Qt
 
So I Downloaded Qt, Now What?
So I Downloaded Qt, Now What?So I Downloaded Qt, Now What?
So I Downloaded Qt, Now What?
 
[Webinar] QtSerialBus: Using Modbus and CAN bus with Qt
[Webinar] QtSerialBus: Using Modbus and CAN bus with Qt[Webinar] QtSerialBus: Using Modbus and CAN bus with Qt
[Webinar] QtSerialBus: Using Modbus and CAN bus with Qt
 
Convert Your Legacy OpenGL Code to Modern OpenGL with Qt
Convert Your Legacy OpenGL Code to Modern OpenGL with QtConvert Your Legacy OpenGL Code to Modern OpenGL with Qt
Convert Your Legacy OpenGL Code to Modern OpenGL with Qt
 
Meet Qt 6.0
Meet Qt 6.0 Meet Qt 6.0
Meet Qt 6.0
 
How to Make Your Qt App Look Native
How to Make Your Qt App Look NativeHow to Make Your Qt App Look Native
How to Make Your Qt App Look Native
 
Qt App Development - Cross-Platform Development for Android, iOS, Windows Pho...
Qt App Development - Cross-Platform Development for Android, iOS, Windows Pho...Qt App Development - Cross-Platform Development for Android, iOS, Windows Pho...
Qt App Development - Cross-Platform Development for Android, iOS, Windows Pho...
 
Chromium on Wayland Desktop (BlinkOn 7)
Chromium on Wayland Desktop (BlinkOn 7)Chromium on Wayland Desktop (BlinkOn 7)
Chromium on Wayland Desktop (BlinkOn 7)
 

Ähnlich wie Development with Qt for Windows CE

LXC, Docker, and the future of software delivery | LinuxCon 2013
LXC, Docker, and the future of software delivery | LinuxCon 2013LXC, Docker, and the future of software delivery | LinuxCon 2013
LXC, Docker, and the future of software delivery | LinuxCon 2013dotCloud
 
LXC Docker and the Future of Software Delivery
LXC Docker and the Future of Software DeliveryLXC Docker and the Future of Software Delivery
LXC Docker and the Future of Software DeliveryDocker, Inc.
 
321 codeincontainer brewbox
321 codeincontainer brewbox321 codeincontainer brewbox
321 codeincontainer brewboxLino Telera
 
JS Fest 2019. Алексей Бороденко. Windows Containers. Why should I care?
JS Fest 2019. Алексей Бороденко. Windows Containers. Why should I care?JS Fest 2019. Алексей Бороденко. Windows Containers. Why should I care?
JS Fest 2019. Алексей Бороденко. Windows Containers. Why should I care?DevOps_Fest
 
Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...
Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...
Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...Odinot Stanislas
 
stackconf 2020 | Replace your Docker based Containers with Cri-o Kata Contain...
stackconf 2020 | Replace your Docker based Containers with Cri-o Kata Contain...stackconf 2020 | Replace your Docker based Containers with Cri-o Kata Contain...
stackconf 2020 | Replace your Docker based Containers with Cri-o Kata Contain...NETWAYS
 
Ch 6: The Wild World of Windows
Ch 6: The Wild World of WindowsCh 6: The Wild World of Windows
Ch 6: The Wild World of WindowsSam Bowne
 
Unikernel User Summit 2015: Getting started in unikernels using the rump kernel
Unikernel User Summit 2015: Getting started in unikernels using the rump kernelUnikernel User Summit 2015: Getting started in unikernels using the rump kernel
Unikernel User Summit 2015: Getting started in unikernels using the rump kernelThe Linux Foundation
 
Radu vunvulea building and testing windows 8 metro style applications using ...
Radu vunvulea  building and testing windows 8 metro style applications using ...Radu vunvulea  building and testing windows 8 metro style applications using ...
Radu vunvulea building and testing windows 8 metro style applications using ...Radu Vunvulea
 
The end of embedded Linux (as we know it)
The end of embedded Linux (as we know it)The end of embedded Linux (as we know it)
The end of embedded Linux (as we know it)Chris Simmonds
 
CNIT 126: 10: Kernel Debugging with WinDbg
CNIT 126: 10: Kernel Debugging with WinDbgCNIT 126: 10: Kernel Debugging with WinDbg
CNIT 126: 10: Kernel Debugging with WinDbgSam Bowne
 
RSA SF Conference talk-2009-ht2-401 sallam
RSA SF Conference talk-2009-ht2-401 sallamRSA SF Conference talk-2009-ht2-401 sallam
RSA SF Conference talk-2009-ht2-401 sallamAhmed Sallam
 
Real-World Docker: 10 Things We've Learned
Real-World Docker: 10 Things We've Learned  Real-World Docker: 10 Things We've Learned
Real-World Docker: 10 Things We've Learned RightScale
 
Running Applications on the NetBSD Rump Kernel by Justin Cormack
Running Applications on the NetBSD Rump Kernel by Justin Cormack Running Applications on the NetBSD Rump Kernel by Justin Cormack
Running Applications on the NetBSD Rump Kernel by Justin Cormack eurobsdcon
 
Surviving a Plane Crash, a NU.nl case-study
Surviving a Plane Crash, a NU.nl case-studySurviving a Plane Crash, a NU.nl case-study
Surviving a Plane Crash, a NU.nl case-studypeter_ibuildings
 
CNIT 127 Ch 6: The Wild World of Windows
CNIT 127 Ch 6: The Wild World of WindowsCNIT 127 Ch 6: The Wild World of Windows
CNIT 127 Ch 6: The Wild World of WindowsSam Bowne
 

Ähnlich wie Development with Qt for Windows CE (20)

Php on Windows
Php on WindowsPhp on Windows
Php on Windows
 
LXC, Docker, and the future of software delivery | LinuxCon 2013
LXC, Docker, and the future of software delivery | LinuxCon 2013LXC, Docker, and the future of software delivery | LinuxCon 2013
LXC, Docker, and the future of software delivery | LinuxCon 2013
 
LXC Docker and the Future of Software Delivery
LXC Docker and the Future of Software DeliveryLXC Docker and the Future of Software Delivery
LXC Docker and the Future of Software Delivery
 
321 codeincontainer brewbox
321 codeincontainer brewbox321 codeincontainer brewbox
321 codeincontainer brewbox
 
JS Fest 2019. Алексей Бороденко. Windows Containers. Why should I care?
JS Fest 2019. Алексей Бороденко. Windows Containers. Why should I care?JS Fest 2019. Алексей Бороденко. Windows Containers. Why should I care?
JS Fest 2019. Алексей Бороденко. Windows Containers. Why should I care?
 
Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...
Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...
Bare-metal, Docker Containers, and Virtualization: The Growing Choices for Cl...
 
stackconf 2020 | Replace your Docker based Containers with Cri-o Kata Contain...
stackconf 2020 | Replace your Docker based Containers with Cri-o Kata Contain...stackconf 2020 | Replace your Docker based Containers with Cri-o Kata Contain...
stackconf 2020 | Replace your Docker based Containers with Cri-o Kata Contain...
 
Ch 6: The Wild World of Windows
Ch 6: The Wild World of WindowsCh 6: The Wild World of Windows
Ch 6: The Wild World of Windows
 
Unikernel User Summit 2015: Getting started in unikernels using the rump kernel
Unikernel User Summit 2015: Getting started in unikernels using the rump kernelUnikernel User Summit 2015: Getting started in unikernels using the rump kernel
Unikernel User Summit 2015: Getting started in unikernels using the rump kernel
 
Radu vunvulea building and testing windows 8 metro style applications using ...
Radu vunvulea  building and testing windows 8 metro style applications using ...Radu vunvulea  building and testing windows 8 metro style applications using ...
Radu vunvulea building and testing windows 8 metro style applications using ...
 
The end of embedded Linux (as we know it)
The end of embedded Linux (as we know it)The end of embedded Linux (as we know it)
The end of embedded Linux (as we know it)
 
Presentation1.pptx
Presentation1.pptxPresentation1.pptx
Presentation1.pptx
 
Docker
DockerDocker
Docker
 
CNIT 126: 10: Kernel Debugging with WinDbg
CNIT 126: 10: Kernel Debugging with WinDbgCNIT 126: 10: Kernel Debugging with WinDbg
CNIT 126: 10: Kernel Debugging with WinDbg
 
RSA SF Conference talk-2009-ht2-401 sallam
RSA SF Conference talk-2009-ht2-401 sallamRSA SF Conference talk-2009-ht2-401 sallam
RSA SF Conference talk-2009-ht2-401 sallam
 
Real-World Docker: 10 Things We've Learned
Real-World Docker: 10 Things We've Learned  Real-World Docker: 10 Things We've Learned
Real-World Docker: 10 Things We've Learned
 
Running Applications on the NetBSD Rump Kernel by Justin Cormack
Running Applications on the NetBSD Rump Kernel by Justin Cormack Running Applications on the NetBSD Rump Kernel by Justin Cormack
Running Applications on the NetBSD Rump Kernel by Justin Cormack
 
Server 2016 sneak peek
Server 2016 sneak peekServer 2016 sneak peek
Server 2016 sneak peek
 
Surviving a Plane Crash, a NU.nl case-study
Surviving a Plane Crash, a NU.nl case-studySurviving a Plane Crash, a NU.nl case-study
Surviving a Plane Crash, a NU.nl case-study
 
CNIT 127 Ch 6: The Wild World of Windows
CNIT 127 Ch 6: The Wild World of WindowsCNIT 127 Ch 6: The Wild World of Windows
CNIT 127 Ch 6: The Wild World of Windows
 

Mehr von account inactive

KDE Plasma for Mobile Phones
KDE Plasma for Mobile PhonesKDE Plasma for Mobile Phones
KDE Plasma for Mobile Phonesaccount inactive
 
Shipping Mobile Applications Using Qt for Symbian
Shipping Mobile Applications Using Qt for SymbianShipping Mobile Applications Using Qt for Symbian
Shipping Mobile Applications Using Qt for Symbianaccount inactive
 
Scripting Your Qt Application
Scripting Your Qt ApplicationScripting Your Qt Application
Scripting Your Qt Applicationaccount inactive
 
Special Effects with Qt Graphics View
Special Effects with Qt Graphics ViewSpecial Effects with Qt Graphics View
Special Effects with Qt Graphics Viewaccount inactive
 
Developments in The Qt WebKit Integration
Developments in The Qt WebKit IntegrationDevelopments in The Qt WebKit Integration
Developments in The Qt WebKit Integrationaccount inactive
 
Qt on Real Time Operating Systems
Qt on Real Time Operating SystemsQt on Real Time Operating Systems
Qt on Real Time Operating Systemsaccount inactive
 
Translating Qt Applications
Translating Qt ApplicationsTranslating Qt Applications
Translating Qt Applicationsaccount inactive
 
Qt State Machine Framework
Qt State Machine FrameworkQt State Machine Framework
Qt State Machine Frameworkaccount inactive
 
Mobile Development with Qt for Symbian
Mobile Development with Qt for SymbianMobile Development with Qt for Symbian
Mobile Development with Qt for Symbianaccount inactive
 
Animation Framework: A Step Towards Modern UIs
Animation Framework: A Step Towards Modern UIsAnimation Framework: A Step Towards Modern UIs
Animation Framework: A Step Towards Modern UIsaccount inactive
 
Using Multi-Touch and Gestures with Qt
Using Multi-Touch and Gestures with QtUsing Multi-Touch and Gestures with Qt
Using Multi-Touch and Gestures with Qtaccount inactive
 
Debugging Qt, Fixing and Contributing a Bug Report (Using Gitorious)
Debugging Qt, Fixing and Contributing a Bug Report (Using Gitorious)Debugging Qt, Fixing and Contributing a Bug Report (Using Gitorious)
Debugging Qt, Fixing and Contributing a Bug Report (Using Gitorious)account inactive
 
Copy Your Favourite Nokia App with Qt
Copy Your Favourite Nokia App with QtCopy Your Favourite Nokia App with Qt
Copy Your Favourite Nokia App with Qtaccount inactive
 
The Next Generation Qt Item Views
The Next Generation Qt Item ViewsThe Next Generation Qt Item Views
The Next Generation Qt Item Viewsaccount inactive
 
Optimizing Performance in Qt-Based Applications
Optimizing Performance in Qt-Based ApplicationsOptimizing Performance in Qt-Based Applications
Optimizing Performance in Qt-Based Applicationsaccount inactive
 

Mehr von account inactive (20)

KDE Plasma for Mobile Phones
KDE Plasma for Mobile PhonesKDE Plasma for Mobile Phones
KDE Plasma for Mobile Phones
 
Shipping Mobile Applications Using Qt for Symbian
Shipping Mobile Applications Using Qt for SymbianShipping Mobile Applications Using Qt for Symbian
Shipping Mobile Applications Using Qt for Symbian
 
The Future of Qt Widgets
The Future of Qt WidgetsThe Future of Qt Widgets
The Future of Qt Widgets
 
Scripting Your Qt Application
Scripting Your Qt ApplicationScripting Your Qt Application
Scripting Your Qt Application
 
Special Effects with Qt Graphics View
Special Effects with Qt Graphics ViewSpecial Effects with Qt Graphics View
Special Effects with Qt Graphics View
 
Developments in The Qt WebKit Integration
Developments in The Qt WebKit IntegrationDevelopments in The Qt WebKit Integration
Developments in The Qt WebKit Integration
 
Qt Kwan-Do
Qt Kwan-DoQt Kwan-Do
Qt Kwan-Do
 
Qt on Real Time Operating Systems
Qt on Real Time Operating SystemsQt on Real Time Operating Systems
Qt on Real Time Operating Systems
 
Translating Qt Applications
Translating Qt ApplicationsTranslating Qt Applications
Translating Qt Applications
 
Qt Creator Bootcamp
Qt Creator BootcampQt Creator Bootcamp
Qt Creator Bootcamp
 
Qt Widget In-Depth
Qt Widget In-DepthQt Widget In-Depth
Qt Widget In-Depth
 
Qt State Machine Framework
Qt State Machine FrameworkQt State Machine Framework
Qt State Machine Framework
 
Mobile Development with Qt for Symbian
Mobile Development with Qt for SymbianMobile Development with Qt for Symbian
Mobile Development with Qt for Symbian
 
Animation Framework: A Step Towards Modern UIs
Animation Framework: A Step Towards Modern UIsAnimation Framework: A Step Towards Modern UIs
Animation Framework: A Step Towards Modern UIs
 
Using Multi-Touch and Gestures with Qt
Using Multi-Touch and Gestures with QtUsing Multi-Touch and Gestures with Qt
Using Multi-Touch and Gestures with Qt
 
Debugging Qt, Fixing and Contributing a Bug Report (Using Gitorious)
Debugging Qt, Fixing and Contributing a Bug Report (Using Gitorious)Debugging Qt, Fixing and Contributing a Bug Report (Using Gitorious)
Debugging Qt, Fixing and Contributing a Bug Report (Using Gitorious)
 
The Mobility Project
The Mobility ProjectThe Mobility Project
The Mobility Project
 
Copy Your Favourite Nokia App with Qt
Copy Your Favourite Nokia App with QtCopy Your Favourite Nokia App with Qt
Copy Your Favourite Nokia App with Qt
 
The Next Generation Qt Item Views
The Next Generation Qt Item ViewsThe Next Generation Qt Item Views
The Next Generation Qt Item Views
 
Optimizing Performance in Qt-Based Applications
Optimizing Performance in Qt-Based ApplicationsOptimizing Performance in Qt-Based Applications
Optimizing Performance in Qt-Based Applications
 

Kürzlich hochgeladen

2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWERMadyBayot
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...apidays
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdflior mazor
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024The Digital Insurer
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAndrey Devyatkin
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024The Digital Insurer
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
A Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusA Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusZilliz
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Jeffrey Haguewood
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...Zilliz
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024The Digital Insurer
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherRemote DBA Services
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsNanddeep Nachan
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native ApplicationsWSO2
 

Kürzlich hochgeladen (20)

2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
A Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusA Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source Milvus
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 

Development with Qt for Windows CE

  • 1. Development with Qt for Windows CE 10/11/09
  • 2. Agenda • Introduction to Windows CE • How to build Qt for Windows CE • Windows CE 5 memory model • Ways to more memory • Demonstration
  • 3. What is Windows CE? • OS for embedded devices • not derived from desktop Windows • monolithic kernel • highly configurable using Platform Builder • runs on x86, ARM, SH4 and MIPS 3
  • 4. The world of Windows CE • Windows CE 5.2 – Windows mobile 5, 6, 6.1, 6.5 • SmartPhone (standard) • PocketPC (classic / professional) • Windows CE 6.0 R2 – Microsoft Auto – Windows mobile 7? 4
  • 5. Desktop Windows vs. Windows CE • UTF16 string representation • No NTFS support → no file security model • No file drives • No current directory • Only 32 processes • Only 32 MB memory per process (CE < 6) 5
  • 6. Desktop Windows vs. Windows CE • Number of threads limited to system resources – no more free memory → no more threads • API is a Win32 API subset – no *A functions – no asynchronous file I/O or network – incomplete standard C libs 6
  • 7. Desktop Windows vs. Windows CE • Situation gets better with Windows CE 6 – Up to 1 GB process memory – More than 32K processes – Improved system call performance – New product name: Windows embedded CE 7
  • 8. What do you need for development? • Visual Studio 2005 Standard or Visual Studio 2008 Professional • Windows CE SDK for your device • Qt for Windows CE from qt.nokia.com • Perl for using out-of-source builds • Qt Visual Studio Add-in from qt.nokia.com 8
  • 9. Development work flow • Prototype on Desktop Windows • Switch to a Windows CE Qt build • Build, deploy and run – Not everybody in the team needs a Windows CE development environment. 9
  • 10. How to build Qt for Windows CE? • Use shadow builds. C:Qt4.6.0qtsource win32 wincewm60professional wince50standard-x86 10
  • 11. How to build Qt for Windows CE? Open a Visual Studio command prompt. Add C:Qt4.6.0wincewm60professionalbin to PATH. cd C:Qt4.6.0wincewm60professional .qtsourcesconfigure -xplatform wincewm60professional-msvc2008 -signature mysignature.pfx Creates Qt configuration and builds the host tools: • qmake, moc, uic, rcc • setcepaths / checksdk • cetest (if Remote API is in INCLUDE, LIBS) 11
  • 12. How to build Qt for Windows CE? ...only two steps left... setcepaths wincewm60professional-msvc2008 nmake 12
  • 13. Qt DLL sizes Library sizes of Qt 4.5.2 on Windows mobile 6 professional: Qt library Size in MB QtCore4.dll 1.67 MB QtGui4.dll 5.67 MB QtNetwork4.dll 0.53 MB QtWebKit4.dll 6.86 MB qjpeg4.dll 0.12 MB sum 14.85 MB 13
  • 14. The Windows CE 5.0 memory model Slot 63 Resource only DLLs • only 32 MB per slot • Application stack & heap grow large memory area from slot's bottom Slot 32 Process 32 • DLLs are loaded into process slots top-down ... • DLLs are guaranteed to have Slot 3 the same address in every slot Process 2 Slot 2 Process 1 Slot 1 bundled DLLs Slot 0 current process 14
  • 15. The Windows CE 5.0 memory model Bundled DLLs Load address for new DLLs 15
  • 16. The Windows CE 5.0 memory model Qt DLLs Stack & heap 16
  • 17. Ways to more Virtual Memory • Reduce the DLL size • Use static linking • Load small DLLs first • Switch to Windows mobile 6.1 17
  • 18. Reducing Qt DLL sizes • Exclude the features you don't need • “feature” = set of classes (e.g. GraphicsView) • define QT_NO_FEATURENAME configure -D QT_NO_FEATURENAME • add this define to your application .pro file DEFINES += QT_NO_FEATURENAME • Tedious stuff! Is there no easier way to do this? 18
  • 19. Reducing Qt DLL sizes using qconfig
  • 20. Reducing Qt DLL sizes using qconfig In your desktop Windows Qt build directory: md toolsqconfig cd toolsqconfig qmake ......toolsqconfigqconfig.pro nmake release releaseqconfig.exe 20
  • 21. Reducing Qt DLL sizes using qconfig Good candiates for exclusion: • Standard dialogs (color, font, input, wizard, …) • Convenience widgets (QCalendarWidget, ...) • Clipboard, drag and drop, shortcuts • QtConcurrent, FTP, QSystemTrayIcon • GraphicsView for QWidget only applications • MDI 21
  • 22. Reducing Qt DLL sizes using qconfig • Open the features description file in srccorelibglobalqfeatures.txt • Unselect unwanted features • Save the result in srccorelibglobalqconfig-myfeatures.h • Reconfigure Qt configure -qconfig myfeatures ... 22
  • 23. Reducing Qt DLL sizes 2.43 minimal 1.42 4.18 QtCore small 1.67 QtGui 5.67 standard 1.67 0 1 2 3 4 5 6 23
  • 24. Accessing the Large Memory Area • just 32 MB? Are you serious? • there's more behind slot 32 • use memory mapped files • use the VirtualAlloc API 24
  • 25. Accessing the Large Memory Area Using memory mapped files: • acquire memory at 64 K boundaries QFile memfile("myfile.bin"); memfile.open(QIODevice::ReadWrite); memfile.resize(1024*1024*2); uchar* buf = memfile.map(0, 1024*1024*2); ... memfile.unmap(buf); memfile.remove(); 25
  • 26. Accessing the Large Memory Area Using VirtualAlloc: • Reserve memory at 64 K boundaries or commit reserved memory at 4 K boundaries void* ptrBase = VirtualAlloc(0, dwSize, MEM_RESERVE, PAGE_NOACCESS); buffer = VirtualAlloc(ptrBase, dwSize, MEM_COMMIT, PAGE_READWRITE); ... VirtualFree(ptr, dwSize, MEM_DECOMMIT); VirtualFree(ptr, 0, MEM_RELEASE); 26