circuit 302 determines a clock period tclk a counter circuit 303 is a portion of the delay circuit that determines the delay time a control circuit 304 controls charging and discharging of the secondary battery the control circuit 304 outputs control signals to the charging control output terminal co and the discharging control output terminal do through output drivers 317 and 318 on the basis of the signal from the detection signal input circuit 301 thus turning the charging and discharging control switch circuit 403 on and off and performing charging and discharging control of the secondary battery a fuse 305 of fig3 switches between the delay time mode 1 and the delay time mode 2 a switch control signal predo input to the output driver 317 and an output signal vdo are input to an nor 316 an output signal test from the nor 316 determines whether the normal operating state or the testing state is used operation of the charging and discharging control circuit of the present invention is explained next with reference to fig1 fig3 and fig4 in fig4 when the charging and discharging control switch circuit 403 uses nmos transistors the circuit is configured as follows the charging control output terminal co and the discharging control output terminal do are both high hereinafter u201c h u201d when the secondary battery 402 is in the normal operating state and not in the overcharge state the overdischarge state or the over current state the charging control output terminal co is low hereinafter u201c l u201d when the secondary battery 402 is in the overcharge state and the discharging control output terminal do is u201c l u201d when the secondary battery 402 is in the overdischarge state or the.