Hello there,

If I wanted to program a GUI, should it be done via BELA IDE, or is there the option to program it somewhere else using
I'm still a beginner with BELA, but my plans are to program a multiFX either for guitar or for vocals. In any case I would like to implement a graphical interface, but I am not sure how it would interact with BELA.
Is there something in the beaglebone at a higher abstraction level that would use Bela as a slave, meaning I could program the GUI directly on linux, etc, or should it be programmed inside the bela IDE?

This part is a little bit confusing for me. Also, the userdata* parameter in the setup function..who configures this?

Cheers

    We give no provision to program a GUI in Bela. It's entirely up to you to create it and connect it to the audio engine.

    However there are a couple of places where we are doing that:
    among the examples you will find 05-Communication/scope-sliders. This shows how you can use some sliders which show up in the Scope window (open the "Controls" panel in the scope window) to send messages back to the running program. These messages are sent from the browser back to the node IDE over websocket, which then relays them to the running Bela project over UDP.
    The code as it is works, but it is a bit clumsy that we are using the scope window for that. You are welcome to use this interface if it suits you, or use it as a starting point. The relevant C++ code which does the UDP messaging between node and the running program is in core/Scope.cpp and include/Scope.h, while the javascript side is handled in dev/scope-src/SliderView.js and dev/scope-src/scope-browser.js.

    We also have a working example of connecting the running program to NexusUI. It is based on a 9-month version of the code, but it should still work https://forum.bela.io/d/156-web-server-on-bela/27 .

    hector_711 Also, the userdata* parameter in the setup function..who configures this?

    see here

      Just a little more info in case you have some experience with other GUI frameworks.

      If you're wanting to run the GUI on an LCD or some kind of HDMI monitor, then you have any flavor of GUI toolkit available that you would find in a typical Linux environment (GTK, QT, FLTK...).

      You can communicate with Bela using shared memory or just use sockets, similar to what giuliomoro suggested.

      The network socket method has an appeal because you can run the GUI from any kind of device, like a smartphone, tablet, separate Raspberry Pi & touch interface, etc. I don't know your goal.

      Either way you can run the Beaglebone as a typical desktop or tablet computer and do all your interactions without needing any separate devices if you want.

      The only part Bela plays is just to pass the audio in real time and process it. In the end all you need is a method to communicate to your audio application and receive status from it -- also look at the OSC examples.

        ryjobil giuliomoro
        Thank you both. I'm no high level programmer so I really need to learn about linux and how to approach this, but knowing how to communicate with the bela program is the first thing to know =)

        Let's see how it all goes =D

        a year later

        hi.

        i just got a bela-board 🙂 and wanted to continue this thread and point out a related project we are working on.

        the mentioned use-case of controlling a composition on a bela-board with a remote device (like phone, tablet, browser, ...) is the reason we developed rabbitControl: https://github.com/rabbitControl/RCP

        while OSC is always a way to achieve remote-control, we focus on automatic ui generation by reading the description of exposed values in a client and show ui-elements fitting the value-type or the widget-definition. no manual mapping is needed, using the libraries exposing a parameter is matter of a couple of lines of code.

        the protocol is almost (95%) done and ready-for-comments, the libraries are coming along as well. unfortunately the cpp library does not compile on bela, but i started to write a c implementation...

        maybe someone finds rabbitControl useful and interesting.
        happy for any feedback.

        a month later

        I'm particularly interested in this, but has anyone here done this wirelessly?
        If so, the HW? BLE or Wifi? Etc.

        3 years later