Single axis motion completion, interpolation motion completion;
Comparison Matching (CMP) trigger;
HSL communication incident.
Users can achieve real-time response by registering an Interrupt Service Program (ISR), such as immediately stopping axis motion when a limit is triggered, or triggering camera capture when a match is made. Reasonable use of interrupts can effectively reduce CPU polling load and improve system real-time performance.
Debugging and Troubleshooting Guide
In practical engineering, common problems and solutions:
Troubleshooting steps for possible causes of fault phenomena
Motor not rotating, pulse output wiring error or driver not enabled to check OUT/DIR differential polarity; Measure pulse output with an oscilloscope; Confirm that the SVON signal has been raised
The encoder feedback value jitter differential signal is interfered with or the cable is too long, using shielded twisted pair, and the shielding layer is grounded at one end; Reduce encoder line length (<1M recommended)
Invalid limit trigger, incorrect wiring or polarity setting of limit switch. Check the voltage of PEL/MEL pins (24V or 0V); Monitor signal status in MotionCreator
The HSL communication red light is on, and the bus is disconnected, the substation is not powered, or there is an ID conflict. Check the network cable connection; Confirm the power supply of the substation; Check if each slave station ID is unique
Analog output nonlinear D/A output overload (<2k Ω), increase buffer operational amplifier; Reduce load current
Call SetInterruptEvent() and check PCI interrupt allocation (IRQ) if the interrupt enable bit is not set or the interrupt line is not connected after the completion of the exercise
In addition, it is recommended to use MotionCreator to test the jog, zeroing, and limit response of each axis one by one during the first power on, to ensure that the hardware is correct before proceeding with code development.
Multi card expansion and system performance optimization
A single system can support up to 6 cPCI-8168 (48 axes in total), please note when expanding:
Assign different base addresses and interrupt numbers to each card (automatically assigned through PCI plug and play);
Multi card synchronous motion can be triggered by software to achieve microsecond level synchronous startup;
Each card's HSL network is independent and can control different slave station areas separately to avoid bus data conflicts;
In terms of performance optimization, it is recommended to allocate high-frequency interrupt tasks (such as position comparison) to one card, while other cards are responsible for regular motion and balancing CPU load.
