⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 dmac.h

📁 A few drivers for the Motorola C380 s celluar phone hardware with a simple test application. It s co
💻 H
字号:
#ifndef DMAC_DRV_H
#define DMAC_DRV_H

#include "../libs/motolibs.h"

/* Initialize and configure DMAC */
//TODO: lacks documentation
void dmac_config(hword transfer_config, hword clock_config, hword data_pol);

/* Check if DMAC is busy */
bool dmac_check_busy(void);

/* Wait for DMAC to finish current operation */
void dmac_wait(void);

/* Abort current DMAC operation */
void dmac_abort(void);

/* Send a byte via DMAC */
void dmac_send_byte(byte abyte, bool isdata);

/* Send a block of data via DMAC */
void dmac_send_data(void * data, word * length);

/* Send a command with no arguments to the display controller */
#define dmac_send_cmd_no(a) dmac_send_byte(a,false);

/* Send a command with one argument to the display controller */
void dmac_send_cmd_one(byte cmd, byte data);

/* Send a command with two arguments to the display controller */
void dmac_send_cmd_two(byte cmd, byte data1, byte data2);

/* Send a command with three arguments to the display controller */
void dmac_send_cmd_three(byte cmd, byte data1, byte data2, byte data3);

/* Send a command with an argument block to the display controller */
void dmac_send_cmd_long(byte cmd, void * data, word length);

#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -