Skip to content

NordicPlayground/skykey-firmware

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

77 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

skykey-firmware

Note: This project is currently not being developed.

Skykey is a demo project which (aims) to illustrate how the Zephyr and nRF SDK codebases can be used to create a physical password safe on the nRF9160 DK. This project features:

  • Use of the Event Manager and the Common Application Framework (CAF)
  • Power management using CAF (still in the works)
  • Interfacing with custom peripherals (fingerprint sensor)
  • Inter-chip communication on the nRF9160 DK (still in the works)
  • Simulation of a bluetooth keyboard (still in the works)
  • UI through a display (ST7789V) powered by LVGL v7.6.1
  • LTE connectivity
  • AWS device shadows
  • File download from a URL with persistent storage

This project is loosely based off Asset Tracker v2.

Initializing the repository

To initialize this repository, call:

west init -m https://github.com/NordicPlayground/skykey-firmware

west update

This project contains code for both the nRF52840 and the nRF9160 that are on the nRF9160 DK. The code for each of the chips is located in their respective folders in ./skykey-firmware

nRF9160

Modules

Modem module: Responsible for LTE connectivity.

Cloud module: Handles cloud communication (AWS).

Download module: Listens to cloud module for a given URL. Downloads a file from the given URL and stores it persistently in the storage flash partition.

Fingerprint module: Glue between fingerprint sensor and the rest of the system

Password module: Opens password file from storage flash partitions, (decrypts) the file and:

  • Submits event containing available platforms if it receives DISPLAY_EVT_REQUEST_PLATFORMS
  • Submits event containing (unencrypted???) password to bluetooth module if it receives DISPLAY_EVT_PLATFORM_CHOSEN (this is a work in progress)

Display module: Handles display-related tasks which allows users to choose a password for the device to input to the PC. The display module itself handles the tracking of state and handling of events, and it is (where possible) kept separate from display-specific code. The code that actually drives the display is found under src/display. The library used is LVGL v7.6.1.

Utils

To ensure that download_module.c does not try to write to the stored file whilst password_module.c tries to read from it, file_util.c manages any operation related to the stored file.

Issuing a certificate from AWS IoT

Follow the steps in creating a thing in AWS IoT with your_client_id being set to the device's IMEI number. A policy is not necessary. Then follow the steps in programming the certificates to the on-board modem of the nRF9160-based kit.

nRF52840

Todo: More documentation here.

Bluetooth keyboard simulation

The nRF52840 simulates a bluetooth keyboard. It generates HID reports corresponding to button presses, and is even capable of typing multi-keystroke characters, such as the character ^ on a Norwegian keyboard layout.

Known issues

Power management and the ST7789V driver: You might get some compilation errors when trying to build with power management activated. This is caused by a bug in ./zephyr/drivers/display/display_st7789v.c. To fix this, change line 418 (case DEVICE_PM_SET_POWER_STATE:) to case PM_DEVICE_STATE_SET:

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published