Pressure (vaccum) regulation by OpenPnP

107 views
Skip to first unread message

Josef Plasil

unread,
May 27, 2023, 9:20:55 AM5/27/23
to OpenPnP
Hi OpenPnP gurus,
I built 0816 feeders Arduino shield and as I have got vacuum pump connected to this shield, I would like to use it for vacuum pressure regulation; simple on/off with hysteresis would be enough. I have got also 1/2 litre reseivoir for this purpose, connected before valves. Does exist some way to do pump regulation directly from OpenPnP, please? I have got configured pump actuator (commands "M155 D3 S0" and "M155 D3 S1") working as OFF/ON commands as well as reading pressure value, when I press the read button in the actuator window ("M144 A0" command). Therefore I would like to create script, which is periodically reading the pressure value and based on this switching off/on the pump. But despite I tried to find principle on web, it doesn't seem script could be periodically run by the OpenPnP core ... Any ideas, please?
Thx for reply. Regards, Josef.

mark maker

unread,
May 27, 2023, 12:41:06 PM5/27/23
to ope...@googlegroups.com

Hi Josef,

This is not possible with the current OpenPnP and it is also difficult to generalize, because of the nature of G-code controllers.

I even started an implementation of polling, but then abandoned it because of that. The G-code drivers spend most of their time being blocked, waiting for an M400 and during that time, no polling is possible.

It would work, if there is a dedicated driver/controller, but since most machines control the vacuum with the same controller as the motion, I found it is not worth the effort.

The best solution is to implement it on the Arduino. That's also how Smoothie and other controllers do it.

See the config  here (end of article):

https://makr.zone/vacuum-sensor/192/

_Mark

--
You received this message because you are subscribed to the Google Groups "OpenPnP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openpnp+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/openpnp/aee410ea-94bd-442d-b29b-8cc0a2ea6c6en%40googlegroups.com.

Josef Plasil

unread,
May 28, 2023, 1:01:08 AM5/28/23
to OpenPnP
Dear Mark,
thank you so much for your explanation. I got it and I will do it in the firmware of 0816 feeders driver ;-). It was just the effort to centralize everything in one place, you know.
What I am also solving is finding fiducials on the board(s). Everything works like a charm (even reference fiducial during homing, feeders holes detection, etc.) , but when I try to find fiducials on the board, it failes = places fiducial in different place (example attached) or din't find fiducial in area set, I don't know why. It is true fiducials are not mandatory, but I as I can see on the web, others are successful. I am attaching 2 pictures ... one without detection and after detection. The system detects fiducial on the place, where I cannot see any difference in picture. Why?
Thank you for your advise.
Kind regards, Josef.
Dne sobota 27. května 2023 v 18:41:06 UTC+2 uživatel ma...@makr.zone napsal:
FiducialIssueBeforeDetection.png
FiducialIssueDetected.png

mark maker

unread,
May 28, 2023, 6:05:29 AM5/28/23
to ope...@googlegroups.com

Hi Josef

please open a new discussion topic for that new problem. 😎

And while you're at it, please proceed as described heren and send native image and units per pixel, and report the fiducial diameter:

https://github.com/openpnp/openpnp/wiki/FAQ#how-can-i-get-a-native-camera-image

_Mark

Josef Plasil

unread,
May 28, 2023, 11:33:09 AM5/28/23
to OpenPnP
Dear Mark,
again, thank you for your help.
I am sending the modified firmware of 0816 feeders driver (as Arduino Mega Shield, changes are commented by "jopl" word), which is responsive for command "M155 D3 S2 P-40 H10", where P is pressure value and H is hysteresis value). Of course, one should set scaling factor as well as offset of analog input 0 appropriately (to have range of pressure -100 to 0, i.e. serial command "M145 A0 S0.10 O-93" in my case).
After that, you the output 3 will switch the pump based on sensor value.
There are also gerber files, schematics and layout picture of my board in the 2nd zip file in the attachment.
Regards, Josef.
Dne neděle 28. května 2023 v 12:05:29 UTC+2 uživatel ma...@makr.zone napsal:
OpenPnP_Feeders_0816_Shield.zip
0816FeedersDriverFWjopl.zip

mark maker

unread,
May 28, 2023, 11:40:15 AM5/28/23
to ope...@googlegroups.com

Cool!

Note I'm not involved with the 0816 feeders. Separate project, made by others. I guess this is the root project, don't know if there are newer forks:

https://github.com/mgrl/0816-feeder-firmware

You should make a Pull Request to where you got it from. If you're not accustomed to Github, it is easy to learn! 😎

_Mark

Reply all
Reply to author
Forward
0 new messages