The period argument is supposed to be the number of samples since the last update.
Attach a file by drag & drop or click to upload