Commit graph

12 commits

Author SHA1 Message Date
tuxuser
272531aed5 Added rudimentary description to some *new* commands 2017-11-25 23:05:34 +01:00
Rena Kunisaki
89be7edab6 Update protocol.md
Add more commands and info

[Peter: typo fix and formatting]
Fixes https://github.com/Lekensteyn/lglaf/pull/18
2017-11-25 20:51:44 +00:00
Peter Wu
396409d3fa Make shell execution a bit more reliable
Previously you would not get feedback when quotes are not terminated or
when the command is too long. Fix this by putting stderr redirection in
the shell command, before eval.
2016-01-04 13:03:30 +01:00
Peter Wu
a1208e6723 Improve INFO GPRO field
Not just the first two bytes should match, it should be the expected
length. Found the hint in dmesg after failing to retrieve the properties
file. Setting all following bytes to 0xff does not seem to affect the
output, so let's keep it like this. The original software does send an
empty buffer though (with all zeroes).
2015-12-29 13:17:44 +01:00
Peter Wu
e7e9036fb9 protocol.md: Fix display of table 2015-12-29 00:59:17 +01:00
Peter Wu
6e2089a12a protocol.md: poweroff
Props to
https://github.com/ghassani/openpst/blob/master/extra/lafshell/laf.h
(which seems to be reverse engineered from the lafd output).
2015-12-29 00:26:53 +01:00
Peter Wu
ab642bd7c0 protocol.md: update erase, read, exec
Thanks to hints from /proc/kmsg, I found the IOCTL_TRIM_CMD (0x1277)
hint. From the kmsg, the meaning of "LAF" was also found (which could be
discovered via the lafd binary too...).

The whence option for read was observed by putting 0xffffffff in the
argument and was tried because the DLL showed a fourth argument that was
always zero.
2015-12-28 23:59:21 +01:00
Peter Wu
01efff446d protocol: Document Unlink
Found in lafd binary.
2015-12-27 18:45:31 +01:00
Peter Wu
d9aa205b17 protocol.md: fix WRTE offset response
Unlike READ, WRTE does not have the same meanings for request/response.
2015-12-26 21:30:14 +01:00
Peter Wu
82174eaa6c protocol.md: update CTRL and READ 2015-12-26 14:52:26 +01:00
Peter Wu
8f35f2f5b5 More protocol details, add property parser
Example output for parse-props.py:

    download cable             = 'USER'
    battery level              = 100
    download type              = ' '
    download speed             = 0
    usb version                = ' '
    hardware revision          = 'rev_10'
    download sw version        = ' '
    device sw version          = 'D85520t'
    secure device              = 'S'
    laf sw version             = '1.1'
    device factory version     = 'LGD855AT-00-V20t-EUR-XX-AUG-18-2015-16G+0'
    device factory out version = 'LGD855AT-00-V20t-GLOBAL-COM-AUG-18-2015-16G+0'
    pid                        = 'YE01S151002002500'
    imei                       = (redacted)
    model name                 = 'LG-D855'
    device build type          = 'U'
    chipset platform           = 'msm8974'
    target_operator            = 'GLOBAL'
    target_country             = 'COM'
    ap_factory_reset_status    = 3
    cp_factory_reset_status    = 0
    isDownloadNotFinish        = 0
    qem                        = 0
    cupss swfv                 = 'A1439892730-M1439892730-C1439940554-U1439940554-0'
    is one binary dual plan    = 0
    memory size                = 30777344
    memory_id                  = 'SDW16G\n'
    bootloader_ver             = 'MiniOS 3.0'
2015-12-25 15:16:42 +01:00
Peter Wu
c88a4289e7 Initial commit of docs 2015-12-24 20:03:03 +01:00