一、思路 基于STM8,按键处理,思路是这样的: 每20ms左右一次去扫描按键,用一个key_now记录当前值,用key_last记录上次的值,如果key_now和key_last同时有效,则开始进行cnt++。 我设定两个阈值,LONG_PRESS为100(100*20ms=2s),SHORT_P...
分类:
其他好文 时间:
2014-07-10 14:08:35
阅读次数:
202
文档的写作,例来分为latex与word两大阵营。一个是论文界的宠儿,一个是平民的所见即所得。看起来好像前者更加牛一些。本来我也是觉得latex比word好。但是使用latex时苦于找不到一个好的编辑软件。Ctex自带的WinEdit交互简直是一团渣。作为Vim的爱好者,又研究了一段时间latex-...
分类:
其他好文 时间:
2014-07-10 12:42:41
阅读次数:
243
执行svnupdate时总是提示输入密码.$cd~/.gnome2/keyrings/$ls$rm默认密钥.keyring
分类:
其他好文 时间:
2014-07-10 00:43:55
阅读次数:
334
span{word-break:normal;width:auto;display:block;white-space:pre-wrap;word-wrap:break-word;overflow:hidden;} white-space -- 通过HTML文档的源代码的排版方式控制页面显示文本的排...
分类:
其他好文 时间:
2014-07-10 00:07:38
阅读次数:
332
1) 网站上经常会出现用户输入一大段字符和字母以至于文字无法正常折行,把版式破坏,这样我们就要参考以下样式:word-wrap:break-word; overflow:hidden; 当然必须得有宽度属性值。2) 文字过长要出现省略号样式如下:white-space: nowrap; text-o...
分类:
Web程序 时间:
2014-07-09 23:51:24
阅读次数:
474
Cold weather is coming and in some northern states is already here. That means it’s time to winterize your car. Vehicle maintenance is something we do...
分类:
其他好文 时间:
2014-07-07 21:42:46
阅读次数:
247
After a perfect inning from Farnsworth in the eighth, the Yankees would have Alex Rodriguez coming to the plate to lead off the inning. Guillen left C...
分类:
其他好文 时间:
2014-07-07 20:49:01
阅读次数:
260
这道题目各种wa。首先是错了一个坐标,居然没测出来。然后是剪枝错误。搜索pen时就返回,可能还存在串pen*。 1 #include 2 #include 3 #include 4 5 #define MAXN 1005 6 7 typedef struct Trie { 8 in...
分类:
其他好文 时间:
2014-07-07 18:07:44
阅读次数:
210
Given a 2D board and a word, find if the word exists in the grid.The word can be constructed from letters of sequentially adjacent cell, where "adjace...
分类:
其他好文 时间:
2014-07-07 17:30:29
阅读次数:
160
服务器是windows server2008 64位系统,项目中需要用到Microsoft.Office.Interop组件,包括excel、word、ppt等。重点一:步骤1.在"开始"->"运行"中输入dcomcnfg.exe启动"组件服务"2.依次双击"组件服务"->"计算机"->"我的电脑"...