There is a great library developed by Stanford University for Fast Research Interface (FRI) of KUKA LWR that can be downloaded here. It has many useful examples but it lacks a Simple Trajectory Generator in Cartesian Impedance Mode.
I have developed one and can be downloaded:

You only require to import it to the main solution of FastResearchLibrary.