/* * irt-MAT - Ir Transceiver for MA-T33 DCM fan * by uratan! 2015.6.28 (released 2020.6.12) */ /* * IrT-MAT とは? */ DC モーターを使った扇風機は消費電力が小さく大変良いものですが、今様に すべてがマイコン制御されているため、首振りや風量など動作パラメータを 装置が覚えてくれず使用時に毎回指定する必要があります。 IrT-MAT は、これら動作のお好みのセットをプログラムしておき、ボタンの 1プッシュで所望の組み合わせにするための赤外リモコンです。現状「風量:2、 首振り、オフタイマー:3時間」になるようプログラムされています。 非動作時は power-down しますのでリモコンとしての消費電力は極小(約30uA)に なり、単4乾電池 2本で ひと夏やふた夏は電池が持っています。 output: LOW 固定 (PIO0_2), 38kHz carrier (PIO0_3) input: pushSW: (PIO0_1) SHORT PUSH: send 'S' when the SW being pushed lesser than 500msec LONG PUSH: send 'L' when the SW being pushed lesser than 1500msec (input: uart0: 57600bps (PIO0_0, same as ISP)) /* * FILES * ( irt-12.zip より派生) */ 00README.txt --- this file Makefile --- Makefile for make.exe link.awk --- a AWK script to generate linker script Startup.S --- CPU start up main.c --- main entry common.h --- system shared difinitions common.c --- system shared functions (uart) rprintf.c --- simple printf() (from sample of WinARM_20060606.zip) uart1.c --- UNUSED (handle uart1 to send Ir signal) sctimer.c --- generate 38kHz to modulate Ir signal irt-MAT-NN.hex --- a hex file image made Compiler used is gcc-4.7.1(2012-0616) from yagarto You may need sh.exe and rm.exe, seek it from web please. (see also https://sourceforge.net/projects/yagarto/files/) Get LPC810 related definitions from: lpcopen_2_01_lpcxpresso_nxp_lpcxpresso_812.zip (LPCXpresso v6.1.0_164, LPCOpen 2.xx software package for LPCXpresso LPC812 boead) then place lpc_chip_8xx_lib/inc/ to ../chip-inc/. Don't you have GNU awk ? use this. -- uratan@miomio.jp