diff -r 4816d766a08a -r f345bda72bc4 Symbian3/PDK/Source/GUID-2C8BE998-BCCE-5A06-AFC1-4B611D9233AB.dita --- a/Symbian3/PDK/Source/GUID-2C8BE998-BCCE-5A06-AFC1-4B611D9233AB.dita Tue Mar 30 11:42:04 2010 +0100 +++ b/Symbian3/PDK/Source/GUID-2C8BE998-BCCE-5A06-AFC1-4B611D9233AB.dita Tue Mar 30 11:56:28 2010 +0100 @@ -1,104 +1,104 @@ - - - - - -Turn -Off Broadcast Receiver Tutorial -

This document helps you to understand how RDvbhReceiver handles -session close and the power off for a Broadcast Receiver hardware.

-
Purpose

This tutorial tells you about shutting -down the Broadcast Receiver hardware. The purpose is to end up with closed -session and, or power off the hardware.

-
Required Background

When you have finished with -a RDvbhReceiver instance, you must close the session before -it is destroyed or else risk causing a memory leak and corrupt reference count -on the receiver.

-
Introduction

To shut down the hardware, you need -to power off and close the session to the receiver. There are two ways to -shut down the receiver, they are as follows:

    -
  • Call RDvbhReceiver::PowerOff() where -signal to the receiver no longer to be called.

  • -
  • Shut down immediately. -This is done by calling RDvbhReceiver::SetDisabled().

  • -
-
Setup and Configuration Requirements

You need a -receiver instance for the DVB-H Receiver to be called.

-
Using Turn Off Broadcast Receiver Tutorial

The -Following tasks will be covered in this tutorial:

    -
  • How to power off the broadcast receiver

  • -
  • How to close session of the broadcast receiver

  • -
  • How to shut down immediately the broadcast receiver

  • -

Basic Procedure -To Shut Down The Receiver

The high level steps to shut down immediately -the broadcast receiver are shown here:

    -
  1. For power downing the -receiver immediately, you need to call RDvbhReceiver::SetDisabled(). -This method takes a boolean parameter as ETrue to disable or EFalse to re-enable. -If this method is called with ETrue on any instance, then power to the receiver -is immediately cut and the receiver is put into disabled state.

    In -disabled state, the power to the receiver remains off even if calls to RDvbhReceiver::PowerOn() are -invoked. Indeed, RDvbhReceiver::PowerOn() returns KErrLocked -while the receiver is in disabled state. In order for the receiver to be moved -out of disabled state, RDvbhReceiver::SetDisabled(EFalse) must -be called from each session that issued is RDvbhReceiver::SetDisabled(ETrue). -When the receiver is moved out of the disabled state, it may be powered back -on call to RDvbhReceiver::PowerOn() as usual.

  2. -
-
Basic procedure to power off the broadcast receiver

The -high level steps to power off the broadcast receiver are shown here:

    -
  1. To power off the receiver, -call RDvbhReceiver::PowerOff().

  2. -
  3. In order to shut down -power completely, RDvbhReceiver::PowerOff() takes into -account the reference count of the receiver client and puts the power off -until each client that has called RDvbhReceiver::PowerOn().

  4. -
-
Example to off the broadcast receiver power - -RDvbhReceiver receiver1; -RDvbhReceiver receiver2; -RDvbhReceiver receiver3; - -User::LeaveIfError(receiver1.Open()); -User::LeaveIfError(receiver2.Open()); -User::LeaveIfError(receiver3.Open()); - -User::LeaveIfError(receiver1.PowerOn()); -User::LeaveIfError(receiver3.PowerOn()); - -//Wait until booting has completed. Shared receiver is now powered on. -receiver1.PowerOff(); //count decremented, but receiver power is still on. -receiver2.PowerOff(); //count not decremented, No effect. -receiver3.PowerOff(); //count decremented to 0. No more clients that have requested power - // on, so the power is turned off. - -
-
Basic Procedure To Close Session Of The Broadcast Receiver

The -high level steps to close session of the broadcast receiver are shown here:

    -
  1. In order to close the -session call RDvbhReceiver::Close().

  2. -
  3. If RDvbhReceiver::PowerOn() is -called on an instance, then RDvbhReceiver::Close() reduces -the reference count as if RDvbhReceiver::PowerOff() is -called. As a result, if there are no more open sessions to the receiver, then -it is powered off.

  4. -
