Question: void LedBlinkingTask ( uint 3 2 _ t period _ seconds ) { while ( g _ ledBlinking ) { GPIO _ PORTN _ DATA
void LedBlinkingTaskuintt periodseconds while gledBlinking GPIOPORTNDATAR LEDPIN; Birinci LED'i yak SysCtlDelayguiSysClock periodseconds; Belirtilen sre kadar bekle GPIOPORTNDATAR & ~LEDPIN; Birinci LED'i sndr GPIOPORTNDATAR LEDPIN; kinci LED'i yak SysCtlDelayguiSysClock periodseconds; Belirtilen sre kadar bekle GPIOPORTNDATAR & ~LEDPIN; int mainvoid MAPSysCtlClockFreqSetSYSCTLXTALMHZ SYSCTLOSCMAIN SYSCTLUSEPLL SYSCTLCFGVCO; MAPSysCtlPeripheralEnableSYSCTLPERIPHGPION; MAPSysCtlPeripheralEnableSYSCTLPERIPHGPIOJ; MAPSysCtlPeripheralEnableSYSCTLPERIPHGPIOC; MAPGPIOPinTypeGPIOOutputGPIOPORTNBASE, GPIOPIN GPIOPIN; MAPGPIOPinTypeGPIOInputGPIOPORTJBASE, GPIOPIN GPIOPIN; MAPGPIOPinTypeGPIOInputGPIOPORTCBASE, GPIOPIN GPIOPIN GPIOPIN GPIOPIN; MAPGPIOPadConfigSetGPIOPORTJBASE, GPIOPIN GPIOPIN GPIOSTRENGTHMA GPIOPINTYPESTDWPU; MAPGPIOPadConfigSetGPIOPORTCBASE, GPIOPIN GPIOPIN GPIOPIN GPIOPIN GPIOSTRENGTHMA GPIOPINTYPESTDWPU; ConfigureUART; guiSysClock SysCtlClockGet; MAPSysTickPeriodSetguiSysClock ; MAPSysTickEnable; MAPSysTickIntEnable; while LedBlinkingTask; Start LED blinking with a second period LedBlinkTask func Hello this code is a small part of the code I wrote for the Tiva Tmc device, I want to add a timer function called Timer to this code and this function should not contain delay, for example, if I say Timer in main after defining this function, it will need to create a second timer. For example, I will be able to call this function in a led onoff function etc. It should also contain an interrupt.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
