Preload 30 seconds of historical data when the chart initializes.
Use setInterval() (or OnTimer() equivalent) to push new data every second.
setInterval()
OnTimer()
Remove old points to keep the chart at a fixed range (e.g., 30 seconds of data).