Patent ID: 6839622

Claim:
A control system that is provided in a vehicle and controls an in-vehicle device, the control system comprising: detecting means for detecting that the vehicle enters an operating state; diagnosing means for executing a failure diagnosis on a diagnosis target when a given condition is effected; a non-volatile memory where stored information is electrically rewritable, wherein the non-volatile memory includes a plurality of blocks, each of which can be stored with frequency information including an operating frequency that is a number of times the vehicle enters the operating state and a failure diagnosis frequency that is a number of times the failure diagnosis is executed; outputting means for outputting execution information relating to the frequency information when it is externally requested that information regarding an execution frequency ratio of the failure diagnosis be outputted; rewriting means for rewriting the frequency information included in a rewriting target block of the blocks, wherein an operating frequency included in the rewriting target block is increased when it is detected that the vehicle enters the operating state while a failure diagnosis frequency in the rewriting target block is increased when the failure diagnosis is executed; and switching means for switching the rewriting target block from a given block of the blocks to a certain block of the blocks, when at least one of a given operating frequency and a given failure diagnosis frequency in the given block reaches an overflow threshold, wherein the rewriting means writes, as initial values, half of the given operating frequency and half of the given failure diagnosis frequency in the certain block, respectively, when the switching means switches the rewriting target block.