|
1 <?xml version="1.0" encoding="utf-8"?> |
|
2 <!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. --> |
|
3 <!-- This component and the accompanying materials are made available under the terms of the License |
|
4 "Eclipse Public License v1.0" which accompanies this distribution, |
|
5 and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". --> |
|
6 <!-- Initial Contributors: |
|
7 Nokia Corporation - initial contribution. |
|
8 Contributors: |
|
9 --> |
|
10 <!DOCTYPE concept |
|
11 PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd"> |
|
12 <concept id="GUID-35D49549-1F4D-583F-A45D-9B557A207DD2" xml:lang="en"><title>GlassTerm: |
|
13 glass teletype terminal</title><prolog><metadata><keywords/></metadata></prolog><conbody> |
|
14 <section><title>Download</title> <p>Click on the following link to download |
|
15 the example: <xref href="guid-6013a680-57f9-415b-8851-c4fa63356636/zips/guid-e132f025-ded6-4ae4-8a4d-dc50d344b55b.zip" scope="external">GlassTerm.zip</xref></p>Download some additional files required |
|
16 by the example: <xref href="guid-6013a680-57f9-415b-8851-c4fa63356636/zips/guid-16f2a07d-2ace-4a32-b383-6f1352dfd72e.zip" scope="external">CommonFiles</xref><p>Click: <xref href="guid-6013a680-57f9-415b-8851-c4fa63356636/guid-e132f025-ded6-4ae4-8a4d-dc50d344b55b.html" scope="peer">browse</xref> to view the example code. </p>View the additional |
|
17 files: <xref href="guid-6013a680-57f9-415b-8851-c4fa63356636/guid-16f2a07d-2ace-4a32-b383-6f1352dfd72e.html" scope="peer">browse</xref>. </section> |
|
18 <section><title>Description</title> <p>GlassTerm is a terminal application |
|
19 with configurable handshaking that illustrates the use of the Serial Communications |
|
20 API. </p> </section> |
|
21 <section><title>Class Summary</title><p><xref href="GUID-3B4E8ED5-72F7-3E51-B188-3C1045526DDF.dita"><apiname>RComm</apiname></xref>: serial port</p><p><xref href="GUID-6B3CA99B-ABF2-32EA-935D-23AE5AE2C306.dita"><apiname>RCommServ</apiname></xref>: |
|
22 Comms server</p><p><xref href="GUID-076DD315-CE3F-3640-BAB4-0FC51C906820.dita"><apiname>TCommCaps</apiname></xref>: serial port capabilities |
|
23 (in package buffer) </p><p><xref href="GUID-BF099B27-4E8A-3765-A6A8-DB88DB4F4F2E.dita"><apiname>TCommConfig</apiname></xref>: serial port configuration |
|
24 (in package buffer) </p><p><xref href="GUID-E0B34F3E-D4C4-3232-B8B1-7DB35B454646.dita"><apiname>TRequestStatus</apiname></xref>: asynchronous |
|
25 request status </p><p><xref href="GUID-A6E4627A-A3AE-3B64-9E5C-710EE15C5595.dita"><apiname>TSerialInfo</apiname></xref>: serial protocol information </p></section> |
|
26 <section><title>Build</title> <p>The source code for this example application |
|
27 can be found in the directory: </p> <p> <filepath>examples\SerialComms\ServerClientSide\GlassTerm</filepath> </p> <p>It |
|
28 may be in the directory in which you installed Symbian OS, or it may be in <filepath>src\common\developerlibrary\</filepath>. |
|
29 It includes the two project files needed for building: <filepath>bld.inf</filepath> and |
|
30 the <filepath>.mmp</filepath> file. </p> <p><xref href="GUID-3100800B-B2F7-50EF-BD4C-3C345ECCB2A5.dita">The |
|
31 Symbian OS build process</xref> describes how to build this application, which |
|
32 results in an executable called <filepath>\epoc32\release\<target>\<urel |
|
33 or udeb>\GLASSTERM.EXE</filepath>. </p> </section> |
|
34 <section><title>Usage</title> <ol id="GUID-1DB8E591-3818-51E6-BDE0-89FFE8B6F96A"> |
|
35 <li id="GUID-A399AF4D-E821-5341-9645-B7F0FA42B76A"><p>Run the executable <filepath>GLASSTERM.EXE</filepath>. </p> <p>Executables |
|
36 for the emulator targets <filepath>wins</filepath> and <filepath>winscw</filepath> can |
|
37 be run on your PC. Executables for ARM targets must be copied to your target |
|
38 platform before being run. </p> </li> |
|
39 <li id="GUID-BD9D8050-474C-5FD0-8485-08CED5D8AEEF"><p>Once running, the glass |
|
40 teletype application performs two simple functions: </p> <ul> |
|
41 <li id="GUID-3384ABA3-13A8-57F7-BE4F-7CC322BDA464"><p>Read any key presses |
|
42 and send the characters to the serial port. </p> </li> |
|
43 <li id="GUID-A44E9991-D87A-5E20-BC01-91454379BFF8"><p>Receive any incoming |
|
44 characters from the serial port and display them on screen. </p> </li> |
|
45 </ul> <p>It sends and receives at 19200 baud, 8 data bits, no parity, 1 stop |
|
46 bit. </p> </li> |
|
47 </ol> <p>In order to see the application working, you must make a suitable |
|
48 serial port connection. A simple way is to connect a PC and a Symbian OS phone, |
|
49 and run the application on both machines simultaneously. (Before doing this, |
|
50 make sure to close down any other applications using the serial port on the |
|
51 PC, and set the phone's <systemoutput>Link To Desktop</systemoutput> option |
|
52 to <systemoutput>Off</systemoutput>). Characters typed on one machine are |
|
53 then echoed to the application on the other. </p> </section> |
|
54 </conbody></concept> |