Api duet responses to Gcode sent
-
Also, if your goal is to monitor multiple printers from one page, please see:
-
it is not the web of control itself, but a personalized dashboard where you can see my 4 printers with duet, with touch screen.
I have seen that software, but I want to use it on touch screen and have buttons for each machine for quick access. preheat, change plastic, home etc ... and not have to open the web of each, although it is inside the dashboard as well.
I also want it to be with a personalized look. I can send the gcode without problem, but I would like to recover important values of the M122, but I think that there is no answer, only the buffer free space.
We are also working on a wireless screen, soon news!
-
@biketrial981 said in Api duet responses to Gcode sent:
Hi, sorry for my bad English, I'm using a translator.
I am creating a dashboard for my printers with duet and see all the centralized info. I have a question with the api:
Does not return response from the gcode sent?
For example, I can not see the response of an M122 for diagnosis?
Thank you!
The standard rr_status response indicates whether there is a reply, but you need to use the rr_reply HTTP request to fetch the reply.
-
Mostly, these interfaces "poll" for status. They generally do not look for the exact response to a given command. This makes them "self healing", if they miss an update for whatever reason, the next poll fixes it. In fact, the web interface included in the Duet (DWC) polls every 1/2 second. Personally, I think that's a bit excessive.
Anyway, polling the printer with a rr_status would seem to do what you want.
-
@biketrial981 "wireless screen, soon news" Looking forward to it!
-
@t3p3tony the idea started with the simple version, only informative.
But we found a wemos with stick, screen and 18650 battery cheap.
With this we can now launch commands and macros, in addition to changing some parameters.
The idea is to have something to move around the house. If you are in the room, have something on the table that indicates the state of the print and not depend on the phone. More than to replace the screen of the printer, it is a gadget or complement
-
@biketrial981 Ahh fair enough. I saw it more as a really easy way to add simple feedback on the printer - so you could grab your phone or laptop to make changes if required. No doubt people will use it for both $10 is pretty impressive for a screen + ESP+ addons. I hope you will release your firmware for it?
-
@t3p3tony Of course! In a short time we will have something already usable so that people can go playing and modifying it
-
@danal not to hijack the thread but is there a screenshot somewhere? I looked around your other threads a bit with no luck.
-
@dc42 said in Api duet responses to Gcode sent:
@biketrial981 said in Api duet responses to Gcode sent:
Hi, sorry for my bad English, I'm using a translator.
I am creating a dashboard for my printers with duet and see all the centralized info. I have a question with the api:
Does not return response from the gcode sent?
For example, I can not see the response of an M122 for diagnosis?
Thank you!
The standard rr_status response indicates whether there is a reply, but you need to use the rr_reply HTTP request to fetch the reply.
Thank you! with Request URL: http://192.168.0.13/rr_reply I can obtain the data that I was missing, for the advanced section of the dashboard
could it affect the printing consult the gcode M122?
the bad thing is that it returns plain text, if it were a json it would be wonderful xD
-
What would be the advantage in having the reply sent as JSON, given the that reply consists of plain text?
-
For normal use there is no advantage, but at the time of processing the data is much more comfortable indexes and to use a Vin.min for example and not having to parse all the text.
It is not something that contributes anything, and with a function it would not be complicated to create the json, but I understand that the use would be minor. I will try to do it in my server part, since I am interested in some data of the diagnosis gcode.
The rr_reply has helped me a lot
Sorry for my bad english!