Change function to read .txt file for chart

Please don't ask the same question twice (Chart timestamp on x-axis not accurate). I am closing this one to avoid confusion. If the information you gave on the first one is no longer correct then comment further on that thread.