News:

SMF - Just Installed!

Main Menu

pisound-btn coming back

Started by benh, October 27, 2021, 12:19:48 AM

Previous topic - Next topic

benh

Hi !

I noticed that pisound-btn was running and eating up quite a bit of CPU in fact, on what is a reasonably fresh re-install. I suspect and apt-get update caused the service to be restarted.

I wonder if it's worth taking it out completely from setup.sh, ie, apt-get remove pisound-btn.

The consequences as far as I can tell will be:

- It takes out these packages: modep-btn-scripts modep-ctl-scripts pisound-btn pisound-ctl pisound-ctl-scripts-common pisound-ctl-scripts-puredata
  pisound-ctl-scripts-system. Do we have anything that relies on any of these ? A bit of grepping around didn't show anything obvious but I'm not
  quite an expert in pi-Stomp yet :-) I took them out here, rebooted and things seem to still function.

- The hostapd configuration (hotspot mode) is part of the pisound-btn debian package, including the dhcp config and the systemd service. I don't know
   if we can convince Blokas to split these into a separate debian package, I'll ask, but in the meantime, we could just ship our own versions of these
   in pi-stomp/setup and copy them over.

Thoughts ?


benh

So Blokas is happy for me to split the hostap config to a separate package. I'll work on that when I get a chance

Randall (Admin)

That's good news.  So pisound-btn getting restarted is a real problem.  It assumes the button is connected to GPIO 17, which pi-stomp uses for... drumroll please... the encoder.

If you had pisound-btn running on your system, I can almost guarantee that was interfering with your encoder.  It can even do crazy things like shutting down, switching wifi, etc. because those operations are control-able via the PiSound button.

So yes, we must make sure it does not start.  I had thought that 'systemctl mask' would assure that, but yes, perhaps we should remove it knowing that it'll never be compatible with pi-Stomp.

benh

Yes mask should work ... except the .deb package install script turns it back on :-)

benh

So sadly, simply not running pisound-btn (I have it removed locally) does NOT fix the encoder. It really needs to be turned very slowly so lengthen the pulses for it to work in polling mode with the current 10ms polling. Works fine with the interrupts patch

benh

See my updates here: https://community.blokas.io/t/split-wifi-hotspot-config-from-pisound-btn-package/3391/7 on moving the wifi hotspot bits out of pisound-btn to a new patchbox-wifi, so we can properly remove pisound-btn

Randy, is there anything else in pisound-btn that we might depend on ? Do we use the BT stuff ? I can move it too later if needed.

Randall (Admin)

Nice.  pi-Stomp does not have any explicit dependency on pisound.  It could share some package dependencies but I don't see any that would leave pi-Stomp incomplete.

BT isn't used by pi-Stomp but could be useful for an OSC client, etc.

I did disable hciuart:
https://github.com/TreeFallSound/pi-stomp/blob/master/setup/services/stop_services.sh

which I mainly did to avoid CPU cycles being spent on it, but also to avoid possible conflicts when a MIDI interface is using the UART via GPIO's 14 and 15.

benh

Right. So if/when Blokas takes my change, we'll be able to remove the pisound-btn package and keep patchbox-wifi, which should solve this (and the pisound-btn package updates re-starting its service)