Symbian is an operating system developed by NOKAI's partnership, mainly for high-end smartphones. Its development language is C , you can use Microsoft Visual C 6.0 as an integrated development environment. It seems that although Symbian's goal is to be with Microsoft's Smartphone, it is not in touch with the means and methods, Microsoft is even secret. Who allowed the VC6 design to be open, and the result was taken by the enemy. This article is primarily for Symbian development, so it should be very simple, because after all, Symbian's development language is C , which is not complicated because it is used for mobile phone operating systems, just a lot of people have been hanging in mouth. The J2ME is also a Java language after all, and it will not be the same because it is used on the phone. 5 hours is all time I don't know if I don't know about Symbian. All the time on Symbian. Because it is used for mobile phone operating systems, we study Symbian, first select a mobile phone and say. NOKIA's 60-series platform is a very good choice. Nokia divides the mobile phone into multiple series according to the screen size and price of mobile phones. The 60 series currently have two mobile phones: 7650 and 3650.60 series use Symbian OS 6.1, then According to the characteristics of the mobile phone screen, some modifications have been made, this modified Symbian is called the NOKIA's 60-series platform. So the first step to get started is to download S60 SDK, you can download from Nokia's development forum: http://www.asia.forum.nokia.com/chinese/sch/main/series60.html. Looking at the latest in the Nokia website is 1.0, but there is a 0.9 Chinese version below, so it is natural to download this version 0.9. More than 100 megabytes, if you don't want it, you can have a CD with Nokia, and it is estimated that they should be very happy. This 0.9 Chinese version of the simulator is Chinese version, and there is a class that supports GBK and Unicode conversion, and I don't know if the English version of 1.0 is. Download is installed, choose a directory, but it is best to put on the C drive. It may be considering that the Windows platform and UNIX platform can be used, this SDK is relatively mentally wisdom when processing the drive letter and the directory, I at the time of the SDK to the C drive, my own program puts the D disk with VC6 to generate new projects. Question, observed is the problem of disk. Therefore, if the insurance is, it is best to put it on the C drive, interested in testing the Nokia. In addition, Java's runtime library and Perl are also taken, but the Perl of him has a problem with Perl, I downloaded a newest ActivePerL eventually installed. From the SDK installation, this is really less professional. Just said, my Symbian installed the C drive, in the Symbian directory of the C disk, there is a 6.1 directory, two directories in the 6.1 directory: Series60 and Shared. Fortunately, you can see the general meaning from the name. Please pay attention to the EPOC32 / build directory under the Series60 directory, because this directory is used repeatedly. The next task is to compile helloWorld and then run again. First, you have to confirm that your system is loaded with VC6 (it is best to install SP3 or more, otherwise you will be able to use VC6 when you use VC6), and
C: / program files / microsoft visual studio / vc98 / bin
Put it in your path, mainly with nmake.exe. So if you have nmake, you can also see HelloWorld. Find the directory of the HelloWord example, in me is c: /ssymbian/6.1/series60/series60ex/helloworld/group
In Symbian, a Project is usually organized according to the catalog of Inc, SRC, Group, and the project file is usually placed in the group directory, so it is necessary to come here when compiling. Use the command prompt mode to enter the directory just said, then execute
BLDMAKE BLDFILES
This command will generate an abld.bat batch file in the group directory and generate C: /Symbian/6.1/series60/epoc32/build/symbian/6.1 under c: /symbian/6.1/series60/epoc32/build / Series60 / series60ex / helloworld / group This deep directory and generates a bunch of .make files in the bottom of the directory. (I can't understand why I don't do it? Because they produce mobile phones?) Although it produces so many things, we don't work, continue to enter
Abld build Wins UDEB
This command compiles our programs, and finally
C: /symbian/6.1/series60/epoc32/Release/Wins/udeb
Generate our HelloWorld under the directory, then we can run the emulator's Debug version from the Start menu, and open the Other directory. You can run HelloWorld. If you want to compile and run HelloWorld in VC6, run the Abld Makefile VC6 after running BLDMAKE BLDFILES, the VC6 DSW file is generated, the location is
C: /ssymbian/6.1/series60/epoc32/build/symbian/6.1/series60 / series60ex / helloworld / group / helloworld / Wins
Look at Symbian so troublesome, it is not easy. If you want to create a new project directly in VC6,
C: /symbian/6.1/series60/series60tools
The files in the directory are copied to the template directory of VC6. Toss it here, you may have to spend more than 2 hours, and the rest of the two hours will look at the document. Let's take a look at the HelloWorld's help documentation to understand the architecture of the Symbian program. The Symbian program is also organized by the document view structure according to the VC. There is an Application class CaknApplication. There is a document CaknDocument. There is a frame Caknappui, there is a view class CCoecontrol, etc. The class seems to be made, I haven't seen this. Regarding the call relationship between these classes, there is a sequence diagram in the HelloWorld document very well, and I know it. When watching Symbian's code, it is most uncomfortable to see the Pushl and POP functions, and there are many functions of L or LC suffixes. In fact, this is the exceptional process mechanism of Symbian. For example, we define a pointer to assign space, but the program suddenly appears in the program suddenly aborted when using it, and the address space occupied by this pointer is definitely not returned, and this is programmed on the PC. It may be no problem, so much memory, but it is not used for more time, but Symbian's designer may think that this is not on the phone, so many design is made. Symbian has a Clean Up Stack, when using the pointer, press PUSHL to press the pointer into the stack, then use the POP pop-up, if you can cause the crash in the middle, then the Clean Up Stack can Recycling the space occupied by calling the destructor of the pointer. These may result in a function of crash in Symbian as a possible Leave function, so a L is added at the end of these functions. The function of the LC suffix indicates that the function has been pressed into the Clean Up Stack internally, and there is no need to use PUSHL when calling, and directly calls the complete POP. The Clean Up Stack also provides a popanddestroy function, which is to pop up the stack and then destroy the pointer. By the way, the official is formally because of the Clean Up Stack mechanism, Symbian seems to be less than the VC program, for example, many types of constructor are constructed, and the operator is assigned when the address is distributed. New () has also become New (Eleave). The above can take a look at the memory management section in the Symbian programming basis. Symbian defines a bunch of data types, if you don't want to find trouble, or use these types of these types. Simply put, the integer has Tint and Tuint, which is divided into 8-bit, 16-bit and 32-bit, such as Tint8, Tint16, Tint32; text type is TTEXT, which is ttext8 and ttext16, but inside It is Unicode, so internal reference should be TTEXT16; BOOL type is TBOOL, the corresponding value is Etrue and Efalse; floating point is TREAL, but it is divided into TREAL32 and TREAL64; there is a reference type TrefbyValue
The bottom is two abstract TDESC and TDES. In fact, TDES is also inherited TDESC, and C letters in TDESC are constant constant meaning. That is, it is a defined constant, which cannot be modified, without c, which can be modified, and the same is the same below. The pointer descriptor is TPTRC and TPTR, similar to the char * in C ; buffer descriptor is TBUFC and TBUF, similar to char []; heap descriptor is HBUFC, similar to (char *) malloc (Length 1) usage. In particular, the above type is divided into 8 bits and 16 bits. For example: TBUF <64> BUF; Ceikonenv :: Static () -> ReadResource (buf, r_example_view_title);
A buffer with a maximum length of 64 is defined first, and then read the resource named r_example_view_title. Another example:
Ttext8 * Str = (Ttext8 *) "Demonstration window title"; TPTRC8 Source (STR); Iinfotext = Hbufc :: newl (Source.Length ()); tptr16 ptr = Iinfotext-> des ();
Define an 8-bit string STR, then construct a pointer constant source, define a 16-bit pointer according to the Source length, and the next step is not written here, but it should be converted to Unicode for GBK. Symbian's resource files are generally named by RSS, without dedicated resource file editing, users must use Notepad to open the RSS file manually to write RSS files. This has certain rules and methods, and the reference example is not difficult to write your own resource files. It should be noted that if there is Chinese in the resource file, you must save the file as a UTF-8 format. It is relatively simple to get started, but it takes a lot of practice. ^ _ ^
Select the database developed mobile app
Transfer from: Yumi.com Time: October 18, 2003 22:59
First quarter introduction
Perhaps developing all networks and enterprise applications must do what must be done using the relational database management system (RDBMS) to effectively process and retrieve the operation of the table-based data. RDBMs has become the most popular database management system (eg Oracle 9i, MS SQL Server, and IBM DB2), and also includes the ability to directly encode application logic within the database in the form of stored procedures and flip-flops. Senior databases such as Oracle 9i and Sybase Adaptive Server Enterprise Edition even include functions of running Java virtual machines in a Java stored procedure or servlet database of operational data.
Enterprise-class database products for these industrial applications can use universal SQL language access data and query using standardized database application interfaces such as ODBC or JDBC. These technologies have evolved to any IT project regardless of size, leaving the relational database will not work. In the face of product managers and users, the company's "moving" request, however, the business application developer is scared is that the database access mechanism of the mobile platform is not yet mature.
A platform like Palm OS and WINDOW CE supports a local file system for storage data in a list format; however, these file systems are actually a very simple system and cannot be queried by SQL. This enables developers to manually encode each custom data storage and retrieval solution.
I should also mention that the database application interface of the mobile platform system is clearly different, and you also need to write your own data synchronization code to ensure that the content edited on the handheld device can return to the enterprise database. Section 2 Mobile Database Application Development Technology
By default, data synchronization on the PDA platform is processed by using a pipe written by developers. When a PALM user presses the SYNC button, the pipe software (DLL or COM object resides in the user system) accesses the Palm system database and retrieves one or more specified tables. If necessary, this action can use an ODBC / JDBC to insert or update a business relational database. If there is no other task, this action is quite simple.
Palm even provides Conduit SDK for Java, COM, and C / C developers. However, if the bad boss also allows your app to be supported by Windows CE and supported by laptop, what should we do? This may result in three database modules (JDBC / ODBC / ADO, PALM OS in the laptop) and the AdoCe in Windows CE and three synchronization solutions (from laptop to the server) TCP / IP socket, from Palm to Conduit's HotSync, and Microsoft ActiveSync from Wince Devices to Conduit.
Don't be afraid, it has existed it in compliance with the mobile relationship database we need! In fact, with the continuous improvement of the version, the functions of these mobile databases are getting more powerful. There are many database systems that can be used on multiple platforms, which can use popular programming languages such as C / C , Java, and Visual Basic, and server-side data merge and synchronization. In this article, we will explore three popular database products that provide multi-operation platforms and programming language support.
Section 3 Sybase SQL Anywhere / UltraLite
The current mobile database market leader (more than 60% market share) is Sybase's SQL Anywhere product. The initial version of this product is to position the Sybase database (now named Adaptive Server Enterprise) that needs to synchronize the support server version (now named Adaptive Server Enterprise). After a few years, this product has slowly includes a miniature relational database, commonly referred to as UltraLite, can be configured on a variety of platforms and supporting many synchronization options. Although the SQL Anywhere database is a powerful SQL database, including security and high-end database functions such as stored procedures and triggers, you may be more interested in UltraLite if you are configuring an application on multiple mobile platforms. UltraLite is now available for Windows 95/98 / NT, Palm OS, Windows CE, and EPOC. Its application interface can be used in C / C and Java program, and these application interface remain unchanged on all supported platforms.
The UltraLite database is designed to be designed for devices that do not have hard drives, which means that this database has been optimized in the memory usage, even if the minimum memory can be used. Provide the highest performance. Another powerful feature included in SQL Anywhere is MobiLink synchronization technology. MobiLink is a server-based synchronization engine that can communicate with remote customers via serial port, TCP / IP, HTTP, HotSync, ScoutSync, or ActiveSync. Using universal synchronization techniques such as MobiLink can greatly reduce development costs because MobiLink can handle advanced synchronization operations, such as spnapshot and timestamp synchronization, primary key maintenance, conflict detection and solution. At the server side, all MobiLink synchronization logic is processed by using the SQL event of the background database (MobiLink Connecting the Database through the ODBC, so in fact support all SQL databases), support the public key by using the Certicom's SSL / TLS Plus Encryption function (using an elliptic curve encryption system technology). If you consider the time that you may happen before writing an application, the SQL Anywhere / UltraLite combination will be an extremely powerful mobile database and synchronous solution to meet any task. Section 4 Oracle 8i Lite
Although Sybase may have attracted mobile computing technology market space, we can't deny the important role in Oracle in the world's database. Like Sybase's respective products, Oracle 8i Lite products can be used in all major mobile platforms (Win32, Windows CE, Palm OS, and EPOC) and in some places have exceeded Sybase UltraLite. 8i Lite contains a complete ability to synchronize with the background Oracle database; however, this product does not stop this. It also includes Windows CE and WIN32 ODBC clients and C / C / Java / ActiveX application interface support. Different features of this product may be more interest: Oracle Mobile Agent and Web-to-GO:
· Oracle Mobile Agents The original market is positioned in standalone wireless middleware products, but in 1999, it was included in the 8i Lite product. Mobile Agents is a communication solution that allows Oracle 8i Lite applications to perform wireless synchronization operations over the network, which have CDPD (AT & T Wireless), MOBITEX (CINGULAR WIRELESS) and Datatac 4000/5000 (Motient). Oracle Mobile Agents handles information by using the application queue. This queue is also integrated with the background Oracle database that runs the Oracle Advanced Queuing option and an AQ Lite product consolidation of 8i Lite.
· Web-to-go is both data synchronization and an application deployment solution. Building a general network development technique such as: Apache and Java servlets, web-to-go allows a network application (for Win32 platform) to be archived within the server and then configured to the client in synchronization. Web-To-Go is a very powerful mobile solution for the development of database logic through Java stored procedures or JDBCs and for web applications built in existing Java Servlets.
I believe that the market is now less confusing for the products provided by Oracle, because the various parts of 8i Lite have been listed (Web-To-Go, Oracle Mobile Agents, Oracle Lite, etc.). In addition, Oracle's own OracleMobile solution is positioned only for wireless applications such as: WAP, SMS, and VoiceXML, which can also be attracted from 8i Lite to a lot of attention. However, for those who develop industrial strength, 8i Lite is a database, synchronized, middleware, and application deployment technology. Section 5 PointBase 4.0 Pocket Edition
Companies such as IBM (DB2 Everywhere) and Microsoft have also developed mobile database systems for multiple platforms, which are very powerful, developers working using DB2 or SQL Server databases will also Familiar with these database products. But in addition, I also want to introduce a new army to enter the enterprise database market: PointBase.
PointBase is very unique because it is the first 100% pure Java database that can be used in any platform for any Java 2 Standard Edition Virtual Machine (JVM). At the June 2001 JAVaone meeting, PointBase released the PointBase Pocket Edition product - a less resource (less than 45KB) database designed for J2SE and J2ME environments. If your target platform contains a virtual machine compatible with J2ME, PointBase allows you to deploy a SQL database application. J2ME MIDP Virtual Machines are currently available in Win32, Palm OS, Windows CE and Motorola Iden calls.