Linux native flashing

Discussion of LibreDrive mode, compatible drives and firmwares
Woodstock
Posts: 10380
Joined: Sun Jul 24, 2011 11:21 pm

Re: Linux native flashing

Post by Woodstock »

Running remote on Windows also introduces a few extra security "gotchas", because the default for Windows is to not allow remote users access to things like optical drives...
SamuriHL
Posts: 2345
Joined: Mon Jun 14, 2010 5:32 pm

Re: Linux native flashing

Post by SamuriHL »

Yea, that's the default. ;) I have powershell scripts I wrote to enable LibreDrive and create an ISO with ImgBurn that I run remote. I just didn't expect MakeMKV to ask me questions in the shell. Oops. :)
Billycar11
Posts: 4395
Joined: Sun Aug 24, 2014 5:49 am

Re: Linux native flashing

Post by Billycar11 »

SamuriHL wrote:
Sat Feb 01, 2020 7:10 pm
Yea, that's the default. ;) I have powershell scripts I wrote to enable LibreDrive and create an ISO with ImgBurn that I run remote. I just didn't expect MakeMKV to ask me questions in the shell. Oops. :)
There is a yes all option look at the thing I posted in the post about the sdf tool
Buy a UHD drive from the guide and how to video maker: https://www.makemkv.com/forum/viewtopic ... 20&t=17831
UHD Drives Guide: https://www.makemkv.com/forum/viewtopic ... 16&t=19634
Auto flash kit $25 Email me for one Billycar5924@gmail.com
SamuriHL
Posts: 2345
Joined: Mon Jun 14, 2010 5:32 pm

Re: Linux native flashing

Post by SamuriHL »

Billycar11 wrote:
Sun Feb 02, 2020 12:21 am
SamuriHL wrote:
Sat Feb 01, 2020 7:10 pm
Yea, that's the default. ;) I have powershell scripts I wrote to enable LibreDrive and create an ISO with ImgBurn that I run remote. I just didn't expect MakeMKV to ask me questions in the shell. Oops. :)
There is a yes all option look at the thing I posted in the post about the sdf tool
I'm painfully aware now, believe me. :lol:
Jobber72
Posts: 9
Joined: Sat Dec 01, 2018 1:32 pm

Re: Linux native flashing

Post by Jobber72 »

mike admin wrote:
Mon Jan 27, 2020 10:07 am
This works on all platforms via so-called "universal flash tool", also known as "sdftool". In a not so distant future this tool will be released as a standalone open-source tool, but for now it shares an executable with makemkv. Current makemkvcon has a "secret" command line argument - if the first command-line argument is "f" then istead of makemkv a sdftool is executed and the rest of command line is interpreted as a command line for sdftool. Just make a shell script named sdftool that calls "makemkvcon f $1 $2 $3 etc...", or just call "makemkvcon f arg1 arg2 arg3 etc..." directly

[/code]
Has anybody told you lately that you are absolutely awesome? :-) Great stuff. Thank you! (Linux user here ;-))
constantsc
Posts: 1
Joined: Mon Feb 24, 2020 7:06 pm

Re: Linux native flashing

Post by constantsc »

Ikkeetnavn wrote:
Tue Jan 28, 2020 8:54 am
stigger wrote:
Mon Jan 27, 2020 11:48 pm
Tried, but it didn't work, unfortunately. Not sure why.

Code: Select all

[Identification SDF] Drive autodetect string:
mtk:19:59:JBC6:ASUS    :BC-12D2HT       3.01:WM00900:-

# ./makemkvcon  f -d /dev/sr0 -f /tmp/sdf_0000006a.bin -v flash -i /tmp/k/mk-firmware-pack-20191206/MK/ASUS/BC-12D2HT/ASUS-BC-12D2HT-3.11-WM00300-211902271319.bin
Loaded SDF.bin version 0x6a

Unknown command

Command produced error code 0x8fffffff
I believe you just need to a minor adjustment to the command ­— "flash" is the command part which the console output describes as unknown. Calling it with "help all" will give the available commands and one small change was enough for my case.
Hello, fantastic application! Registered and been using from a few months now - with great success. My drive has been identified as being available for the LibreDrive firmware upgrade. I've attempted to do so but am getting an error that I can't find any references or help on. If anyone has some insight or suggestions it's be greatly appreciated.

