📬❄️📦Adafruit Holiday Shipping Deadlines 2019: Please place all UPS 3 Day orders by 11am ET Friday December 13 📬❄️📦
0

NRF52 I/O via Adadfruit BLE App
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

NRF52 I/O via Adadfruit BLE App

by freddy257 on Thu Oct 26, 2017 10:49 am

Dear Adafruit Support Team,

I recently bought the NRF 52 Feather and was looking for the control of an I/O Pin at the Feather via your Bluefruit App (to set the Pin High/Low).
Unfortunately, there are no libraries for the NRF52 like there are for the nrf8001-based or nrf51822-based breakouts (1)/(2).

It would be great, if you could help me in any way.

Thank you


(1): https://learn.adafruit.com/bluefruit-le ... ng-options
(2): https://learn.adafruit.com/bluefruit-le ... and-config

freddy257
 
Posts: 3
Joined: Thu Oct 26, 2017 10:11 am

Re: NRF52 I/O via Adadfruit BLE App

by hathach on Fri Oct 27, 2017 10:48 am

yes, it is possible with the firmata sketch here
https://github.com/adafruit/Adafruit_nR ... ataBLE.ino

hathach
 
Posts: 1030
Joined: Tue Apr 23, 2013 1:02 am

Re: NRF52 I/O via Adadfruit BLE App

by freddy257 on Sat Oct 28, 2017 10:04 am

Thank you for your support hathach!

However, i get an error with this code. Is something missing or wrong?

Code: Select all | TOGGLE FULL SIZE
In file included from C:\Program Files (x86)\Arduino\libraries\Firmata/Firmata.h:17:0,

                 from C:\Privat\LE Wire\Programmierung\PIN IO\Firmata_NRF52\Firmata_NRF52.ino:25:

C:\Program Files (x86)\Arduino\libraries\Firmata/Boards.h:738:2: error: #error "Please edit Boards.h with a hardware abstraction for this board"

 #error "Please edit Boards.h with a hardware abstraction for this board"

  ^

Mehrere Bibliotheken wurden für "Servo.h" gefunden
 Benutzt: C:\Users\Frederic\AppData\Local\Arduino15\packages\adafruit\hardware\nrf52\0.7.5\libraries\Servo
 Nicht benutzt: C:\Program Files (x86)\Arduino\libraries\Servo
exit status 1
Fehler beim Kompilieren für das Board Adafruit Bluefruit nRF52 Feather.

The second error says there are 2 libraries for the "Servo.h" (shouldn't make a difference to it) and it couldn't compile to the NRF52 in german.

What is the Firmata in general about? Is it like a library for another source code or should it provide the I/O attachment for itself?
I am very unfamiliar with this toppic...

Thank you!

freddy257
 
Posts: 3
Joined: Thu Oct 26, 2017 10:11 am

Re: NRF52 I/O via Adadfruit BLE App

by hathach on Sat Oct 28, 2017 10:59 pm

Firmata is a protocol to remotly control IO for an mcu in a std way. For the compile error, please try to upgrade your IDE and/or upgrade Firmata library to latest via IDE. You can then control the nrf52 via IO module in bluefruit app

hathach
 
Posts: 1030
Joined: Tue Apr 23, 2013 1:02 am

Re: NRF52 I/O via Adadfruit BLE App

by freddy257 on Sun Oct 29, 2017 10:30 am

Thank you! Now it works properly.

I
1. updated the Arduino IDE
2. changed the code firmata.h to the code from (1) firmata.h in C:\Program Files (x86)\Arduino\libraries\Firmata
3. changed the code boards.h to the code from (2) boards.h in C:\Program Files (x86)\Arduino\libraries\Firmata
4. copied those two new files into C:/documets/.../libraries

(For those who have got the same issue)

(1): https://github.com/firmata/arduino/blob ... /Firmata.h
(2): https://github.com/firmata/arduino/blob/master/Boards.h

freddy257
 
Posts: 3
Joined: Thu Oct 26, 2017 10:11 am

Re: NRF52 I/O via Adadfruit BLE App

by jerryn on Sun Oct 29, 2017 10:43 am

FYI - I just went through this exercise and I wonder if the original poster made the same mistake I did.
I did not see any examples for the nrf52 unit I selected the nrf52 as the board type - then under Examples I found all of the "Example for ArduinoBluefruit nRF52 Feather". The peripherals/StandardFirmataBLE is working for me to view/set pin status via the Bluefruit app.

So all I had to do was install the BSP for the nRF52 then select the "Adafruit Bluefruit nRF52 Feather" then look in Examples.
I do have the Firmata and Adafruit BLEFirmata Libraries installed as well.

I hope that helps - Good luck.

jerryn
 
Posts: 1082
Joined: Sat Sep 14, 2013 9:05 am

Please be positive and constructive with your questions and comments.