the general project is an EDM machine, from an arduino perspective I need to be able make a pulse and read the voltage between the two electrodes(to adjust spark gap). I have the pulse system down but the reading of the voltage is giving me a real hard time. In my current iteration, I am getting “inverted” voltage readings…when the mosfet is on, I get adc vals around 200 (low I guess), when mosfet is off, I get adc vals of 1023. If you are thinking I messed up a register or am doing something wrong in software, I did too…so I put a multi meter on the voltage divider and it shows the same (1.2v when mosfet is on, 5.2v when off).
some additional tidbits:
-all grounds are common
-i have been testing with a small load on the mosfet(fan), if I measure the voltage when ON, I get 11.6, off ~=0v…but if I remove that load, that voltage ranges from [6.6 ->11.6]. I am not SURE this is dysfunctional behavior, but that range being exactly 5v makes me dubious.
-I know the 3205 is not logical level, that’s why its being driven by an NPN to get proper gate voltage…I know this is not ideal for fast switching, but its what I have & it does seem to work.
i have attach a diagram, note the electrodes are not pictured, but connect to +VpulseSupply and the drain of the mosfet.
any guidance would be greatly appreciated. thanks.