OpenLog Artemis Hookup Guide

Contributors: Nate, bboyho, PaulZC
Favorited Favorite 4

Low Power Considerations

Ambiq, the manufacturer of the Apollo3, has done years of research into something they call Sub-threshold Power Optimized Technology (SPOT™). This is a fancy description of a power saving technique that works by lowering the logic level voltages necessary to indicate a 1 or a 0. By doing so at the silicon level, Ambiq has managed to eke out a 48MHz processor which can draw less than half a milliamp.

The Artemis processor can also be put into a deep sleep state where it draws approximately 18µA of current. For the OLA, we take advantage of this by putting the Artemis into this deep sleep state:

  • between reads (if you are reading less frequently than once every two seconds)
  • when the battery voltage becomes low, or external power is switched off or removed
  • logging is stopped (via pin 32 when stop logging is enabled)

In deep sleep:

  • most of the Artemis’ I/O pins are turned off since they draw current. Only the essential ones are left enabled
  • the serial and I2C interfaces are disabled
  • the Artemis clock frequency is reduced from 48MHz to 32kHz
  • non-essential flash memory and RAM are powered down
  • the RTC is left running (at 32kHz)

We have included a Seiko Instruments ML414H rechargeable battery on the OLA to provide power while the Artemis is in deep sleep so it can keep its Real Time Clock (RTC) running. Now, we have tried to cover all of the options here, but there are some things you need to be aware of if you want to reduce the OLA power consumption to the absolute minimum. The Seiko battery can only provide µA of current, which is enough to power the Artemis while it is in deep sleep, but it cannot provide enough current to let the Artemis run at usual speeds. Resetting the Artemis brings it out of deep sleep and into normal operation, so you need to make sure that external power or a battery is connected first.

The OLA 3.3V regulator is an AP2112K which has a low drop-out voltage (approximately 250mV) and a low quiescent current of 55µA. If you cut the MEAS jumper link and use the MEAS pins to measure the OLA’s current draw from external power or the LiPo battery, you will see:

  • when the Artemis is in deep sleep, the current draw can be as low as 80µA which is made up of:
    • 18µA drawn by the Artemis
    • 55µA quiescent current drawn by the regulator
    • approximately 3µA drawn by the LiPo charger
  • the current draw will be higher while the RTC battery is charging
  • if USB-C is connected and providing power, the current draw is much higher due to the current drawn by the CH340E USB-to-Serial interface

The PSWC pins can be used to power down the AP2112K regulator, reducing the regulator’s quiescent current to well below 1µA.

If the OLA’s logging interval is greater than 2 seconds, the Artemis automatically goes into deep sleep between reads. An RTC alarm is used to wake the Artemis up for the next read.

The OLA goes into deep sleep automatically:

  • if the voltage divider shows that the battery voltage is low (the Artemis reads the divider via an analog pin)
  • if power is disconnected or disabled. The 3.0V voltage monitor causes an interrupt which places the Artemis immediately into deep sleep
  • if logging is stopped by pulling pin 32 low (see “Configuration” for more details on how to enable stop logging)

Once in deep sleep, the Artemis can only be woken by:

  • an RTC alarm for long logging intervals
  • a reset caused by:
    • Pressing the RST button or pulling the RST breakout pin low
    • Attaching USB-C (opening USB-C serial communication automatically triggers a reset)

Don’t forget that the RTC battery cannot provide enough current to run the Artemis at normal speeds, so you need to make sure that power is connected before generating a reset. If you do accidentally press the RST button while the power is disconnected:

  • the RTC will reset (the time and date will be lost)
  • the RTC battery will discharge (and will need to be recharged by external power)

So, how should you put all of this together for your low power logging application? Here are a couple of suggestions.

Stop Logging and Reset Buttons

One of our favorite ways is to connect up external “stop logging” and “reset” buttons to the RST and pin 32 breakout pins. If stop logging has been enabled using the configuration menus, pulling pin 32 to GND via a push-to-close button will gracefully stop the logging and place the OLA into deep sleep. Pulling the RST pin to GND will reset the Artemis, waking it up again and logging is restarted. We like this method because the log file on the SD card is closed gracefully, making sure that no data is lost. You can think of the pin 32 and RST buttons as “Off” and “On” buttons. When “Off”, the current drawn from a LiPo battery will be no lower than 80µA because the 3.3V regulator is still enabled.


As we described above, the PSWC pins can be used to disable (switch off) the OLA’s 3.3V regulator. Connecting the pins together via a SPST toggle switch pulls the regulator’s EN pin low and disables it. This causes the 3.3V rail to collapse. If the Artemis is running, the voltage supervisor will generate an interrupt to immediately put the Artemis into deep sleep. Because the 3.3V rail has already collapsed, the Artemis cannot close the log file on the SD card gracefully. The OLA syncs the log file regularly while it is logging, but there is a small risk of data loss if you use this method to disable the OLA.

A better method is to use a “stop logging” button as described above. Pressing the stop logging button will gracefully close the log file and place the Artemis into deep sleep. Then you can disable the regulator safely via the PSWC pins. In this state, the OLA will draw less than 1µA from external power or LiPo battery, the RTC battery will provide the 18µA needed by the Artemis to keep its RTC running.

The Artemis will stay in deep sleep when you toggle the regulator back on again. You will need to reset it via a reset button to start it logging again.

Slow Logging

As described in the Configure Terminal Output section, you can also use slow logging to conserve your battery life. You can choose to go into slow logging mode: according to the state of Pin 11; or once per day (with configurable start and end times).