Decoding HS1527 OTP Encoder data signals (with learning mode)

PhilHornby

Senior Member
The HS1527 (or variants thereof) is a One-Time-Programmable encoder that finds its way into many RF Remote Control products. Its data sheet is here: http://sc-tech.cn/en/hs1527.pdf
Its output signal comprises a 20bit 'controller id' that is factory-set and 4 data bits that make up the 'payload'.

This is an example of the signals one might expect to see from data encoded using the HS1527: Click for larger view --> HS1527.jpg <--- Click for larger view!

These signals are from this remote, which was used to develop the software. The same supplier also has a HS1527-based RF transmitter board. It is intended for use with a Raspberry Pi, but is easily Picaxe-able.


Oddly, no matching Decoder seems to exist for this product - so I thought I'd have a go at doing it with a Picaxe 08M2.

The attached code snippet learns the controller id from the Remote, if one is not stored in EEPROM. Only Remote Controls that match this 'controller id' are recognised from then on, and the 4 user data bits are returned to the caller, when said controller is detected.

Code: View attachment HS1527.bas
 
Last edited:

kirangowle

New Member
Hello,

The data encoding image is very useful.. Thanks

Do you have the code for Microcontrollers like PIC16F family on how to decode the data.

Thanks
Kiran
 

PhilHornby

Senior Member
No - the techniques employed in the attached code are tailored to the interpreted (and therefore slow) Basic found on the Picaxe. If using the PIC directly, you'd presumably be using a compiler of some sort and those techniques wouldn't be appropriate.
 
Top