Skip to content

Conversation

@maxpmick
Copy link

New Package

Remote Timeout: fixed 1s remote disconnect safety package

Description

  • Functionality: Adds a small safety script that monitors remote input age via get-remote-state and sets motor current to zero if age > 1.00 s.
  • Why: Some VESC-based devices do not properly implement the UART timeout feature in VESC Tool, and as a result, have an extremely unsafe failure mode that treats the last received throttle position as good indefinitely (ask me how I know).
  • Behavior:
    • Fixed threshold: 1.00 s remote command age threshold
    • Auto-start: Start once from Packages to save; then auto-runs on boot (image-save).
    • Compatibility: ESC-only install (pkgdesc lists compatibility).
  • Files:
    • timeout/timeout.lisp
    • timeout/pkgdesc.qml
    • timeout/Makefile
    • timeout/README.md
    • Root Makefile and res_all.qrc updated to include package

@maxpmick
Copy link
Author

My first ever PR by the way, I hope everything is formatted properly.

I have yet to fully investigate the possible firmware issue causing this problem, but I have confirmed that the UART timeout feature is completely non-functional on certain VESC-based Chinese devices.

This package is my quick fix to allow myself and others to easily add this much needed safety feature to their boards/vehicles until the issue is resolved by the manufacturer.

I specifically chose to make a PR on the main vesc_pkg repo so that VESC Mobile App users are able to implement this fix by installing it from the official package list.

@surfdado
Copy link
Contributor

Nice! You could have just squashed all 3 commits into a single one since this is a whole new package...

@maxpmick
Copy link
Author

Nice! You could have just squashed all 3 commits into a single one since this is a whole new package...

Ah, got it, yeah it's my first time doing a proper fork and then merge, I didn't know it would keep them separated like that.
I'm learning!

@vedderb
Copy link
Owner

vedderb commented Nov 5, 2025

I didn't see this one, sorry about that.

I think what you are trying to do with the package is already done by default with the regular timeout. It would only get the behavior you are describing if something else keeps resetting the timeout while the remote input stops or if the timeout is disabled in the config.

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants