Lattice pen data processing method based on local database
By adopting the local database-based dot-matrix pen data processing method in the APP, the problems of low data processing efficiency and poor user experience in the APP application are solved, and higher fluency, flexibility and fault tolerance are achieved.
Patent Information
- Application Number
- CN202411678107.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-22
- Publication Date
- 2025-03-07
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The existing mass-produced dot matrix pens have problems such as low data processing efficiency and poor user experience in APP applications due to the problems of too small chip storage and too slow synchronous handwriting.
The dot matrix pen data processing method based on local database is adopted, and the data transmission of dot matrix pen is received and stored through the local database, and the data is directly synchronized to the cloud remote database, and data display is performed in the APP, reducing the dependence on remote databases.
It improves the fluency and user experience of the APP, enhances the flexibility, robustness and security of the program, unenforced binding of hardware data and remote data, and improves the fault tolerance of the APP in case of downtime and no network.
Smart Images

Figure CN119577030A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the fields of APP software, Internet of Things and the Internet, and in particular to a dot matrix pen data processing method based on a local database. Background Art
[0002] A dot matrix digital pen is a kind of digital pen that prints an invisible dot pattern on ordinary paper. The high-speed camera on the front end of the digital pen captures the movement trajectory of the pen tip at any time. At the same time, the pressure sensor transmits the pressure data back to the data processor, and finally transmits the information to the APP via Bluetooth. The dot matrix pen mainly collects handwriting data. The data is a data list composed of the X-coordinate and Y-coordinate of the point and the page number.
[0003] An important feature of dot pens is that they work without actual ink, which means anything written with a dot pen can be easily edited, saved or shared. In addition, many dot pens also support pressure sensitivity, which can adjust the thickness and depth of the line according to the amount of pressure applied by the user, thus achieving a more natural and rich expression effect.
[0004] Dot pens are widely used in applications, especially in software that requires fine hand-drawn input, signature authentication, note taking, etc. The following are some specific application scenarios:
[0005] Educational software: In online education platforms and learning applications, dot pens make it easier for students and teachers to write, draw, and mark. For example, in math class, teachers can use dot pens to draw complex formulas or geometric figures on electronic whiteboards; students can also use it to complete homework and write answers directly on tablets.
[0006] Design and creative tools: For designers, illustrators and artists, dot pen is one of the indispensable tools. Professional drawing software such as Adobe Illustrator, Photoshop, etc. support dot pen input, allowing users to create with extremely high precision and flexibility. These software usually also provide pressure sensing function to make the work more vivid and realistic.
[0007] Office document processing: In some document processing software, such as the Microsoft Office suite, users can use a dot pen to add annotations to PDF files, sign contracts, or fill out forms, greatly improving work efficiency and convenience.
[0008] Note-taking applications: Note-taking applications such as Evernote and OneNote allow users to use a dot pen to record meeting points, class notes, or flashes of inspiration. Such applications usually provide a variety of pen styles and colors, as well as powerful search functions to help users better organize and review information.
[0009] Healthcare: In the medical industry, doctors and nurses can use dot matrix pens to quickly and accurately record patients' condition changes, treatment plans, and other information in the electronic medical record system. They can also draw anatomical diagrams or surgical planning diagrams to improve communication efficiency.
[0010] Signature verification service: Some banks and financial institutions may provide mobile applications that integrate dot-pen signature functions for identity verification or transaction confirmation. In this case, the dot-pen can capture the unique characteristics of the signature, providing users with a safe and reliable means of authentication.
[0011] In short, with the development of technology, the application areas of dot pens are constantly expanding, bringing users more diverse interactive experiences, especially APP applications. However, due to price and other reasons, the dot pens currently produced in the market generally have problems such as small chip storage and slow handwriting synchronization. It is particularly important to solve these problems between dot pens and APPs. Summary of the invention
[0012] In order to solve the above technical problems, the present invention provides a dot matrix pen data processing method based on a local database.
[0013] The technical solution of the present invention is:
[0014] A dot matrix pen data processing method based on a local database receives data transmission from a dot matrix pen in the form of a local database, the local database directly synchronizes with a cloud remote database, and an APP directly obtains data from the local database for display, thereby increasing the fluency of the APP and improving the flexibility, robustness and security of program operation.
[0015] The present invention stores the real-time and offline data of the dot matrix pen locally in the APP based on the local database method such as sqlite, which can continuously release the storage capacity of the dot matrix pen memory and improve the adaptability of the APP to the hardware; when the dot matrix pen is writing, it directly synchronizes data with the local database, improves the synchronization loading speed when the dot matrix pen is writing, and also improves the user experience. The APP local database releases the mandatory binding of hardware data and remote data. In the case of downtime and no network, the APP can normally use the synchronization handwriting function of the dot matrix pen, making the APP more fault-tolerant.
[0016] When the App obtains note data for display, it directly obtains it from the local database through SQL statements, which makes data acquisition seamless and at least twice as fast as before. The user experience is improved because there is no need to obtain data from the remote database through an interface. The synchronization of data between the local database and the remote database is also performed silently in the background. The background silent synchronization does not affect the user's operation, which increases the fluency of the App.
[0017] Data acquisition does not have to rely on remote databases, making the system more flexible.
[0018] If you encounter extreme situations and the remote server is inaccessible, the dot pen will be synchronized to the local database via Bluetooth as usual, and the APP will obtain the note data normally. Data acquisition does not have to rely on the remote database. After the system remote server returns to normal, the local data will synchronize the incremental data during the downtime to the remote database, making the APP more flexible.
[0019] The data processing method of the dot matrix pen in the APP is based on the local database, which removes the mandatory binding of hardware data and remote data. In the event of a crash or no network, the APP can use the synchronous note-taking function of the dot matrix pen normally, making the APP more fault-tolerant.
[0020] The APP local database expands the memory of the dot pen to a certain extent and reduces the storage limit of the dot pen chip. The data storage size of the dot pen chip on the market is generally 4M, and there is a common storage bottleneck. Before uploading to the cloud storage, the local database in the APP can synchronize the offline data in the dot pen in time, releasing the storage in the dot pen and making the APP more adaptable to the hardware devices of the dot pen.
[0021] The beneficial effects of the present invention are
[0022] (1) The dot pen data is processed in the APP based on the local database. The APP directly obtains data from the local database for display. The data acquisition speed is fast, making the APP more fluent.
[0023] (ii) The dot pen data is processed in the APP based on the local database. The APP data acquisition and display do not have to rely on remote databases and networks, making the program more flexible.
[0024] (III) The main feature of the data processing method of the dot matrix pen in the APP based on the local database is to release the mandatory binding of hardware data and remote data. In the case of downtime or no network, the APP can normally use the synchronous note-taking function of the dot matrix pen, making the APP more fault-tolerant.
[0025] (iv) The data of the dot matrix pen is processed in the APP based on the local database. The APP local database expands the memory of the dot matrix pen, reduces the impact of the storage limitation of the dot matrix pen chip, and makes the APP more adaptable to the hardware device of the dot matrix pen. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] Figure 1 It is a schematic diagram of the business architecture work of the present invention. DETAILED DESCRIPTION
[0027] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments in the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.
[0028] The data storage device of the dot matrix pen is currently limited in size, generally at 4M, which means that offline data can store up to 4M of data. There is a storage bottleneck problem. Timely synchronization of online and offline data is very important for continuously releasing the storage capacity of the dot matrix pen memory. If it is released directly to the cloud server, real-time synchronization will continuously put pressure on the server. In the event of downtime and network problems, the hardware data cannot synchronize the note data to the cloud client normally. Because the dot matrix pen's data storage device has storage limitations, there is an overflow problem in data storage, and the corresponding data will be lost. Dot matrix pen data processing based on the local database can effectively solve the above problems.
[0029] Based on the local database method such as sqlite, the real-time and offline data of the dot matrix pen are stored locally in the APP, which can continuously release the storage capacity of the dot matrix pen memory and improve the adaptability of the APP to the hardware; when the dot matrix pen is writing, it directly synchronizes data with the local database, which improves the synchronization loading speed when the dot matrix pen is writing, and also improves the user experience. The APP local database releases the mandatory binding of hardware data and remote data. In the case of downtime and no network, the APP can normally use the dot matrix pen's synchronization handwriting function, making the APP more fault-tolerant.
[0030] like Figure 1 The dot pen synchronizes data to the APP data for page display. According to the real-time nature of the synchronization, there are two synchronization methods: offline data synchronization and real-time data synchronization.
[0031] Offline data synchronization: When using the dot matrix pen to write on paper, the APP is not started or is not connected to Bluetooth or WIFI normally, that is, the dot matrix pen is not connected to the APP, the dot matrix pen will temporarily store the offline data in the data storage device. After the offline data is stored inside the dot matrix pen, the APP is started again. When the Bluetooth is connected to recognize the dot matrix pen, the user is reminded to synchronize the offline data. After clicking "Agree", the offline data in the dot matrix pen can be stored in pages, that is, each page of data is stored as a single data in the table and saved in the locally created database table. A single data has a column specifically for storing the point set of the page, that is, the (X, Y) coordinate set, which is the coordinate set of all tracks written on the page.
[0032] Real-time data synchronization: When the dot matrix pen is normally connected to the APP via Bluetooth, when writing on paper with dot matrix code, the dot information will be transmitted to the APP via Bluetooth. The APP finds the data in the local data table through the page number of each track point and updates the point set of the corresponding page. The update of the point set is generally the addition of points. Deletion and modification will not occur, because the current dot matrix pens are ballpoint pens. No matter how you write or draw, even if you keep drawing back and forth in the original position, the point will be re-added by 3 positions. Of course, the element data of the point also includes the time when the point was written.
[0033] Page number data: The data in the local database is stored in units of page numbers. Each page of data corresponds to a piece of data in the data table, which corresponds one-to-one to the page number of the paper. The writing track on the paper is actually a collection of points. Through the dot matrix pen, we can obtain the coordinates of the point and the page number of the point.
[0034] Business attributes: add some business attributes, such as the creation time and update time of the data, user ID, notebook ID, page ID, etc.
[0035] in,
[0036] User ID: Used to increase the privacy of notes or test papers. Users who log in to the APP can only see their own synchronized notes.
[0037] Notebook ID: Generally, a shop code can generate many identical notebooks. When notebook A is used up, a new notebook B is updated. When the notebook is replaced, the local database will automatically generate the ID of notebook B to distinguish the notebooks with the same shop code.
[0038] Page ID: The page ID is different from the page number. A corresponding page ID is generated for each page.
[0039] Update and creation time: used to compare updates with cloud data. The update time is used as the comparison item. If the update time of the local database is later than that of the cloud database, the data inserted during the period between the local database and the cloud database will be uploaded. If the update time of the local database is earlier than that of the cloud database, the cloud data will be pulled based on the time difference between the local database and the cloud database to synchronize the data on both ends.
[0040] Data synchronization mechanism: divided into three situations: normal synchronization, uninstall synchronization, and offline synchronization.
[0041] When the APP is used normally, the dot matrix pen is directly synchronized to the APP for data display, and the data synchronized by the pen is synchronized to the local database at the same time.
[0042] If the APP is uninstalled and reinstalled and the cloud database data has been synchronized before, the data will be downloaded from the cloud database to the local database first, and then the APP will obtain the data from the local database for display.
[0043] When the APP is closed, after the dot matrix pen writes in an offline state, that is, when the offline data needs to be processed, when the APP is restarted and connected to the dot matrix pen, the offline data will be synchronized to the local database as soon as possible, and the local database will be synchronized to the cloud database in the form of update time field increments.
[0044] The above description is only a preferred embodiment of the present invention, which is only used to illustrate the technical solution of the present invention, and is not used to limit the protection scope of the present invention. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention are included in the protection scope of the present invention.
Claims
1. A dot pen data processing method based on a local database, characterized in that: The data transmission of the dot matrix pen is received in the form of a local database, the local database directly synchronizes with the cloud remote database, and the APP directly obtains data from the local database for display.
2. The method according to claim 1, characterized in that When the App obtains note data for display, it directly obtains it from the local database through SQL statements, and the data is obtained seamlessly. The synchronization of data between the local database and the remote database is also performed silently in the background, and the user's operation is not affected during the background silent synchronization.
3. The method according to claim 2, characterized in that If the remote server is not accessible, the dot pen will be synchronized to the local database via Bluetooth, and the APP will obtain the note data normally. After the system remote server returns to normal, the local data will synchronize the incremental data during the downtime to the remote database.
4. The method according to claim 3, characterized in that: The dot pen synchronizes data to the APP data for page display. According to the real-time nature of the synchronization, there are two synchronization methods: offline data synchronization and real-time data synchronization.
5. The method according to claim 4, characterized in that Offline data synchronization: When using the dot matrix pen to write on paper, if the APP is not started or is not connected to Bluetooth or WIFI normally, that is, the dot matrix pen is not connected to the APP, the dot matrix pen will temporarily store the offline data in the data storage device. After the offline data is stored inside the dot matrix pen, the APP is started again, and when the Bluetooth is connected to recognize the dot matrix pen, the user is reminded to synchronize the offline data; After agreeing, the offline data in the dot matrix pen can be stored in units of pages, that is, each page of data is stored as a single piece of data in the table and saved in the locally created database table.
6. The method according to claim 5, characterized in that A single piece of data has a column dedicated to storing the point set of the page, that is, the (X, Y) coordinate set, which is the coordinate set of all tracks written on the page.
7. The method according to claim 4, characterized in that Real-time data synchronization: When the dot matrix pen is connected to the APP via Bluetooth, when writing on paper with dot matrix code, the dot information will be transmitted to the APP via Bluetooth. The APP finds the data in the local data table through the page number of each track point and updates the point set of the corresponding page.
8. The method according to claim 4, characterized in that The data in the local database is stored in units of page numbers. Each page of data corresponds to a piece of data in the data table, which corresponds one-to-one to the page number of the coded paper. The writing track on the paper is a collection track of points, and the coordinates of the point and the page number of the point are obtained through the dot matrix pen.
9. The method according to claim 4, characterized in that Add the creation time and update time of a piece of data, user ID, notebook ID, and page ID; among them, User ID: used to increase the privacy of notes or test papers. Users who log in to the APP can only see their own synchronized notes; Notebook ID: The shop code generates several identical notebooks. When notebook A is used up, a new notebook B is updated. When the notebook is replaced, the local database automatically generates the ID of notebook B to distinguish the notebooks with the same shop code; Page ID: The page ID is different from the page number. A corresponding page ID is also generated for each page. Update and creation time: used to compare updates with cloud data. The update time is used as the comparison item. If the update time of the local database is later than that of the cloud database, the data inserted during the period between the local database and the cloud database will be uploaded. If the update time of the local database is earlier than that of the cloud database, the cloud data will be pulled based on the time difference between the local database and the cloud database to synchronize the data on both ends.
10. The method according to claim 1, 2 or 3, characterized in that: Data synchronization is divided into three types: normal synchronization, uninstall synchronization, and offline synchronization. 1): When the APP is used normally, the dot matrix pen is directly synchronized to the APP for data display, and the data synchronized by the pen is synchronized to the local database at the same time; 2): If the APP is uninstalled and reinstalled and the cloud database data has been synchronized before, the data is first downloaded from the cloud database to the local database, and then the APP obtains the data from the local database for display: 3): When the APP is closed, after the dot matrix pen writes in an offline state, that is, when the offline data needs to be processed, when the APP is restarted and connected to the dot matrix pen, the offline data will be synchronized to the local database as soon as possible, and the local database will be synchronized to the cloud database in the form of update time field increments.
Citation Information
Patent Citations
Synchronous display and data electronization system based on intelligent writing and implementation method
CN110928507A
Data synchronization method, interactive electronic whiteboard and server
CN111262920A
Note synchronization method and device
CN113239004A
Control method and system for intelligent pen based on cloud computing, intelligent pen and storage medium
CN118689327A