drmrs / auto_pen

Open Source 3D Printed Automatic Penetrator
34 stars 9 forks source link

chrt error #5

Closed daftandhungry closed 1 year ago

daftandhungry commented 1 year ago

Hi, I recently found this machine on reddit and decided to build it. I had a raspberry pi 3B, nema 23, driverand a 36V PSU laying around. The software all installed fine, when I use help and configure commands it works, but whenever I try to use the static, random, lock or unlock commands I get an error chrt: failed to set pid XXX's policy: Operation not permitted

Any ideas on why this may be happening and how I can fix it?

Thanks.

I also modified the case to make it bigger to fit the psu, added an IEC socket and switch instead of the dc jack, a mount for the pi, mounts for two buck converters to lower voltage to run the pi and a couple of 40mm noctua fans.

drmrs commented 1 year ago

Hey! Run the command as root. Let me know if that works.

Originally I had used a VERY slow raspberry pi gen 1 and I added some stuff behind the scenes to speed things up. Needing to run as root is one of the side effects.

daftandhungry commented 1 year ago

Running as root failed, until I installed again with sudo, no more chrt errors, atm I can't get the motor to move using auto_pen and your gpio setup, I have got the motor to move using a different configuration and code to test the motor actually works and got movement, so I will have to keep playing with it until I can work it out, 3d printing and design, I've got covered, but I know pretty much nothing when it comes to coding for the pi and troubleshooting, I only had the pi for octoprint.
Thanks for your help.