DC shift on voltage measurements

Discussion on both general simulation and Proteus VSM microcontroller simulation.
Post Reply
John K
Professional User
Posts: 8
Joined: Wed 2020-11-25 9:58

DC shift on voltage measurements

Post by John K »

When simulating a circuit containing a low pass filter, I get a DC shift at the output of the lowpass filter. The frequency is 50Hz, so there should in principle be no problems with speed.
The voltage across C3 is as expected both on the voltmeter and the oscilloscope. However, the voltage across C6 for no apparent reason is shifted by several volts.
I have tried to improve accuracy by changing simulation options, but this has not improved the results.
Can anyone explain why?
xx1_Test_4.pdsprj
Circuit adding DC shift
(26.73 KiB) Downloaded 60 times
Ettore
Labcenter Staff
Posts: 2932
Joined: Fri 2006-03-03 11:56
Location: Milan
Contact:

Re: DC shift on voltage measurements

Post by Ettore »

I'm not sure about this circuit is intended for but a common reference (i.e. ground terminal) is required. IMO, you should place a reference ground to the common line connected to C6(pin 2), C3(pin1) etc. Alternatively and even better you may connect L2 pin of J1 to the same common line, as it looks like L2 generator in not connected to any section of the main circuit.
Attachments
xx1_Test_4_a.pdsprj
(26.74 KiB) Downloaded 57 times
Kind regards,
Ettore Arena - Labcenter Electronics.
John K
Professional User
Posts: 8
Joined: Wed 2020-11-25 9:58

Re: DC shift on voltage measurements

Post by John K »

The cicuit already has a ground connection connected to the PE-terminal (through a mA-meter to measure residual current). I need the ground reference in this place to generate the correct mains voltages with respect to earth for the circuit and to measure the PE-conductor current (residual current). I appreciate that this generates high voltages with respect to earth (100V) and that the differential voltages measured on the scope are two decades lower. However, I would have thought that this would be within the capabilities of the simulator. Or is this asking for too much?
(I also noticed that when I downloaded the circuit you submitted, I got a different result (smaller shift) even though the circuit seems to be identical)
Ettore
Labcenter Staff
Posts: 2932
Joined: Fri 2006-03-03 11:56
Location: Milan
Contact:

Re: DC shift on voltage measurements

Post by Ettore »

If you need the ground connection to PE terminal then I agree you cannot put another ground terminal to (-) pin of DB3 as this would short it.
Nevertheless the drift you are seeing is the contribute of the voltage at DB3 (-)pin as this node offers an high impedance path. You can see that better if you detach the pin 1 of R14: the output will drift up to about 3V. So, I have tried to add a path 10n capacitor to (-) DB3 pin to ground and this will remove the drift caused by that circuit.
When you attach R14 again to the main circuit then the output voltage should go up to about 0.5V which is the voltage rectified by D1 and integrated by C6.

What I cannot understand is what L2 is for as it is not connected to anywhere in the main circuit if not to a couple of AC meters and a connector.

Anyway, I attach the modified circuit; it differs only by the path capacitor C1.
Attachments
xx1_Test_4_b.pdsprj
(26.83 KiB) Downloaded 54 times
Kind regards,
Ettore Arena - Labcenter Electronics.
John K
Professional User
Posts: 8
Joined: Wed 2020-11-25 9:58

Re: DC shift on voltage measurements

Post by John K »

L2 is the second supply terminal, which may be the Neutral conductor in some cases and a second phase conductor in other cases.
The circuit is part of a bigger circuit, so the L2 terminal has a function in the real application.
With regard to the problem, I have removed components to see what affects the simulation.
I have found that what is causing the problem is the mA-meter in the PE-connection between ground and the PE terminal block.
When I remove the mA-meter, the simulation seems to work OK, and I do not get the DC voltage shift.
In principle this meter should have zero impedance, so it should not affect the simulation. But it does.
Your comment about the high impedance path is wrong, all circuits do get a specific voltage level at all times. And if you look at the voltage across the two capacitors, they will inevitably get the same DC-level, there is only a low pass filter between the two.
Please see the attached files and compare the two circuits.

Best regards
John
Attachments
TEST_Sim_Without mA-meter.pdsprj
Circuit without mA-meter
(26.51 KiB) Downloaded 53 times
TEST_Sim.pdsprj
Circuit with mA-meter
(26.59 KiB) Downloaded 50 times
Ettore
Labcenter Staff
Posts: 2932
Joined: Fri 2006-03-03 11:56
Location: Milan
Contact:

Re: DC shift on voltage measurements

Post by Ettore »

Upon a quick test I've carried out the AC AMMETER does seem indeed to have a zero dc impedance.
At any rate I will investigate about the reason why it affects simulation in your specific case.
Attachments
ammetter impedance test.pdsprj
(11.62 KiB) Downloaded 53 times
Kind regards,
Ettore Arena - Labcenter Electronics.
Post Reply