资源简介
微型热敏打印头的驱动例程,实现了打印头加热控制,电机PWM控制,缺纸检测等功能。

代码片段和文件信息
/*---------------------------------------------------------------------------------------------------------*/
/* */
/* Copyright (c) 2008 by Nuvoton Technology Corporation */
/* All rights reserved */
/* */
/*---------------------------------------------------------------------------------------------------------*/
/*---------------------------------------------------------------------------------------------------------*/
/* Check semihosting function. For standalone application */
/*---------------------------------------------------------------------------------------------------------*/
#if 1
#pragma import(__use_no_semihosting_swi)
#endif
#include
#include
extern void DrvSIO_PutChar(char ch);
#define USE_SERIAL_PORT
#define uputchar DrvSIO_PutChar
#define ugetchar DrvSIO_GetChar
struct __FILE { int handle; /* Add whatever you need here */};
FILE __stdout;
__value_in_regs struct __initial_stackheap __user_initial_stackheap (
unsigned R0
unsigned SP
unsigned R2
unsigned SL
)
{
struct __initial_stackheap config;
extern __weak unsigned int Image$$ZI$$Limit;
extern __weak unsigned int Image$$RAM$$ZI$$Limit;
if((unsigned int)&Image$$ZI$$Limit)
config.heap_base = (unsigned int)&Image$$ZI$$Limit;
else if((unsigned int)&Image$$RAM$$ZI$$Limit)
config.heap_base = (unsigned int)&Image$$RAM$$ZI$$Limit;
else
config.heap_base = 0x4000;
config.heap_limit = SP;
config.stack_base = SP;
config.stack_limit = SL;
return config;
}
//unsigned int aaaa;
int fputc(int ch FILE *f)
{
/* Place your implementation of fputc here */
/* e.g. write a character to a UART or to the */
/* debugger console with SWI WriteC */
char tempch = ch;
#ifdef USE_SERIAL_PORT
extern void uputchar(char ch);
uputchar(tempch); // output to UART
#else
WriteC( &tempch );
#endif
return ch;
}
int ferror(FILE *f)
{ /* Your implementation of ferror */
return EOF;
}
void _ttywrch(int ch)
{
char tempch = ch;
#ifdef USE_SERIAL_PORT
DrvSIO_PutChar( tempch );
#else
WriteC( &tempch );
#endif
}
// Returns the number of characters transmitted.
int print_sys_buf(unsigned int count unsigned char *stream_ptr)
{
do
{
DrvSIO_PutChar(*(char *)stream_ptr);
count--;
stream_ptr++;
}while (count != 0);
return count;
}
// Routine to fill the stream buffer from the com port.
// Returns the first character read.
i
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2017-01-24 16:47 HW\
目录 0 2017-01-24 16:47 HW\Include\
文件 6684 2009-11-10 17:14 HW\Include\ADC.h
文件 3105 2009-11-10 17:14 HW\Include\AIC.h
文件 3257 2009-11-10 17:14 HW\Include\APU.h
文件 2027 2009-11-10 17:14 HW\Include\ba
文件 3523 2009-11-10 17:14 HW\Include\CLK.h
文件 4357 2009-11-10 17:14 HW\Include\GCR.h
文件 13128 2009-11-10 17:14 HW\Include\GPIO.h
文件 2193 2009-11-10 17:14 HW\Include\I2C.h
文件 2311 2009-11-10 17:14 HW\Include\NVTChipDef.h
文件 7496 2009-11-10 17:14 HW\Include\PWM.h
文件 3903 2009-11-10 17:14 HW\Include\RTC.h
文件 1246 2009-11-10 17:14 HW\Include\SFR.h
文件 4955 2009-11-10 17:14 HW\Include\SPIM.h
文件 2225 2009-11-10 17:14 HW\Include\SPIMS.h
文件 1830 2009-11-10 17:14 HW\Include\SRAM.h
文件 668 2009-11-10 17:14 HW\Include\SYS.h
文件 2514 2009-11-10 17:14 HW\Include\Timer.h
文件 4602 2009-11-10 17:14 HW\Include\UART.h
文件 8037 2009-11-10 17:14 HW\Include\USB.h
目录 0 2017-01-24 16:47 NuvotonPlatform_ADS\
目录 0 2017-01-24 16:47 NuvotonPlatform_ADS\Include\
目录 0 2017-01-24 16:47 NuvotonPlatform_ADS\Include\Driver\
文件 9133 2009-11-10 17:14 NuvotonPlatform_ADS\Include\Driver\DrvADC.h
文件 4947 2009-11-10 17:14 NuvotonPlatform_ADS\Include\Driver\DrvAIC.h
文件 4192 2009-11-10 17:14 NuvotonPlatform_ADS\Include\Driver\DrvAPU.h
文件 2058 2011-01-06 17:10 NuvotonPlatform_ADS\Include\Driver\DrvAUDIO.h
文件 6630 2009-11-10 17:14 NuvotonPlatform_ADS\Include\Driver\DrvGPIO.h
文件 4183 2009-11-10 17:14 NuvotonPlatform_ADS\Include\Driver\DrvI2C.h
文件 7460 2009-11-10 17:14 NuvotonPlatform_ADS\Include\Driver\DrvPWM.h
............此处省略136个文件信息
相关资源
- IAR For ARM 7.3最新注册机
- 郭天祥ARM9视频教程
- IAR ARM 7.8破解
- IAR For ARM V5.5 注册机
- IAR for ARM 7.40 破解
- IAR For ARM 7.4 破解
- arm触摸屏与LCD校准程序三点校准法
- ARM嵌入式项目实战
- 基于ARM蓝牙传输源程序
- USB 驱动 让电脑与arm进行通信
- arm flash 烧写程序源码
- 基于LW IP的嵌入式串口服务器的设计与
- Studies In Vitro and In Vivo of Pharmacologica
- Research on pharmacological effects of lycorin
- 汉印A300 CPCL协议 android 热敏打印app(
- ARM64 完整指令集,学习必备
- WINCC报表(OLE-DB Tag and Alarm Export_V8.x
- ARM9指令cache的verilog代码
- 基于ARM7处理器的CAN总线网络设计
- 基于ARM和GPRS的无线通信系统设计
- 关于proteus仿真arm7出现错误的问题
- 基于ARM7的LCD显示电压示波系统的设计
- 基于ARM7和DSP的逆变电源设计电路
- 基于ARM开发板的车辆检测系统控制单
- ARM7TDMI-S在嵌入式系统中的Bootloader代码
- ARM汇编指令集PDF
- 基于ARM7 PWM定时器的图像传感器时序信
- 基于ARM7的分布式远程测控系统设计
- LPC2100系列ARM7微控制器加密ARM芯片
- ARM7内核的中断屏蔽方法
评论
共有 条评论