Patent ID: 9563292
Date: 2017-02-07
CPC Classifications: G06F

Claim:
1. A stylus pen that performs touch input to a touch panel, comprising: a correction circuit that corrects difference between the number of controller clocks generated by a touch panel controller, which controls operation of the touch panel, for outputting a synchronization signal by the touch panel controller and the number of pen clocks generated by the stylus pen for receiving, by the stylus pen, the synchronization signal output from the touch panel controller, wherein the number of pen clocks is represented by the number of pen clocks Data[M] indicating a clock number of the stylus pen at a time point when an M-th synchronization signal supplied from the touch panel controller is output from the touch panel controller and the number of pen clocks Data[N] indicating a clock number of the stylus pen at a time point when an N-th synchronization signal supplied from the touch panel controller is output from the touch panel controller, where M and N are non-negative integers, the correction circuit includes a sense circuit that detects the numbers of pen clocks Data[M] and Data[N], and a synchronization signal detection circuit that generates a timing correction signal as a control signal for causing the stylus pen to operate in synchronization with the touch panel controller based on the numbers of pen clocks Data[M] and Data[N] detected by the sense circuit, and the synchronization signal detection circuit includes a difference matrix generation unit that uses the numbers of pen clocks Data[M] and Data[N] to generate, by operation of Data_Relative[MN]=Data[M]−Data[N] (0≦M≦K and 0≦N≦K, where K is an integer), a difference matrix Data_Relative[MN] that represents difference between the numbers of pen clocks Data[M] and Data[N] as a two-dimensional data array, an auxiliary matrix generation unit that uses a value during a time period at which a synchronization signal is output from the touch panel controller and a value of a clock period of the touch panel controller, which are known parameters in the stylus pen, to generate a plurality of types of auxiliary matrixes based on the difference matrix Data_Relative[MN], a verification matrix generation unit that generates a verification matrix Verify[MN] for verifying whether or not values of the numbers of pen clocks Data[M] and Data[N] are valid based on the plurality of types of auxiliary matrixes, a valid data determination unit that determines whether or not a value of each component of the verification matrix Verify[MN] is valid, a valid matrix generation unit that generates a valid matrix Valid[MN] by extracting a value of each component of the verification matrix Verify[MN], which is determined as being valid in the valid data determination unit, and a timing correction signal generation unit that generates the timing correction signal by using the value of each component of the valid matrix Valid[MN].