Ubuntu 19.10, amd64
MakeMKV v1.14.7 [linux(x64-release)]
Executing as non-root user.
Using sdf_0000006d.bin (presume newest, also tried other sdf_ from _private_data.tar sdf_00000069.bin sdf_0000006a.bin sdf_0000006b.bin - same results).

Drive Information
OS device name: /dev/sr0
Current profile: BD-ROM
Manufacturer: HL-DT-ST
Product: BD-RE BP50NB40
Revision: 1.01
Serial number: SIM01I9FA4401
Firmware date: 2117-11-23 16:15
Bus encryption flags: 17
Highest AACS version: 68

LibreDrive Information
Status: Possible (with patched firmware)
Drive platform: MT1959
Harware support: Yes
Firmware support: No
Firmware type: Original (patched version available)
Firmware version: 1.01
DVD all regions: Possible (with patched firmware)
BD raw data read: Possible (with patched firmware)
BD raw metadata read: Possible (with patched firmware)
Unrestricted read speed: Possible (with patched firmware)

Code: Select all

makemkvcon  f -d /dev/sr0 -f ~/.MakeMKV/t/sdf_0000006d.bin --info
SDF.bin version: 0x006D

Drive Tool SDF not present

Drive Specific SDF present

[Drive Specific SDF] Embedded Info Strings:
8000:LibreDrive Information

8013:Status
8109:Possible (with patched firmware)

8001:Drive platform
:MT1959

8010:Harware support
8100:Yes

8011:Firmware support
8101:No

8002:Firmware type
8108:Original (patched version available)

8003:Firmware version
:1.01

8005:DVD all regions
8109:Possible (with patched firmware)

8006:BD raw data read
8109:Possible (with patched firmware)

8007:BD raw metadata read
8109:Possible (with patched firmware)

8009:Unrestricted read speed
8109:Possible (with patched firmware)


[Drive Specific SDF] Embedded Status Message:
8096:LibreDrive mode for this drive is only possible with firmware upgrade (id=%1)
:5861E4013FB5

Code: Select all

makemkvcon  f -d /dev/sr0 -f ~/.MakeMKV/t/sdf_0000006d.bin flash -i /usr/local/src/mk-firmware-pack-20200214/MK/HL-DT-ST/BP50NB40-NB50/HL-DT-ST-BD-RE_BP50NB40-NB50-1.02-NM00700-211811011016.bin
No drive tool logic found in SDF.bin
Internal error 0x8d000000
[/code]

Am I missing a supporting 3rd party package, library or executable?

Thank you!
sleepyguy
Posts: 1
Joined: Fri Feb 28, 2020 3:13 am

Re: Linux native flashing

Post by sleepyguy »

mike admin wrote:
Sun Jan 26, 2020 8:37 pm
MakeMKV has builtin (non-advertized) flashing capability. It is yet not exactly one-click user-friendly, but if you are OK with using command-line and not doing something stupid just in case, it is a lot more safer and user-friendlier than devilsclaw flasher. Please (anyone) PM me for details if you would like to use and test it.
Sorry, apparently I don't yet have access to PM. I've read this entire thread and it seems that the windows version differs from the linux. I have 1.14.7[win(x64-release)] installed.There is no sdftool. The makemkvcon tool produces this help text:

Code: Select all

C:\Program Files (x86)\MakeMKV>makemkvcon.exe f -d E: help all

MTK19xx firmware module v1.12

Commands:

  dump [auto|full|user] dumps firmware image
    dump full      - dumps full rom image (if not disabled in firmware)
    dump user      - dumps non-volatile user data
    dump auto      - dumps full image if possible, user data otherwise

  rawflash [main|full|<flags>] sends the image and flashing flags to drive
                               for flashing in self-update mode
    rawflash main  - flashes main firmware (this is the default)
    rawflash full  - flashes boot loader and main firmware (caution!!!)
    rawflash 0x..  - any flashing flags may be specified manually
