Date post: | 25-Dec-2015 |
Category: |
Documents |
Upload: | lydia-obrien |
View: | 214 times |
Download: | 0 times |
1
Windows Vista: Reaching Your Users Windows Vista: Reaching Your Users When Their Machine Is Off, Using When Their Machine Is Off, Using Auxiliary Display DevicesAuxiliary Display Devices
Sriram Viji, Program ManagerSriram Viji, Program ManagerDan Polivy, Software Design Dan Polivy, Software Design EngineerEngineerSession PRS308Session PRS308Microsoft CorporationMicrosoft Corporation
2
AgendaAgenda
Platform introductionPlatform introduction
Writing gadgets using C++ and COMWriting gadgets using C++ and COM
Writing gadgets using C#Writing gadgets using C#
Design considerationsDesign considerations
3
Devices for Windows Devices for Windows SideShowSideShow
Laptop in-lid displaysLaptop in-lid displays
Connected and online displaysConnected and online displays
Remote or detachable devicesRemote or detachable devices
4
Gadget PlatformsGadget Platforms
Windows SideShowWindows SideShowExtends data from the PC to devicesExtends data from the PC to devices
COM and C++ APIsCOM and C++ APIs
Windows SidebarWindows SidebarShows information on the clientShows information on the client
DHTML scripting and libraries/WPFDHTML scripting and libraries/WPF
Start.comStart.comWeb based with AJAX like architectureWeb based with AJAX like architecture
Integration with client platformIntegration with client platform
5
Platform BenefitsPlatform Benefits
Increase application reach and Increase application reach and visibilityvisibility
Provide user valueProvide user value
Easy to write gadgetsEasy to write gadgets
6
Windows SideShow Windows SideShow PrototypePrototype
7
Sample ScenariosSample Scenarios
Cached/Offline scenarios: Calendar, Cached/Offline scenarios: Calendar, driving directions, e-mail, weather, driving directions, e-mail, weather, traffictraffic
Make use of data that is cached on a Make use of data that is cached on a devicedevice
User can interact when the PC is on or User can interact when the PC is on or offoff
Live/Online scenarios: Media control, Live/Online scenarios: Media control, presentation control, instant presentation control, instant messaging, notificationsmessaging, notifications
Data and events sent during user Data and events sent during user interactioninteraction
User can interact when the PC is onUser can interact when the PC is on
8
User ControlUser Control
User selects gadgets to view on User selects gadgets to view on devicedevice
InstalledInstalledGadgetsGadgets
Installed Installed DevicesDevices
9
Software ArchitectureSoftware Architecture
Auxiliary Display APIAuxiliary Display API
GadgetGadget
Auxiliary Display DriverAuxiliary Display Driver
Display DeviceDisplay Device
Inter-process communicationInter-process communication
Transport ChannelTransport Channel
10
Conference SchedulerConference Scheduler
11
Gadget InstallationGadget Installation
Friendly nameFriendly name
IconIcon
EndpointEndpointSpecifies data format Specifies data format between gadget and devicebetween gadget and device
[HKCU\SOFTWARE\Microsoft\AuxiliaryDisplay\Applications\{[HKCU\SOFTWARE\Microsoft\AuxiliaryDisplay\Applications\{APPLICATION_IDAPPLICATION_ID}]}]"FriendlyName"=“"FriendlyName"=“Application name”Application name” ; User friendly name; User friendly name““Icon”=Icon”=myapplication.dll,0myapplication.dll,0 ; 16,32,48 px icons; 16,32,48 px icons"OnlineOnly"=dword:"OnlineOnly"=dword:0000000000000000 ; Is it “Live” or “Cached”?; Is it “Live” or “Cached”?"Endpoints"=MULTI_SZ:"Endpoints"=MULTI_SZ:Endpoint GUID(s) Endpoint GUID(s) ; Data format(s) supported; Data format(s) supported
Friendly Friendly NameName
IconIcon
12
Registering A SessionRegistering A Session
Create an instance of the RegistrarCreate an instance of the Registrar
Register application ID and data Register application ID and data formatformat
// Create the AuxiliaryDisplayRegistrar object that// Create the AuxiliaryDisplayRegistrar object that// enables us to talk to the platform.// enables us to talk to the platform.hr = ::CoCreateInstance(CLSID_AuxiliaryDisplayRegistrar, NULL,hr = ::CoCreateInstance(CLSID_AuxiliaryDisplayRegistrar, NULL, CLSCTX_INPROC_SERVER,CLSCTX_INPROC_SERVER, IID_IAuxiliaryDisplayRegistrar,IID_IAuxiliaryDisplayRegistrar, (LPVOID*)&m_pRegistrar);(LPVOID*)&m_pRegistrar);
if (SUCCEEDED(hr))if (SUCCEEDED(hr)){{ // Register application with the platform// Register application with the platform hr = m_pRegistrar->Register(hr = m_pRegistrar->Register(MY_APPLICATION_IDMY_APPLICATION_ID,, AUX_ENDPOINT_SIMPLE_CONTENT_FORMATAUX_ENDPOINT_SIMPLE_CONTENT_FORMAT,, &m_pContentMgr);&m_pContentMgr);}}
13
Content ManagementContent Management
Sta
rtup: se
nd
Sta
rtup: se
nd
init
ial co
nte
nt
init
ial co
nte
nt
Updat
e c
onte
nt
Update
conte
nt
Use
r U
ser
inte
ract
s w
ith
inte
ract
s w
ith
devi
ce
devi
ce(i.e
. get
(i.e
. get
deta
ils
on a
deta
ils
on a
sess
ion)
sess
ion)
GadgetGadget
DeviceDevice
Resp
onse
to
Resp
onse
to
acti
on (
i.e.
acti
on (i.e.
send s
ess
ion
send s
ess
ion
deta
ils)
deta
ils)
Use
r U
ser
inte
ract
ion (
i.e.
inte
ract
ion (
i.e.
sele
ct s
ess
ion
sele
ct s
ess
ion
to a
ttend)
to a
ttend)
Peri
odic
Peri
odic
updat
es
updat
es
(i.e
. updat
e
(i.e
. update
“next
sess
ion”)
“next
sess
ion”)
14
Creating ContentCreating Content
Developer implements Developer implements IAuxiliaryDisplayContentIAuxiliaryDisplayContent
Returns a content ID (unsigned 32-bit value)Returns a content ID (unsigned 32-bit value)
Provides the content as an array of bytes Provides the content as an array of bytes (opaque)(opaque)
Allows developer to send different content to Allows developer to send different content to each device based on the device’s capabilitieseach device based on the device’s capabilitiesHRESULT get_ContentId(HRESULT get_ContentId(
PCONTENT_ID out_pcontentIdPCONTENT_ID out_pcontentId););
HRESULT get_DifferentiateContent(HRESULT get_DifferentiateContent(BOOL * out_pfDifferentiateContentBOOL * out_pfDifferentiateContent
););
HRESULT GetContent(HRESULT GetContent(IAuxiliaryDisplayCapabilities * in_pICapabilities,IAuxiliaryDisplayCapabilities * in_pICapabilities,DWORD * out_pdwSize,DWORD * out_pdwSize,BYTE ** out_ppbDataBYTE ** out_ppbData
););
15
Content FormatContent Format
Gadgets and devices need a common format to Gadgets and devices need a common format to exchange dataexchange data
Simple Content FormatSimple Content FormatNew, Documented XML data format for which we are New, Documented XML data format for which we are encouraging device supportencouraging device support
Provides simple layout and interaction for devices with Provides simple layout and interaction for devices with varying capabilitiesvarying capabilities
Functions in both “PC on” (live/online) and “PC off” Functions in both “PC on” (live/online) and “PC off” (cached) modes(cached) modes
iCalendariCalendarAllows transfer of appointments in a standard formatAllows transfer of appointments in a standard format
Presentation is determined by the device; thus the Presentation is determined by the device; thus the calendar calendar display and interaction can be richer than by using the display and interaction can be richer than by using the Simple Content FormatSimple Content Format
16
Glance ContentGlance Content
Glance or Overview ContentGlance or Overview ContentContent id of 0 reserved for overview Content id of 0 reserved for overview contentcontent
Simple text stringSimple text string
Easy to support on all devices, Easy to support on all devices, regardless of actual content format usedregardless of actual content format used
Glance Glance ContentContent
17
Simple Content FormatSimple Content Format
Menu PageMenu PageProvides a list of itemsProvides a list of items
Selection causes navigationSelection causes navigation
Can be used as a context Can be used as a context menu on menu items and menu on menu items and content pagescontent pages
<body><body> <menu id=“1” title="Image List"><menu id=“1” title="Image List"> <item target="2">Sunset</item><item target="2">Sunset</item> <item target="3">Winter</item><item target="3">Winter</item> <item target="4">Water lilies</item><item target="4">Water lilies</item> <item target="5">Blue hills</item><item target="5">Blue hills</item> </menu></menu></body></body>
18
<body><body> <content id=“2”><content id=“2”> <txt align="c">Sunset</txt><txt align="c">Sunset</txt> <txt>Driving on the coastal highway <txt>Driving on the coastal highway is fun</txt>is fun</txt> <img id=“10" alt="[sunset.jpg]"/><img id=“10" alt="[sunset.jpg]"/> </content></content></body></body>
Simple Content FormatSimple Content Format
Layout PageLayout PageProvides flow layoutProvides flow layout
Support for text and imagesSupport for text and images
Simple text formatting Simple text formatting (emphasis, color, alignment)(emphasis, color, alignment)
Button mapping to override Button mapping to override default navigation actiondefault navigation action
19
<body><body> <dialog id="200" title="Image rotate"><dialog id="200" title="Image rotate"> <txt>Your image will lose some <txt>Your image will lose some quality when rotated. Would you like to quality when rotated. Would you like to proceed?</txt>proceed?</txt> <btn target="201">Yes</btn><btn target="201">Yes</btn> <btn target="202">No</btn><btn target="202">No</btn> </dialog></dialog></body></body>
Simple Content FormatSimple Content Format
Dialog PageDialog PageProvides simple dialog box with icon, Provides simple dialog box with icon, title, message, buttonstitle, message, buttons
User input on a decisionUser input on a decision
Icon available for visual clueIcon available for visual clue
20
Sending/Updating ContentSending/Updating Content
Content manager allows applications Content manager allows applications toto
Add/Update content on devicesAdd/Update content on devices
Remove contentRemove contentIAuxiliaryDisplayContent* pIContent;IAuxiliaryDisplayContent* pIContent;CMyContent pContent = new CMyContent(1 /* CONTENT_ID */, “Content”);CMyContent pContent = new CMyContent(1 /* CONTENT_ID */, “Content”);
hr = pContent->QueryInterface(IID_IAuxiliaryDisplayContent,hr = pContent->QueryInterface(IID_IAuxiliaryDisplayContent, &pIContent);&pIContent);
// Add a content object that implements IAuxiliaryDisplayContent// Add a content object that implements IAuxiliaryDisplayContenthr = m_pContentMgr->Add(pIContent);hr = m_pContentMgr->Add(pIContent);
// Remove Content ID “1” from all devices// Remove Content ID “1” from all deviceshr = m_pContentMgr->Remove(1);hr = m_pContentMgr->Remove(1);
// Remove all content from devices// Remove all content from deviceshr = m_pContentMgr->RemoveAll();hr = m_pContentMgr->RemoveAll();
21
Platform EventsPlatform Events
ISV implements IAuxiliaryDisplayEvents ISV implements IAuxiliaryDisplayEvents interfaceinterfaceFour eventsFour events
ContentMissingContentMissingOccurs when the device requires a specific piece of Occurs when the device requires a specific piece of content it does not have cachedcontent it does not have cached
ApplicationEventApplicationEventGenerated due to user interaction with the device, i.e.Generated due to user interaction with the device, i.e.User selection on a list itemUser selection on a list itemNavigation to a specific page of contentNavigation to a specific page of content
Device Added/Device RemovedDevice Added/Device RemovedIncludes both PnP events, as well as “permission Includes both PnP events, as well as “permission change” events generated from enabling/disabling a change” events generated from enabling/disabling a gadget in the CPLgadget in the CPL
22
Simple Content Format Simple Content Format EventsEvents
Events propagated to PC gadget Events propagated to PC gadget (when on) as user navigates content (when on) as user navigates content on deviceon device
NavigationEventNavigationEventTriggered upon any navigation starting on a Triggered upon any navigation starting on a content or dialog pagecontent or dialog page
MenuEventMenuEventTriggered upon selection of an item off a Triggered upon selection of an item off a menu pagemenu page
ContextMenuEventContextMenuEventTriggered upon any navigation off of a Triggered upon any navigation off of a context menucontext menu
23
Device CapabilitiesDevice Capabilities
Developer can retrieve a collection of Developer can retrieve a collection of IAuxiliaryDisplayCapabilities IAuxiliaryDisplayCapabilities interfaces from the Content Managerinterfaces from the Content Manager
Capabilities interface is external Capabilities interface is external representation of a devicerepresentation of a deviceCan query device properties, such as:Can query device properties, such as:
Screen width/heightScreen width/heightColor depthColor depthCurrent languageCurrent language
IHV extensibleIHV extensible
Interface also provided on some Interface also provided on some events to identify initiating deviceevents to identify initiating device
24
NotificationsNotifications
IAuxiliaryDisplayNotificationManager IAuxiliaryDisplayNotificationManager interface mirrors the content interface mirrors the content managermanager
Show/Revoke/RevokeAllShow/Revoke/RevokeAll
IAuxiliaryDisplayNotification IAuxiliaryDisplayNotification CoCreate’able by ISVCoCreate’able by ISV
PropertiesPropertiesTitleTitle
MessageMessage
IconIcon
Expiration timeExpiration time
25
Expedia.comExpedia.com
26
Managed CodeManaged Code
Accessible through standard COM Accessible through standard COM InteropInterop
Same functionality availableSame functionality available
Sample code provided for interopSample code provided for interop
27
Design ConsiderationsDesign Considerations
Gadget lifetime managementGadget lifetime managementUser expects device to be up to dateUser expects device to be up to date
Missing content needs to be providedMissing content needs to be provided
OptionsOptionsBackground process (as part of an existing Background process (as part of an existing system tray or any other process)system tray or any other process)
Add on to an existing applicationAdd on to an existing application
28
Design ConsiderationsDesign Considerations
Device SupportDevice SupportSupport wide range of device capabilitiesSupport wide range of device capabilities
RecommendationsRecommendationsProvide useful glance contentProvide useful glance content
Ensure accurate data for text only displaysEnsure accurate data for text only displays
If possible, differentiate content for displaysIf possible, differentiate content for displays
PerformancePerformanceMobile PCs are a big target – conserve Mobile PCs are a big target – conserve batterybattery
Selectively update contentSelectively update content
29
Summing UpSumming Up
New opportunities and new scenariosNew opportunities and new scenarios
Value-add for existing applicationsValue-add for existing applications
Tools and samples to get startedTools and samples to get started
30
Mobile PC and Tablet PCMobile PC and Tablet PCBreakout SessionsBreakout Sessions
PRS308 - Windows Vista: Reaching Your Users When PRS308 - Windows Vista: Reaching Your Users When Their Machine Is Off, Using Auxiliary Display DevicesTheir Machine Is Off, Using Auxiliary Display DevicesWednesday, 1:45 PM - 3:00 PMWednesday, 1:45 PM - 3:00 PM
PRS315 - Windows Vista Tablet PC: Advances in PRS315 - Windows Vista Tablet PC: Advances in Creating Tablet Enabled ApplicationsCreating Tablet Enabled ApplicationsWednesday, 5:00 PM - 6:15 PMWednesday, 5:00 PM - 6:15 PM
DAT317 - Windows Vista: Centralizing Data DAT317 - Windows Vista: Centralizing Data Synchronization with the New Sync CenterSynchronization with the New Sync CenterThursday, 11:30 AM - 12:45 PMThursday, 11:30 AM - 12:45 PM
FUN319 - Windows Vista: Developing Power-Aware FUN319 - Windows Vista: Developing Power-Aware ApplicationsApplicationsThursday, 5:15 PM - 6:30 PMThursday, 5:15 PM - 6:30 PM
PNL12 - Future Directions in Mobile Device HardwarePNL12 - Future Directions in Mobile Device HardwareFriday, 1:00 PM- 2:30 PMFriday, 1:00 PM- 2:30 PM
31
Get involved with Mobile PC Get involved with Mobile PC and Tablet PC at PDC!and Tablet PC at PDC!
Hands-On-Labs Hands-On-Labs Use the Tablet PCs located in the Presentation Track SectionUse the Tablet PCs located in the Presentation Track Section
PRSHOL26PRSHOL26 -- Mobile PC: Getting Started with Auxiliary Displays Mobile PC: Getting Started with Auxiliary Displays (C++ and C#) - (C++ and C#) - Provide your users with instant access to data—even Provide your users with instant access to data—even in powered-down states—with Auxiliary Display devices on Windows in powered-down states—with Auxiliary Display devices on Windows Vista.Vista.
FUNHOL09 - Mobile PC: Building Energy Smart Windows Vista FUNHOL09 - Mobile PC: Building Energy Smart Windows Vista Applications (C#) -Applications (C#) - Learn how to be compatible with Windows Vista’s Learn how to be compatible with Windows Vista’s new Sleep behavior and learn how to integrate with the power policy new Sleep behavior and learn how to integrate with the power policy engine to build a more robust application. engine to build a more robust application.
PRSHOL31PRSHOL31 && PRSHOL32PRSHOL32 -- Tablet PC: Getting Started with the Tablet PC: Getting Started with the Tablet PC Platform (C# and Visual Basic .NET) -Tablet PC Platform (C# and Visual Basic .NET) - Create ink- Create ink-enabled forms to empower your Tablet PC customers by using ink enabled forms to empower your Tablet PC customers by using ink controls, the InkPicture object, and other APIs from the Windows XP controls, the InkPicture object, and other APIs from the Windows XP Tablet PC Edition SDK 1.7.Tablet PC Edition SDK 1.7.
PRSHOL30PRSHOL30 -- Tablet PC: Advanced Development with Stylus Tablet PC: Advanced Development with Stylus Input APIs (C#) - Input APIs (C#) - Enhance performance and rendering by using the Enhance performance and rendering by using the Tablet PC Stylus Input API to intercept and modify stylus data in real Tablet PC Stylus Input API to intercept and modify stylus data in real time.time.
Get spotted with this button Get spotted with this button for a chance to win a Tablet PC!for a chance to win a Tablet PC!
32
ResourcesResources
Windows SideShow at PDCWindows SideShow at PDCHands on Lab: Hands on Lab: PRSHOL26 Mobile PC: Getting started with PRSHOL26 Mobile PC: Getting started with Auxiliary Displays / Windows SideShowAuxiliary Displays / Windows SideShow
Booth: Booth: Prototype device and other conceptsPrototype device and other concepts
PRS Track lounge: PRS Track lounge: Wed 3-5pmWed 3-5pm
Related: Related: PRS332 Developing Windows Sidebar GadgetsPRS332 Developing Windows Sidebar Gadgets Thu 3:45pm – 5:00pm 402ABThu 3:45pm – 5:00pm 402AB
After PDCAfter PDCGadgets: Gadgets: http://http://microsoftgadgets.com/sideshow.aspxmicrosoftgadgets.com/sideshow.aspx
Mobile PC and Tablet PC Forum under Windows Vista Mobile PC and Tablet PC Forum under Windows Vista Development : Development : http://http://forums.microsoft.com/msdnforums.microsoft.com/msdn//
Business Contact: Business Contact: [email protected]@microsoft.com
Windows Vista Beta and SDK: Windows Vista Beta and SDK: http://http://msdn.microsoft.com/windowsvistamsdn.microsoft.com/windowsvista//
33
© 2005 Microsoft Corporation. All rights reserved.This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.