Compiling new self-developed plug-ins for PHL

Post Reply
yishen
Posts: 2
Joined: Tue May 16, 2023 10:10 pm

Compiling new self-developed plug-ins for PHL

Post by yishen » Tue May 16, 2023 10:25 pm

We have developed a new algorithm as a new mha plug-in. We are able to compile the source code in C++ in a windows machine and run it in windows without an issue. I'd like to be able to compile it to run on PHL.

Are there compilers and necessary software (e.g., "make", "libsndfile1 -dev", etc.) already installed with the standard software release of PHL, so that we can just copy our source code and compile it. If so, where should we place the file.

Alternatively, if we need to compile the plug-in on a separate linux system, we will still need some help on which files would need to be copied over to PHL and where.

If my question is not clear, please let me know, I will try to clarify more.

hendrikkayser
Posts: 39
Joined: Fri May 10, 2019 7:58 am

Re: Compiling new self-developed plug-ins for PHL

Post by hendrikkayser » Wed May 17, 2023 3:19 pm

We have started to prepare the PHL for compilation of plugins on the device, but the manual is not yet finished and the software may not be complete, yet. At least the required dev packages are available on the latest Mahalia image available under http://mahalia.openmha.org/
We will work on this in the future, but you may want to try yourself, see how far you get and report here.

In the meanwhile it might be the easiest way to set up a Raspberry Pi, compile the plugin there and scp it to the PHL into the /usr/lib/ directory.

yishen
Posts: 2
Joined: Tue May 16, 2023 10:10 pm

Re: Compiling new self-developed plug-ins for PHL

Post by yishen » Wed May 17, 2023 8:02 pm

Appreciate the answer. This is really helpful. It would be super convenient if we can just compile source codes right on the PHL. For now, we will do what you've suggested by setting up a Raspberry Pi and compiling our codes on it. I will report back if we run into any issues!

JacopoC
Posts: 2
Joined: Fri Oct 27, 2023 9:34 am

Re: Compiling new self-developed plug-ins for PHL

Post by JacopoC » Fri Oct 27, 2023 10:43 am

hendrikkayser wrote:
Wed May 17, 2023 3:19 pm
In the meanwhile it might be the easiest way to set up a Raspberry Pi, compile the plugin there and scp it to the PHL into the /usr/lib/ directory.

What version of Raspberry Pi would you recommend using for this?
Thank you very much!

nmichael
Posts: 16
Joined: Thu Nov 18, 2021 1:44 pm

Re: Compiling new self-developed plug-ins for PHL

Post by nmichael » Thu Nov 02, 2023 4:09 pm

JacopoC,

I've used an RPi 4 model B to compile a test plugin and other code for the PHL, but if you don't have one laying around you might want to wait a few weeks for a new Mahalia release before you buy one. There's been a lot of work on this lately for compiling directly on the PHL with progress from Dr. Shen's group and also Oldenburg, as Hendrik mentioned.

For now the instructions at
https://github.com/HoerTech-gGmbH/openM ... ILATION.md
describe what you need to do if you want to give it a try. Install the needed packages on a compatible platform (RPi or BeagleBone) then build.
Once your plugin module is built, move the associated *.so file to your PHL at /usr/lib.

Nick

JacopoC
Posts: 2
Joined: Fri Oct 27, 2023 9:34 am

Re: Compiling new self-developed plug-ins for PHL

Post by JacopoC » Fri Nov 10, 2023 10:38 am

In the end we did it using a Beaglebone Black we had and it worked!
Thank you.

Jacopo.

hendrikkayser
Posts: 39
Joined: Fri May 10, 2019 7:58 am

Re: Compiling new self-developed plug-ins for PHL

Post by hendrikkayser » Wed Jun 05, 2024 2:51 pm

Hi,
we just released a new version of Mahalia (operating system runnign on the PHL) which supports the compilation of single plugins on the PHL. An example that demonstrates this is available in the latest openMHA release 4.18.0.

The Mahalia 4.18.0-r0 disk image is available here .

Post Reply