Lenovo C340-15IML/FLEX-15IML/S340-15IML S340-14IML Bios Extract & DMI Edit Tutorial

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • SMDFlea
    Super Moderator
    • Jan 2018
    • 20276
    • UK

    #1

    Lenovo C340-15IML/FLEX-15IML/S340-15IML S340-14IML Bios Extract & DMI Edit Tutorial

    These models use the same bios: Lenovo IdeaPad C340-15IML/FLEX-15IML/S340-15IML/S340-15IML Touch/S340-14IML Lenovo XiaoXin-15IML 2019/XiaoXin-14IML 2019

    Backup bios used for this tutorial https://www.badcaps.net/forum/showthread.php?t=97978 Post #13

    Extract & Edit.

    Download the lenovo update from - https://download.lenovo.com/consumer...s/crcn17ww.exe
    Extract the first exe using innoextract - https://constexpr.org/innoextract/#download
    Extract the second exe using 7-zip or winrar - https://www.7-zip.org/download.html

    Open the EL5C4109.ROM file with HxD hex editor - https://mh-nexus.de/en/downloads.php?product=HxD20

    Use the Text search by clicking on "Search" ,then "Find" and type in the word BIOSIMG .Click on the "OK" button.

    The line below BIOSIMG is the start of the new bios,put your cursor at the beginning of that line,then select "Edit" -> "Select Block" or right click and choose "Select Block".

    The "Start-offset" should be already set to 130AD0 as thats where you put the cursor.

    Next, click on the "Length" button and enter 1000000 (1 Million) into the white box and click on the "OK" button


    (1000000 in hex is 16MB).(some updates do not contain a full bios image,only a partial update)

    Select "Edit" -> "Copy" or right click anywhere in the highlighted Blue area and select "Copy".

    Next,select "File" -> "New" -> "Edit" -> "Paste insert" or right click inside the new file and select "Paste insert" .


    Select "File" -> "Save" and name the file with a .bin or .rom file extension, for example BIOS.BIN .Close the EL5C4109.ROM tab by right clicking on the tab and selecting Close ,or by clicking on the tab and selecting "File" -> "Close" . Keep the HxD window open with the new file.

    Copying the windows key and DMI from the old bios.

    Open your backup by selecting "File" -> "Open" or drag the old bios backup onto the HxD window.The new bios and backup should be side by side now on seperate tabs.

    Click on the backup tab, then "Search" -> "Find" .Click on the "Hex-values" tab,enter the following by typing in or copy/pasting into the white box and
    click ok:

    01 00 00 00 00 00 00 00 01 00 00 00 00 00 00 00 1D 00 00 00



    You will see the key in plain text.You need to copy the hex on the left to include the dots and key on the right,note that there is one letter or number on the fourth line down on its own.Its all too easy to forget to copy that last one,the file length in hex will be 31 if you only copy the dots and key,its much easier to copy the whole line that its on,then the length will be 40 ,much easier to remember and guaranteed not to miss the last letter/number

    Right click and choose "Select block" (or use your cursor to select the 4 lines) ,set the "Start-offset" to 62D000 and the "End-offset" to 62D03F ,or click on the "Length" button and set to 40 and click OK .


    Next,choose "Edit" -> "Copy" ,click on the new bios tab,right click and choose "Select block" .Enter the same values as before,set the "Start-offset" to 62D000 and the "End-offset" to 62D03F ,or click on the "Length" button and set to 40 and click OK .

    Right click and select "Paste insert" or choose "Edit" -> "Paste insert" .Select "File" -> "Save" .

    Now we have to find the rest of the DMI info.Click back onto the backup tab,use the "Search" -> "Find" and enter the model number or lenovo into the Text-string white box.Set the search direction button to backward,forward or All and then click "ok".In th right side column you can see the word lenovo and some other numbers/DMI info.

    Set the start-offset to 520000 and the end-offset to 5207FF ,copy and paste-insert into the same start/end offset in the new bios ,then save .


    The reason for setting the offset to 5207FF will become clear when you see that the area in the new bios is all FF

    .You have to use your best judgement where the DMI should be set,its a matter of trial and error finding the offsets.
    With some models the DMI info is stored in the EC and there`s no need to copy it from the old backup.
    Attached Files
    Last edited by SMDFlea; 04-22-2023, 04:30 PM.
    All donations to badcaps are welcome, click on this link to donate. Thanks to all supporters
  • Vesko356
    VIP Moderator
    • Aug 2018
    • 4386
    • Bulgaria 🇧🇬

    #2
    Re: Lenovo C340-15IML/FLEX-15IML/S340-15IML S340-14IML Bios Extract & DMI Edit Tutori

    Well done, good job.
    Excellently written guide , should be on top as sticky thread.
    ----------------------------------------------------------------------------------------------------------------------------------------------------------
    All donations to Badcaps are welcome.
    Become a Badcaps supporter
    >>>>> click on this link to donate <<<<<
    Thanks to all supporters.​
    ----------------------------------------------------------------------------------------------------------------------------------------------------------
    Doctrina est fructus dulcis, radicis amarae.
    .

    Comment

    • kalilinux25
      Badcaps Legend
      • Mar 2018
      • 2069
      • ZAMBOANGA SIBUGAY

      #3
      Re: Lenovo C340-15IML/FLEX-15IML/S340-15IML S340-14IML Bios Extract & DMI Edit Tutori

      thanks sir Ill try it for my slef

      Comment

      • amtoufik09
        New Member
        • Feb 2022
        • 2
        • Algérie

        #4
        Re: Lenovo C340-15IML/FLEX-15IML/S340-15IML S340-14IML Bios Extract & DMI Edit Tutori

        thanks good job

        Comment

        • kalilinux25
          Badcaps Legend
          • Mar 2018
          • 2069
          • ZAMBOANGA SIBUGAY

          #5
          Re: Lenovo C340-15IML/FLEX-15IML/S340-15IML S340-14IML Bios Extract & DMI Edit Tutori

          Do you have also for asus?

          Comment

          • SMDFlea
            Super Moderator
            • Jan 2018
            • 20276
            • UK

            #6
            Re: Lenovo C340-15IML/FLEX-15IML/S340-15IML S340-14IML Bios Extract & DMI Edit Tutori

            Originally posted by kalilinux25
            Do you have also for asus?
            No not yet. There are some asus tools to add dmi ,but mostly its easier to use a hex editor and UEFITool https://www.badcaps.net/forum/showpo...43&postcount=5
            Last edited by SMDFlea; 03-03-2022, 10:11 AM.
            All donations to badcaps are welcome, click on this link to donate. Thanks to all supporters

            Comment

            • kalilinux25
              Badcaps Legend
              • Mar 2018
              • 2069
              • ZAMBOANGA SIBUGAY

              #7
              Re: Lenovo C340-15IML/FLEX-15IML/S340-15IML S340-14IML Bios Extract & DMI Edit Tutori

              Originally posted by SMDFlea
              No not yet. There are some asus tools to add dmi ,but mostly its easier to use a hex editor and UEFITool https://www.badcaps.net/forum/showpo...43&postcount=5
              Im new on creating my own bios, i though dmi is not very important. Another learning

              Comment

              • wandy
                New Member
                • Oct 2018
                • 7
                • tangerang

                #8
                Re: Lenovo C340-15IML/FLEX-15IML/S340-15IML S340-14IML Bios Extract & DMI Edit Tutori

                what if the old bios no longer exists, and can't copy the DMI? will the new bios not work?

                Comment

                • anshad
                  Badcaps Veteran
                  • Nov 2010
                  • 249

                  #9
                  Re: Lenovo C340-15IML/FLEX-15IML/S340-15IML S340-14IML Bios Extract & DMI Edit Tutori

                  Originally posted by wandy
                  what if the old bios no longer exists, and can't copy the DMI? will the new bios not work?
                  Usually the system will work but obliviously you will loose original Serial no, Windows key etc and that will also cause software activation issues. Application software which uses system serial,UUID etc. for generating Machine ID may also stop working. Depending on the machine, you may also get an error message or warning message about invalid DMI on startup.

                  Comment

                  • rediii
                    h???, spurrrn
                    • Mar 2018
                    • 485
                    • somewhere in europe

                    #10
                    Re: Lenovo C340-15IML/FLEX-15IML/S340-15IML S340-14IML Bios Extract & DMI Edit Tutori

                    perfect, thank you

                    Comment

                    • dariusgc
                      Member
                      • May 2020
                      • 35
                      • Lithuania

                      #11
                      Re: Lenovo C340-15IML/FLEX-15IML/S340-15IML S340-14IML Bios Extract & DMI Edit Tutori

                      Thank you, SMDFlea, for sharing your knowledge

                      Comment

                      • chromecut
                        New Member
                        • Apr 2021
                        • 4
                        • United states

                        #12
                        Re: Lenovo C340-15IML/FLEX-15IML/S340-15IML S340-14IML Bios Extract & DMI Edit Tutori

                        uh OK how do you write the edited bios back in? insyde tools wont work and fptw wont work either-(protected range registers funhouse)I have B40-30 lenovo insyde bios thats I unlocked with uefi tool confirmed-Ive been trying to add nvme support for almost 2 years lol-I have full unlocked advanced tabs via keyboard sequence so I only need nvme boot support which Ive already modded-hardware programmed back in results in brick-Ive even hex edited and unlocked the bios of the stock bios and flashed back with stock tools after verifying h20 showing its still signed
                        any advice?
                        thanks

                        Comment

                        • SMDFlea
                          Super Moderator
                          • Jan 2018
                          • 20276
                          • UK

                          #13
                          Re: Lenovo C340-15IML/FLEX-15IML/S340-15IML S340-14IML Bios Extract & DMI Edit Tutori

                          Originally posted by chromecut
                          uh OK how do you write the edited bios back in? insyde tools wont work and fptw wont work either-(protected range registers funhouse)I have B40-30 lenovo insyde bios thats I unlocked with uefi tool confirmed-Ive been trying to add nvme support for almost 2 years lol-I have full unlocked advanced tabs via keyboard sequence so I only need nvme boot support which Ive already modded-hardware programmed back in results in brick-Ive even hex edited and unlocked the bios of the stock bios and flashed back with stock tools after verifying h20 showing its still signed
                          any advice?
                          thanks
                          You`re off-topic it seems. You will have to use an SPI programmer.Anyone doing bios modding should know that flashing a modded bios back can result in a brick.

                          .
                          All donations to badcaps are welcome, click on this link to donate. Thanks to all supporters

                          Comment

                          • chromecut
                            New Member
                            • Apr 2021
                            • 4
                            • United states

                            #14
                            Re: Lenovo C340-15IML/FLEX-15IML/S340-15IML S340-14IML Bios Extract & DMI Edit Tutori

                            off topic? I would think any good tutorial would include procedure for flashing back edited bios-(excellent tutorial by the way) the sleep bug trick only works with versions before security change from oem-that verson for me is 933n30ww.exe which somebody(you?) posted a dump of not the .exe including signed bios
                            to be clear I am no noob and have manually edited many bios as well as flashed back with hardware programmer (I have 5 of them and every bios tool
                            imaginable) but hardware flashing ANY modded bios that breaks signature=brick
                            Ive managed to manually edit signed bios to unlock all fields (according to uefi tool) and flash that bios back with official insyde tools but any other edits after reboot results in=brick
                            from what I can tell the insyde flash tool AND the bios itself needs to be signed as I read official intel doc stating hardware flash even after blanking chip doesnt guarantee success
                            it could be the nvme mod itself as I noticed from newer insyde bios has smm&dxe "combo" type modules which my bios seems to support
                            extracting the nvme module with h20 and uefi and then comparing reveals difference between by one byte so Im unsure which nvme module version to use or where to place it (using h20 for my bios gives 4 fv choices and places it near the end (I chose FV#3 as other smmdxe resides there)and donor bios crams it in between 1p4 and ip6 so using h20 (which breaks the bios)

                            so my question is how to modify either newest oem or sleep bug bios for nvme support and then flash it back with either hardware, fptw or insyde flash package tool?
                            p.s I have followed your excellent guidance towards similar endeavers on different sites only to have the OP drop the ball and giving up before success
                            so after almost 2 years of trying you can imagine my frustration

                            any advice would be well recieved as I need to get back to my current projects of booting windows off a linux raid array, my special ramdisk driver that is persistent and fools windows thinkings its real hardware(Im getting 10,000gt/s) or my dual enterprise class m.2 adapter for pcie 4.0x8(12,000gt/s on that bad boy) that after modding works without bifurcation that Im going to release for alienware aurora R machines with x8 gimped pcie lanes

                            donation is not a problem
                            thanks

                            Comment

                            Related Topics

                            Collapse

                            • Caimano
                              Need to copy DMI info for HP ProBook 650 G2 Bios
                              by Caimano
                              UPDATE of JANUARY 5th : I am cancelling this post because problem has been solved by creating a new bios starting from the old one with correct dmi and cleaning ME. everything works fine . thanks anyway

                              Hi, I am replacing a motherboard circus-6050A2723701-MB-A02 to an HP 650 G2 laptop because the original one was faulty. I bought and repaired a used MB which works fine now with its BIOS, but I wanted to copy the DMI data from the old to the new MB. I created with Flash Image Tool a new bios starting from the old original chip , cleaned ME region and new updated dump region extracted...
                              01-03-2024, 05:19 AM
                            • SMDFlea
                              Copy DMI info easily with Hex editing software and Macro script
                              by SMDFlea
                              Copying DMI information from an old bios to a new one is difficult for some members, often they have no experience with a hex editor,or some that have tried find it too hard.There is an option to make things easier for those members so that they don`t need to post their own bios backup for the DMI copying.

                              Experienced bios modding members can help by posting in other threads the DMI offsets,macro script generated by the software and a download link to the software at softpedia mentioned in this guide,or post your macros in the comments here with a link to the bios request thread ....
                              02-28-2023, 02:14 PM
                            • m0seba
                              how to block copy from network access
                              by m0seba
                              hi
                              there is a small company have 4 computers and server with windows server 2016
                              all computers are entered into the server by local users, and there is shared folders on server with limited access to every computer
                              my question is there any method to disable copping form all shared folders on this server, but jest disable copy form server not paste on it.
                              my client want his team copy from their computers and paste on any shared folders on server, on the other way can not copy anything from shared folders to their computer.
                              or any way to disable copy on windows...
                              03-16-2021, 03:35 PM
                            • EazyBone
                              Hisense 55H8F Emmc programming help
                              by EazyBone
                              I am extremely new to programming and dipping into this. I picked up a XGECU T48 Programmer and have the correct socket for EMMC.
                              I took the EMMC off a working main board with no problems and threw it into the programmer. I click analysis IC and it gives me a report (attached) of the current EMMC. Model H26M41204HPR

                              1) I manually found this chip(above model number) in the select IC section of the XGPRO 12.xx programmer software and it had a option for 4 bit and 1 bit. I chose 4... is this correct?

                              2) In the options section point number 2 operation says "30...
                              06-11-2024, 06:03 PM
                            • Victor Petrovich
                              Lenovo IdeaPad 3 15ITL6 doesn't start
                              by Victor Petrovich
                              I have laptop Lenovo IdeaPad 3 15ITL6 with Intel Core i3-1115G4. When I press the start button, LED light on the start button starts blinking 12 times, then stops and after some time starts blinking 12 times again. When it stops, all voltages are down.

                              The motherboard is HS460 HS560 HS760 NM-D471 Rev: 2.0
                              S/N: PF3Q0WTF

                              The motherboard is not mine, also there were corrosion on the board which I cleaned.

                              Methods of fixing like fully turning off the motherboard or starting only with adapter doesn't work. All testing were did only with adapter on.
                              ...
                              06-07-2025, 02:40 AM
                            • Loading...
                            • No more items.
                            Working...