dfrobot / blunobasicdemo Goto Github PK
View Code? Open in Web Editor NEWThe basic demo for bluno
License: GNU General Public License v3.0
The basic demo for bluno
License: GNU General Public License v3.0
Looking for the source -- I saw the links from this page https://www.dfrobot.com/wiki/index.php/Bluno_SKU:DFR0267#FAQ but I do not see the source for the BLE Firmware, only binary blobs.
Hello Experts,
I would like to interface the bluno beetle board with raspberry pi board.
Can you please point out some arduino examples to add BLE attributes and/or how we can send the switch status to raspberry pi or other BLE receiver system.
Thanks for the help.
I am sure it is possible to enable a sort of secure communications, which would only allow a specific device to communicate with the Bluno based on something like a MAC address, but I am not sure how it could be implemented, and I am not sure if that would require it's own project. However there does seem to be interest in this topic. I didn't see any reference to this topic here in the project nor did I see any info on the wiki of the Bluno.
Hello,
I've been using the Bluno board successfully with an Android app based on this demo.
I'm using sensor input from the Bluno to trigger sounds in this app.
My problem is : it seems that there is a constant latency due to the BLE protocol, around a few hundreds of miliseconds, which makes the Bluno unsuitable for this particular application.
I'm wondering if there is a way to increase the priority of BLE communication with the Bluno.
I think it's possible because some bluetooth devices like mice and keyboards have a much lower communication latency.
Does anyone know if it is even possible, and if so, where to look at to improve this behaviour ?
I'd like to reach a more or less constant latency of around 20ms, maximum 50ms (this is what is needed to preserve a sensation of immersion in real-time applications involving gesture and sound feedback).
Thanks for any pointers,
Joseph
Hi!
This is regarding the onSerialReceive(String theString) function, in MainActivity.
I am using a Bluno Beetle to take readings from a PPG sensor and sending the comma separated raw values over bluetooth to an Android App.
However, if I send 20 values (by appending them in a comma separated string), I receive only 5 values in one execution of the function onSerialReceive.
For eg.
If I send the following from Bluno Beetle:
"231,511,231,524,231,522,231,525,231,513,506,230,509,230,515,522,231,525,231,513"
I receive the following theString values in 4 consecutive executions of the function:
"231,511,231,524,231"
",522,231,525,231,513"
",506,230,509,230,515"
",522,231,525,231,513"
I do not receive the complete string in a go.
Debugging this is a little urgent, so I request you to kindly reply soon. Let me know if you need more information to help me out with this.
Thanks!
Just fix a little mistake in a log: mSerialPortCharacteristic instead
of mCommandPortCharacteristic.
BlunoLibrary.java (480):
System.out.println("mSerialPortCharacteristic "+mSerialPortCharacteristic.getUuid().toString());
->
System.out.println("mCommandPortCharacteristic "+mCommandPortCharacteristic.getUuid().toString());
Hi, I've used this app before for connecting my Bluno Beetle, but it doesn't seem to be actively maintained now.
I have created a Bluetooth controller App that should work with Bluno devices and has a lot more features.
https://github.com/jerameel/bacon
If would love to help to add this to your wiki page as an alternative for the demo
When I want to connect to the Bluno nano my phone ask me the password which seems to be "000000" ("0" x 6) but I can't change the password via AT commands and can't use an app I've designed to work with the HC-05. Are we forced to use your app?
I am using the Arduino IDE and am experiencing the following problem .
• I have the bluno beetle wirelessly connected to a HM-10 Bluetooth module which is connected to an Arduino nano.
• I am sending a ‘1’ and a '0' through serial.write function from the beetle to the to the HM-10 in the main loop.
• The HM-10 acknowledges the receiving ‘1’ when the serial monitor of the bluno beetle is open or open then closed which turns on and off an LED.
But the main problem I am having is if I do not open the serial monitor to the Beetle when first connected it will not receive the ‘1’.
I hope this is clear as I am quite new to this and it is very hard to describe through text.
I can upload my HM-10 code if needed
Github_sketch.txt
Just the Bluetooth lib not work rightly, cant scan successful.
I tried below, seems doesn't work
// LED and button pin
// create peripheral instance, see pinouts above
BLEPeripheral blePeripheral = BLEPeripheral(BLE_REQ, BLE_RDY, BLE_RST);
// create service
BLEService ledService = BLEService("19b10010e8f2537e4f6cd104768a1214");
// create switch and button characteristic
BLECharCharacteristic switchCharacteristic = BLECharCharacteristic("19b10011e8f2537e4f6cd104768a1214", BLERead | BLEWrite);
BLECharCharacteristic buttonCharacteristic = BLECharCharacteristic("19b10012e8f2537e4f6cd104768a1214", BLERead | BLENotify);
void setup() {
Serial.begin(115200);
delay(5000); //5 seconds delay for enabling to see the start up comments on the serial board
// set LED pin to output mode, button pin to input mode
pinMode(LED_PIN, OUTPUT);
pinMode(BUTTON_PIN, INPUT);
// set advertised local name and service UUID
blePeripheral.setLocalName("LED Switch");
blePeripheral.setAdvertisedServiceUuid(ledService.uuid());
// add service and characteristics
blePeripheral.addAttribute(ledService);
blePeripheral.addAttribute(switchCharacteristic);
blePeripheral.addAttribute(buttonCharacteristic);
// begin initialization
blePeripheral.begin();
Serial.println(F("BLE LED Switch Peripheral"));
}
void loop() {
// poll peripheral
blePeripheral.poll();
// read the current button pin state
char buttonValue = digitalRead(BUTTON_PIN);
// has the value changed since the last read
bool buttonChanged = (buttonCharacteristic.value() != buttonValue);
if (buttonChanged) {
// button state changed, update characteristics
switchCharacteristic.setValue(buttonValue);
buttonCharacteristic.setValue(buttonValue);
}
if (switchCharacteristic.written() || buttonChanged) {
// update LED, either central has written to characteristic or button state has changed
if (switchCharacteristic.value()) {
Serial.println(F("LED on"));
digitalWrite(LED_PIN, HIGH);
} else {
Serial.println(F("LED off"));
digitalWrite(LED_PIN, LOW);
}
}
}
The current sdk version is no longer supported.
This should be updated to atleast version 26.
Please see #20 to fix this.
Hi guys I meet a problem that the android app display always miss data(some characters) when i using a 50Hz rate. But there is no matter at a low display rate (like 1Hz). in addition, It is OK on the PC serial monitor.
what happened and what should i do?
I want to add to my android project a ble bluno connection ( target sdk : 26, min sdk : 21, compile sdk : 28). I followed the demo but i had a problem with the scan (obselete?) so i found a solution, i connected directly with a paired device using the "connect" function. But now i want to write something to the bluno using the "serialSend" function and it says :
"serialSend: Attempt to invoke virtual method 'boolean android.bluetooth.BluetoothGattCharacteristic.setValue(java.lang.String)' on a null object reference"
my SerialSend function :
` public void serialSend(String theString){
if (mConnectionState == connectionStateEnum.isConnected) {
try{
mSCharacteristic.setValue(theString);
mBluetoothLeService.writeCharacteristic(mSCharacteristic);
}catch (Exception e){
Log.d(TAG, "serialSend: "+e.getMessage());
}
}
}`
The characteristic i want to write in is null and the BroadcastReceiver is never used, in my opinion the characteristic is instanced in this receiver. the BroadcastReceiver is called after the broadcastUpdate but i enter well in the 'update' function and dont in the receiver.
private void broadcastUpdate(final String action) { final Intent intent = new Intent(action.toLowerCase()); sendBroadcast(intent); }
Is it because i dont used the scan to connect my bluno or there is a problem with version or there is an other problem?
Waiting for an answer, thank you.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.