[Solved] "Error processing client command" with setProperty

Hello All,

I thought I’d take advantage of setProperty, but have yet to see it work.

With debug I see the signals sent and in the app I then get the error…

“Error processing client command”

Where am I going wrong? Or maybe it has something to do with BLE? Unfortunately BLE is the only way I can connect without dismantling my hardware.

Hardware:
Nexus 6 with Android 7.0 installed
Sparkfun RedBoard (Uno clone)
Adafruit BlueFruit LE Shield
Big Easy Driver (stepper motor driver – not used in this sketch, but is connected)
Blynk library v0.3.10

Here’s a sketch as an example

/////////////////////////////////////
//
// V2   labeledValue, freq = 10sec
// V20  gauge, freq = 10sec
// BLE module

#define BLYNK_DEBUG
#define BLYNK_PRINT Serial
#define BLYNK_USE_DIRECT_CONNECT // If trouble connecting trying commenting out

#include <SimpleTimer.h>
#include <SPI.h>
#include <SoftwareSerial.h>

// BLE
#include <BlynkSimpleSerialBLE.h>
// Adafruit Bluefruit LE Shield which using SPI
#include <Adafruit_BLE.h>
#include <Adafruit_BluefruitLE_SPI.h>

#define BLUEFRUIT_SPI_CS 8
#define BLUEFRUIT_SPI_IRQ 7
#define BLUEFRUIT_SPI_RST 4
#define BLUEFRUIT_VERBOSE_MODE false

Adafruit_BluefruitLE_SPI ble(BLUEFRUIT_SPI_CS, BLUEFRUIT_SPI_IRQ, BLUEFRUIT_SPI_RST);

char auth[] = "xxxxxxxxxxxxxxxxxxxxxxxxxxx";

void gaugeColor()
{
  Blynk.setProperty(V20, "color", "#999999");
}

void valueLabel()
{
  Blynk.setProperty(V2, "label", "Hello Label");
}

SimpleTimer timer;
int gauge_timer = timer.setInterval(10000, gaugeColor);
int value_timer = timer.setInterval(15000, valueLabel);

void setup()
{
  Serial.begin(9600);
  Blynk.begin(auth, ble);

  ble.begin(BLUEFRUIT_VERBOSE_MODE);
  ble.factoryReset(); // Optional but advisable
  ble.setMode(BLUEFRUIT_MODE_DATA);
  while (!ble.isConnected())
  {
    delay(2000);
  }
  Blynk.setProperty(V2, "label", "vDisplay");
  timer.restartTimer(gauge_timer);
  timer.restartTimer(value_timer);
}

void loop()
{
  Blynk.run();
  timer.run();
}

you have two set properties for V2 - did you try just doing one?

Ha – after a while I forget what I tried and didn’t try!

But yeah I did and went back and tried just one setProperty again. Below is a sketch of that.

I don’t know if you noticed but there is an open issue #170 on git hub for multiple setProperty(s) in a row.

/////////////////////////////////////
//
// V2   labeledValue, freq = 10sec
// BLE module

#define BLYNK_DEBUG
#define BLYNK_PRINT Serial
#define BLYNK_USE_DIRECT_CONNECT // If trouble connecting trying commenting out

#include <SimpleTimer.h>
#include <SPI.h>
#include <SoftwareSerial.h>

// BLE
#include <BlynkSimpleSerialBLE.h>
// Adafruit Bluefruit LE Shield which using SPI
#include <Adafruit_BLE.h>
#include <Adafruit_BluefruitLE_SPI.h>

#define BLUEFRUIT_SPI_CS 8
#define BLUEFRUIT_SPI_IRQ 7
#define BLUEFRUIT_SPI_RST 4
#define BLUEFRUIT_VERBOSE_MODE false

Adafruit_BluefruitLE_SPI ble(BLUEFRUIT_SPI_CS, BLUEFRUIT_SPI_IRQ, BLUEFRUIT_SPI_RST);

char auth[] = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx";

void valueLabel()
{
  Blynk.setProperty(V2, "label", "Hello Label");
}

SimpleTimer timer;
int value_timer = timer.setInterval(15000, valueLabel);

void setup()
{
  Serial.begin(9600);
  Blynk.begin(auth, ble);

  ble.begin(BLUEFRUIT_VERBOSE_MODE);
  ble.factoryReset(); // Optional but advisable
  ble.setMode(BLUEFRUIT_MODE_DATA);
  while (!ble.isConnected())
  {
    delay(2000);
  }
  timer.restartTimer(value_timer);
}

void loop()
{
  Blynk.run();
  timer.run();
}

Thanks. We’ll check. I think this related somehow with BLE.

Thanks,

It’s Android app issue - will be fixed with next release.

1 Like

Looks like its working now with the new release. Thanks!

2 Likes