Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation regarding TunnelMessage #8

Open
MoreRustLessAccess opened this issue Nov 20, 2024 · 2 comments
Open

Documentation regarding TunnelMessage #8

MoreRustLessAccess opened this issue Nov 20, 2024 · 2 comments

Comments

@MoreRustLessAccess
Copy link

o/

Hey, I've been fiddling around with the spike making it remote controllable, which I need 2 way communication for.
Currently I've been using file uploads in a spesific format with the bot polling for those and printing lines of json... which isn't ideal.
I saw TunnelMessage was a thing a while ago, however didn't have time back then.
Anyway now I do have time now to try fiddling around with it, however the documentation around it doesn't help much so I feel a bit lost.
I tried sending a "hello" payload, however that seems to just crash the spike (my frame: 6 49 7 4 119 102 112 119 2). Unsure if the crash is because of me misunderstanding TunnelMessage or just a weird bug in my typescript spike implementation showing up here.

@SteffenLEGO
Copy link

Tunnel messages are definitely the right tool for the job, I think maybe what you are running into is a known issue where the hub crashes if it gets a tunnel message while not running a program.

Since you need a program to be able to pick up the tunnel message anyway it shouldn't be too big a deal, but I do think there is a fix planned for the crash, as obviously that shouldn't happen.

If you are already running a program on the hub when this happens, please try to provide reproducible steps, and I'll take a look and see if I can help find the issue.

@MoreRustLessAccess
Copy link
Author

MoreRustLessAccess commented Nov 20, 2024

I did forget to start the program, however it does not seem to matter as it crashes regardless of if a program is running or not.

Reproduction steps:

  1. Upload this program to the spike on slot 0
while True:
    print(input("Waiting"))
  1. Start the spike program on slot 0
  2. Send Info request (0 0 2)
  3. Send TunnelMessage with "hello" as the payload (6 49 7 4 119 102 112 119 2)
  4. Observe the spike crash

This is probably not the way to accept messages on the spike, however I couldn't find any docs around it so just trying things and hoping something works.

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

No branches or pull requests

2 participants