Solving audio delay (lag) with Yamaha YAS-306 surround system

The problem

I recently experienced huge (> 400 ms) audio delay with a YAS-306 sound bar when connected to a TV using the supplied Optical audio cable.

After updating the YAS-306 firmware (via MusicCast app) and checking the TV audio settings, I identified the root cause of the problem.

The solution

The problem seems to be caused by multi-room being enabled (Two Yamaha devices are linked). Then applying a solution is simple : disable multi-room link when watching TV.

To test the result or identify your lag, use this great Twitch video on youtube.

Here’s a link the device owner’s manual which shows how to setup audio delay with the remote.

I contacted Yamaha support on May 19th 2018 about the matter.

Configuring Tango VDSL with TD-W9980 modem

Configuring a xDSL router for the Luxembourg Tango ADSL/VDSL provider.

In Luxembourg, if you opt to use your own router, you will get no support from Tango to configure it. For the people who don’t enjoy having a FritzBox (from AVM), here are the steps to configure your own VDSL modem.

Modem : TD-9980 from TP-Link
Provider : Tango Luxembourg

My internet : Tango Blue 30 Mbits

Configuring DSL settings

DSL settings on TD-W9980 admin page

DSL Modulation type: VDSL2
Annex Type : should be in the mail received from Tango, mine is Annex A

Configuring WAN settings

WAN Settings on TD-W9980

VLAN ID : 35
Connection Type : PPPoE
PPP Username & password : provided by Tango

Splunk : Indexing multi-events JSON data


  • Splunk : Splunk light 6.2.6
  • OS : MacOSX 10.10.3 (Yosemite)


Index a multi-event JSON file with Splunk properly

Source JSON

I had a single line JSON, pretty print is only to ease the reading


  • TIME_PREFIX : Regular expression that tells Splunk where to find the date of the event. In my case it was : “Starting with double quotes, followed by ‘create_at’, followed by double quotes, followed by a colon and finally followed by a space”.
  • TRUNCATE : Don’t truncate after reaching a length limit. I needed this because I had I single JSON line.
  • LINE_BREAKER : When parsing the file, when should Splunk decide to create a new event ? In the above example, that would be between ‘}, {‘. Notice that the capture group only contains ‘,’. When reading the documentation, you will find out that everything before capture group is evicted from the final events.
  • SHOULD_LINEMERGE : Don’t merge my events once you’re finishing with the extractions
  • SEDCMD-remove_header: SED expression that will remove all the trash JSON before the ‘comments : []’ section
  • TIME_FORMAT : Instructs Splunk what is the format it should expect when parsing ‘created_at’
  • SEDCMD-add_closing_bracket : Since LINE_BREAKER above is removing our trailing ‘}’, we need to add it back to every event.
  • crcSalt : Instructs Splunk to use the filename instead of the salt in order to estrablish the uniqueness of your file. I don’t need this, because I have no log rotation in place. Therefore it is safe to use the filename.
  • SEDCMD-correctly-close : Since we did a cleanup in the beginning of the file by using SEDCMD-remove_header, we have to cleanup the end of the JSON. In plain english it says : “Replace ‘} ] }’ by ‘} }'”

Result in Splunk

Indexed JSON file on Splunk

Useful links

Gigabyte BRIX : Installing CentOS 7

I was tired of using Ubuntu for different reasons, and I wanted to give a try on CentOS 7.

  • client side steps were performed on a Macbook air running OSX Yosemite 10.10
  • server side steps are done on a Gigabyte BRIX model GB-XM12-3227 rev 1.0

1. Preparing the ISO

Download the ISO from the CentOS official download website. The image is 666 MB.

Convert the ISO to URDW by typing the following in your MacOS terminal

2. Preparing the USB drive

Insert your USB drive, and backup any existent files.
Get the disk name by typing

Partition de disk using the correct disk name

Copy the CentOS image to the USB drive

Eject the disk, and we’re good to go

3. Installing on BRIX

Plug a USB keyboard on the BRIX, plug the USB key, and then press F12 like your life depends on it.

You should be prompted with the boot options. Choose the appropriate one, and from there you shouldn’t face any issues.

I did had to play a little bit with the mouse because the keyboards shortcuts were driving me crazy when I was deleting and creating partitions.

sources :


CentOS 7 : Wi-Fi Hotspot

My Wi-Fi card (RTL8188CE) doesn’t have the reputation one could envy. Since I use ethernet for internet access, find below the steps to create a Wi-Fi hotspot that will allow you to share your internet connection over Wi-Fi on CentOS (I’ve also successfully tested this with Ubuntu 15).

What we want ?

Create a Wi-Fi hotspot that shares the internet connection from the ethernet cable. That’s it.

What will we need ?

I stumbled accros create_ap a few weeks ago. It’s simple, easy to use and it WORKS magi-perfectly. It has a lot of little hacks that addresses some of known issues with some adapters and wifi modes.


1. Install required packages and create_ap

2. Get your network cards information and test

Since CentOS 7 uses a different naming convention for the network cards, find the label of your card by typing

Once you get them, test create_ap :

3. Make create_ap start on boot

Copy the provided .service file to the systemd folder

