Chinaunix首页 | 论坛 | 博客
  • 博客访问: 167323
  • 博文数量: 18
  • 博客积分: 285
  • 博客等级: 二等列兵
  • 技术积分: 201
  • 用 户 组: 普通用户
  • 注册时间: 2012-07-02 11:26
文章分类

全部博文(18)

文章存档

2015年(2)

2014年(4)

2012年(12)

我的朋友

分类: LINUX

2012-09-10 10:40:05

    原文地址:
 
NEC Protocol

To my knowledge the protocol I describe here was developed by NEC. I've seen very similar protocol descriptions on the internet, and there the protocol is called Japanese Format.
I do admit that I don't know exactly who developed it. What I do know is that it is used in my late VCR produced by Sanyo and was marketed under the name of Fisher. NEC manufactured the remote control IC.
This description was taken from the VCR's service manual. Those were the days, when service manuals were fulled with useful information!

Features
  • 8 bit address and 8 bit command length
  • Address and command are transmitted twice for reliability
  • Pulse distance modulation
  • Carrier frequency of 38kHz
  • Bit time of 1.125ms or 2.25ms
Modulation

NEC Modulation The NEC protocol uses pulse distance encoding of the bits. Each pulse is a 560µs long 38kHz carrier burst (about 21 cycles). A logical "1" takes 2.25ms to transmit, while a logical "0" is only half of that, being 1.125ms. The recommended carrier duty-cycle is 1/4 or 1/3. (是脉距调制,宽是固定的)


 

Protocol

NEC Pulse Train

The picture above shows a typical pulse train of the NEC protocol. With this protocol the LSB is transmitted first. In this case Address $59 and Command $16 is transmitted. A message is started by a 9ms AGC burst, which was used to set the gain of the earlier IR receivers. This AGC burst is then followed by a 4.5ms space, which is then followed by the Address and Command. Address and Command are transmitted twice. The second time all bits are inverted and can be used for verification of the received message. The total transmission time is constant because every bit is repeated with its inverted length. If you're not interested in this reliability you can ignore the inverted values, or you can expand the Address and Command to 16 bits each!

NEC Repeat

A command is transmitted only once, even when the key on the remote control remains pressed. Every 110ms a repeat code is transmitted for as long as the key remains down. This repeat code is simply a 9ms AGC pulse followed by a 2.25ms space and a 560µs burst.

NEC Sequence

Extended NEC protocol

The NEC protocol is so widely used that soon all possible addresses were used up. By sacrificing the address redundancy the address range was extended from 256 possible values to approximately 65000 different values. This way the address range was extended from 8 bits to 16 bits without changing any other property of the protocol.
The command redundancy is still preserved. Therefore each address can still handle 256 different commands.

Extended NEC protocol

Keep in mind that 256 address values of the extended protocol are invalid because they are in fact normal NEC protocol addresses. Whenever the low byte is the exact inverse of the high byte it is not a valid extended address. (这段描述没弄懂,256这个地址值是无效的,因为它已作为NEC协议的一个标准地址。地址值的地位和高位不能是一对取反值,否则无效)。

阅读(7880) | 评论(0) | 转发(0) |
0

上一篇:C 语言中const变量

下一篇:RC5 IR协议

给主人留下些什么吧!~~