It is working fine as i already tested it with your attached file.
There are some constants there you can change it if required.