CN108037964A - A kind of method, storage medium and smart machine that resolution ratio is set - Google Patents

A kind of method, storage medium and smart machine that resolution ratio is set Download PDF

Info

Publication number
CN108037964A
CN108037964A CN201711431344.8A CN201711431344A CN108037964A CN 108037964 A CN108037964 A CN 108037964A CN 201711431344 A CN201711431344 A CN 201711431344A CN 108037964 A CN108037964 A CN 108037964A
Authority
CN
China
Prior art keywords
resolution
vga
operating system
parameter
device tree
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201711431344.8A
Other languages
Chinese (zh)
Inventor
宋友林
林哲明
李捷
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Fujian Star Net eVideo Information Systems Co Ltd
Original Assignee
Fujian Star Net eVideo Information Systems Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Fujian Star Net eVideo Information Systems Co Ltd filed Critical Fujian Star Net eVideo Information Systems Co Ltd
Priority to CN201711431344.8A priority Critical patent/CN108037964A/en
Publication of CN108037964A publication Critical patent/CN108037964A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/4401Bootstrapping
    • G06F9/4411Configuring for operating with peripheral devices; Loading of device drivers

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)

Abstract

The present invention provides a kind of method for setting resolution ratio, include the following steps:Uboot reads the resolution parameter of preset memory locations, and resolution parameter is passed to operating system nucleus;Operating system nucleus is according to matching corresponding VGA resolution resource in the resolution parameter slave device tree received and register driving;Load corresponding VGA resolution display driving;Called by matching of the definite and operating system nucleus of device tree intrinsic resolution allocation list information to VGA resolution resource and load the corresponding display driving of VGA resolution, different resolution VGA display screens can be adapted to, the present invention need not rely on the adjustment on hardware, only device tree, which need to be changed, can set required resolution ratio, solve the problems such as different resolution needs to change corresponding VGA display screens, resolution ratio storage is easily destroyed;It is simple with manipulating, the advantages that improving efficiency, reduce cost.

Description