What am I missing?
marukuru
Posts: 2
Joined: Wed Jan 01, 2014 6:24 pm

Re: Linux native flashing

Post by marukuru »

Tried updating my ASUSBC-12D2HT, but stuck with:

Code: Select all

Unable to load sdf.bin
Internal error 0xffffffff

Code: Select all

sudo makemkvcon f -d /dev/sr0 -flash -i ASUS-BC-12D2HT-3.11-WM00300-211902271319.bin
Also tried pointing to SDF.bin by using -f.

Code: Select all

$ sudo makemkvcon f -d /dev/sr0 --info
[sudo] password for user: 
SDF.bin version: 0x006D

Drive Tool SDF present

Drive Specific SDF present

[Drive Specific SDF] Embedded Info Strings:
8000:LibreDrive Information

8013:Status
8105:Enabled

8001:Drive platform
:MT1959

8002:Firmware type
8107:Patched (microcode access re-enabled)

8003:Firmware version
:3.01

8005:DVD all regions
8100:Yes

8006:BD raw data read
8100:Yes

8007:BD raw metadata read
8100:Yes

8009:Unrestricted read speed
8102:Possible, not yet enabled


[Drive Specific SDF] Embedded Status Message:
8099:Using LibreDrive mode (v%1 id=%2)
:05
:0C5D2E3D15D1


Identification SDF present

[Identification SDF] Embedded Info Strings:
8000:LibreDrive Information

8013:Status
8102:Possible, not yet enabled

8001:Drive platform
:MT1959


[Identification SDF] Drive autodetect string:
mtk:19:59:JBC6:ASUS    :BC-12D2HT       3.01:WM00900:-

Code: Select all

$ sudo makemkvcon f --version
LibDriveIo/SdfTool version: 2.01
HereInPlainSight
Posts: 1
Joined: Wed Apr 01, 2020 10:13 pm

Re: Linux native flashing

Post by HereInPlainSight »

sleepyguy wrote:
Fri Feb 28, 2020 4:04 am
mike admin wrote:
Sun Jan 26, 2020 8:37 pm
MakeMKV has builtin (non-advertized) flashing capability. It is yet not exactly one-click user-friendly, but if you are OK with using command-line and not doing something stupid just in case, it is a lot more safer and user-friendlier than devilsclaw flasher. Please (anyone) PM me for details if you would like to use and test it.
Sorry, apparently I don't yet have access to PM. I've read this entire thread and it seems that the windows version differs from the linux. I have 1.14.7[win(x64-release)] installed.There is no sdftool. The makemkvcon tool produces this help text:

Code: Select all

C:\Program Files (x86)\MakeMKV>makemkvcon.exe f -d E: help all

MTK19xx firmware module v1.12

Commands:

  dump [auto|full|user] dumps firmware image
    dump full      - dumps full rom image (if not disabled in firmware)
    dump user      - dumps non-volatile user data
    dump auto      - dumps full image if possible, user data otherwise

  rawflash [main|full|<flags>] sends the image and flashing flags to drive
                               for flashing in self-update mode
    rawflash main  - flashes main firmware (this is the default)
    rawflash full  - flashes boot loader and main firmware (caution!!!)
    rawflash 0x..  - any flashing flags may be specified manually
What am I missing?
That... looks like output from the sdftool, I would presume. It's telling you what it can do with that drive -- it can dump the firmware or flash the drive raw. It even specifies the firmware module. But to be sure I'd try to run makemkvcon.exe f --help', and if it starts with 'Use: sdftool', you're good.

That said, I can't PM yet, but as a Linux user, I'm very interested in this. My drive info from within makemkv itself is:

Code: Select all

Drive Information
OS device name: /dev/sr0
Current profile: DVD-ROM
Manufacturer: ASUS
Product: BC-12B1ST
Revision: 1.01
Serial number: <removed>
Firmware date: 
Bus encryption flags: 12
But, when I try to do anything of interest with the sdftool, I'm not sure if it has anything to do with the firmware date being missing, but I keep hitting a wall, which seems best surmised with:

