The last weeks I spent a lot of time with small things. Hardly worth to mention like the mandatory pedals with AC logo:
I have mounted a master switch to be save the battery during the long winter months:
And the washer motor has found it's place behind the dashboard and it works fine:
In the meantime I have three (3 !!!) different rotary switches from lucas for the windscreen wiper. All of them have a push mechanism to switch on the washer motor. Testing these switches together with the wiper motor often results into short-curcuits and sometimes into fume. Thus I decided to simulate these on computer. If anybody of you have a Verilog simulator he my be interested in modelling the motor:
module wiper(inout i1,i2,input i3,inout i4,input i5);
integer i = 0;
tranif1 t1(i1,i2,i == 0 || i == 1);
tranif1 t2(i4,i2,i != 0 && i != 1);
always #100//@(i or i3 or i5 or i1 or i2 or i3)
begin
case ({i1,i5,i3})
3'b000: $display("break");
3'b00Z: $display("break");
3'b0ZZ: $display("no operation");
3'b01Z:
begin
$display("speed 1");
i = (i+1) % 10;
end
3'b0Z1:
begin
$display("speed 2");
i = (i+2) % 10;
end
default: $display("error 1=%d 3=%d 5=%d",i1,i3,i5);
endcase
end
endmodule // wiper
and the switch:
module switch39125(input [1:0] pos,inout i1,i2,i3,i4);
tranif1 t1(i2,i3,pos == 0);
tranif1 t2(i2,i4,pos == 1);
tranif1 t3(i1,i4,pos == 2);
endmodule // switch
A typical simulation cycle shows no problems with a correct wiring:
/top/i models the switch position: 0 is the parking position, 1 is low-speed and 2 is high-speed. /top/w/i is the internal state of the motor. When it is running it counts up to 9 and starts again at 0. You can see that the internal state is increased by 2 during high-speed (/top/i == 2). When the wiper switch is turned back to parking position (/top/i == 0) the increase of the internal status of the wiper motor is 1 in each step which means low-speed but the motor is still running. Reaching the internal state 0 the motor has reached the parking position and the motor stops. During this simulation cycle no signals were red indicating a short-curcuit. That's fine and I can test this wiring in the "real world".