A kind of method, storage medium and smart machine that resolution ratio is set
Technical field
The present invention relates to field of video transmission, more particularly to a kind of method for setting resolution ratio, storage medium and intelligence to set It is standby.
Background technology
Android operation system is widely used to TV box, screen, cashier terminal are thrown in advertisement, common aobvious on the market Display screen interface generally use VGA, HDMI and DVI, but most common is to use VGA agreements, and most of chip is EDP agreements connects Mouthful, a VGA conversion chip is added on hardware, is VGA agreements by EDP protocol conversions, and its fixed resolution parameter is configured, if more The VGA display screens of different resolution parameter have been changed, its correlative code must be changed, usually because of the VGA display screens of different resolution Correspond to different code and cause the shortcomings of code redundancy, durability are low, upgrade package is excessive.
The content of the invention
For this reason, it may be necessary to provide a kind of matching process for being adapted to different resolution, need to be changed greatly with solving different resolution Measure code, the problems such as durability is low, upgrade package is excessive.
To achieve the above object, a kind of method that resolution ratio is set is inventor provided, is preferably included the following steps:
Bootstrap reads the resolution parameter of preset memory locations, and resolution parameter is passed to operating system nucleus;
Operating system nucleus is according to matching corresponding resolution ratio resource in the resolution parameter slave device tree received and note Volume driving;
Load corresponding resolution ratio display driving.
Further optimization, further includes following steps:
Device tree is generated according to the allocation list of different resolution.
Further optimization, it further includes following steps:
By device tree programming to system partitioning.
Further optimization, it further includes following steps:
Upper level applications set resolution ratio and are saved in corresponding preset memory locations.
Further optimization, " bootstrap reads the resolution parameter of preset memory locations to the step, by resolution parameter Pass to operating system nucleus " further include following steps before:
Restarting systems.
Further optimization, the operating system is Android system.
Further optimization, the resolution ratio is VGA resolution.
Further optimization, the preset memory locations are product identification memory block area.
A kind of storage medium, the storage medium are stored with computer program, and the computer program is executed by processor The step of Shi Shixian above methods.
A kind of smart machine, including memory, processor, are stored with computer program, the calculating on the memory The step of machine program realizes the above method when being executed by processor.
The prior art is different from, above-mentioned technical proposal determines and operate system by device tree intrinsic resolution allocation list information The matching of verification resolution ratio resource calls and loads the corresponding display driving of resolution ratio in system, can be adapted to different resolution and show Screen, the present invention need not rely on the adjustment on hardware, and need to only change device tree can set required resolution ratio, manipulate simply, Efficiency is improved, reduces cost.Solve different resolution needs to change corresponding VGA display screens, resolution ratio storage is easily destroyed etc. Problem.
Brief description of the drawings
Fig. 1 is an embodiment of the present invention the method flow chart;
Fig. 2 is another embodiment the method flow chart of the present invention.
Embodiment
To describe the technology contents of technical solution, construction feature, the objects and the effects in detail, below in conjunction with specific reality Apply example and coordinate attached drawing to be explained in detail.
The English full name of VGA is Video Graphic Array, that is, shows drawing array.
Uboot full name Universal Boot Loader, are the open source code projects for following GPL clauses, its effect is to be System guiding.
Fig. 2 is please referred to Fig.1, inventor provides a kind of method that resolution ratio is set, the present processes can be applied In in the embedded system based on Linux, such as Android system, these operating systems include bootstrap (can in embedded Referred to as Uboot) and operating system nucleus (operating system can be Android operation system or linux operating systems).These systems It may be mounted on electronic equipment, the processor of electronic equipment is read from the memory for be stored with operating system and load operating Operating system.The method of the present embodiment can be used for setting VGA resolution, can be used for setting the resolution of other display types Rate, the present embodiment are described in detail with VGA resolution.The method of the present embodiment includes the following steps:It is step S101 first: Bootstrap reads the resolution parameter of preset memory locations, and resolution parameter is passed to operating system nucleus.It is default to deposit Storage space puts the specific location that can be stored in memory, which is write in bootstrap in advance by developer, guiding Program can go read-out resolution parameter after electronic equipment just powers on operation, and operating system is also not actuated at this time, be in operation System starts resolution parameter can be sent to operating system after starting.Then enter step S103:Operating system nucleus is according to connecing Corresponding VGA resolution resource is matched in received resolution parameter slave device tree and registers driving.In step S105:Loading pair The VGA resolution display driving answered.
Wherein, Uboot is the open source code project for following GPL clauses, resolution parameter can it is pre-set and store to Matching in preset memory locations for operating system nucleus is called, and Uboot is used to guide system, and Uboot can be read and call pre- If the resolution parameter in storage location, operating system nucleus can be handled resolution parameter, and step S101 is being performed When, Uboot reads the resolution parameter in preset memory locations first, and the resolution parameter is transferred to operating system nucleus Place, so as to fulfill the process of resolution parameter transmission, so that resolution parameter is further processed in operating system nucleus.
Device tree is generated by the allocation list of different resolution, and device tree is used to store default VGA resolution money Source, device tree call for the matching of operating system nucleus, and the effect of operating system nucleus in step s 103 is to basis point Resolution parameter is matched, and the matching is exactly resolution parameter and the matching of VGA resolution resource in device tree, and matching is completed The corresponding VGA resolution display driving of post-registration, when executed, operating system nucleus is first to resolution parameter by step S101 Parsed, and match VGA resolution resource in device tree corresponding with resolution parameter, the matching completion post-registration VGA is shown Show driving, in state to be loaded, registration driving is that driver is stored in kernel bus by kernel, is not performed.It is most laggard Row VGA shows the loading of driving, and load driver refers to that kernel detects equipment, corresponding driving is found from kernel bus, and Perform the process of driver.The present invention is realized in the case where not changing the precondition of hardware device, that is, does not change operation System kernel, only need to change VGA resolution resource in device tree can be adapted to the product of different resolution, and again due to resolution ratio Preset memory locations are stored in, preset memory locations can be IDB, IDB full name identification block, that is, produce Product identification memory block area, resolution ratio will not be destroyed because of factory reset and the upgrading of product, renewal.
Operating system nucleus is registered A and is shown according to corresponding VGA resolution resource in resolution parameter matching unit tree Driving is that when executed, operating system nucleus loads VGA to step S105 according to step S103 VGA resolution display drivings Display drives and completes the output that VGA resolution resource corresponds to resolution ratio, realizes the adaptation of different resolution product.
In certain embodiments, as shown in Fig. 2, the step S101 of wherein step S211 to S215 and above-described embodiment is arrived S105 is similar, which further includes following steps:Step S201 generates device tree according to the allocation list of different resolution, different Resolution ratio corresponds to different resolution parameters, resolution parameter and the one-to-one allocation list of resolution ratio, it configures correspondence And device tree is generated, this step realizes upon execution corresponds to different resolution parameter configuration generation equipment by different resolution Tree, the storage management of parameter is corresponded to being called easy to resolution ratio.Step S201 is a kind of method and step of device tree generation, this Field technology personnel can also generate device tree by other forms, as long as including the configuration of different resolution in device tree Parameter.
In all embodiments, device tree can be stored in advance in system partitioning or pack together with system followed by being Unify storage and arrive system partitioning.In certain embodiments, can also be by way of independent programming, then the present embodiment method is also Include the following steps:For step S203 by device tree programming to system partitioning, programming is the process of storage device tree, this step exists It is performed and realizes the device tree storage by allocation list generation to system partitioning, so as to fulfill operating system nucleus to device tree Matching and calling.
In order to realize the setting of upper level applications or user application to resolution ratio, following steps are further included:Step Rapid S205 upper level applications set VGA resolution to be simultaneously saved in corresponding preset memory locations, and set VGA resolution can be with It is upper level applications, for example the VGA resolution carried out in Android desktop adjusts, and can also be in production and processing to VGA Resolution ratio carries out unified setting, when this step performs, after upper level applications have set VGA resolution, and operating system nucleus The setting operation and VGA resolution can be preserved to corresponding preset memory locations, preset memory locations can be IDB, that is, Product identification memory block area, the preset memory locations are on the required product for setting VGA output resolution ratios, easy to step Readings of the Uboot to preset memory locations information in S101.
In the embodiment further optimized, " bootstrap reads the resolution parameter of preset memory locations to step, will differentiate Rate parameter passes to operating system nucleus " further include following steps before:Step S205 restarting systems.
Different resolution corresponds to parameter and forms allocation list and generate after device tree is stored into system partitioning, due to system partitioning The renewal of content, for convenience of calling, it is necessary to which restarting systems, facilitate step S101 to pass the calling for having updated resolution parameter Pass.
The present embodiment provides a kind of storage medium, the storage medium is stored with computer program, the computer program The step of above-mentioned, method is realized when being executed by processor, so that above-mentioned reality can be realized by running the electronic equipment of the storage medium Apply all functions of example.
The present embodiment provides a kind of smart machine, including memory, processor, computer journey is stored with the memory The step of sequence, the computer program realizes the above method when being executed by processor, smart machine of the invention pass through modularization Management, not only durability it is high, need not other loading upgrading bag, need to only carry out the simple modification of device tree content can effectively reduce Code redundancy, reduces maintenance difficulties.This smart machine utilizes the characteristics of operating system nucleus device tree, and different resolution is configured Parameter, generates equipment tree node, upper level applications set VGA resolution, and the VGA resolution is stored in default storage position Put, after system is restarted, Uboot reads dependent resolution parameter, and the resolution parameter is transferred to operating system nucleus, The corresponding resolution parameter of operating system nucleus parsing, and corresponding VGA resolution resource is matched in device tree, register and load The VGA resolution resource, operating system nucleus device tree are adapted to different resolution product in the case where not changing code, with Code difficulty is safeguarded in reduction.
It should be noted that although the various embodiments described above have been described herein, but not thereby limit The scope of patent protection of the present invention.Therefore, based on the present invention innovative idea, to embodiment described herein carry out change and repair Change, or the equivalent structure or equivalent flow shift made using description of the invention and accompanying drawing content, directly or indirectly will be with Upper technical solution is used in other related technical areas, is included within the scope of patent protection of the present invention.

