CLIENT
Sibex LLC
OVERVIEW
The being described project includes both hardware and software parts: standalone electronic device + PC software. The main purpose of this complex is to input the desired positioner's setting in manual mode and to watch it's actual position. Comparing both desired and actual trajectories can really help in situations when someone is about to somehow serve the positioner, to adjust it and/or to increase its accuracy.
GOALS
The requirement list to software part is presented below. It has to be able to:
- discover and to connect to plugged device via USB2.0 FS HID interface continuously in the background;
- create / save / load from file previously created SRD991 control charts;
- execute active control chart with simultaneous displaying of desired and actual position of SRD991;
- generate report according to the results of control chart execution in PDF format;
- notify the user in case of any of the following device-related situations:
- any current loop (command or feedback) breakup;
- any current loop short-circuit (overcurrent protection);
- device overheating;
- perform low-level calibration of device's input measumerent channel;
- be Microsoft Windows and Linux OS compatible;
The electronic device must satisfy to the following requirement list:
- power supply from USB port: 5V and 500 mA (max);
- data exchange with PC software via USB2.0 FS HID interface;
- full galvanic isolation of device's interfacing, generating and measuring parts between each other;
- command current setting error: < 0.2%;
- feedback current measumerent error: < 0.5%;
Being powered on the device has to perform the following tasks in continuous mode:
- to perform full data-exchange with software;
- to generate current in command current-loop according to received via USB setting;
- to measure current in feedback current-loop;
- to perform self-diagnostics in background with fast reaction in any case;
SOLUTION
The device block diagram is shown below:
All hardware including schematic and PCB topology was designed with open-source KiCAD. The firmware for device's STM32F0 series MCU was developed with heavy usage of Eclipse + GDB + OpenOCD.
The Qt5 toolkit was chosen as a basis for the target software implementation. The Qwt library was selected to add 2D-charts rendering functionality with pan/zoom/scroll ability. To implement data exchange via USB the hidapi library was deployed. The cross-platform support has become a nice feature of each of mentioned earlier libraries.
Below you may see the screenshot of the target application with Russian UI translation in Linux environment:
On the next screenshot you may see zoomed-in area of the source chart that contains transition of the SRD991:
The demo-report that was generated by the software can be shown on the following link