Help: Trouble with the Signed LEB128

This is a discussion on Help: Trouble with the Signed LEB128 within the Android Forum forums, part of the Android Discussions category; Hi all, I had a problem with The signed LEB128 number An example like this: -624485 (0xFFF6789b) is encoded as 0x9b 0xf1 0x59. But when ...

Results 1 to 2 of 2

Thread: Help: Trouble with the Signed LEB128

  1. #1
    Android Lurker hoaibaotre's Avatar
    Join Date
    Jul 2012
    Posts
    6

    Exclamation Help: Trouble with the Signed LEB128

    Hi all,

    I had a problem with The signed LEB128 number

    An example like this: -624485 (0xFFF6789b) is encoded as 0x9b 0xf1 0x59.

    But when I followed description: LEB128 - Wikipedia, the free encyclopedia,

    1/ 0x 6 78 9B = 0110 0111 1000 1001 1011

    2/ I broke it into some groups (7 bit) + Add high 1 bits on all but last group form bytes

    0110 0111 1000 1001 1011

    ( 0 0110 01) ( 11 1000 1) ( 001 1011)

    (0 0 0110 01) (1 11 1000 1) (1 001 1011)

    (1 0 0110 01) (1 11 1000 1) (1 001 1011)

    0x99 0xF1 0x9B

    write on memory: 0x9B 0xF1 0x99 won't not equal to 0x9b 0xf1 0x59


    Why was the result wrong?

    Thanks,
    HoaND

  2. Android.net is the premier Android Forum. Registered users do not see these ads. .

  3. #2
    Android Lurker hoaibaotre's Avatar
    Join Date
    Jul 2012
    Posts
    6
    Hi friends,

    Follow this link about Variable Length Quantity (VLQ): Variable-length quantity - Wikipedia, the free encyclopedia

    I guested the Right chain convert value like this:


    0110 0111 1000 1001 1011

    ( 0 0110 01) ( 11 1000 1) ( 001 1011)

    (0 0 0110 01) (1 11 1000 1) (1 001 1011)

    (0 1 0110 01) (1 11 1000 1) (1 001 1011)


    Note: 1 is the VLQ represents a negative number.

    Am I right?

    Thanks,
    HoaND

Remove Ads

http://www.scramblerducati.org/

Sponsored Links

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

Similar Threads

  1. Replies: 0
    Last Post: 07-11-2012, 10:39 AM
  2. Please Help. having trouble installing new ROM
    By BLKZILLA in forum Samsung Captivate Hacking
    Replies: 3
    Last Post: 06-06-2011, 10:56 PM
  3. AT&T 4G trouble
    By cuneyyy in forum HTC Inspire 4G
    Replies: 23
    Last Post: 02-23-2011, 10:50 AM
  4. Trouble with MMS
    By cheddarbob41 in forum Motorola Backflip Tech Issues / Bug Reports
    Replies: 9
    Last Post: 06-30-2010, 04:10 AM
  5. Replies: 14
    Last Post: 06-07-2010, 09:11 PM

Search tags for this page

hoand hoaibaotre
,

leb128

,
leb128 convert
,
leb128 convertor
,
leb128 example usage
,
leb128 examples
,
signed leb 128
,

signed leb128

,
signed leb128 example
Click on a term to search our sites for related topics.
Android Forum