This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

Bluetooth ouput node not clearing buffer at input
Makes sense, indeed.

The current solution is to handle erasing in the analysis block. Sending BLE data is always (and only) done when the analysis cycle has finished, so you can control the data before each send. Usually, you would react to the button push by preparing the data to be sent. So, for example, your button would write the value 1 to a buffer "buttonTriggered" and in the analysis block you would copy some data to "dataToBeSent" if "buttonTriggered" equals 1 and just clear "dataToBeSent" otherwise (clear="true" at the output a type="empty" input for the else case). You can then simply unconditionally append a zero afterwards to clear the "buttonTriggered" buffer.

In your case this seems a bit awkward as you want to send the same value as set by the button. So you would do something like this, which appears unnecessarily overcomplicated as you do not need to fetch special data:

<if equal="true">
  <input clear="true">buttonTriggered</input>
  <input type="value">1</input>
  <input type="value">1</input>
  <input type="empty" />
  <output clear="true">dataToBeSend</output>

  <input type="value">0</input>

Messages In This Thread
RE: Bluetooth ouput node not clearing buffer at input - by Sebastian Staacks - 12-09-2020, 03:38 PM

Forum Jump: