Create plane perpendicular to MarkupsLine from 1º point

I have 2 points in a MarkupsLine and I want to align a model perpendicular to this line from 1º line point. i should like to have a slider to rotate model arround itself throw this custom axis and another slider to traslate model all over the line.
Thanks on advance

This example in the script repository shows how to create a transform that rotates any node around a markups line. With slight modifications you can make it do exactly what you need (e.g., position the object at the line endpoint, etc).

These programming tutorials explain how to create a module with a GUI, such as node selectors for the line and model and a slider for controlling the rotation angle.