Hello everyone, I am facing a common issue with my program. The program is designed to activate an AutoRetract feature for my actuator when buttons A and B are held simultaneously for 1.5 seconds. The AutoRetract feature runs until the movement is complete, even if the buttons are released. Additionally, pressing button B during the AutoRetract will stop the movement with a single press. While the setup works well in general, there is an issue where releasing button B slightly after button A triggers the stop command. I aim to only acknowledge the stop command after the AutoRetract has been active for 1 second. I made minor tweaks to the code to address this issue. However, during testing, I encountered faults related to "under voltage errors" when trying to stop the AutoRetract using button B, leading to the actuators shutting down and requiring a machine power cycle to reset. I have attached some images of the code for reference. The NTWK 62 command remains unchanged, as it triggers the AutoRetract. The additions include NTWK 64 and 65 to ensure that the SeatStop command only functions after the 1-second timer is complete when button B (SitToStandSwitchDown) is pressed. The final image illustrates the replacement of the previous button B variable with the NTWK65 variable. I believe there may be a simple solution that I am overlooking, causing confusion in the logic. Any assistance would be greatly appreciated. Thank you!
If you are confused about the surrounding logic, I am here to clarify. Any assistance you can provide would be greatly appreciated.
The initial issue arose from the logic stopping abruptly upon detecting B instead of A. To improve this, I suggest triggering the stop action on B's rising edge instead of using a timer. This will ensure that releasing A before B will not stop the process until the next push of B occurs.
Hi there! I think your issue might be related to how you're handling the delay and stop functionality. Perhaps, instead of placing the delay within the AutoRetract function, you could create a separate function, say, 'DelayStop' that activates only after button B is pressed and the AutoRetract has been active for the requisite time. This 'DelayStop' would then stop AutoRetract, bypassing any under voltage errors. An additional advantage would be reducing the overall code complexity, as now you don't need to check for the delay each cycle of the AutoRetract, but just once in the DelayStop function.
It sounds like you're dealing with a tricky situation! One thing you might want to check is how the timer and button presses interact in your code. It seems like the logic for button B could be conflicting with the state of your AutoRetract feature, especially if the stop command is being processed before the 1-second mark. You could try implementing a flag that only allows the stop command after the timer has elapsed, regardless of the button state. Additionally, reviewing how you handle the under voltage errors during the stop command could provide some insights as well—perhaps adding a buffer time before the system decides to stop to avoid those shutdowns. Good luck, and I hope you find a smooth solution!
It sounds like you’re on the right track with the timing adjustments, but the under voltage errors could indicate that there’s an issue with how the actuator is being controlled when you interrupt the AutoRetract. You might want to add some debounce logic for button B to ensure it registers cleanly without interference when stopping the retract. Also, double-check if the actuator can handle an immediate stop command without causing dips in power that could lead to those errors. Sometimes, implementing a small delay before allowing the stop command can help stabilize the system. Good luck, and keep us posted on how it goes!
✅ Work Order Management
✅ Asset Tracking
✅ Preventive Maintenance
✅ Inspection Report
We have received your information. We will share Schedule Demo details on your Mail Id.
Answer: - The issue is that releasing button B slightly after button A triggers the stop command, which should only be acknowledged after the AutoRetract has been active for 1 second.
Answer: - The AutoRetract feature is activated when buttons A and B are held simultaneously for 1.5 seconds. Pressing button B during AutoRetract stops the movement with a single press.
Answer: - Minor tweaks were made to the code, including adding NTWK 64 and 65 commands to ensure that the SeatStop command only functions after the 1-second timer is complete when button B is pressed.
Answer: - "Under voltage errors" were encountered, leading to the actuators shutting down and requiring a machine power cycle to reset.
Answer: - There may be a simple solution overlooked in the logic that is causing confusion. Double-checking the code and ensuring proper voltage supply may help resolve this issue.
Join hundreds of satisfied customers who have transformed their maintenance processes.
Sign up today and start optimizing your workflow.