GUI-O Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login

    Number of widgets limited to 28

    Scheduled Pinned Locked Moved
    Report Bugs
    2
    9
    508
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • P
      pcu
      last edited by

      Hello,

      I'm working with the pro version.

      I have an app in communication with a ble ESP32 and 30 widgets, the last two widgets are not displayed.

      With gui-o-designer + ethernet it works fine, but the same init code in the ESP32 (BLE mode) doesn't work well. The last two widgets are not visible.
      If I removed some of the first widgets, the last two widgets are then displayed.

      May be there is a limitation with the number of widgets, or a time-out in the loading in the "@init" ?

      Pierre

      K 1 Reply Last reply Reply Quote 0
      • K
        kl3m3n @pcu
        last edited by kl3m3n

        @pcu Hi,

        there is no limit on the GUI-O application side in PRO version. There is a timeout on the @init request, but is dismissed when the first message is received.

        Maybe you are hitting some buffer limit on the ESP32 side? Can you try putting some timeouts between each message sent from the ESP32?

        Best regards,
        kl3m3n

        1 Reply Last reply Reply Quote 0
        • P
          pcu
          last edited by

          Hi,

          Thank you for your answer.

          The result is random. Sometimes it works, sometimes it doesn't.

          What I did (and should have done at the beginning) was to sniff the BLE with my Nordic dongle and Wireshark.
          And I see that sometimes the last 2 messages are not sent from @init of the ESP32

          Adding more time to the 'sendMsg' function doesn't change anything. However, adding a 100ms delay in the middle of the init seems to work.

          I'll have a look in time...

          Pierre

          1 Reply Last reply Reply Quote 0
          • P
            pcu
            last edited by

            Hi,

            The extra time between frame was not effective.
            Now, I had to add some widgets, what was worse.

            I found an indirect solution: because the MTU is set at 512 (as seen by wireshark), I concatenate the message like this method instead of send each widget one by one:

            memset(initBuf, 0, sizeof(initBuf));
            strcpy(initBuf, "|CB UID:TempMotor X:25 Y:55 W:25 BGC:#121212 FGC:#990000 HAW:2 HAH:2 HAR:4 VAL:20 HVAL:120 BTH:2 TXTC:#000000 XTC:6 YTC:2 STA:225 ENA:-45 SHN:1 NC:#000000 CE:0 SHT:1\r\n");
            strcat(initBuf, "|LB UID:T_Mot_label X:25 Y:61 W:100 FGC:#000000 FSZ:2 FFA:\"font5\" TXT:\"Mot \u00B0C\"\r\n");
            strcat(initBuf, "|CB UID:TempFuel X:75 Y:55 W:25 BGC:#121212 FGC:#990000 HAW:2 HAH:2 HAR:4 VAL:20 HVAL:60 BTH:2 TXTC:#000000 XTC:6 YTC:2 STA:225 ENA:-45 SHN:1 NC:#000000 CE:0 SHT:1 LT:-1 CHAR:-1\r\n");
            sendMsg(initBuf);
            

            I send less messages, but with more datas.
            In comparison, with the STM32WB I can get a status if the notification buffer is busy, but it seems it doens't in ESP32...

            Pierre

            K 1 Reply Last reply Reply Quote 0
            • K
              kl3m3n @pcu
              last edited by

              @pcu Hi,

              thank you for the information regarding this. I am glad you solved this.
              It seems that the Arduino BLE library does not have an option to check if the buffer is full before sending the data.

              I think that per specification, the maximum characteristic length is 512 bytes.

              BTW: Do you have any examples with GUI-O and STM32?

              Best regards,
              Klemen

              1 Reply Last reply Reply Quote 0
              • P
                pcu
                last edited by

                Hi,
                Yes I have transposed the GUI-O part of my ESP32 project for the Nucleo WB55. Partially ported but enough to test.

                K 1 Reply Last reply Reply Quote 0
                • K
                  kl3m3n @pcu
                  last edited by

                  @pcu said in Number of widgets limited to 28:

                  Nucleo WB55

                  Nice! I will order this board - I need to make some examples for STM32...

                  Do you by chance have any good references for BLE UART implementation?

                  Best regards,
                  Klemen

                  P 1 Reply Last reply Reply Quote 0
                  • P
                    pcu @kl3m3n
                    last edited by pcu

                    @kl3m3n

                    The STM32CubeMX comes with a lot a example:

                    bb3207ca-2313-4617-b5a5-86db4ad166b5-image.png

                    I think CableReplacement is what you're looking for.

                    K 1 Reply Last reply Reply Quote 0
                    • K
                      kl3m3n @pcu
                      last edited by

                      @pcu Hi!

                      I have made two examples using Nucleo board (USB and BLE).

                      You can find them here, if you are interested:
                      https://www.gui-o.com/examples/gui-o-and-boards/stm32-nucleo-wb55

                      Best wishes.
                      Klemen

                      1 Reply Last reply Reply Quote 0
                      • First post
                        Last post