openpcd/firmware/src/picc/opicc_reg.h @ master
1 |
#ifndef _OPCD_REG_H
|
---|---|
2 |
#define _OPCD_REG_H
|
3 |
|
4 |
#include <openpicc.h>
|
5 |
#include <sys/types.h>
|
6 |
|
7 |
#ifdef DEBUG
|
8 |
uint16_t opicc_reg_read(enum opicc_reg reg); |
9 |
void opicc_reg_write(enum opicc_reg reg, uint16_t val); |
10 |
#else
|
11 |
uint16_t opicc_regs[_OPICC_NUM_REGS]; |
12 |
#define opicc_reg_read(x) (opicc_regs[x])
|
13 |
#define opicc_reg_write(x, y) (opicc_regs[x] = y)
|
14 |
#endif
|
15 |
|
16 |
void opicc_usbapi_init(void); |
17 |
|
18 |
#endif
|