chenee / darkblue Goto Github PK
View Code? Open in Web Editor NEWLightBlue like CoreBluetooth Demo for BT LE, include dynamic logger (you even could send the log.txt to you mail with you iPhone)
LightBlue like CoreBluetooth Demo for BT LE, include dynamic logger (you even could send the log.txt to you mail with you iPhone)
Especially for data which write bigger than 20 bytes, and use multi packages to send.
i tried to read temperature from foramed devices with command 0x26 i can pairing and read info (name ,version , manufacturer) but i cann't write command 0x26 to read result
// Scaning 4 seconds for peripherals
[[LGCentralManager sharedInstance] scanForPeripheralsByInterval:10
completion:^(NSArray *peripherals)
{
// If we found any peripherals sending to test
for (LGPeripheral *per in peripherals) {
if ([per.UUIDString isEqualToString:@"2FF2DAFC-D4D5-4929-8E80-4CA23C56EEF2"]) {
const uint16_t bytes[] = {0x26};
NSData *data = [NSData dataWithBytes:bytes length:sizeof(bytes)];
[LGUtils writeData:data
charactUUID:@"00001524-1212-efde-1523-785feabcd123"
serviceUUID:@"00001523-1212-efde-1523-785feabcd123"
peripheral:per completion:^(NSError *error) {
NSLog(@"Error : %@", error);
[LGUtils readDataFromCharactUUID:@"00001524-1212-efde-1523-785feabcd123"
serviceUUID:@"00001523-1212-efde-1523-785feabcd123"
peripheral:per
completion:^(NSData *data, NSError *error) {
NSLog(@"Data : %s Error : %@", (char *)[data bytes], error);
}];
}];
}
NSLog(@"name:%@ UUID:%@",per.name,per.UUIDString);
}
}];
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.