File tree Expand file tree Collapse file tree 1 file changed +9
-3
lines changed
TESTS/mbed_drivers/ticker Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -71,7 +71,9 @@ void ticker_callback_1(void)
7171void ticker_callback_2 (void )
7272{
7373 ++callback_trigger_count;
74- switch_led2_state ();
74+ if (LED2 != NC) {
75+ switch_led2_state ();
76+ }
7577}
7678
7779
@@ -110,7 +112,9 @@ void test_case_1x_ticker()
110112 Ticker ticker;
111113
112114 led1 = 1 ;
113- led2 = 1 ;
115+ if (LED2 != NC) {
116+ led2 = 1 ;
117+ }
114118 callback_trigger_count = 0 ;
115119
116120 greentea_send_kv (" timing_drift_check_start" , 0 );
@@ -151,7 +155,9 @@ void test_case_2x_ticker()
151155 Ticker ticker1, ticker2;
152156
153157 led1 = 0 ;
154- led2 = 1 ;
158+ if (LED2 != NC) {
159+ led2 = 1 ;
160+ }
155161 callback_trigger_count = 0 ;
156162
157163 ticker1.attach_us (ticker_callback_1, 2 * ONE_MILLI_SEC);
You can’t perform that action at this time.
0 commit comments