diff --git a/JenkinsfileHW b/JenkinsfileHW index 39e3891..81cbfa5 100644 --- a/JenkinsfileHW +++ b/JenkinsfileHW @@ -53,10 +53,18 @@ lock(label: 'sdg_nuc_04') { harness.set_docker_args(['Vivado', 'MATLAB']) harness.set_nebula_local_fs_source_root("artifactory.analog.com") - // Set stages (Stages are run sequentially on agents.) - // harness.add_stage(harness.stage_library("UpdateBOOTFiles"), 'stopWhenFail', - // harness.stage_library("RecoverBoard")) - + def rebootBoard = { String board -> + stage("Restart target"){ + try{ + harness.nebula('net.restart-board --board-name=' + board) + } catch(Exception ex){ + println("Failed to restart target.") + } + harness.nebula('net.check-board-booted --board-name=' + board) + } + } + harness.add_stage(rebootBoard,'continueWhenFail') + // Test stage harness.set_matlab_commands(["addpath(genpath('test'))", "pyenv('Version','/usr/bin/python3')",