I want to write gatttool
in non-interactive mode.
$ sudo gatttool -i hci0 -b 78:A5:04:44:0A:57 -I
[78:A5:04:44:0A:57][LE]> connect
Attempting to connect to 78:A5:04:44:0A:57
Connection successful
[78:A5:04:44:0A:57][LE]> char-write-cmd 0x0025 ff
I'm changing color of light that is using bluetooth.
What is the equivalent by using non-interactive mode?
I tried like this, but it doesn't change the color of light and to stop it I must use ctrl+c
. There is no message at all.
sudo gatttool -i hci0 -b 78:A5:04:44:0A:57 --char-write -a 0x0025 -n ff
How can I write the command?
Environment:
I'm using Raspberry Pi
and Rasbian
.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…