A data processing method and apparatus are provided. The data processing apparatus includes a converter module and a control module. The converter module receives a clock signal through a pin, and decides a bit value of the first data according to a length of a corresponding period of the clock signal. The control module determines whether to perform a bit writing operation for writing the bit value into a memory according to the clock signal and the first data.
|
1. A data processing method, comprising:
receiving a clock signal through a pin;
performing a reversible logic operation on original data to generate first data, wherein a number of bits having a first logic value requiring a bit writing operation in the first data is less than a number of bits having the first logic value requiring the bit writing operation in the original data, and a number of bits of the first data is equal to a number of bits of the original data;
determining a bit value of the first data according to a time length of a corresponding period of the clock signal; and
determining whether to perform the bit writing operation into a memory according to the clock signal and the first data, wherein the bit writing operation is performed on the bit value when the bit value of the first data is determined to be the first logic value, and the bit writing operation is not performed on the bit value when the bit value of the first data is determined to be a second logic value.
14. A data processing apparatus, comprising:
a converter circuit, having a first terminal receiving a clock signal, wherein the converter circuit determines a bit value of first data according to a time length of a corresponding period of the clock signal;
a control circuit, coupled to the converter circuit, and determining whether to perform a bit writing operation into a memory according to the clock signal and the first data, wherein the bit writing operation is performed on the bit value when the bit value of the first data is determined to be a first logic value, and the bit writing operation is not performed on the bit value when the bit value of the first data is determined to be a second logic value;
a modulation circuit, having an output terminal coupled to the first terminal of the converter circuit for providing the clock signal; and
an operation circuit, having an output terminal coupled to an input terminal of the modulation circuit, and an input terminal receiving original data, wherein the operation circuit performs a reversible logic operation on the original data to generate the first data to the input terminal of the modulation circuit, wherein a number of bits having the first logic value requiring the bit writing operation in the first data is less than a number of bits having the first logic value requiring the bit writing operation in the original data, and a number of bits of the first data is equal to a number of bits of the original data.
2. The data processing method as claimed in
filtering a noise in the clock signal.
3. The data processing method as claimed in
determining the bit value to be the first logic value when the time length of the corresponding period is greater than a reference value; and
determining the bit value to be the second logic value when the time length of the corresponding period is smaller than the reference value.
4. The data processing method as claimed in
counting a waiting time for waiting to complete the bit writing operation;
not to reset the waiting time before the waiting time reaches a rated time of the bit writing operation when the bit value of the first data is the first logic value, so as to perform the bit writing operation on the bit value; and
not to perform the bit writing operation on the bit value and resetting the waiting time when the bit value of the first data is the second logic value, so as to process a next bit value.
5. The data processing method as claimed in
defining a first time length and a second time length, wherein the first time length is greater than or equal to a time require for writing the bit value into the memory, and the second time length is smaller than the first time length;
setting the corresponding period of the clock signal to the first time length when the bit value of the first data represents that the bit writing operation is required; and
setting the corresponding period of the clock signal to the second time length when the bit value of the first data represents that the bit writing operation is not required.
6. The data processing method as claimed in
7. The data processing method as claimed in
performing the XOR logic operation on the original data and an operation key to generate the first data.
8. The data processing method as claimed in
performing the NOT logic operation on the original data to generate the first data when a number of bits requiring the bit writing operation in the original data is greater than a reference number.
9. The data processing method as claimed in
performing the reversible logic operation on the first data to restore the first data to the original data.
10. The data processing method as claimed in
11. The data processing method as claimed in
12. The data processing method as claimed in
13. The data processing method as claimed in
15. The data processing apparatus as claimed in
a filter circuit, coupled to the first terminal of the converter circuit for receiving the clock signal, and filtering a noise in the clock signal; and
a sampling circuit, coupled to a second terminal of the converter circuit for receiving a data signal, and coupled to the filter circuit for receiving the noise-filtered clock signal, wherein the sampling circuit samples the data signal according to a timing of the clock signal to obtain and determine a logic value of the first data.
16. The data processing apparatus as claimed in
a filter circuit, coupled to the first terminal of the converter circuit for receiving the clock signal, and filtering a noise in the clock signal; and
a demodulation circuit, coupled to the filter circuit for receiving the noise-filtered clock signal, wherein when the time length of the corresponding period of the noise-filtered clock signal is greater than a reference value, the demodulation circuit generates and determines the bit value of the first data to be the first logic value, and when the time length of the corresponding period of the noise-filtered clock signal is smaller than the reference value, the demodulation circuit generates and determines the bit value of the first data to be the second logic value.
17. The data processing apparatus as claimed in
18. The data processing apparatus as claimed in
19. The data processing apparatus as claimed in
20. The data processing apparatus as claimed in
21. The data processing apparatus as claimed in
22. The data processing apparatus as claimed in
a processor, coupled to the memory for reading the first data, and performing the reversible logic operation on the first data to restore the first data to the original data.
23. The data processing apparatus as claimed in
24. The data processing apparatus as claimed in
25. The data processing apparatus as claimed in
26. The data processing apparatus as claimed in
|
This application claims the priority benefit of Taiwan application serial no. 102127309, filed on Jul. 30, 2013. The entirety of the above-mentioned patent application is hereby incorporated by reference herein and made a part of this specification.
Technical Field
The invention relates to an electronic apparatus. Particularly, the invention relates to a data processing method and an apparatus.
Related Art
In recent years, as customers have increasing demand on quality of multimedia data, transmission interface of the multimedia data is quickly developed. When the multimedia data is transmitted through a high resolution interface, a high-bandwidth digital content protection (HDCP) is usually used to prevent data from being stolen. When a user wants to watch the data protected by the HDCP, the user has to use a playing device and a display device inbuilt with a HDCP key. The playing device and the display device have to perform an authentication process for exchanging keys in order to successfully play the data. If a problem is occurred during the authentication process, the data protected by the HDCP may have problems of low resolution, poor sound quality or unable to be played when the data is played. A HDCP key set is generally composed of 40 keys of 56 bits. A production machine or a test machine can write the keys into a memory of a circuit to be tested (for example, the playing device and/or the display device) through a manner of one bit after another.
The test machine may write data (for example, the HDCP key or other data) into the memory of the circuit to be tested through a plurality of pins, so as to perform function test on the circuit to be tested. For example,
On the other hand, the memory of the circuit to be tested (for example, the playing device and/or the display device) can be a memory device/circuit of any type, for example, a one-time programmable (OTP) memory or other non-volatile memory. The bit writing operation (to write the keys into the OTP memory) generally consumes a plenty of time. When the data DATA2 is written into the OTP memory, the test machine generally writes the data DATA2 into the OTP memory in a way of one bit each time. When a data amount of the data DATA2 to be written into the OTP memory is huge, for example, when a HDCP key set composed of 40 keys of 56 bits is to be written into the OTP memory, or when a plurality of HDCP key sets are to be written into the OTP memory, the test machine has to consume a plenty of time to write the data DATA2 with the huge data amount into the OTP memory. In the embodiment of
The invention is directed to a data processing method and an apparatus, which is capable of decreasing a time and/or a number of pins used for transmitting data from external to internal of a chip.
The invention provides a data processing method including following steps. A clock signal is received through a pin of an integrated circuit. A bit value of first data is determined according to a time length of a corresponding period of the clock signal. It is determined whether to perform a bit writing operation for writing the bit value into a memory according to the clock signal and the first data.
The invention provides a data processing apparatus including a converter module and a control module. A first terminal of the converter module receives a clock signal. The converter module determines a bit value of first data according to a time length of a corresponding period of the clock signal. The control module is coupled to the converter module, and determines whether to perform a bit writing operation for writing the bit value into a memory according to the clock signal and the first data.
According to the above descriptions, in the data processing method and the data processing apparatus of the invention, by modulating the time length of the period of the clock signal, the time required for transmitting/processing data is decreased.
In order to make the aforementioned and other features and advantages of the invention comprehensible, several exemplary embodiments accompanied with figures are described in detail below.
The accompanying drawings are included to provide a further understanding of the invention, and are incorporated in and constitute a part of this specification. The drawings illustrate embodiments of the invention and, together with the description, serve to explain the principles of the invention.
In the aforementioned embodiment of
The clock signal CLK2 has a plurality of periods. The converter module 310 determines a bit value of the data DATA4 according to a time length of the corresponding period of the clock signal CLK2 (step S203). For example, in the present embodiment, the data processing apparatus 300 can sample/latch the bit value of the data DATA3 according a timing (for example, timing of a falling edge) of the clock signal CLK2, so as to generate corresponding data DATA4 in internal of the data processing apparatus 300.
The control module 320 is coupled to the converter module 310 for receiving the data DATA4 and other related control/trigger signals (which are not shown) output by the converter module 310. The control module 320 determines whether to perform the bit writing operation according to the clock signal CLK2 and the data DATA4. In the present embodiment, the control module 320 may generate a plurality of programming signals Sprog of different functions to the memory 330 according to the data DATA4 provided by the converter module 310. For example, when the bit value of the data DATA4 is a first logic value (i.e. a bit value requiring the bit writing operation, for example, logic 1), the control module 320 can perform the bit writing operation to a certain bit in the memory 330 according to a setting of the programming signals Sprog, so as to write the first logic value to the corresponding bit in the memory 330. For another example, when the bit value of the data DATA4 is a second logic value (i.e. a bit value not requiring the bit writing operation, for example, logic 0), the control module 320 can adjust the programming signal Sprog to maintain a certain bit in the memory 330 in an initial state (i.e. not to perform the bit writing operation), so as to maintain the corresponding bit of the memory 330 to the second logic value (the initial state). Therefore, the control module 320 determines whether to perform the bit writing operation according to the clock signal CLK2 and the data DATA4, so as to write the bit value of the data DATA4 into the memory 330 (step S205).
The memory 330 can be a memory device/circuit of any type, for example, a one-time programmable (OTP) memory or other non-volatile memory. The OTP memory may adopts E-fuses or other memory devices having the similar function to record data. For example, the system may define a logic value of a trim state (a blown state) of the E-fuse to be the first logic value (for example, logic 1), and define the logic value of the initial state (a not blown state) of the E-fuse to be the second logic value (for example, logic 0). In other embodiments, the first logic value can be logic 0, and the second logic value can be logic 1. Since the process of blowing the E-fuse is irreversible, information written into the OTP memory is permanent.
The embodiment of
The converter module 310 can be implemented through any method. For example, in the embodiment of
A first terminal of the filter unit 311 is coupled to a clock pin of the converter module 310 to receive the external clock signal CLK2. Then, the filter unit 311 filters noise in the clock signal CLK2. The sampling unit 313 is coupled to a second terminal of the filter unit 311 for receiving the noise-filtered clock signal CLK2. The sampling unit 313 is further coupled to a data pin of the converter module 310 for receiving the data signal (for example, the data DATA3). The sampling unit 313 samples the data signal DATA3 according to a timing of the clock signal CLK2 to obtain a logic value of the data DATA4, and transmits the data DATA4 to the control module 320.
In step S205, after the control module 320 receives the logic value of the data DATA4, a timer (or a counter) in internal of the control module 320 starts to count a waiting time for waiting to complete the bit writing operation. When the bit value of the data DATA4 is the first logic value (i.e. the bit value requiring the bit writing operation, for example, logic 1), before the waiting time counted by the timer reaches a rated time (for example, several microseconds) of the bit writing operation, the control module 320 does not reset the waiting time counted by the timer, so as to facilitate the control module 320 performing the bit writing operation on the bit value, i.e. write the bit value into the memory 330. When the bit value of the data DATA4 is the second logic value (i.e. the bit value not requiring the bit writing operation, for example, logic 0), since the control module 320 is not required to perform the bit writing operation on the bit value, the control module 320 immediately resets the waiting time counted by the timer to end the bit writing operation early and addresses a next bit to prepare processing a next bit value. Therefore, the data processing device 300 can reduce the operation time for writing the data DATA4 into the memory 330.
In the example of
Implementation of the data processing apparatus is not limited to the embodiment of
A first terminal of the demodulation unit 513 is coupled to the second terminal of the filter unit 511 for receiving the noise-filtered clock signal CLK2. The demodulation unit 513 can demodulate the clock signal CLK2 to obtain data DATA5 (step S203). When the time length of the corresponding period of the noise-filtered clock signal CLK2 is greater than a reference value, the demodulation unit 513 generates and determines the bit value of the data DATA5 to be the first logic value (i.e. the bit value requiring the bit writing operation, for example, logic 1). When the time length of the corresponding period of the noise-filtered clock signal CLK2 is smaller than the reference value, the demodulation unit 513 generates and determines the bit value of the data DATA5 to be the second logic value (i.e. the bit value not requiring the bit writing operation, for example, logic 0). As that shown in
After the data DATA5 is demodulated from the clock signal CLK2, the demodulation unit 513 transmits the data DATA5 to the control module 520. An input terminal of the control module 520 is coupled to the demodulation unit 513 for receiving the data DATA5. The control module 520 performs the bit writing operation on the data DATA5 to write the bit value of the data DATA5 into the memory 530 (step S205). The operation method of the control module 520 is the same to that of the control module 320 of the first embodiment, which is not repeated.
After the data DATA5 is written into the memory 530, the processor 540 can read the data DATA5 from the memory 530 for utilization. For example, if the data DATA5 includes a HDCP key, the processor 540 can use the HDCP key recorded in the memory 530 to authenticate, encrypt or decrypt a video stream.
In other embodiments, the data (or information) carried by the modulated clock signal CLK2 may include an encrypted HDCP key. The encrypted HDCP key is obtained by encrypting the original HDCP key in advance by using a reversible logic operation. The number of bits requiring the bit writing operation in the encrypted HDCP key is less than the number of bits requiring the bit writing operation in the original HDCP key. The demodulation unit 513 demodulates the encrypted HDCP key (the data DATA5) from the clock signal CLK2. During the process that the control module 520 writes the encrypted HDCP key into the memory 530, since the number of bits requiring the bit writing operation is reduced, the operation time required for writing the data DATA5 into the memory 530 is shortened. After the processor 540 obtains the encrypted HDCP key from the memory 530, the processor 540 performs the reversible logic operation on the encrypted HDCP key to restore the encrypted HDCP key to the original HDCP key. After obtaining the original HDCP key, the processor 540 uses the original HDCP key to authenticate, encrypt or decrypt the video stream. The reversible logic operation is described later.
In the example of
Referring to
An input terminal of the modulation unit 720 is coupled to an output terminal of the operation unit 710 for receiving the data DATA5. An output terminal of the modulation unit 720 is coupled to a clock pin of the converter module 730 for providing the clock signal CLK2 to the converter module 730. The modulation unit 720 defines a first time length T1 and a second time length T2, where the first time length T1 is greater than or equal to a time required for writing the bit value (for example, logic 1 into the memory 750, and the second time length T2 is smaller than the first time length T1. When the bit value of the data DATA5 indicates that the bit writing operation is required, the modulation unit 720 sets the corresponding period in the clock signal CLK2 to the first time length T1. When the bit value of the data DATA5 indicates that the bit writing operation is not required, the modulation unit 720 sets the corresponding period in the clock signal CLK2 to the second time length T2. The modulated clock signal CLK2 can be deduced according to the related description of
The demodulation unit 733 receives the modulated clock signal CLK2 through the filter unit 731, and demodulates the data DATA5 from the clock signal CLK2, and writes the data DATA5 into the memory 750 through the control module 740. Compared to the data DATA6, since the number of bits of logic 1 in the data DATA5 is decreased, the control module 740 may decrease the operation time required for writing the data DATA5 into the memory 750. After the writing operation of the data DATA5 is completed, the processor 760 can use the data DATA5 in the memory 750. For example, the processor 760 can use a reversible logic operation that is the same to that of the operation unit 710 to restore the data DATA5 in the memory 750 to the data DATA6, where the data DATA6 can be an encryption and decryption key, for example, HDCP key or other encryption and decryption key.
In the present embodiment, the operation unit 710 may include a NOT gate, an XOR gate, an XNOR gate or other logic gates to implement the reversible logic operation. Different embodiments that the operation unit 710 performs the reversible logic operation on the data DATA6 to generate the first data DATA5 are described below.
In some embodiments, the operation unit 710 may provide an operation key, and use the XOR gate to perform an XOR logic operation on the data DATA6 and the operation key to generate the data DATA5. For example, it is assumed that the data DATA6 includes “1100”, “1001” and “1101”, and the operation key is “1101”, the operation unit 710 uses the operation key “1101” to respectively perform the XOR logic operation with “1100”, “1001” and “1101” to generate the data DATA5 of “0001”, “0100” and “0000”. The number of bits of logic 1 in the data DATA6 is 7, and the number of bits of logic 1 in the data DATA5 is 2. Compared to the data DATA6, since the number of bits of logic 1 in the data DATA5 has been decreased, the control module 740 can decrease the operation time required for writing the data DATA5 into the memory 750. After the writing operation of the data DATA5 is completed, the processor 760 can use a reversible logic operation that is the same to that of the operation unit 710 to restore the data DATA5 in the memory 750 to the data DATA6. For example, the processor 760 can use the operation key “1101” to respectively perform the XOR logic operation with “0001”, “0100” and “0000” (the data DATA5) in the memory 750 to generate “1100”, “1001” and “1101”.
For another example, it is assumed that the data DATA6 includes “10011101”, “00010101”, “11001111” and “10000111”, and the operation key is “10011101”, the processor 760 uses the operation key “10011101” to respectively perform the XOR logic operation with “10011101”, “00010101”, “11001111” and “10000111” to generate the data DATA5 of “00000000”, “10001000”, “01010010” and “00011010”. The number of bits of logic 1 in the data DATA6 is 5+3+6+4=18, and the number of bits of logic 1 in the data DATA5 is 0+2+3+3=8. Compared to the data DATA6, the number of bits of logic 1 in the data DATA5 is reduced, so that the control unit 740 can reduce the operation time required for writing the data DATA5 into the memory 750.
In some other embodiments, the operation unit 710 can combine a plurality of HDCP keys to implement the reversible logic operation. For simplicity's sake, it is assumed that one HDCP key has 4 bits. Assuming 8 HDCP keys are respectively “1001”, “1101”, “0001”, “0101”, “1100”, “1111”, “1000” and “0111”, and the operation key is “1000 1101 0000 0101”, the operation unit 710 may use the operation key “1000 1101 0000 0101” to respectively perform the XOR logic operation with “1001 1101 0001 0101” and “1100 1111 1000 0111” to generate the data DATA5 of “0001 0000 0001 0000” and “0100 0010 1000 0010”. Compared to the data DATA6 (i.e. “1001 1101 0001 0101” and “1100 1111 1000 0111”), since the number of bits of logic 1 in the data DATA5 (i.e. “0001 0000 0001 0000” and “0100 0010 1000 0010”) has been reduced, the control unit 740 can reduce the operation time required for writing the data DATA5 into the memory 750.
In some embodiments, the operation unit 710 can provide the operation key, and use the XNOR gate to perform an XNOR logic operation on the data DATA6 and the operation key to generate the data DATA5.
In some other embodiments, the operation unit 710 determines whether to perform the reversible logic operation according to the number of bits of logic 1 in the data DATA6. If the number of bits requiring the bit writing operation in the data DATA6 is greater than a reference number, the operation unit 710 can use the NOT gate to perform a NOT logic operation on the data DATA6 to generate the data DATA5.
In summary, according to the data processing method and the data processing apparatus provided by the embodiments of the invention, the time length of the corresponding period of the clock signal CLK can be used to determine whether the bit value requires the bit writing operation, so as to decrease the time required for writing the bit value into the memory. On the other hand, in some other embodiments of the invention, the reversible logic operation can be used to decrease the number of bits requiring the bit writing operation in the data, so as to further decrease the time required for writing the bit value into the memory.
It will be apparent to those skilled in the art that various modifications and variations can be made to the structure of the invention without departing from the scope or spirit of the invention. In view of the foregoing, it is intended that the invention cover modifications and variations of this invention provided they fall within the scope of the following claims and their equivalents.
Patent | Priority | Assignee | Title |
Patent | Priority | Assignee | Title |
4954825, | Mar 22 1989 | Eastman Kodak Company | Self clocking binary data encoding/decoding method |
5321749, | Sep 21 1992 | KRYPTOFAX PARTNERS L P | Encryption device |
6021162, | Oct 01 1997 | Micro Motion, Inc | Vortex serial communications |
6163576, | Apr 13 1998 | AVAGO TECHNOLOGIES INTERNATIONAL SALES PTE LIMITED | Video encoder having reduced memory bandwidth requirements |
6590503, | Jan 28 2000 | NINTENDO OF AMERICA INC | Remote control system |
7322040, | Mar 27 2001 | Microsoft Technology Licensing, LLC | Authentication architecture |
7369629, | Sep 02 2003 | DEUTSCHE BANK AG NEW YORK BRANCH, AS COLLATERAL AGENT | FSK signal demodulation circuit |
7801308, | Jul 17 2006 | Synaptics Incorporated | Secure key encoding for content protection |
20020041527, | |||
20020141589, | |||
20050084041, | |||
20060250915, | |||
20070216438, | |||
20080309818, | |||
20090135307, | |||
20090140774, | |||
20090238277, | |||
20100163631, | |||
20130182349, | |||
20130318319, | |||
CN1279854, | |||
CN1592287, |
Executed on | Assignor | Assignee | Conveyance | Frame | Reel | Doc |
Sep 03 2013 | LIN, PAO-YEN | Novatek Microelectronics Corp | ASSIGNMENT OF ASSIGNORS INTEREST SEE DOCUMENT FOR DETAILS | 031353 | /0423 | |
Sep 27 2013 | Novatek Microelectronics Corp. | (assignment on the face of the patent) | / |
Date | Maintenance Fee Events |
Feb 17 2021 | M1551: Payment of Maintenance Fee, 4th Year, Large Entity. |
Date | Maintenance Schedule |
Sep 05 2020 | 4 years fee payment window open |
Mar 05 2021 | 6 months grace period start (w surcharge) |
Sep 05 2021 | patent expiry (for year 4) |
Sep 05 2023 | 2 years to revive unintentionally abandoned end. (for year 4) |
Sep 05 2024 | 8 years fee payment window open |
Mar 05 2025 | 6 months grace period start (w surcharge) |
Sep 05 2025 | patent expiry (for year 8) |
Sep 05 2027 | 2 years to revive unintentionally abandoned end. (for year 8) |
Sep 05 2028 | 12 years fee payment window open |
Mar 05 2029 | 6 months grace period start (w surcharge) |
Sep 05 2029 | patent expiry (for year 12) |
Sep 05 2031 | 2 years to revive unintentionally abandoned end. (for year 12) |