Claims (10)

  1. A kind of 1. method that resolution ratio is set, it is characterised in that include the following steps:
    Bootstrap reads the resolution parameter of preset memory locations, and resolution parameter is passed to operating system nucleus;
    Operating system nucleus is according to matching corresponding resolution ratio resource in the resolution parameter slave device tree received and register drive It is dynamic;
    Load corresponding resolution ratio display driving.
  2. 2. setting resolution method according to claim 1, it is characterised in that further include following steps:
    Device tree is generated according to the allocation list of different resolution.
  3. 3. setting resolution method according to claim 1, it is characterised in that it further includes following steps:
    By device tree programming to system partitioning.
  4. 4. setting resolution method according to claim 1, it is characterised in that it further includes following steps:
    Upper level applications set resolution ratio and are saved in corresponding preset memory locations.
  5. 5. setting resolution method according to claim 1, it is characterised in that " bootstrap reads default the step The resolution parameter of storage location, operating system nucleus is passed to by resolution parameter " further include following steps before:
    Restarting systems.
  6. 6. setting resolution method according to claim 1, it is characterised in that the operating system is Android system.
  7. 7. resolution method is set according to claim 1 to 6 any one of them, it is characterised in that the resolution ratio is VGA points Resolution.
  8. 8. resolution method is set according to claim 1 to 6 any one of them, it is characterised in that the preset memory locations For product identification memory block area.
  9. A kind of 9. storage medium, it is characterised in that:The storage medium is stored with computer program, and the computer program is located Manage when device performs and realize such as the step of claim 1,4-8 any one the methods.
  10. A kind of 10. smart machine, it is characterised in that:Including memory, processor, computer journey is stored with the memory Sequence, is realized such as the step of claim 1,4-8 any one the methods when the computer program is executed by processor.
