Integration of JoyStick for PTZ

We are integrating a joystick through a browser to control the PTZ of the camera through the Milestone .net API. We are struggling with the smoothness of the control - is there any documentation on how to integrate a joystick into MIlestone or has anyone done it before. I know using a joystick directly through Milestone works well - trying to get this same performance through the API.

Could you please explore PTZandPresets sample? It might be helpful.

https://doc.developer.milestonesys.com/html/index.html?base=samples/ptzandpresets_sample.html&tree=tree_search.html?search=ptzandpreset