How do you plot a graph where $y$ increases in short bursts and not linearly? I am wondering if it's possible to plot this sort of graph with one equation.


Note: the application of what I am doing is for video animation, but I
  am just asking for the mathematical explanation; software has nothing
  to do with this.

For context, $y$-axis is rotation in degrees, and $x$-axis is time in seconds. The item rotates 30 degrees every half second. I wonder if it's possible to plot a graph more like the red line, where the rotation ($y$) will accelerate and decelerate to almost a stop at every 30 degrees.
Is there a name for a graph like this? I don't think I would call it an oscillation or a saw-tooth or something.

Hint:
You can use a function like 
$$
y=ax-b|\sin (cx+d)|
$$
adjusting  the constants $a,b,c,d$.
