Commit 12190880 authored by Wesley W. Terpstra's avatar Wesley W. Terpstra Committed by Alessandro Rubini

pps: do not blink PPS when a slave has no link

parent ced3db1b
......@@ -43,7 +43,7 @@ void shw_pps_gen_init()
ppsg_write(CR, cr | PPSG_CR_CNT_SET);
ppsg_write(CR, cr);
ppsg_write(ESCR, 0x6); /* enable PPS output */
ppsg_write(ESCR, 0); /* disable PPS output */
}
/* Adjusts the nanosecond (refclk cycle) counter by atomically adding (how_much) cycles. */
......
......@@ -258,8 +258,10 @@ int main(void)
break;
case LINK_WENT_DOWN:
if (wrc_ptp_get_mode() == WRC_MODE_SLAVE)
if (wrc_ptp_get_mode() == WRC_MODE_SLAVE) {
spll_init(SPLL_MODE_FREE_RUNNING_MASTER, 0, 1);
shw_pps_gen_enable_output(0);
}
break;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment