Thursday, December 19, 2013

Playing .mkv files with DTS audio codec on Sony Bravia

I have already blogged on how to play mkv files on "Sony Bravia HD 3D LED KDL-40HX750" TV. But for playing mkv files with DTS audio codec, there is one extra step we have to do before converting the mkv files to the m2ts files.

We need to convert the DTS audio codec inside the mkv file to AC3 audio codec. This is because, the DTS audio codec is not supported by the Sony Bravia KDL-40HX750. I used the script mkvdts2ac3.sh by Jake Wharton and Chris Hoekstra. This script converts the DTS track in the mkv file to AC3 track. And the usage of this script is very simple.

Get the script mkvdts2ac3.sh (on my ubuntu 12.04 LTS) as follows:

wget https://raw.github.com/JakeWharton/mkvdts2ac3/master/mkvdts2ac3.sh

Give the mkv file with the DTS audio codec as the input to the script as shown below:

The conversion starts and gets completed by displaying the summary on the conversion process as shown below:

Now the mkv file can be converted to the m2ts file with only the AC3 audio codec.

Thus obtained m2ts file can be played on "Sony Bravia HD 3D LED KDL-40HX750" TV.

Thursday, July 25, 2013

Patents search

'www.freepatentsonline.com' can be used for Patents search. In this site, we could list down the patents based on several search conditions. I.e. If we want to list down the patents filed by indian inventors, we should use ICN/IN in the search term. ICN stands for 'Inventors Country Name' and IN stands for 'India' (Country Code Table). Similarly the patents database can be searched for several other conditions.

For example, to search patents for 'heterogeneous multiprocessor' filed by indian inventors in-between the period 2007 to 2009, the search condition should be as follows:

APD/01/01/2007->12/31/2009 AND ICN/IN AND (heterogeneous AND multiprocessor)

The links listed below can be used to get introduced to the search condition keywords:
Also consider whether you would require 'Word Stemming' option enabled for your search. By default, it is enabled. Enabling this for a search term, it would search for all variants of a search term. If you would like narrow down the search in particular to your search term, then you just disable it. (for more info on this)

Wednesday, April 3, 2013

lldb for llvm-3.1


We had a cross-compiler tool-chain based on llvm-3.0. And we needed a debugger for the target. We chose lldb and we ported it for the target architecture. (Click here for somemore details). We used lldb svn trunk revision '142603'. We were able to integrate this revision of lldb into the llvm-3.0.

Recently the cross-compiler tool-chain has been upgraded to llvm-3.1. Since lldb depends on llvm, the lldb also has to be upgraded to a revision that would get build with llvm-3.1. (Note: The lldb svn trunk revision '142603' that we used with llvm-3.0 cannot be used with llvm-3.1. This is because lldb uses few modules of llvm for some functionalities such as expressions evaluation, disassembling. Hence changes in llvm would be reflected in lldb as it grows).

Till llvm-3.1, there is no sync between a llvm release and the lldb. And hence finding a right svn trunk revision of lldb that would work with llvm-3.1 is a little time-consuming task. The lldb trunk revisions are traversed to find the right revision that would work with llvm-3.1. And I found that lldb svn trunk revision 161210 works with llvm-3.1 after the following tweaks.

Change #1:
File: lldb/include/lldb/Expression/RecordingMemoryManager.h
Line: 284
Incorporated the changes from svn revision-164563 of this file. Added the following code:

    //------------------------------------------------------------------
    /// Passthrough interface stub
    //------------------------------------------------------------------
    virtual void *getPointerToNamedFunction(const std::string &Name,
                                            bool AbortOnFailure = true) {
        return m_default_mm_ap->getPointerToNamedFunction(Name, AbortOnFailure);
    }

Change #2:
File: lldb/lib/Makefile
Line: 60
Incorporated the changes from svn revision-164703 of this file. Removed the following line

      clangIndex.a \ 

Change #3:
File: lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp
Line: 1519
Incorporated changes from svn revision-164563 of this file. Changed the following line

        case DW_TAG_APPLE_Property:
to
        case DW_TAG_APPLE_property:

Change #4:
File: lldb/source/Symbol/ClangASTContext.cpp
Line: 361
Incorporated the changes from svn revision-164563 of this file. Changed the following line

    Opts.NoInline = !Opt;
to
    Opts.NoInlineDefine = !Opt;

After the above mentioned tweaks, the lldb is successfully ported to our target.