This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Low power mode for the nRF51822 module

I have purchased an nRF51822 module. I am using the Arduino IDE and the ST link to program the module. I have used the library BLEPeripheral by Sandeep Mistry (see below). I programmed the Eddystone-URL example on the nRF51822 module and it works! But as with other users, I also need a less of a current draw from the device. So far it is in the low mA range but I need to be in the uA (microamps) range.

Is there a way I can incorporate a low power solution but I want the device to first transmit the Eddystone URL and then go to "sleep" for 10 seconds and wake back up and then transmit the URL again and go back to sleep and then loop this for an entity. I do not want to use a button or external device to wake up the module, it must all be done internally.

#include <SPI.h>
#include <EddystoneBeacon.h>

// define pins (varies per shield/board)
//
//   Adafruit Bluefruit LE   10, 2, 9
//   Blend                    9, 8, UNUSED
//   Blend Micro              6, 7, 4
//   RBL BLE Shield           9, 8, UNUSED

#define EDDYSTONE_BEACON_REQ   6
#define EDDYSTONE_BEACON_RDY   7
#define EDDYSTONE_BEACON_RST   4

EddystoneBeacon eddystoneBeacon = EddystoneBeacon(EDDYSTONE_BEACON_REQ, EDDYSTONE_BEACON_RDY, EDDYSTONE_BEACON_RST);

void setup() {
  Serial.begin(9600);

  delay(1000);

  eddystoneBeacon.begin(-18, "http://www.example.com"); // power, URI

  Serial.println(F("Eddystone URL Beacon"));
}

void loop() {
  eddystoneBeacon.loop();
}

Parents
  • Hi,

    1. We don't officially support ST Link, I rather suggest that you get either a standalone J-link or a nRF51 DK which has an onboard debugger on it.
    2. I'm not familiar with the library that you're referring to as it's external to us, but what you basically want is what is implemented in the ble_app_beacon example. You only need to change the advertising interval to 10 seconds and change the advertising data to the URL. 

    regards

    Jared

Reply
  • Hi,

    1. We don't officially support ST Link, I rather suggest that you get either a standalone J-link or a nRF51 DK which has an onboard debugger on it.
    2. I'm not familiar with the library that you're referring to as it's external to us, but what you basically want is what is implemented in the ble_app_beacon example. You only need to change the advertising interval to 10 seconds and change the advertising data to the URL. 

    regards

    Jared

Children
Related