📄 release_notes.txt
字号:
S60 Platform: Internet Access Points Example v2.0
-------------------------------------------------------------------------------
This C++ code example demonstrates how an application can open an Internet connection.
The application opens a connection to a predefined Internet access point (IAP); access
points are configured using the Settings tools in the device or an access point
handler dialog.
The example also shows how to list existing IAPs grouped by the network type;
that is, how to show only IAPs supporting packet-switched data (PSD) or circuit-switched
data (CSD) to the user.
Functionality for creating new IAPs and deleting them is also provided.
The steps involved in monitoring connections using TNifProgress, RConnection,
and RConnectionMonitor are also shown in this example. RConnectionMonitor is
supported from S60 2nd Edition, Feature Pack 2 onwards.
The Internet Access Points Example v2.0 combines the functionality of the
previously released IAPConnect and ConnectionManager examples.
To use all the features of the example in S60 3rd Edition devices and later,
WriteDeviceData and NetworkControl capabilities are needed.
-------------------------------------------------------------------------------
PREREQUISITES
Symbian/C++ basics and Symbian OS key concepts.
--------------------------------------------------------------------------------
IMPORTANT FILES/CLASSES
src\IAPConnectEngine.cpp | The main engine class, handles opening
| and closing the connections and creating
| and removing IAPs.
src\IAPConnectProgressNotifier.cpp | A class that demonstrates how to observe
| the progress and state of an RConnection
| using TNifProgress and TNifProgressBuf.
src\IAPConnectView.cpp | The main view of the application.
src\IAPConnectConnInfoView.cpp | A view for displaying information about
| the currently active connection(s).
src\IAPConnectRemoveIapView.cpp | A view for removing IAPs.
src\demosrc\IAPConnectDemoEngine.cpp | The demo engine class for
| running the demo connection.
| Demonstrates how to open and
| close a socket connection
| and how to write to and read
| from the socket.
src\demosrc\IAPConnectDemoConnectionMonitor.cpp | A class that shows how to get
| information about a connection
| and its subconnections using
| RConnectionMonitor (uplink/
| downlink data, connection time).
src\demosrc\IAPConnectDemoDataNotification.cpp | Demonstrates how to get
| notifications from an
| RConnection when a certain
| amount of data has been sent
| or received.
src\demosrc\IAPConnectDemoSocketsReader.cpp | A class for reading from the
| socket in the demo connection.
src\demosrc\IAPConnectDemoSocketsWriter.cpp | A class for writing to the
| socket in the demo connection.
--------------------------------------------------------------------------------
KNOWN ISSUES
- Running this example in a device is preferred, since some of the features are
not available in the emulator environment (see the other known issues below).
- The commands "Connect" and "Connect (CSD)" might not work correctly on some
S60 2nd Edition emulators (the IAP selection prompt might fail to launch properly,
which results in "General error" in this example). For more information, see
CIAPConnectView::HandleCommandL(). The "Connect AP Handler" command should work
properly in all environments.
- Using a user-created IAP to establish a connection will not work, since the
hard-coded connection parameters are just example values.
- Editing the default access point in the emulator using "Connect (AP Handler)"
-> "Edit" is not possible (causes System Error -6: Access point is in use).
Editing a user-created IAP, however, is possible.
- To fully use all the features of this example application in an S60 3rd
Edition device, WriteDeviceData and NetworkControl capabilities are needed.
These capabilities cannot be used with a developer certificate. If you have
access to these capabilities, modify the following files:
group\IAPConnect_s60_3rd_ed.mmp
src\IAPConnectView.cpp
src\IAPConnectEngine.cpp
according to the instructions found in those files.
- The background of the CEikEdwin used in CIAPConnectView is not drawn properly
in S60 3rd Edition; the background should be grey instead of white.
--------------------------------------------------------------------------------
RUNNING THE EXAMPLE
The application is accessed through the Options menu. The following menu items
can be selected (depending on the application state and view):
1) Application state is "disconnected"
* Connect
A list of all the available access points is shown and the user can choose one.
After the selection is made, the application connects to the Internet using
the chosen access point, and the state of the application changes to
"connection open".
* Connect (PSD)
The same as Connect, but only access points using packet-switched data
are shown.
* Connect (CSD)
The same as Connect, but only access points using circuit-switched data
connections are shown.
* Connect (AP Handler)
Launches the access point handler dialog, which provides menu options to
select, edit, create, and delete access points.
2) Application state is "connection open"
* Connection Info
Displays information about the currently open connection(s). This view
provides menu options for running a simple demo connection and changing
the settings for the demo. After the demo connection has been started,
menu options for querying the following connection parameters will become
available: the number of bytes transferred uplink and downlink,
and the time the connection has been active (in minutes).
* Release
The application stops using the connection. If there are no other
applications using the connection, the system disconnects after the
inactivity timer triggers. Normally, this is how an application should
disconnect when it stops using the connection.
* Terminate
The application terminates the network interface immediately, regardless of
whether other applications are using it. Thus, in general, applications
should not use this option. However, in cases where it is necessary, user
confirmation must be given.
3) Menu items not dependent of the application state
* Create new IAP
Queries for the name of the IAP to be created and creates the IAP. Other
parameters than the name are hard coded for demonstration purposes.
* Remove IAP
Launches a list of currently available IAPs where the user can select the
IAP to be removed.
* Exit
Releases the connection and exits the application.
--------------------------------------------------------------------------------
BUILD & INSTALLATION INSTRUCTIONS
Steps for building and installing the application to a device depend on the S60
platform version:
--Mobile device (S60 3rd Edition)
Go to /InternetAccessPoints_Example_v2_0/group
bldmake bldfiles
abld build gcce urel
Go to /InternetAccessPoints_Example_v2_0/sis
Edit the IAPConnect_s60_3rd_ed_selfsigned.pkg's paths to match those on
your system.
makesis IAPConnect_s60_3rd_ed_selfsigned.pkg
Sign the SIS package:
- See the SDK Help for information about self-signed .sis packages, or
www.symbiansigned.com for information about Developer Certificates.
Install the signed .sis file to an S60 3rd Edition device.
- If you get a "Certificate error" during installation of a self-signed
package, check that App.Manager -> Settings -> Software Installation is
set to "All".
--Mobile device (S60 2nd Edition)
Go to /InternetAccessPoints_Example_v2_0/group
bldmake bldfiles
abld build thumb urel
Go to /InternetAccessPoints_Example_v2_0/sis
Edit the IAPConnect.pkg's paths to match those on your system.
makesis IAPConnect.pkg
Install the .sis file to your device
--Emulator (WINSCW)
Go to /InternetAccessPoints_Example_v2_0/group
bldmake bldfiles
abld build winscw udeb
Start the emulator
--Carbide.c++ IDE
1. Make sure that the path for the current Carbide workspace does not
contain any whitespace characters. If necessary, select a new workspace
folder in Carbide (File -> Switch workspace
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -