SD Logging for Genuino 101

General project help for Adafruit customers

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
sysmaster89
 
Posts: 2
Joined: Sat Mar 11, 2017 5:56 pm

SD Logging for Genuino 101

Post by sysmaster89 »

Good evening to everyone!

I have a Genuino 101 board and I developed a project where I read two MPU6050 through I2C network, I can update both in ~5ms.
I also added a BLE 20-byte characteristic: via integrated PC/Android interface now I properly read data (es: with Vsual Studio)

BUT I have a little "problem": the BLE interface of the PC/Android (or the entire BLE stack?) will not let me go below ~100ms response rate (on notify and read also).
This would make me lose a lot of acquisition samples. Then I would try to log data as fast as possible to a SD card (I hope more fast than BLE stack) and then deliver them via BLE in a second time (like weareable devices).

Then I would ask..:
- How fast I can store one sample (20 bytes in this case) on SD card using MicroSD shield?
- There would be energy consumption or performance difference using the Data Logging shield?
- Are they both compatible with Genuino 101 board?

I tried to be as accurate as possible, if you have other questions write down.
If someone need I can also post my code.

Greetings from Italy
Marco

User avatar
adafruit_support_mike
 
Posts: 67446
Joined: Thu Feb 11, 2010 2:51 pm

Re: SD Logging for Genuino 101

Post by adafruit_support_mike »

Take a look at the AT+GAPINTERVALS command in the tutorials:

https://learn.adafruit.com/introducing- ... pintervals

That lets you set the connection interval.. basically the limit on how often the BLE module will make a connection and transfer data. The smaller the connection interval, the more times per second the BLE module will transmit data.

Writing to an SD card usually takes between 2ms and 10ms, but sometimes it takes longer. The best thing to do is write a test sketch that just writes data to the card and keeps track of the time with an RTC. After 100 seconds of writing, you'll get a pretty good estimate of the writ speed for the card you're using.

All of our Shields are compatible with Genuino devlopment boards.

User avatar
sysmaster89
 
Posts: 2
Joined: Sat Mar 11, 2017 5:56 pm

Re: SD Logging for Genuino 101

Post by sysmaster89 »

Dear Mike,
I've tried to find how to send AT commands to my Genuino 101 board, but I didn't find anything useful!
It's possibile to set this interval during initial setup function?

User avatar
adafruit_support_mike
 
Posts: 67446
Joined: Thu Feb 11, 2010 2:51 pm

Re: SD Logging for Genuino 101

Post by adafruit_support_mike »

Use the ble.print() function.

Locked
Please be positive and constructive with your questions and comments.

Return to “General Project help”