44 * SPDX-License-Identifier: Apache-2.0
55 *
667- *
7+ *
88 * Change Logs:
99 * Date Author Notes
10- * 2022-12-10 liqiaozhong first commit
11- * 2025-04-08 liqiaozhong
10+ * 2022-12-10 liqiaozhong first commit
11+ * 2025-04-08 liqiaozhong
1212 *
1313 */
1414
@@ -58,7 +58,6 @@ static int gpio_toggle_sample(uint8_t argc, char **argv)
5858 input_pin_index = FGPIO_ID (FGPIO_CTRL_0 , FGPIO_PIN_0 );
5959 rt_pin_mode (input_pin_index , PIN_MODE_INPUT );
6060 rt_pin_attach_irq (input_pin_index , PIN_IRQ_MODE_RISING , gpio_irq_test , RT_NULL );
61-
6261 output_pin_index = FGPIO_ID (FGPIO_CTRL_4 , FGPIO_PIN_13 );
6362 rt_pin_mode (output_pin_index , PIN_MODE_OUTPUT );
6463#endif
@@ -68,11 +67,9 @@ static int gpio_toggle_sample(uint8_t argc, char **argv)
6867 input_pin_index = FGPIO_ID (FGPIO_CTRL_4 , FGPIO_PIN_13 );
6968 rt_pin_mode (input_pin_index , PIN_MODE_INPUT );
7069 rt_pin_attach_irq (input_pin_index , PIN_IRQ_MODE_RISING , gpio_irq_test , RT_NULL );
71-
7270 output_pin_index = FGPIO_ID (FGPIO_CTRL_4 , FGPIO_PIN_10 );
7371 rt_pin_mode (output_pin_index , PIN_MODE_OUTPUT );
7472#endif
75-
7673 /* toggle operation */
7774 rt_pin_write (output_pin_index , set_level );
7875 set_level = (FGPIO_OPS_LEVEL_LOW == set_level ) ? FGPIO_OPS_LEVEL_HIGH : FGPIO_OPS_LEVEL_LOW ;
0 commit comments