-
-Turn On Broadcast -Receiver -Setting Data -Reception -DVB-H Signal -Scanning -Tuning IP -Platform -Receiving -Broadcast Data + + + + + +Turn +Off Broadcast Receiver Tutorial +

This document helps you to understand how RDvbhReceiver handles +session close and the power off for a Broadcast Receiver hardware.

+
Purpose

This tutorial tells you about shutting +down the Broadcast Receiver hardware. The purpose is to end up with closed +session and, or power off the hardware.

+
Required Background

When you have finished with +a RDvbhReceiver instance, you must close the session before +it is destroyed or else risk causing a memory leak and corrupt reference count +on the receiver.

+
Introduction

To shut down the hardware, you need +to power off and close the session to the receiver. There are two ways to +shut down the receiver, they are as follows:

    +
  • Call RDvbhReceiver::PowerOff() where +signal to the receiver no longer to be called.

  • +
  • Shut down immediately. +This is done by calling RDvbhReceiver::SetDisabled().

  • +
+
Setup and Configuration Requirements

You need a +receiver instance for the DVB-H Receiver to be called.

+
Using Turn Off Broadcast Receiver Tutorial

The +Following tasks will be covered in this tutorial:

    +
  • How to power off the broadcast receiver

  • +
  • How to close session of the broadcast receiver

  • +
  • How to shut down immediately the broadcast receiver

  • +

Basic Procedure +To Shut Down The Receiver

The high level steps to shut down immediately +the broadcast receiver are shown here:

    +
  1. For power downing the +receiver immediately, you need to call RDvbhReceiver::SetDisabled(). +This method takes a boolean parameter as ETrue to disable or EFalse to re-enable. +If this method is called with ETrue on any instance, then power to the receiver +is immediately cut and the receiver is put into disabled state.

    In +disabled state, the power to the receiver remains off even if calls to RDvbhReceiver::PowerOn() are +invoked. Indeed, RDvbhReceiver::PowerOn() returns KErrLocked +while the receiver is in disabled state. In order for the receiver to be moved +out of disabled state, RDvbhReceiver::SetDisabled(EFalse) must +be called from each session that issued is RDvbhReceiver::SetDisabled(ETrue). +When the receiver is moved out of the disabled state, it may be powered back +on call to RDvbhReceiver::PowerOn() as usual.

  2. +
+
Basic procedure to power off the broadcast receiver

The +high level steps to power off the broadcast receiver are shown here:

    +
  1. To power off the receiver, +call RDvbhReceiver::PowerOff().

  2. +
  3. In order to shut down +power completely, RDvbhReceiver::PowerOff() takes into +account the reference count of the receiver client and puts the power off +until each client that has called RDvbhReceiver::PowerOn().

  4. +
+
Example to off the broadcast receiver power + +RDvbhReceiver receiver1; +RDvbhReceiver receiver2; +RDvbhReceiver receiver3; + +User::LeaveIfError(receiver1.Open()); +User::LeaveIfError(receiver2.Open()); +User::LeaveIfError(receiver3.Open()); + +User::LeaveIfError(receiver1.PowerOn()); +User::LeaveIfError(receiver3.PowerOn()); + +//Wait until booting has completed. Shared receiver is now powered on. +receiver1.PowerOff(); //count decremented, but receiver power is still on. +receiver2.PowerOff(); //count not decremented, No effect. +receiver3.PowerOff(); //count decremented to 0. No more clients that have requested power + // on, so the power is turned off. + +
+
Basic Procedure To Close Session Of The Broadcast Receiver

The +high level steps to close session of the broadcast receiver are shown here:

    +
  1. In order to close the +session call RDvbhReceiver::Close().

  2. +
  3. If RDvbhReceiver::PowerOn() is +called on an instance, then RDvbhReceiver::Close() reduces +the reference count as if RDvbhReceiver::PowerOff() is +called. As a result, if there are no more open sessions to the receiver, then +it is powered off.

  4. +
+
+Turn On Broadcast +Receiver +Setting Data +Reception +DVB-H Signal +Scanning +Tuning IP +Platform +Receiving +Broadcast Data
\ No newline at end of file