Code: Select all

$ ./sdftool.sh -d /dev/sr0 help
No drive tool logic found in SDF.bin
Internal error 0x8d000000
and:

Code: Select all

$ ./sdftool.sh -d /dev/sr0 --info
SDF.bin version: 0x006D
Drive Tool SDF not present
Drive Specific SDF not present
Identification SDF present
Of the two missing -- am I supposed to do anything specific to get / provide them? It looks like my drive is supported, just not on this specific firmware, which is... obviously exactly what I'm trying to fix (though I'm not entirely certain if I'm supposed to update to the latest for my system and then downgrade to the BW-16D1HT 3.02 firmware, that seems like what's being recommended but I'm a bit too new to understand the exact benefits, people just keep saying it can be done).

Any guidance on what I'm missing to be able to at least update my firmware would be great.
olupome
Posts: 7
Joined: Mon Feb 01, 2016 7:29 pm

Re: Linux native flashing

Post by olupome »

Hi,
I am joining this conversation as I am in the same situation. I am trying to flash libredrive on my Asus BW-16D1HT in Ubuntu using makemkvcon/sdftool which returns the exact same output:

Code: Select all

sudo makemkvcon f -f /tmp/sdf.bin -d /dev/sr0 --info
SDF.bin version: 0x003E
Drive Tool SDF not present
Drive Specific SDF not present
Identification SDF present
kahomono
Posts: 7
Joined: Mon Apr 10, 2017 10:40 am

Re: Linux native flashing

Post by kahomono »

I have a BC12B1ST from Asus, and it needs the firmware upgraded from 3.00 to 3.01.

My problem is, that download is ONLY available from Asus as a Windows executable. No BIN file.

I tried inspecting said .EXE as an archive but there was nothing identifiable in there.

Suggestions?
mike admin
Posts: 4075
Joined: Wed Nov 26, 2008 2:26 am
Contact:

Re: Linux native flashing

Post by mike admin »

kahomono wrote:
Thu May 28, 2020 10:05 am
I have a BC12B1ST from Asus, and it needs the firmware upgraded from 3.00 to 3.01.
What makes you think that? Never upgrade the drive firmware if the drive works...
kahomono
Posts: 7
Joined: Mon Apr 10, 2017 10:40 am

Re: Linux native flashing

Post by kahomono »

mike admin wrote:
Sat May 30, 2020 9:12 pm
What makes you think that? Never upgrade the drive firmware if the drive works...
I am getting the message the Libre Drive functionality requires a firmware upgrade, and only 3.01 is on the Supported list for this model drive.
MartyMcNuts
Posts: 2951
Joined: Wed Nov 22, 2017 11:45 pm

Re: Linux native flashing

Post by MartyMcNuts »

kahomono wrote:
Sun May 31, 2020 11:14 am
mike admin wrote:
Sat May 30, 2020 9:12 pm
What makes you think that? Never upgrade the drive firmware if the drive works...
I am getting the message the Libre Drive functionality requires a firmware upgrade, and only 3.01 is on the Supported list for this model drive.
If you want to upgrade to 3.01 for LibreDrive compatibility, you can download the modified ASUS flasher + firmware pack from viewtopic.php?f=16&t=18933. The 3.01 firmware is located in the MK pack "old" folder.
Cheers :D
----------------------------------------------------------------------------------------------------------------------------
For UHD enabled drives (AU/NZ/SG + Others) & DIY Single Drive Flasher (WW): https://uhdenableddrives.com
mike admin
Posts: 4075
Joined: Wed Nov 26, 2008 2:26 am
Contact:

Re: Linux native flashing

Post by mike admin »

kahomono wrote:
Sun May 31, 2020 11:14 am
mike admin wrote:
Sat May 30, 2020 9:12 pm
What makes you think that? Never upgrade the drive firmware if the drive works...
I am getting the message the Libre Drive functionality requires a firmware upgrade, and only 3.01 is on the Supported list for this model drive.
Sorry for the delayed response. No, your drive is already supported with "beta LD v6" code, please see the sticky. And the SDF.bin with new code soon will be published for all...
Post Reply