用C51实现单片机的中文输入法
说明:
拼音输入法杳询函数: unsigned char code * py_ime(unsigned char input_py_val[]); input_py_val为已输入的拼音码字符串头指针,
反回值为中文的起始地址,当为0时,杳询失败
应用举例:
{
unsigned char input_string[]={"bang"};
unsigned char chines_string[100];
sprintf(chines_string,"%s",py_ime(input_string));
}
C51程序:
//"********************CCDC01采集器测试仪软件:拼音输入法模块********************" //"* 软件设计: *"
//"* 日期: 2001/3 *"
//"* 编译环境:Franklin 3.3.4 *"
//"******************************************************************************"
#include
#include
//"********************CCDC01采集器测试仪软件:拼音输入法码表********************" //"* 软件设计:张凯 *"
//"* 日期: 2001/3 *"
//"* 编译环境:Franklin 3.3.4 *"
//"******************************************************************************"
//"拼音输入法汉字排列表"
unsigned char code PY_mb_a []={"阿啊"};
unsigned char code PY_mb_ai []={"哎哀唉埃挨皑癌矮蔼艾爱隘碍"};
unsigned char code PY_mb_an []={"安氨鞍俺岸按案胺暗"};
unsigned char code PY_mb_ang []={"肮昂盎"};
unsigned char code PY_mb_ao []={"凹敖熬翱袄傲奥澳懊"};
unsigned char code PY_mb_ba []={"八巴叭扒吧芭疤捌笆拔跋把靶坝爸罢霸"};
unsigned char code PY_mb_bai []={"白百佰柏摆败拜稗"};
unsigned char code PY_mb_ban []={"扳班般颁斑搬板版办半伴扮拌绊瓣"};
unsigned char code PY_mb_bang []={"邦帮梆绑榜膀蚌傍棒谤磅镑"};
unsigned char code PY_mb_bao []={"包苞胞褒雹宝饱保堡报抱豹鲍暴爆剥薄瀑"}; unsigned char code PY_mb_bei []={"卑杯悲碑北贝狈备背钡倍被惫焙辈"};
unsigned char code PY_mb_ben []={"奔本苯笨夯"};
unsigned char code PY_mb_beng []={"崩绷甭泵迸蹦"};
unsigned char code PY_mb_bi []={"逼鼻比彼笔鄙币必毕闭庇毖陛毙敝痹蓖弊碧蔽壁避臂"};
unsigned char code PY_mb_bian []={"边编鞭贬扁卞便变遍辨辩辫"};
unsigned char code PY_mb_biao []={"彪标膘表"};
unsigned char code PY_mb_bie []={"憋鳖别瘪"};
unsigned char code PY_mb_bin []={"宾彬斌滨濒摈"};
unsigned char code PY_mb_bing []={"冰兵丙秉柄炳饼并病"};
unsigned char code PY_mb_bo []={"拨波玻钵脖菠播伯驳帛泊勃铂舶博渤搏箔膊卜"}; unsigned char code PY_mb_bu []={"补哺捕不布步怖部埠簿"};
unsigned char code PY_mb_ca []={"擦"};
unsigned char code PY_mb_cai []={"猜才材财裁采彩睬踩菜蔡"};
unsigned char code PY_mb_can []={"参餐残蚕惭惨灿"};
unsigned char code PY_mb_cang []={"仓沧苍舱藏"};
unsigned char code PY_mb_cao []={"操糙曹槽草"};
unsigned char code PY_mb_ce []={"册侧厕测策"};
unsigned char code PY_mb_ceng []={"层蹭曾"};
unsigned char code PY_mb_cha []={"叉插查茬茶搽察碴岔诧差刹"};
unsigned char code PY_mb_chai []={"拆柴豺"};
unsigned char code PY_mb_chan []={"掺搀谗馋缠蝉产铲阐颤"};
unsigned char code PY_mb_chang []={"昌猖肠尝偿常厂场敞畅倡唱"};
unsigned char code PY_mb_chao []={"抄钞超巢朝嘲潮吵炒绰"};
unsigned char code PY_mb_che []={"车扯彻掣撤澈"};
unsigned char code PY_mb_chen []={"郴尘臣忱沉辰陈晨衬趁"};
unsigned char code PY_mb_cheng []={"称撑成呈承诚城乘惩程澄橙逞骋秤"}; unsigned char code PY_mb_chi []={"吃痴弛池驰迟持尺侈齿耻斥赤炽翅"}; unsigned char code PY_mb_chong []={"充冲虫崇宠"};
unsigned char code PY_mb_chou []={"抽仇绸畴愁稠筹酬踌丑瞅臭"}; unsigned char code PY_mb_chu []={"出初除厨滁锄雏橱躇础储楚处搐触矗畜"}; unsigned char code PY_mb_chuai []={"揣"};c51中字符串函数
unsigned char code PY_mb_chuan []={"川穿传船椽喘串"};
unsigned char code PY_mb_chuang[]={"闯疮窗床创"};
unsigned char code PY_mb_chui []={"吹炊垂捶锤"};
unsigned char code PY_mb_chun []={"春椿纯唇淳醇蠢"};
unsigned char code PY_mb_chuo []={"戳"};
unsigned char code PY_mb_ci []={"疵词茨瓷慈辞磁雌此次刺赐"};
unsigned char code PY_mb_cong []={"囱从匆葱聪丛"};
unsigned char code PY_mb_cou []={"凑"};
unsigned char code PY_mb_cu []={"粗促醋簇"};
unsigned char code PY_mb_cuan []={"蹿窜篡"};
unsigned char code PY_mb_cui []={"崔催摧脆淬瘁粹翠"};
unsigned char code PY_mb_cun []={"村存寸"};
unsigned char code PY_mb_cuo []={"搓磋撮挫措错"};
unsigned char code PY_mb_da []={"搭达答瘩打大"};
unsigned char code PY_mb_dai []={"呆歹傣代带待怠殆贷袋逮戴"};
unsigned char code PY_mb_dan []={"丹单担耽郸胆掸旦但诞弹惮淡蛋氮"}; unsigned char code PY_mb_dang []={"当挡党荡档"};
unsigned char code PY_mb_dao []={"刀导岛倒捣祷蹈到悼盗道稻"};
unsigned char code PY_mb_de []={"得德的"};
unsigned char code PY_mb_deng []={"灯登蹬等邓凳瞪"};
unsigned char code PY_mb_di []={"低堤滴狄迪敌涤笛嫡底抵地弟帝递第缔蒂"}; unsigned char code PY_mb_dian []={"掂滇颠典点碘电佃甸店垫惦淀奠殿靛"}; unsigned char code PY_mb_diao []={"刁叼凋碉雕吊钓掉"};
unsigned char code PY_mb_die []={"爹跌迭谍叠碟蝶"};
unsigned char code PY_mb_ding []={"丁叮盯钉顶鼎订定锭"};
unsigned char code PY_mb_diu []={"丢"};
unsigned char code PY_mb_dong []={"东冬董懂动冻侗恫栋洞"};
unsigned char code PY_mb_dou []={"都兜斗抖陡豆逗痘"};
unsigned char code PY_mb_du []={"督毒读犊独堵赌睹妒杜肚度渡镀"};
unsigned char code PY_mb_duan []={"端短段断缎锻"};
unsigned char code PY_mb_dui []={"堆队对兑"};
unsigned char code PY_mb_dun []={"吨敦墩蹲盾钝顿遁"};
unsigned char code PY_mb_duo []={"多哆夺掇朵垛躲剁堕舵惰跺"};
unsigned char code PY_mb_e []={"讹俄娥峨鹅蛾额厄扼恶饿鄂遏"};
unsigned char code PY_mb_en []={"恩"};
unsigned char code PY_mb_er []={"儿而尔耳洱饵二贰"};
unsigned char code PY_mb_fa []={"发乏伐罚阀筏法珐"};
unsigned char code PY_mb_fan []={"帆番翻藩凡矾钒烦樊繁反返犯泛饭范贩"}; unsigned char code PY_mb_fang []={"方坊芳防妨房肪仿访纺放"};
unsigned char code PY_mb_fei []={"飞非啡菲肥匪诽吠废沸肺费"};
unsigned char code PY_mb_fen []={"分吩纷芬氛酚坟汾焚粉份奋忿愤粪"};
unsigned char code PY_mb_feng []={"丰风枫封疯峰烽锋蜂冯逢缝讽凤奉"};
unsigned char code PY_mb_fo []={"佛"};
unsigned char code PY_mb_fou []={"否"};
unsigned char code PY_mb_fu []={"夫肤孵敷弗伏扶拂服俘氟浮涪符袱幅福辐抚甫府斧俯釜辅腑腐父讣付妇负附咐阜复赴副傅富赋缚腹覆"};
unsigned char code PY_mb_ga []={"嘎噶"};
unsigned char code PY_mb_gai []={"该改钙盖溉概"};
unsigned char code PY_mb_gan []={"干甘杆肝柑竿秆赶敢感赣"};
unsigned char code PY_mb_gang []={"冈刚岗纲肛缸钢港杠"};
unsigned char code PY_mb_gao []={"皋羔高膏篙糕搞稿镐告"};
unsigned char code PY_mb_ge []={"戈疙哥胳鸽割搁歌阁革格葛隔个各铬咯"}; unsigned char code PY_mb_gei []={"给"};
unsigned char code PY_mb_gen []={"根跟"};
unsigned char code PY_mb_geng []={"更庚耕羹埂耿梗"};
unsigned char code PY_mb_gong []={"工弓公功攻供宫恭躬龚巩汞拱共贡"};
unsigned char code PY_mb_gou []={"勾沟钩狗苟构购垢够"};
unsigned char code PY_mb_gu []={"估咕姑孤沽菇辜箍古谷股骨蛊鼓固故顾雇"}; unsigned char code PY_mb_gua []={"瓜刮剐寡挂褂"};
unsigned char code PY_mb_guai []={"乖拐怪"};
unsigned char code PY_mb_guan []={"关观官冠棺馆管贯惯灌罐"};
unsigned char code PY_mb_guang []={"光广逛"};
unsigned char code PY_mb_gui []={"归圭龟规闺硅瑰轨诡癸鬼刽柜贵桂跪"};
unsigned char code PY_mb_gun []={"辊滚棍"};
unsigned char code PY_mb_guo []={"郭锅国果裹过"};
unsigned char code PY_mb_ha []={"蛤哈"};
unsigned char code PY_mb_hai []={"孩骸海亥骇害氦"};
unsigned char code PY_mb_han []={"酣憨含邯函涵寒韩罕喊汉汗旱悍捍焊憾撼翰"}; unsigned char code PY_mb_hang []={"杭航行"};
unsigned char code PY_mb_hao []={"毫豪嚎壕好郝号浩耗"};
unsigned char code PY_mb_he []={"呵喝禾合何和河阂核荷涸盒菏贺褐赫鹤"};
unsigned char code PY_mb_hei []={"黑嘿"};
unsigned char code PY_mb_hen []={"痕很狠恨"};
unsigned char code PY_mb_heng []={"亨哼恒横衡"};
unsigned char code PY_mb_hong []={"轰哄烘弘红宏洪虹鸿"};
unsigned char code PY_mb_hou []={"侯喉猴吼后厚候"};
unsigned char code PY_mb_hu []={"乎呼忽弧狐胡壶湖葫瑚糊蝴虎唬互户护沪"}; unsigned char code PY_mb_hua []={"花华哗滑猾化划画话"};
unsigned char code PY_mb_huai []={"怀徊淮槐坏"};
unsigned char code PY_mb_huan []={"欢还环桓缓幻宦唤换涣患焕痪豢"};
unsigned char code PY_mb_huang []={"荒慌皇凰黄惶煌蝗磺簧恍晃谎幌"};
unsigned char code PY_mb_hui []={"灰恢挥辉徽回蛔悔卉汇会讳绘诲烩贿晦秽惠毁慧"}; unsigned char code PY_mb_hun []={"昏荤婚浑魂混"};
unsigned char code PY_mb_huo []={"豁活火伙或货获祸惑霍"};
unsigned char code PY_mb_ji []={"讥击饥圾机肌鸡迹姬积基绩缉畸箕稽激及吉汲级即极急疾棘集嫉辑籍几己挤脊计记伎纪妓忌技际剂季既济继寂寄悸祭蓟冀藉"};
unsigned char code PY_mb_jia []={"加夹佳枷家嘉荚颊甲贾钾价驾架假嫁稼挟"};
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系QQ:729038198,我们将在24小时内删除。
发表评论