#include <stdio.h>
#include <pic24_all.h>
#include "pm.h"
Go to the source code of this file.
Defines | |
#define | __FILE_ID__ 0x51 |
#define | ISR_PERIOD 1 |
Functions | |
void _ISR | _T2Interrupt (void) |
void | configTimer2 (void) |
PmReturn_t | plat_init (void) |
PmReturn_t | plat_deinit (void) |
uint8_t | plat_memGetByte (PmMemSpace_t memspace, uint8_t const **paddr) |
PmReturn_t | plat_getByte (uint8_t *b) |
PmReturn_t | plat_putByte (uint8_t b) |
PmReturn_t | plat_getMsTicks (uint32_t *r_ticks) |
void | plat_reportError (PmReturn_t result) |
Variables | |
volatile uint32_t | u32_ms = 0 |
Definition in file plat.c.
#define ISR_PERIOD 1 |
void _ISR _T2Interrupt | ( | void | ) |
Interrupt Service Routine for Timer2. Receives one interrupts per ISR_PERIOD milliseconds.
void configTimer2 | ( | void | ) |
Configure timer 2 to produce interrupts every ISR_PERIOD ms.
PmReturn_t plat_deinit | ( | void | ) |
PmReturn_t plat_getByte | ( | uint8_t * | b | ) |
PmReturn_t plat_getMsTicks | ( | uint32_t * | r_ticks | ) |
PmReturn_t plat_init | ( | void | ) |
uint8_t plat_memGetByte | ( | PmMemSpace_t | memspace, | |
uint8_t const ** | paddr | |||
) |
Returns the byte at the given address in memspace.
Increments the address (just like getc and read(1)) to make image loading work (recursively).
PORT: fill in getByte for each memspace in the system; call sys_error for invalid memspaces.
memspace | memory space/type | |
paddr | ptr to address |
PmReturn_t plat_putByte | ( | uint8_t | b | ) |
void plat_reportError | ( | PmReturn_t | result | ) |