Embodiment
By reference to the accompanying drawings the present invention is described in further detail below by embodiment.
Intelligent transportation field, the concrete Organization Chart of existing hand-held set Android operating system as shown in Figure 1, be divided into and drive layer, system layer and application layer, wherein, drive layer to comprise driver module, webcam driver module, bluetooth driver module, USB driver module, Keyboard drive module, WIFI driver module, power management module and touch pad driver module etc.; When system layer comprises application architecture, function library and Android operation, application architecture comprises system process manager, window manager, content manager, view system, notification manager, software package manager, telephone supervisor, explorer, location manager and can expanding communication protocol service etc., function library comprises interface manager, media framework, database engine, 3D graphics engine, font engine, browser engine, safe socket character protocol and standard C system library etc., comprises core letter formula storehouse and Android virtual machine when Android operation; Application layer comprises homepage, contact person, telephone directory and browser etc., in Fig. 1, all functions module of each layer in existing hand-held set operating system framework is not listed, and only lists above-mentioned mainly for reference.
The Android operating system of existing hand-held set generally all has open operating platform, its operator relates to polytype, such as: production firm, owner, operator, issuing working personnel and other general operation persons are in addition as domestic consumer etc., and all operators who relates to possess the authority of directly installing or deleting software in the Android of hand-held set operating system, and possess hand-held set all functions are arranged arbitrarily or the authority of additions and deletions.
Given this, on the one hand, consider under some specific use scenes, do not need all functions of opening hand-held set operating system to general operation person (such as communication function, phonebook function, SMS etc.); On the other hand, in view of there is the hidden danger that affects the professional application performance of hand-held set own in wide-open hand-held set Android operating system in prior art, the invention provides a kind of hand-held set operating system of switching according to pre-defined rule between user EXEC and superuser mode, with the open different operating right of the operator for different.
In hand-held set Android operating system of the present invention, be provided with at least two kinds of user models:
1, superuser mode: there are all authorities, there are the rights of using of the setting of all operations system and all application programs.
2, user EXEC: the application program that can use superuser mode mandate to allow, can not change system arranges or mounting software etc.
The all authorities of user EXEC all can be controlled setting by superuser mode, operating system setting and the application program that can move etc. that can use such as user EXEC, all can control setting by superuser mode, this control is set can be at interface operation, also can be by the restriction of operating system internal profile be set, as enter after superuser mode, in the setting option of operating system, setting of many increases is application permission setting options, operator can select which application or which function to be used by user EXEC or restriction etc.When the restriction of operating system internal profile is set, can be in the time that hand-held set dispatches from the factory in batches carry out product customization and modification, and do not need every hand-held set to do setting and the adjustment of repetition.By the design of such hybrid user pattern, can make hand-held set use more stable, convenient flexible.Conventionally, general operator can only enter user EXEC according to pre-defined rule, in needs, only enters superuser mode according to pre-defined rule, just can carry out the setting of operating system or the additions and deletions of function etc.Wherein, under user EXEC, various services or the setting in system layer, set, application layer can only conduct interviews or use and can not change, and has guaranteed the validity of its high priority and functional limitations.
Embodiment mono-
Refer to Fig. 2, this preferred embodiment provides a kind of hand-held set operating system method, the operating system of this preferred embodiment has increased User Status application module and User Status monitoring modular in the framework of prior art operating system, wherein, User Status application module belongs to application layer, User Status monitoring modular belongs to system layer, is arranged in application architecture.Operating system method in the present embodiment comprises the steps:
Monitor step: User Status monitoring modular is monitored the state value of power management module, and the concurrent state value of power management module that send is to User Status application module;
Switch step: User Status application module is according to the state value of the power management module receiving, with the switching between pre-defined rule control different user pattern.Be preferably with pre-defined rule control user model and switch between user EXEC and superuser mode.
Operator enters after superuser mode according to pre-defined rule, utilizes super authority to carry out special software installation or hand-held set function setting; And for general operation person, owing to not needing open operation system all functions, such as communication function, phonebook function, SMS etc., can only enter user EXEC according to pre-defined rule, enter after user EXEC, cannot carry out the setting of hand-held set function and delete operation, avoiding the unlatching of unnecessary software installation and function to impact hand-held machine operation system performance.
Embodiment bis-
This preferred embodiment provides another kind of hand-held set operating system method, and the operating system method in the present embodiment comprises the steps:
Monitor step: User Status monitoring modular is monitored the state value of power management module, and the state value that sends the power management module listening to is to User Status application module.
Switch step in embodiment mono-relatively, in the present embodiment, switch step specifically comprises:
Enter user EXEC sub-step: be converted to open state value if User Status monitoring modular is monitored power management module by off-mode value, User Status application module, by user's modular converter, is controlled user model and entered user EXEC;
Conversion sub-step: be converted to by screen lock state value the state value of spreading its tail if User Status monitoring modular is monitored power management module, User Status application module, by user's modular converter, is controlled user model and entered superuser mode.
Wherein, preferably, in above-mentioned monitoring step, when User Status monitoring modular is monitored the state value of power management module, also monitor the state value of touch pad driver module, and the state value that sends in real time touch pad driver module is to User Status application module, now, conversion sub-step is specially:
Identifying code detects: if power management module is converted to by screen lock state value the state value of spreading its tail, and touch pad driver module is converted to input state value by idle-mode value, User Status monitoring modular detects the identifying code of touch pad driver module input, sends identifying code to User Status application module; During identifying code detects, if power management module is converted to by screen lock state value the state value of spreading its tail, but User Status monitoring modular is monitored touch pad driver module and is inputted without identifying code in idle-mode value within a predetermined period of time always, User Status application module, accordingly by user's modular converter, is controlled user model and is entered user EXEC.
Enter superuser mode: if User Status application module judges authentication code matches, by user's modular converter, control user model and enter superuser mode; Otherwise, if the identifying code that the judgement of User Status application module is repeatedly inputted does not mate, by user's modular converter, control user model and enter user EXEC.
Further, monitor in step: User Status monitoring modular is also monitored the state value of driver module simultaneously, and the state value that sends in real time driver module is to User Status application module; Now, after switch step, also comprise step display: be without show state value if User Status monitoring modular is monitored the state value of driver module, by user interface control module, User Status application module control driver module is according to above-mentioned interface display of carrying out corresponding user EXEC or superuser mode, or presents identifying code input frame; If the state value of driver module is show state value, User Status application module is switched to user EXEC or superuser mode by user interface control module controls driver module by display interface, or presenting identifying code input frame, handled easily person carries out corresponding function operation like this.
Please refer to Fig. 2 and 3, in the preferred embodiment, in the system layer of hand-held set operating system, increase User Status monitoring modular, in application layer, increase User Status application module.The major function of User Status monitoring modular is: detect the state value that drives driver module, power management module and touch pad driver module in layer, and the state value of uploading in real time these three modules is to User Status application module, so that User Status application module judges accurately the state of current hand-held set operating system and provides correct response or demonstration etc. according to state value according to state value, the major function of User Status application module is: the state value detecting according to User Status monitoring modular, according to pre-defined rule, carry out the switching of user model by user's modular converter, and control user interface control module and carry out demonstration or the cancellation etc. of respective user mode interface, in this preferred embodiment, the pre-defined rule of indication preferably includes: be converted to open state value if User Status monitoring modular is monitored power management module by off-mode value, User Status application module is by user's modular converter, control user model and enter user EXEC, and/or, if User Status monitoring modular is monitored power management module and is converted to by screen lock state value the state value of spreading its tail, User Status application module is by user's modular converter, control user model and enter superuser mode, in the time of user EXEC and superuser mode switching, after preferably detecting coupling according to the identifying code of above-mentioned elaboration, can enter superuser mode, otherwise, identifying code does not mate or inputs without identifying code, enter user EXEC.These newly-increased two modules make the switching of user model belong to the overall situation control of whole hand-held set operating system.
Wherein, the state value of driver module comprises show state value, without show state value and dormant state value, the state value of power management module comprises open state value, off-mode value, screen lock state value and the state value of spreading its tail, the state value of touch pad driver module comprises input state value and idle-mode value, the state value that can identify for application program that User Status monitoring modular transmits to User Status application module, and the transmission of these corresponding states values is all to transmit in real time, object is to provide in real time state value to make a decision use to User Status application module according to pre-defined rule, User Status application module is in the time receiving the state value that User Status monitoring modular uploads, respond, response comprises the switching of user model and controls user interface control module and carry out demonstration or the cancellation of respective user mode interface, and demonstration or the cancellation etc. of identifying code input frame.
In the preferred embodiment, user model handoff functionality loads as a service processes of operating system, a rather than common application program, be that superuser mode or user EXEC all can not be closed this process, each process loads flow process and please refer to Fig. 4 in when hand-held set operating system.
In the preferred embodiment, first introduce the linkage process of User Status monitoring modular, User Status application module and driver module, power management module and touch pad driver module according to foregoing description.
When hand-held set operating system initialization, User Status monitoring modular starts snoop-operations system state value, comprise whether screen locking, whether show and whether input etc., at this moment just need to obtain state value by these three driver modules of power management module, driver module and touch pad driver module.How to obtain as for power management module, driver module and touch pad driver module etc. the functional characteristic that these state values belong to driver itself, or may be different according to different hardware realization mechanisms.
When power management module is converted to by screen lock state value the state value of spreading its tail, while being screen locking recovery, User Status monitoring modular just detects the state value of power management module in real time, now User Status monitoring modular just can be uploaded this state value with notice User Status application module, also can continue to understand by real-time detection touch pad driver module user's input condition simultaneously, it is User Status application module that input also can pass to upper level applications by touch pad driver module through active user's interface control module certainly, whether switched according to the user model of pre-defined rule final decision system by User Status application module etc., after switching, carry out the interface display of respective user pattern without the driver module showing, while having demonstration, driver module is by the control of user interface control module responds User Status application module, carry out the switching of corresponding display interface.
After leaving unused, operating system a period of time of hand-held set closes screen display, be that power management module is in screen lock state value, and driver module is in dormant state value, User Status monitoring modular also can gather corresponding states value and notify User Status application module.
In the hand-held set operating system course of work, the interlock implementation procedure of each module is specific as follows, please refer to Fig. 5:
First, when hand-held set os starting, acquiescence starts this User Status monitoring modular process, and no matter, under which kind of user model, the background service process of this User Status monitoring modular all can not be closed, and has guaranteed the validity that it is lasting.
After starting, User Status monitoring modular detects the state value of power management module, driver module and these three driver modules of touch pad driver module, when hand-held set start, the state value that User Status monitoring modular detects power management module changes open state value into by off-mode value, and User Status application module control user modular converter makes hand-held set operating system acquiescence enter user EXEC.
Enter after user EXEC, after operating system a period of time of hand-held set is idle or the switch key of hand-held set be pressed, hand-held set enters screen lock state, if again press the switch key of hand-held set, the state value that User Status monitoring modular just can detect power management module changes by screen lock state value the state value of spreading its tail into, and transmit in real time this state value to User Status application module, with invoke user state application module, User Status application module is by controlling user interface control module controls driver module interface switching, identifying code input frame just presents, operator is input validation code in identifying code input frame, now, if detecting touch pad driver module, User Status monitoring modular changes input state value into by idle-mode value, User Status monitoring modular detects the identifying code of touch pad driver module input, and send this identifying code to User Status application module and carry out identifying code checking, if User Status application module judges authentication code matches, by user's modular converter, control user model and be transformed into superuser mode by user EXEC, otherwise, if the User Status application module judgement repeatedly identifying code of input is not mated, by user's modular converter, control user model and again enter user EXEC, or, when operator presses the switch key of hand-held set again, make the state value of power management module be converted to and spread its tail after state value by screen lock state value, there is not within a predetermined period of time input action, now, User Status monitoring modular detects touch pad driver module and inputs without identifying code in idle-mode value within a predetermined period of time always, User Status application module is by user's modular converter, control user model and again enter user EXEC.
Enter after superuser mode, in the setting option of operating system, relatively user EXEC increases by one to set is application permission setting options, and operator can select which application or which function to be used by user EXEC or restriction etc.
In hand-held set operating system process, User Status monitoring modular service processes continues the state value of corresponding each functional module in Monitor detection driving layer, trigger User Status application module according to state value, user model is switched between user EXEC and superuser mode, enter after user EXEC, the application permission setting options in the setting option in operating system also can be closed thereupon.
In the preferred embodiment, the operating system that after hand-held set os starting, acquiescence enters is user EXEC, and this pattern has been accomplished transparent processing to domestic consumer.After the each dormancy screen locking of hand-held set operating system, spreading its tail is all the change-over switch of a user model again, now user interface control module is pointed out and can be entered superuser mode by input validation code by driver module, according to pre-defined rule, identifying code with coupling just can enter superuser mode, input validation code or the input of multiple authentication code are not mated, enter user EXEC, initial authentication code can do initialization by production firm, and operator logs in after entering superuser mode and can revise voluntarily according to pre-defined rule.
Embodiment tri-
This preferred embodiment provides a kind of hand-held set, and with respect to traditional hand-held set, the hand-held set in this preferred embodiment has increased following functions module: User Status application module and User Status monitoring modular.
Please refer to Fig. 6, hand-held set comprises User Status application module, User Status monitoring modular and power management module; User Status monitoring modular is for monitoring the state value of power management module, and the state value that sends the power management module listening to is to User Status application module; User Status application module, for according to the state value of the power management module receiving, with the switching between pre-defined rule control different user pattern, is preferably with pre-defined rule control user model and switches between user EXEC and superuser mode.
Preferably, hand-held set also comprises: user's modular converter, touch pad driver module, user interface control module and driver module, User Status application module, by controlling user's modular converter, is realized user model and is switched between user EXEC and superuser mode; Touch pad driver module is for the input of Receipt Validation code; By user interface control module, User Status application module control driver module carries out the interface display of user EXEC or superuser mode, or presents identifying code input frame.
User Status monitoring modular, in the time monitoring the state value of power management module, is converted to open state value if listen to power management module by off-mode value, and User Status application module, by user's modular converter, is controlled user model and entered user EXEC; If User Status monitoring modular is monitored power management module and is converted to by screen lock state value the state value of spreading its tail, User Status application module, by user's modular converter, is controlled user model and is entered superuser mode.
Further, User Status monitoring modular is also for monitoring the state value of touch pad driver module, and the state value that simultaneously sends touch pad driver module is to User Status application module; If power management module is converted to by screen lock state value the state value of spreading its tail, and touch pad driver module is converted to input state value by idle-mode value, User Status monitoring modular detects the identifying code of touch pad driver module input, sends identifying code to User Status application module; If User Status application module judges authentication code matches, by user's modular converter, control user model and enter superuser mode; Otherwise, if the identifying code that the judgement of User Status application module is repeatedly inputted does not mate, by user's modular converter, control user model and enter user EXEC; If User Status monitoring modular is monitored touch pad driver module and inputted without identifying code in idle-mode value within a predetermined period of time always, User Status application module, by user's modular converter, is controlled user model and is entered user EXEC.
Further, User Status monitoring modular is also monitored the state value of driver module simultaneously, and the state value that sends in real time driver module is to User Status application module; If the state value of driver module is without show state value, by user interface control module, User Status application module control driver module carries out the interface display of user EXEC or superuser mode, or presents identifying code input frame; If the state value of driver module is show state value, User Status application module is switched to user EXEC or superuser mode by user interface control module controls driver module by display interface, or presents identifying code input frame.
In the preferred embodiment, hand-held set is provided with the hand-held set operating system of embodiment mono-or two, operating system is specifically carried out instruction according to the step of embodiment mono-or two, makes the hand-held set in the present embodiment realize the switching between user EXEC and superuser mode.
Above content is in conjunction with concrete embodiment further description made for the present invention, can not assert that specific embodiment of the invention is confined to these explanations.For general technical staff of the technical field of the invention, without departing from the inventive concept of the premise, can also make some simple deduction or replace.