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

Retry the laser status remotely #674

Open
magostinelli opened this issue Nov 14, 2024 · 4 comments
Open

Retry the laser status remotely #674

magostinelli opened this issue Nov 14, 2024 · 4 comments

Comments

@magostinelli
Copy link

Anyone knows if is ti possible to know the engraving process status remotely? Like an API top call, or otherwise a command from ssg that return the current status?

Thanks.

@cprezzi
Copy link
Member

cprezzi commented Nov 14, 2024

There is a qCount Event sent from server to client every 500ms whilst a job is running, but this does only tell how many gcode lines are in the server queue. This is not exact, because the firmware also has an own queue. See https://github.com/LaserWeb/lw.comm-server/wiki/API-(for-client-communication)

@cprezzi
Copy link
Member

cprezzi commented Nov 14, 2024

PS: You can connect to the server from multiple clients (or your own websocket app) at the same time.

@magostinelli
Copy link
Author

Thanks for reply, in the link posted there is runStatus how can i use it?

I'm looking at something like thie:
curl -s http://laserweb.local/status -> idle|ingraving|stopped

@cprezzi
Copy link
Member

cprezzi commented Nov 14, 2024

There is no http API. You need to connect to the server by websocket (socket.io). Unfortunately I can't help with that. You eventually can find out by reviewing the lw frontend code in https://github.com/LaserWeb/LaserWeb4/blob/dev-es6/src/components/com.js.

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