CN201711431344.8A 2017-12-26 2017-12-26 A kind of method, storage medium and smart machine that resolution ratio is set Pending CN108037964A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201711431344.8A CN108037964A (en) 2017-12-26 2017-12-26 A kind of method, storage medium and smart machine that resolution ratio is set

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201711431344.8A CN108037964A (en) 2017-12-26 2017-12-26 A kind of method, storage medium and smart machine that resolution ratio is set

Publications (1)

Publication Number Publication Date
CN108037964A true CN108037964A (en) 2018-05-15

Family

ID=62101091

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201711431344.8A Pending CN108037964A (en) 2017-12-26 2017-12-26 A kind of method, storage medium and smart machine that resolution ratio is set

Country Status (1)

Country Link
CN (1) CN108037964A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110308941A (en) * 2019-07-03 2019-10-08 深圳市海邻科信息技术有限公司 BIOS compatibility method, device, terminal and computer storage medium without EDID screen
WO2022161317A1 (en) * 2021-01-29 2022-08-04 展讯通信(上海)有限公司 Lcd debugging method and apparatus

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6907597B1 (en) * 2000-10-13 2005-06-14 Ati International Srl Method and apparatus for constructing an executable program in memory
CN104407874A (en) * 2014-12-11 2015-03-11 天津中兴智联科技有限公司 Embedded equipment compatible to a plurality of types of LCD screens
CN104503722A (en) * 2014-12-19 2015-04-08 广东欧珀移动通信有限公司 Display screen compatible method and device and mobile terminal
CN105630465A (en) * 2014-10-29 2016-06-01 Tcl商用信息科技(惠州)股份有限公司 Display screen parameter setting method applied to terminal and terminal
CN105912350A (en) * 2015-11-02 2016-08-31 乐视致新电子科技(天津)有限公司 Software adaption method and software adaption system compatible to a plurality of screen parameters
CN105975227A (en) * 2016-04-27 2016-09-28 深圳市索力科技有限公司 Method and system for driving display screen, and display device
CN105988850A (en) * 2015-05-12 2016-10-05 乐视移动智能信息技术(北京)有限公司 Startup control method and device of mobile terminal

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6907597B1 (en) * 2000-10-13 2005-06-14 Ati International Srl Method and apparatus for constructing an executable program in memory
CN105630465A (en) * 2014-10-29 2016-06-01 Tcl商用信息科技(惠州)股份有限公司 Display screen parameter setting method applied to terminal and terminal
CN104407874A (en) * 2014-12-11 2015-03-11 天津中兴智联科技有限公司 Embedded equipment compatible to a plurality of types of LCD screens
CN104503722A (en) * 2014-12-19 2015-04-08 广东欧珀移动通信有限公司 Display screen compatible method and device and mobile terminal
CN105988850A (en) * 2015-05-12 2016-10-05 乐视移动智能信息技术(北京)有限公司 Startup control method and device of mobile terminal
CN105912350A (en) * 2015-11-02 2016-08-31 乐视致新电子科技(天津)有限公司 Software adaption method and software adaption system compatible to a plurality of screen parameters
CN105975227A (en) * 2016-04-27 2016-09-28 深圳市索力科技有限公司 Method and system for driving display screen, and display device

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
高磊 等编著: "《Android应用开发精解》", 30 September 2012, 北京:北京航空航天大学出版社 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110308941A (en) * 2019-07-03 2019-10-08 深圳市海邻科信息技术有限公司 BIOS compatibility method, device, terminal and computer storage medium without EDID screen
WO2022161317A1 (en) * 2021-01-29 2022-08-04 展讯通信(上海)有限公司 Lcd debugging method and apparatus

