diff --git a/Inc/main.h b/Inc/main.h index d67ce04..ea5146f 100644 --- a/Inc/main.h +++ b/Inc/main.h @@ -58,6 +58,17 @@ void Error_Handler(void); /* USER CODE END EFP */ /* Private defines -----------------------------------------------------------*/ +#define GENLOCK_Pin GPIO_PIN_2 +#define GENLOCK_GPIO_Port GPIOE +#define GENLOCK_EXTI_IRQn EXTI2_IRQn +#define KEY1_Pin GPIO_PIN_3 +#define KEY1_GPIO_Port GPIOE +#define KEY0_Pin GPIO_PIN_4 +#define KEY0_GPIO_Port GPIOE +#define ENCODER_LIGHT_Pin GPIO_PIN_9 +#define ENCODER_LIGHT_GPIO_Port GPIOF +#define DEBUG_LIGHT_Pin GPIO_PIN_10 +#define DEBUG_LIGHT_GPIO_Port GPIOF #define ETH_RST_Pin GPIO_PIN_3 #define ETH_RST_GPIO_Port GPIOD diff --git a/LWIP.ioc b/LWIP.ioc index 638a670..92d6dd0 100644 --- a/LWIP.ioc +++ b/LWIP.ioc @@ -52,33 +52,34 @@ Mcu.Name=STM32F407Z(E-G)Tx Mcu.Package=LQFP144 Mcu.Pin0=PE2 Mcu.Pin1=PE3 -Mcu.Pin10=PC4 -Mcu.Pin11=PC5 -Mcu.Pin12=PD12 -Mcu.Pin13=PD13 -Mcu.Pin14=PC6 -Mcu.Pin15=PC7 -Mcu.Pin16=PA9 -Mcu.Pin17=PA10 -Mcu.Pin18=PA13 -Mcu.Pin19=PA14 +Mcu.Pin10=PA7 +Mcu.Pin11=PC4 +Mcu.Pin12=PC5 +Mcu.Pin13=PD12 +Mcu.Pin14=PD13 +Mcu.Pin15=PC6 +Mcu.Pin16=PC7 +Mcu.Pin17=PA9 +Mcu.Pin18=PA10 +Mcu.Pin19=PA13 Mcu.Pin2=PE4 -Mcu.Pin20=PD3 -Mcu.Pin21=PG11 -Mcu.Pin22=PG13 -Mcu.Pin23=PG14 -Mcu.Pin24=VP_FREERTOS_VS_CMSIS_V1 -Mcu.Pin25=VP_LWIP_VS_Enabled -Mcu.Pin26=VP_SYS_VS_tim1 -Mcu.Pin27=VP_TIM6_VS_ClockSourceINT -Mcu.Pin3=PF10 -Mcu.Pin4=PH0-OSC_IN -Mcu.Pin5=PH1-OSC_OUT -Mcu.Pin6=PC1 -Mcu.Pin7=PA1 -Mcu.Pin8=PA2 -Mcu.Pin9=PA7 -Mcu.PinsNb=28 +Mcu.Pin20=PA14 +Mcu.Pin21=PD3 +Mcu.Pin22=PG11 +Mcu.Pin23=PG13 +Mcu.Pin24=PG14 +Mcu.Pin25=VP_FREERTOS_VS_CMSIS_V1 +Mcu.Pin26=VP_LWIP_VS_Enabled +Mcu.Pin27=VP_SYS_VS_tim1 +Mcu.Pin28=VP_TIM6_VS_ClockSourceINT +Mcu.Pin3=PF9 +Mcu.Pin4=PF10 +Mcu.Pin5=PH0-OSC_IN +Mcu.Pin6=PH1-OSC_OUT +Mcu.Pin7=PC1 +Mcu.Pin8=PA1 +Mcu.Pin9=PA2 +Mcu.PinsNb=29 Mcu.ThirdPartyNb=0 Mcu.UserConstants= Mcu.UserName=STM32F407ZETx @@ -141,23 +142,32 @@ PD3.GPIOParameters=GPIO_Label PD3.GPIO_Label=ETH_RST PD3.Locked=true PD3.Signal=GPIO_Output -PE2.GPIOParameters=GPIO_PuPd,GPIO_ModeDefaultEXTI +PE2.GPIOParameters=GPIO_PuPd,GPIO_Label,GPIO_ModeDefaultEXTI +PE2.GPIO_Label=GENLOCK PE2.GPIO_ModeDefaultEXTI=GPIO_MODE_IT_FALLING PE2.GPIO_PuPd=GPIO_PULLUP PE2.Locked=true PE2.Signal=GPXTI2 -PE3.GPIOParameters=GPIO_PuPd +PE3.GPIOParameters=GPIO_PuPd,GPIO_Label +PE3.GPIO_Label=KEY1 PE3.GPIO_PuPd=GPIO_PULLUP PE3.Locked=true PE3.Signal=GPIO_Input -PE4.GPIOParameters=GPIO_PuPd +PE4.GPIOParameters=GPIO_PuPd,GPIO_Label +PE4.GPIO_Label=KEY0 PE4.GPIO_PuPd=GPIO_PULLUP PE4.Locked=true PE4.Signal=GPIO_Input -PF10.GPIOParameters=GPIO_PuPd +PF10.GPIOParameters=GPIO_PuPd,GPIO_Label +PF10.GPIO_Label=DEBUG_LIGHT PF10.GPIO_PuPd=GPIO_PULLUP PF10.Locked=true PF10.Signal=GPIO_Output +PF9.GPIOParameters=GPIO_PuPd,GPIO_Label +PF9.GPIO_Label=ENCODER_LIGHT +PF9.GPIO_PuPd=GPIO_PULLUP +PF9.Locked=true +PF9.Signal=GPIO_Output PG11.Locked=true PG11.Mode=RMII PG11.Signal=ETH_TX_EN diff --git a/MDK-ARM/LWIP.uvoptx b/MDK-ARM/LWIP.uvoptx index 2286e43..3a249f9 100644 --- a/MDK-ARM/LWIP.uvoptx +++ b/MDK-ARM/LWIP.uvoptx @@ -1,4 +1,4 @@ - + 1.0 @@ -45,7 +45,7 @@ 79 66 8 - + 1 @@ -104,16 +104,16 @@ 0 0 3 - - - - - - - - - - + + + + + + + + + + BIN\CMSIS_AGDI.dll @@ -130,12 +130,12 @@ 0 ARMDBGFLAGS - + 0 DLGUARM - + 0 @@ -167,7 +167,7 @@ 0 1 ..\usersrc\atcmd.c - + \\LWIP\../usersrc/atcmd.c\132 @@ -183,7 +183,7 @@ 0 1 ../Src/ethernetif.c - + \\LWIP\../Src/ethernetif.c\198 @@ -228,19 +228,19 @@ 0 0 - - + + 0 0 0 - - - - - - - - + + + + + + + + 1 0 diff --git a/MDK-ARM/LWIP.uvprojx b/MDK-ARM/LWIP.uvprojx index 21b0d95..4cd39ac 100644 --- a/MDK-ARM/LWIP.uvprojx +++ b/MDK-ARM/LWIP.uvprojx @@ -1,10 +1,7 @@ - - - + + 2.1 -
### uVision Project, (C) Keil Software
- LWIP @@ -19,28 +16,28 @@ Keil.STM32F4xx_DFP.2.16.0 http://www.keil.com/pack/ IRAM(0x20000000-0x2001FFFF) IRAM2(0x10000000-0x1000FFFF) IROM(0x8000000-0x807FFFF) CLOCK(25000000) FPU2 CPUTYPE("Cortex-M4") - - - - - - - - - - - - - - + + + + + + + + + + + + + + $$Device:STM32F407ZETx$CMSIS\SVD\STM32F40x.svd 0 0 - - - - - + + + + + 0 0 @@ -55,15 +52,15 @@ 1 1 0 - + 1 0 0 0 0 - - + + 0 0 0 @@ -72,8 +69,8 @@ 0 0 - - + + 0 0 0 @@ -82,15 +79,15 @@ 0 0 - - + + 0 0 0 0 0 - + 0 @@ -104,8 +101,8 @@ 0 0 3 - - + + 0 @@ -138,11 +135,11 @@ 1 STLink\ST-LINKIII-KEIL_SWO.dll - - - - - + + + + + 0 @@ -175,7 +172,7 @@ 0 0 "Cortex-M4" - + 0 0 0 @@ -309,7 +306,7 @@ 0x10000 - + 1 @@ -336,9 +333,9 @@ 0 0 - + USE_HAL_DRIVER,STM32F407xx - + ../Inc;../Middlewares/Third_Party/LwIP/src/include;../Middlewares/Third_Party/LwIP/system;../Drivers/STM32F4xx_HAL_Driver/Inc;../Drivers/STM32F4xx_HAL_Driver/Inc/Legacy;../Middlewares/Third_Party/FreeRTOS/Source/portable/RVDS/ARM_CM4F;../Middlewares/Third_Party/LwIP/src/include/netif/ppp;../Drivers/CMSIS/Device/ST/STM32F4xx/Include;../Middlewares/Third_Party/FreeRTOS/Source/include;../Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS;../Middlewares/Third_Party/LwIP/src/include/lwip;../Middlewares/Third_Party/LwIP/src/include/lwip/apps;../Middlewares/Third_Party/LwIP/src/include/lwip/priv;../Middlewares/Third_Party/LwIP/src/include/lwip/prot;../Middlewares/Third_Party/LwIP/src/include/netif;../Middlewares/Third_Party/LwIP/system/arch;../Drivers/CMSIS/Include;../Drivers/BSP/Components/lan8742;../Middlewares/Third_Party/LwIP/src/include/compat/posix;../Middlewares/Third_Party/LwIP/src/include/compat/posix/arpa;../Middlewares/Third_Party/LwIP/src/include/compat/posix/net;../Middlewares/Third_Party/LwIP/src/include/compat/posix/sys;../Middlewares/Third_Party/LwIP/src/include/compat/stdc @@ -354,9 +351,9 @@ 0 1 - - - + + + ..\\Inc;..\Inc @@ -369,13 +366,13 @@ 0 0x08000000 0x20000000 - - - - - - - + + + + + + + @@ -435,8 +432,6 @@ 2 2 11 - - 1 @@ -464,12 +459,6 @@ 2 2 2 - - - - - - @@ -491,8 +480,6 @@ 2 2 11 - - 1 @@ -520,12 +507,6 @@ 2 2 2 - - - - - - @@ -557,8 +538,6 @@ 2 2 11 - - 1 @@ -586,12 +565,6 @@ 2 2 2 - - - - - - @@ -663,8 +636,6 @@ 2 2 11 - - 0 @@ -692,12 +663,6 @@ 2 2 2 - - - - - - 2 @@ -710,12 +675,6 @@ 2 2 0 - - - - - - @@ -737,8 +696,6 @@ 2 2 11 - - 1 @@ -766,12 +723,6 @@ 2 2 2 - - - - - - @@ -793,8 +744,6 @@ 2 2 11 - - 0 @@ -822,12 +771,6 @@ 2 2 2 - - - - - - 2 @@ -840,12 +783,6 @@ 2 2 0 - - - - - - @@ -867,8 +804,6 @@ 2 2 11 - - 1 @@ -896,12 +831,6 @@ 2 2 2 - - - - - - @@ -923,8 +852,6 @@ 2 2 11 - - 1 @@ -952,12 +879,6 @@ 2 2 2 - - - - - - @@ -979,8 +900,6 @@ 2 2 11 - - 1 @@ -1008,12 +927,6 @@ 2 2 2 - - - - - - @@ -1035,8 +948,6 @@ 2 2 11 - - 1 @@ -1064,12 +975,6 @@ 2 2 2 - - - - - - @@ -1091,8 +996,6 @@ 2 2 11 - - 1 @@ -1120,12 +1023,6 @@ 2 2 2 - - - - - - @@ -1147,8 +1044,6 @@ 2 2 11 - - 1 @@ -1176,12 +1071,6 @@ 2 2 2 - - - - - - @@ -1203,8 +1092,6 @@ 2 2 11 - - 1 @@ -1232,12 +1119,6 @@ 2 2 2 - - - - - - @@ -1259,8 +1140,6 @@ 2 2 11 - - 1 @@ -1288,12 +1167,6 @@ 2 2 2 - - - - - - @@ -1315,8 +1188,6 @@ 2 2 11 - - 1 @@ -1344,12 +1215,6 @@ 2 2 2 - - - - - - @@ -1371,8 +1236,6 @@ 2 2 11 - - 1 @@ -1400,12 +1263,6 @@ 2 2 2 - - - - - - @@ -1427,8 +1284,6 @@ 2 2 11 - - 1 @@ -1456,12 +1311,6 @@ 2 2 2 - - - - - - @@ -1483,8 +1332,6 @@ 2 2 11 - - 1 @@ -1512,12 +1359,6 @@ 2 2 2 - - - - - - @@ -1539,8 +1380,6 @@ 2 2 11 - - 1 @@ -1568,12 +1407,6 @@ 2 2 2 - - - - - - @@ -1595,8 +1428,6 @@ 2 2 11 - - 1 @@ -1624,12 +1455,6 @@ 2 2 2 - - - - - - @@ -1651,8 +1476,6 @@ 2 2 11 - - 1 @@ -1680,12 +1503,6 @@ 2 2 2 - - - - - - @@ -1707,8 +1524,6 @@ 2 2 11 - - 1 @@ -1736,12 +1551,6 @@ 2 2 2 - - - - - - @@ -1763,8 +1572,6 @@ 2 2 11 - - 1 @@ -1792,12 +1599,6 @@ 2 2 2 - - - - - - @@ -1819,8 +1620,6 @@ 2 2 11 - - 0 @@ -1848,12 +1647,6 @@ 2 2 2 - - - - - - 2 @@ -1866,12 +1659,6 @@ 2 2 0 - - - - - - @@ -1893,8 +1680,6 @@ 2 2 11 - - 1 @@ -1922,12 +1707,6 @@ 2 2 2 - - - - - - @@ -1949,8 +1728,6 @@ 2 2 11 - - 0 @@ -1978,12 +1755,6 @@ 2 2 2 - - - - - - 2 @@ -1996,12 +1767,6 @@ 2 2 0 - - - - - - @@ -2023,8 +1788,6 @@ 2 2 11 - - 1 @@ -2052,12 +1815,6 @@ 2 2 2 - - - - - - @@ -2079,8 +1836,6 @@ 2 2 11 - - 1 @@ -2108,12 +1863,6 @@ 2 2 2 - - - - - - @@ -2135,8 +1884,6 @@ 2 2 11 - - 1 @@ -2164,12 +1911,6 @@ 2 2 2 - - - - - - @@ -2191,8 +1932,6 @@ 2 2 11 - - 1 @@ -2220,12 +1959,6 @@ 2 2 2 - - - - - - @@ -2247,8 +1980,6 @@ 2 2 11 - - 1 @@ -2276,12 +2007,6 @@ 2 2 2 - - - - - - @@ -2303,8 +2028,6 @@ 2 2 11 - - 1 @@ -2332,12 +2055,6 @@ 2 2 2 - - - - - - @@ -2359,8 +2076,6 @@ 2 2 11 - - 1 @@ -2388,12 +2103,6 @@ 2 2 2 - - - - - - @@ -2415,8 +2124,6 @@ 2 2 11 - - 1 @@ -2444,12 +2151,6 @@ 2 2 2 - - - - - - @@ -2471,8 +2172,6 @@ 2 2 11 - - 1 @@ -2500,12 +2199,6 @@ 2 2 2 - - - - - - @@ -2527,8 +2220,6 @@ 2 2 11 - - 1 @@ -2556,12 +2247,6 @@ 2 2 2 - - - - - - @@ -2583,8 +2268,6 @@ 2 2 11 - - 0 @@ -2612,12 +2295,6 @@ 2 2 2 - - - - - - 2 @@ -2630,12 +2307,6 @@ 2 2 0 - - - - - - @@ -2657,8 +2328,6 @@ 2 2 11 - - 1 @@ -2686,12 +2355,6 @@ 2 2 2 - - - - - - @@ -2713,8 +2376,6 @@ 2 2 11 - - 1 @@ -2742,12 +2403,6 @@ 2 2 2 - - - - - - @@ -2769,8 +2424,6 @@ 2 2 11 - - 1 @@ -2798,12 +2451,6 @@ 2 2 2 - - - - - - @@ -2825,8 +2472,6 @@ 2 2 11 - - 1 @@ -2854,12 +2499,6 @@ 2 2 2 - - - - - - @@ -2881,8 +2520,6 @@ 2 2 11 - - 1 @@ -2910,12 +2547,6 @@ 2 2 2 - - - - - - @@ -2937,8 +2568,6 @@ 2 2 11 - - 1 @@ -2966,12 +2595,6 @@ 2 2 2 - - - - - - @@ -2993,8 +2616,6 @@ 2 2 11 - - 1 @@ -3022,12 +2643,6 @@ 2 2 2 - - - - - - @@ -3049,8 +2664,6 @@ 2 2 11 - - 1 @@ -3078,12 +2691,6 @@ 2 2 2 - - - - - - @@ -3105,8 +2712,6 @@ 2 2 11 - - 1 @@ -3134,12 +2739,6 @@ 2 2 2 - - - - - - @@ -3161,8 +2760,6 @@ 2 2 11 - - 1 @@ -3190,12 +2787,6 @@ 2 2 2 - - - - - - @@ -3217,8 +2808,6 @@ 2 2 11 - - 1 @@ -3246,12 +2835,6 @@ 2 2 2 - - - - - - @@ -3273,8 +2856,6 @@ 2 2 11 - - 1 @@ -3302,12 +2883,6 @@ 2 2 2 - - - - - - @@ -3329,8 +2904,6 @@ 2 2 11 - - 1 @@ -3358,12 +2931,6 @@ 2 2 2 - - - - - - @@ -3385,8 +2952,6 @@ 2 2 11 - - 1 @@ -3414,12 +2979,6 @@ 2 2 2 - - - - - - @@ -3441,8 +3000,6 @@ 2 2 11 - - 1 @@ -3470,12 +3027,6 @@ 2 2 2 - - - - - - @@ -3497,8 +3048,6 @@ 2 2 11 - - 1 @@ -3526,12 +3075,6 @@ 2 2 2 - - - - - - @@ -3553,8 +3096,6 @@ 2 2 11 - - 1 @@ -3582,12 +3123,6 @@ 2 2 2 - - - - - - @@ -3609,8 +3144,6 @@ 2 2 11 - - 1 @@ -3638,12 +3171,6 @@ 2 2 2 - - - - - - @@ -3665,8 +3192,6 @@ 2 2 11 - - 1 @@ -3694,12 +3219,6 @@ 2 2 2 - - - - - - @@ -3721,8 +3240,6 @@ 2 2 11 - - 1 @@ -3750,12 +3267,6 @@ 2 2 2 - - - - - - @@ -3777,8 +3288,6 @@ 2 2 11 - - 1 @@ -3806,12 +3315,6 @@ 2 2 2 - - - - - - @@ -3833,8 +3336,6 @@ 2 2 11 - - 1 @@ -3862,12 +3363,6 @@ 2 2 2 - - - - - - @@ -3889,8 +3384,6 @@ 2 2 11 - - 1 @@ -3918,12 +3411,6 @@ 2 2 2 - - - - - - @@ -3945,8 +3432,6 @@ 2 2 11 - - 1 @@ -3974,12 +3459,6 @@ 2 2 2 - - - - - - @@ -4001,8 +3480,6 @@ 2 2 11 - - 1 @@ -4030,12 +3507,6 @@ 2 2 2 - - - - - - @@ -4057,8 +3528,6 @@ 2 2 11 - - 1 @@ -4086,12 +3555,6 @@ 2 2 2 - - - - - - @@ -4113,8 +3576,6 @@ 2 2 11 - - 1 @@ -4142,12 +3603,6 @@ 2 2 2 - - - - - - @@ -4169,8 +3624,6 @@ 2 2 11 - - 1 @@ -4198,12 +3651,6 @@ 2 2 2 - - - - - - @@ -4225,8 +3672,6 @@ 2 2 11 - - 1 @@ -4254,12 +3699,6 @@ 2 2 2 - - - - - - @@ -4281,8 +3720,6 @@ 2 2 11 - - 1 @@ -4310,12 +3747,6 @@ 2 2 2 - - - - - - @@ -4337,8 +3768,6 @@ 2 2 11 - - 1 @@ -4366,12 +3795,6 @@ 2 2 2 - - - - - - @@ -4393,8 +3816,6 @@ 2 2 11 - - 1 @@ -4422,12 +3843,6 @@ 2 2 2 - - - - - - @@ -4449,8 +3864,6 @@ 2 2 11 - - 1 @@ -4478,12 +3891,6 @@ 2 2 2 - - - - - - @@ -4505,8 +3912,6 @@ 2 2 11 - - 1 @@ -4534,12 +3939,6 @@ 2 2 2 - - - - - - @@ -4561,8 +3960,6 @@ 2 2 11 - - 1 @@ -4590,12 +3987,6 @@ 2 2 2 - - - - - - @@ -4617,8 +4008,6 @@ 2 2 11 - - 1 @@ -4646,12 +4035,6 @@ 2 2 2 - - - - - - @@ -4673,8 +4056,6 @@ 2 2 11 - - 1 @@ -4702,12 +4083,6 @@ 2 2 2 - - - - - - @@ -4729,8 +4104,6 @@ 2 2 11 - - 1 @@ -4758,12 +4131,6 @@ 2 2 2 - - - - - - @@ -4785,8 +4152,6 @@ 2 2 11 - - 1 @@ -4814,12 +4179,6 @@ 2 2 2 - - - - - - @@ -4841,8 +4200,6 @@ 2 2 11 - - 1 @@ -4870,12 +4227,6 @@ 2 2 2 - - - - - - @@ -4897,8 +4248,6 @@ 2 2 11 - - 1 @@ -4926,12 +4275,6 @@ 2 2 2 - - - - - - @@ -4953,8 +4296,6 @@ 2 2 11 - - 1 @@ -4982,12 +4323,6 @@ 2 2 2 - - - - - - @@ -5009,8 +4344,6 @@ 2 2 11 - - 1 @@ -5038,12 +4371,6 @@ 2 2 2 - - - - - - @@ -5065,8 +4392,6 @@ 2 2 11 - - 1 @@ -5094,12 +4419,6 @@ 2 2 2 - - - - - - @@ -5121,8 +4440,6 @@ 2 2 11 - - 1 @@ -5150,12 +4467,6 @@ 2 2 2 - - - - - - @@ -5177,8 +4488,6 @@ 2 2 11 - - 1 @@ -5206,12 +4515,6 @@ 2 2 2 - - - - - - @@ -5233,8 +4536,6 @@ 2 2 11 - - 1 @@ -5262,12 +4563,6 @@ 2 2 2 - - - - - - @@ -5289,8 +4584,6 @@ 2 2 11 - - 1 @@ -5318,12 +4611,6 @@ 2 2 2 - - - - - - @@ -5345,8 +4632,6 @@ 2 2 11 - - 1 @@ -5374,12 +4659,6 @@ 2 2 2 - - - - - - @@ -5401,8 +4680,6 @@ 2 2 11 - - 1 @@ -5430,12 +4707,6 @@ 2 2 2 - - - - - - @@ -5457,8 +4728,6 @@ 2 2 11 - - 1 @@ -5486,12 +4755,6 @@ 2 2 2 - - - - - - @@ -5513,8 +4776,6 @@ 2 2 11 - - 1 @@ -5542,12 +4803,6 @@ 2 2 2 - - - - - - @@ -5569,8 +4824,6 @@ 2 2 11 - - 1 @@ -5598,12 +4851,6 @@ 2 2 2 - - - - - - @@ -5625,8 +4872,6 @@ 2 2 11 - - 1 @@ -5654,12 +4899,6 @@ 2 2 2 - - - - - - @@ -5681,8 +4920,6 @@ 2 2 11 - - 1 @@ -5710,12 +4947,6 @@ 2 2 2 - - - - - - @@ -5737,8 +4968,6 @@ 2 2 11 - - 1 @@ -5766,12 +4995,6 @@ 2 2 2 - - - - - - @@ -5793,8 +5016,6 @@ 2 2 11 - - 1 @@ -5822,12 +5043,6 @@ 2 2 2 - - - - - - @@ -5849,8 +5064,6 @@ 2 2 11 - - 1 @@ -5878,12 +5091,6 @@ 2 2 2 - - - - - - @@ -5905,8 +5112,6 @@ 2 2 11 - - 1 @@ -5934,12 +5139,6 @@ 2 2 2 - - - - - - @@ -5961,8 +5160,6 @@ 2 2 11 - - 1 @@ -5990,12 +5187,6 @@ 2 2 2 - - - - - - @@ -6017,8 +5208,6 @@ 2 2 11 - - 1 @@ -6046,12 +5235,6 @@ 2 2 2 - - - - - - @@ -6073,8 +5256,6 @@ 2 2 11 - - 1 @@ -6102,12 +5283,6 @@ 2 2 2 - - - - - - @@ -6129,8 +5304,6 @@ 2 2 11 - - 1 @@ -6158,12 +5331,6 @@ 2 2 2 - - - - - - @@ -6185,8 +5352,6 @@ 2 2 11 - - 1 @@ -6214,12 +5379,6 @@ 2 2 2 - - - - - - @@ -6241,8 +5400,6 @@ 2 2 11 - - 1 @@ -6270,12 +5427,6 @@ 2 2 2 - - - - - - @@ -6297,8 +5448,6 @@ 2 2 11 - - 1 @@ -6326,12 +5475,6 @@ 2 2 2 - - - - - - @@ -6353,8 +5496,6 @@ 2 2 11 - - 1 @@ -6382,12 +5523,6 @@ 2 2 2 - - - - - - @@ -6409,8 +5544,6 @@ 2 2 11 - - 1 @@ -6438,12 +5571,6 @@ 2 2 2 - - - - - - @@ -6465,8 +5592,6 @@ 2 2 11 - - 1 @@ -6494,12 +5619,6 @@ 2 2 2 - - - - - - @@ -6521,8 +5640,6 @@ 2 2 11 - - 1 @@ -6550,12 +5667,6 @@ 2 2 2 - - - - - - @@ -6577,8 +5688,6 @@ 2 2 11 - - 1 @@ -6606,12 +5715,6 @@ 2 2 2 - - - - - - @@ -6633,8 +5736,6 @@ 2 2 11 - - 1 @@ -6662,12 +5763,6 @@ 2 2 2 - - - - - - @@ -6689,8 +5784,6 @@ 2 2 11 - - 1 @@ -6718,12 +5811,6 @@ 2 2 2 - - - - - - @@ -6745,8 +5832,6 @@ 2 2 11 - - 1 @@ -6774,12 +5859,6 @@ 2 2 2 - - - - - - @@ -6801,8 +5880,6 @@ 2 2 11 - - 1 @@ -6830,12 +5907,6 @@ 2 2 2 - - - - - - @@ -6857,8 +5928,6 @@ 2 2 11 - - 1 @@ -6886,12 +5955,6 @@ 2 2 2 - - - - - - @@ -6913,8 +5976,6 @@ 2 2 11 - - 1 @@ -6942,12 +6003,6 @@ 2 2 2 - - - - - - @@ -6969,8 +6024,6 @@ 2 2 11 - - 1 @@ -6998,12 +6051,6 @@ 2 2 2 - - - - - - @@ -7025,8 +6072,6 @@ 2 2 11 - - 1 @@ -7054,12 +6099,6 @@ 2 2 2 - - - - - - @@ -7081,8 +6120,6 @@ 2 2 11 - - 1 @@ -7110,12 +6147,6 @@ 2 2 2 - - - - - - @@ -7137,8 +6168,6 @@ 2 2 11 - - 1 @@ -7166,12 +6195,6 @@ 2 2 2 - - - - - - @@ -7184,18 +6207,17 @@ - - + - + - + - + -
+ diff --git a/Src/gpio.c b/Src/gpio.c index 8cb7460..a51ba34 100644 --- a/Src/gpio.c +++ b/Src/gpio.c @@ -54,25 +54,25 @@ void MX_GPIO_Init(void) __HAL_RCC_GPIOG_CLK_ENABLE(); /*Configure GPIO pin Output Level */ - HAL_GPIO_WritePin(GPIOF, GPIO_PIN_10, GPIO_PIN_RESET); + HAL_GPIO_WritePin(GPIOF, ENCODER_LIGHT_Pin|DEBUG_LIGHT_Pin, GPIO_PIN_RESET); /*Configure GPIO pin Output Level */ HAL_GPIO_WritePin(ETH_RST_GPIO_Port, ETH_RST_Pin, GPIO_PIN_RESET); - /*Configure GPIO pin : PE2 */ - GPIO_InitStruct.Pin = GPIO_PIN_2; + /*Configure GPIO pin : PtPin */ + GPIO_InitStruct.Pin = GENLOCK_Pin; GPIO_InitStruct.Mode = GPIO_MODE_IT_FALLING; GPIO_InitStruct.Pull = GPIO_PULLUP; - HAL_GPIO_Init(GPIOE, &GPIO_InitStruct); + HAL_GPIO_Init(GENLOCK_GPIO_Port, &GPIO_InitStruct); - /*Configure GPIO pins : PE3 PE4 */ - GPIO_InitStruct.Pin = GPIO_PIN_3|GPIO_PIN_4; + /*Configure GPIO pins : PEPin PEPin */ + GPIO_InitStruct.Pin = KEY1_Pin|KEY0_Pin; GPIO_InitStruct.Mode = GPIO_MODE_INPUT; GPIO_InitStruct.Pull = GPIO_PULLUP; HAL_GPIO_Init(GPIOE, &GPIO_InitStruct); - /*Configure GPIO pin : PF10 */ - GPIO_InitStruct.Pin = GPIO_PIN_10; + /*Configure GPIO pins : PFPin PFPin */ + GPIO_InitStruct.Pin = ENCODER_LIGHT_Pin|DEBUG_LIGHT_Pin; GPIO_InitStruct.Mode = GPIO_MODE_OUTPUT_PP; GPIO_InitStruct.Pull = GPIO_PULLUP; GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_LOW; diff --git a/Src/stm32f4xx_it.c b/Src/stm32f4xx_it.c index 06fe9aa..b22d460 100644 --- a/Src/stm32f4xx_it.c +++ b/Src/stm32f4xx_it.c @@ -168,7 +168,7 @@ void EXTI2_IRQHandler(void) /* USER CODE BEGIN EXTI2_IRQn 0 */ /* USER CODE END EXTI2_IRQn 0 */ - HAL_GPIO_EXTI_IRQHandler(GPIO_PIN_2); + HAL_GPIO_EXTI_IRQHandler(GENLOCK_Pin); /* USER CODE BEGIN EXTI2_IRQn 1 */ /* USER CODE END EXTI2_IRQn 1 */