Testing Hardware (NRF52) Functionality Using Robot Framework

Hi all,

I am currently working on automating the testing process using the Robot Framework for nrf52833 board, programmed with Zephyr RTOS and VS Code . Specifically, I am trying to test the functionality of an LED blink on the board with a delay of 1 second.

I have successfully flashed the blinky code onto the board and trying on how to implement the testing procedure using the RF. The objective is to verify if the LED blinks with 1second delay, and if so, consider the test as a pass; otherwise, mark it as a fail.

Could you please provide insights, resources, or examples on how to automatically test the delay used in the program?

Hook up a webcam that is directed to the leds, record a video and count the frames between blinks ?

1 Like

I have a similar suggestion, use a webcam to take a photo, sleep 1 sec (or maybe ~990ms if the photo takes a few ms to save) then take photo 2, repeat with photo 3.

now you can test the photo’s with something like ImageCompare Library, you can compare photo 1 and 3 to confirm they are the same, confirm photo 1 and 2 are different, compare photo 1 and previously stored photo of LED ON to confirm LED is on, likewise photo 2 and previously stored photo of LED OFF.

Not sure if there’s an existing library for controlling a camera (didn’t find one in my quick 10 sec search) so you may need to resort to calling a python function with Evaluate to trigger the taking of the photo.

hope that’s helpful,


Plenty of people have used OpenCV to to detect blinking and frequency. Quick googling also comes back with plenty of example code either in C or Python that do led blink detection. Even eye blink detection could be utilized by a bit of modification to this; Blink Detection using Python. | AlgoAsylum

1 Like