Similar Documents

Publication Publication Date Title
CN100511156C (en) Apparatus for compulsively terminating thread blocked on input/output operation and method for the same
CN104508589A (en) Selectable graphics controllers to display output
CN102662717A (en) Bootstrap starting method of embedded system
US9530386B2 (en) Methods and apparatus to provide extended graphics processing capabilities
US10521216B2 (en) Unified extensible firmware interface updates
CN106020837A (en) Method and system for loading set top box drive
CN108037964A (en) A kind of method, storage medium and smart machine that resolution ratio is set
CN110221840B (en) Function implementation method and device of application program, equipment and storage medium
CN103530165B (en) A kind of java solution that is applied to Internet of Things industry
CN110515671A (en) Initial method, apparatus for initializing, terminal device and readable storage medium storing program for executing
US20140089906A1 (en) Dynamically building locale objects at run-time
CN111580847B (en) GPU (graphics processing unit) driving updating method and device, computer storage medium and electronic equipment
CN114127685B (en) Electronic apparatus and control method thereof
US7680909B2 (en) Method for configuration of a processing unit
CN113050962B (en) Mobile service upgrading method, device and terminal
EP3480703B1 (en) Hardware independent peripheral control system and method
CN112540777A (en) Method and terminal for supporting dynamic read-write of NV (network video) parameters
CN105068835A (en) Mobile terminal and debugging information display method thereof
CN116661951B (en) Mirror image file processing method and device, electronic equipment and storage medium
CN113127051B (en) Application resource packaging process monitoring method, device, equipment and medium
CN102567034B (en) Driver management system
US20230393820A1 (en) MVVM Architecture-Based Application Development Method and Terminal
CN114706635A (en) Application program logic processing method, device and equipment
CN116578791A (en) Navigation bar loading method, device, equipment and storage medium
CN117093225A (en) Code file compiling method, system updating method, device, server and equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20180515

RJ01 Rejection of invention patent application after publication