Modify the create_ap.service file to include your adapters labels and add other desired options.

Mine looks like this :

Enable the create_ap daemon on boot and start it

I might be wrong but after installing, you can delete the create_ap folder

PLEX DLNA issue with MKV / Panasonic VIERA

My Panasonic VIERA TX-42ASM651 and DLNA weren’t 100% working with the Default profile that comes with Plex media server. The symptom was that the TV was unable to play MVK files and prompting the error : “Failed to read file”. Additionaly, the video format displayed by the TV when browsing was : “video” instead of “mkv

By turning on the DLNA logs, I’ve found this :

When you check the shipped profile (this one) you see that dca is not part of the supported formats.

Find below a modified version that worked well for mkv files in my case, I had to slighty modify the following line:

Make sure to place it under : <PLEX_HOME_FOLDER>/Profiles/Panasonic Viera 3D TV.xml and not modify the existing one

if the file loads correctly, you should see :


SickRage issue with Torcache


  • SickRage not downloading any torrent.
  • You could see the following in your SickRage logs :2015-01-15 22:51:05 WARNING SEARCHQUEUE-DAILY-SEARCH :: Connection error HTTPConnectionPool(host='', port=80): Max retries exceeded with url: /torrent/92C32E1489F5248616C25AA2FF08EAB47FB29B66.torrent (Caused by : [Errno 11001] getaddrinfo failed) while loading URL

Possible cause

  • Your ISP might be blocking the domain

How to validate ISP blocking

Using terminal, ping torcache

If you get this,
ping: unknown host

then validate torcache is not down by using this website

If you get something like this

Torcache status

Torcache status

Then your ISP is blocking the domain.

How to overcome ISP blocking

To overcome the limitation, you need to use an alternative DNS. There are a lot of free and paid DNS out there, just use Google. You then have too ways of changing that.

Router settings

Navigate to your router settings and add the new DNS server (ie: – Google’s one)

Ubuntu network settings

This option is better if you don’t want to change the router settings. I don’t use Network Manager so I’m not sure if this solution works for everyone. I’m using Ubuntu 14.10

Add this to your /etc/dhcp/dhclient.conf
append domain-name-servers;

This way, you don’t loose your ISP DNS entries, you just add additional ones for the hosts he doesn’t find.

After the change, reboot and then you’re good to go
PING ( 56(84) bytes of data.
64 bytes from icmp_seq=1 ttl=53 time=72.6 ms
64 bytes from icmp_seq=2 ttl=53 time=51.1 ms
64 bytes from icmp_seq=3 ttl=53 time=39.5 ms
64 bytes from icmp_seq=4 ttl=53 time=61.3 ms

Getting daily Boxcar 2 notifications for Deluge downloads

Context : I have a headless Ubuntu HTPC with Sickrage, Couchpotato, Deluge, and XBMC (now called Kodi) installed

Use case : I wanted to know all my current torrents status without having to daily connect to my remote Deluge

Solution : Python script that uses deluge-console to extract information from Deluge and send a Boxcar2 notification. From my iPhone, I’ve being using Boxcar2 as a replacement to the paid and well know Prowl.

How it works : A cronjob calls daily the python script at a fixed time

How it looks like on iOS (Boxcar2 app) :

Boxcar2 notification - downloads paused

Boxcar2 notification - downloads active

Python script :
aside note : I’m not a Python developer and I don’t pretend to be one

The original script contains more stuff, and some logic was removed for the sake of the article. I’m pretty sure that for the only purpose of only sending Boxcar2 notifications, it could be trimmed down to 5 lines.

In the following script, replace REPLACE-WITH-USER-TOKEN by your boxcar2 token

And finally, the crontab (must be done using the same user used by Deluge) :

Video tearing fix for Gigabyte BRIX @ Ubuntu 14.04 LTS

Feedback after the update from Ubuntu 13.10 to 14.04 LTS  – Video tearing problems

The installer completed the update without any noticeable problems.

After the computer rebooted, my auto lightdm login settings brought me directly (as usual) to my XBMC welcome home screen.

However, I noticed that my HDMI video output was sluggish, with a lot of video tearing (

After a lot of research, I discovered that a bug with libsdl was causing this.

Solutions can be found here :

I personnally chose to update the library, cf :



No central speaker audio on XBMC 13.0-ALPHA11 and Ubuntu Saucy

In the last few days, I’ve decided to update my HTPC ubuntu to Saucy (13.10). In the same time, I added the XBMC nightly repository ( in order to provide some feedback to the XBMC community.

However, in the last days, maybe after a reboot, I’ve lost the audio from my central speaker (in my 5.1 audio system). It was very weird, because I had all ambiant sounds but no voices at all.

After some digging, I saw that XBMC was using the PulseAudio driver. After fighting myself to make PulseAudio work correctly, I’ve decided simple and plain to remove it by issuing :

apt-get remove pulseaudio  gstreamer0.10-pulseaudio

So audio is now handled directly by ALSA and no problems so far.


Doing that I have a fully working 5.1 audio but keep in mind that if you remove PulseAudio you loose a lot of configuration options (includes audio volume per application).

Related :

© 2018 jmichelgarcia

Theme by Anders NorénUp ↑