Second button click does not trigger

Hi All,

I have an Bluetooth device which I want to control using an Android App (created in MIT App Inventor)
So what it does is you can select the Bluetooth device then tap on the open button the it will turn on the LED light.

The above works great but the problem I face now is when I click on the close button the LED stays on. What I need it to do is to turn of the LED light.

Here is what I have at the moment:

So button one works, but button two does not seem to work.

Am I missing something?


Found my problem.
When sending text to Bluetooth device I needed to add "\n" to create a new line.

All is working now