0% found this document useful (0 votes)
50 views1 page

SRPWMH Final

This document contains header information for an SRPWM (Shift Register Pulse Width Modulation) module. It includes definitions for events and services used by the module. It also declares functions for initializing the SRPWM service, posting and handling events, setting the pulse width on outputs via a shift register, initializing the hardware, and encoding/extracting the pulse width and output pin from a parameter.

Uploaded by

api-340769184
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
50 views1 page

SRPWMH Final

This document contains header information for an SRPWM (Shift Register Pulse Width Modulation) module. It includes definitions for events and services used by the module. It also declares functions for initializing the SRPWM service, posting and handling events, setting the pulse width on outputs via a shift register, initializing the hardware, and encoding/extracting the pulse width and output pin from a parameter.

Uploaded by

api-340769184
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 1

#ifndef SRPWM_H

#define SRPWM_H
/****************************************************************************
Header file for SRPWM
based on the Gen 2 Events and Services Framework
****************************************************************************/
#include <stdint.h>
#include <stdbool.h>
#include <stdio.h>
// Event
#include
#include
#include
#include
#include
#include

Definitions
"ES_Configure.h" /* gets us event definitions */
"ES_Types.h"
/* gets bool type for returns */
"ES_ShortTimer.h"
"ES_Framework.h"
"ES_Events.h"
"ES_Port.h"

#include
#include
#include
#include
#include
#include

"termio.h"
"inc/hw_memmap.h"
"inc/hw_types.h"
"inc/hw_gpio.h"
"inc/hw_sysctl.h"
"driverlib/gpio.h"

#include "DEFINITIONS.h"
#include "ShiftRegisterWrite.h"
#define MAX_PULSE_WIDTH 30
typedef enum { SRPWM_InitPState } SRPWMState_t ;
bool Init_SRPWMService(uint8_t Priority);
bool Post_SRPWMService(ES_Event ThisEvent);
ES_Event Run_SRPWMService(ES_Event ThisEvent);
void SR_SetPWM(uint8_t PulseWidth, uint8_t OutputPin);
void SRPWM_HWInit(void);
uint16_t Encode_Idx_PW(uint8_t PW, uint8_t PW_idx);
static uint8_t ExtractIdx(uint16_t Param);
static uint8_t ExtractPW(uint16_t Param);
#endif

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy