blynkkk / blynk_Issues

6 stars 6 forks source link

Menu widget issues #209

Closed Bresca-eng closed 3 years ago

Bresca-eng commented 3 years ago

Blynk library version: [1.0.1] IDE: [Arduino] IDE version: [1.8.15] Board type: [MKR1010] Additional modules: [...] Blynk app: [3.2.4(1)] OS: [iOS 14.7.1]

Scenario, steps to reproduce

I'm experimenting problems with menu widget: I would like to add some items in menu but it is not possible or, better, initially I have correct menu then (after 1-2 minutes) it disappears I have a template called TestMenu with an only widget: menu widget. Istantanea schermo 2021-08-18 (09 43 44)

It is linked to a virtual pin V0 in following way

image

Software comes from Blink.Edgent example of Blynk library and is so-made

// Fill-in information from your Blynk Template here
#define BLYNK_TEMPLATE_ID "TMPLwuxyywbi"
#define BLYNK_DEVICE_NAME "TestMenu"
#define BLYNK_FIRMWARE_VERSION        "0.1.0"
#define BLYNK_PRINT Serial
//#define BLYNK_DEBUG
#define APP_DEBUG
#include "BlynkEdgent.h"

String MenuItem[10]={"S0","S1","S2","S3","S4","S5","S6","S7","S8","S9"};

BLYNK_CONNECTED()
  {
  BlynkParamAllocated items(128);
  for (int i=0;i<10;i++) items.add(MenuItem[i]);
  Blynk.setProperty(V0, "labels", items);
  SerialUSB.println("Menu' updated!");    
  }

void setup()
  {
  Serial.begin(9600);
  delay(2000);
  BlynkEdgent.begin();
  }

void loop() 
  {
  BlynkEdgent.run();
  }

Expected Result

I expect to obtain... Istantanea schermo 2021-08-18 (13 02 14)

Actual Result

Actually I get the screen seen before with the 10 items, but if I lock the phone and after 1-2 minutes I go back to see the screen, I find ... Istantanea schermo 2021-08-18 (13 04 03)

You can see also this discussion on Blynk forum: https://community.blynk.cc/t/menu-widgets-issues-on-blynk-2-0/55700/3

Bresca-eng

doom369 commented 3 years ago

@eepetrash please take a look

eepetrash commented 3 years ago

Blynk.setProperty(V0, "labels", items);

if I lock the phone and after 1-2 minutes I go back to see the screen

@doom369 looks like server did not update labels property

Bresca-eng commented 3 years ago

If it can be useful, I got the similar behavior with an android phone.

doom369 commented 3 years ago

@Bresca-eng bug confirmed. We'll fix it soon.

doom369 commented 3 years ago

@Bresca-eng fixed. Please reopen if not.

Bresca-eng commented 3 years ago

It seems to work. Thanks!