Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Windows version #1

Open
IgorA100 opened this issue Feb 19, 2023 · 24 comments
Open

Windows version #1

IgorA100 opened this issue Feb 19, 2023 · 24 comments

Comments

@IgorA100
Copy link

I really want your program to work under Windows!
How can I do that?

@Bucklew
Copy link

Bucklew commented Feb 20, 2023

I tried, got every prerequisites installed (python, pip, some pip packages) and the multimeter is reacting on the connection (switches to remote mode), but the program is not receiving any data.

Too bad.

image

@martin-bochum
Copy link
Owner

The Windows Software from the CD is working ? Sorry I don't work with Windows.

@IgorA100
Copy link
Author

The Windows Software from the CD is working ?

I don't have a CD that has a program similar to yours :(
There is a disk with "DMMEasyControl V1.2.3", but this program is not convenient, buggy and does not know how to build graphics :(

@martin-bochum
Copy link
Owner

Slow down Baud-Tate to 57600
RS232_SPEED = 57600

@Bucklew
Copy link

Bucklew commented Feb 21, 2023

@martin-bochum No difference. But i am using an RS232/Ethernet Bridge so maybe this is the issue.

With DMM it works fine, even with 115k.

@Bucklew
Copy link

Bucklew commented Feb 21, 2023

Also not working with an RS232/USB Bridge from Prolific. Guess there is some difference in serial handeling between Windows/Linux.

@martin-bochum
Copy link
Owner

I don't know how old the DMM's Firmware is. My Firmware (1 year ago) was very buggy and i changed the OWON-DMM to a Siglent-DMM ( https://martin-bochum.github.io/DMM-Siglent-SDM/ ) . The RS-232 connection never worked for me with 115KBaud. With 57600Baud it works quite stable. The TCP connection, that I want to use, was very unstable.
http://martin-bochum.de/Cloud/peak_tcp_rs232.mp4

@Bucklew
Copy link

Bucklew commented Feb 21, 2023

But that firmware is not for XDM2041, right?

@martin-bochum
Copy link
Owner

Yes, I have had a PEAKTECH but it is from OWON

@Groko93
Copy link

Groko93 commented Feb 22, 2023

I'm trying to get your program running on windows 10 with my new Peaktech P4094. The device is connected via the com port to the PC (USB with virtual com port => PORT6). The original software DMMEasyControl V1.8.2 is running without major issuse.
Unfortunatley your script is hanging on the same position as Bucklew reportet.
The connection to the measuring device seems to work, because the "*IDN?" query provides the correct serial number from the device.
I'm wondering that the queries "SCIP version/DMM Date/DMM Time" etc. didn't provide an answer. According to the programming manuel these are valid commands.
By the way, the original "DMMEasyControl" is running with 115,2kB without problems. Lowering the baud rate resulting in the same effect (no response).
Any idees what we can try further? I would like to use your script for some automatic measuring procedures.
2023-02-22 10 47 40

@Bucklew
Copy link

Bucklew commented Feb 22, 2023

I tried yesterday with an Ubuntu LiveCD and it did not work either. So it does not depend on Windows vs. Linux but I guess more on a buggy firmware on the device.

Which firmware do you have @Groko93? (Under "Utility").

Our devices ODOM XDM2041 and Peaktech P4094 are the same, so i guess they are running the same firmware.

@Groko93
Copy link

Groko93 commented Feb 22, 2023

It's version 3.1.0 as you can see on my screenshot above from the program. Checksum: 504D96ED

@Bucklew
Copy link

Bucklew commented Feb 22, 2023

Yeah, got the same.

I write a request to OWon, if there is a newer firmware.

@Groko93
Copy link

Groko93 commented Feb 22, 2023

I'll ask PeakTech service about it. Let's see if we get the same answer. :o)

@martin-bochum
Copy link
Owner

Sorry, but I am using just Linux. I don't have the P4095 anymore and the last Firmware was 2.22.0 with more bugs then the previous Version . I think there is a problem with the Windows VISA, what you need to run the Windows Software, and pyvisa. You can check it in a Console with pyvisa-shell.

pyvisa-shell

Welcome to the VISA shell. Type help or ? to list commands.

(visa) list
( 0) ASRL/dev/ttyUSB1::INSTR
( 1) ASRL/dev/ttyUSB0::INSTR
( 2) ASRL/dev/ttyACM0::INSTR
(visa) ?

Documented commands (type help ):

EOF attr close exit help list open query read termchar timeout write

(visa)

@Groko93
Copy link

Groko93 commented Feb 22, 2023

So, the pyvisa-shell is working. I guess, the P4094 doesn't support some commands eg. SYSTem:VERSion oder DATE. These commands are missing inside the manual. But I can read a valid measurement value (MEAS?). By the way, the DMMEasyControl is using the same command.
2023-02-22 12 27 16

PS: I had to change to 9600 baud on the measurment device (seems to be the default value).

@martin-bochum
Copy link
Owner

@Groko93
Copy link

Groko93 commented Feb 22, 2023

Ok, thanx, but still the same.
I commented out also that line:
#leer = self.tcpip('RATE S')
#print ("RATE: " + str(leer))
Always "hanging"...afterwards.
I made a simple test with the pyvisa class.

------test.py----------------
import pyvisa
rm = pyvisa.ResourceManager()
print(rm.list_resources())
inst = rm.open_resource('ASRL6::INSTR')

inst.baud_rate = 115200
print(inst.query("*IDN?"))
inst.write("RATE S") # ok
print("Measurement rate:" + inst.query("RATE?"))

print(inst.query("MEAS?"))

That's working.

@martin-bochum
Copy link
Owner

what happens if you set RS232_PORT = ASRL6::INSTR in the ini file ? I reactivate DATE and TIME. With pyvisa-shell try print(inst.query("MEAS1?"))
and
print(inst.query("MEAS2?"))
for DUAL-DISPLAY.

http://martin-bochum.de/Cloud/Multimeter-RS232-Test.py is a new version
http://martin-bochum.de/Cloud/PeakTech_4094_Programming_Manual_V1.0.0_EN.pdf

SET the DMM and the Software to 57600 Baud or slower. If it works you can speed up. I start a measurement every 250ms! Slower is better.

@martin-bochum
Copy link
Owner

The 4094 has no real Dual-Display, neither AUTO1/AUTO2 nor RANG1/RANGE2 is working. I remove 1 and 2 from AUTO and RANGE, don't know what happens.
http://martin-bochum.de/Cloud/Multimeter-RS232-Test.py a new version

@martin-bochum
Copy link
Owner

Sorry i can not remove RANGE2. Don't use DUAL-DISPLAY !!! ALL RANGE1 are replaced with RANGE
http://martin-bochum.de/Cloud/Multimeter-RS232-Test.py the last version for today

@Bucklew
Copy link

Bucklew commented Feb 22, 2023

Just getting "No connection to DMM" with your latest Test version.

@Groko93
Copy link

Groko93 commented Feb 22, 2023

what happens if you set RS232_PORT = ASRL6::INSTR in the ini file ?

That throws an exeption, because you used "oscilloscope = serial.Serial(RS232_PORT,..."
For that call "COMx" will be fine.

print(inst.query("MEAS1?"))

That command provides the real measurement value. Same as "MEAS?"

print(inst.query("MEAS2?"))

That command delivers: "NONe"

The latest test script crashed again. :o(

@Groko93
Copy link

Groko93 commented Feb 22, 2023

Based on your ideas I've written a really simple data logger for my purpose.
I measure the voltage, store everything in an excel workbook an create a small graph direct out of the data (with mathplot).
That's all what I temporary need. ;o) (everything hard coded without comfort)...but it works for me.

In fact the P4094 is quite limited in functionality and probably I've paid too much for it.

PS: I got an answer from the PeakTech support. There are currently no know bugs inside the firmware. May be it's a feature and no bug. :o))

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants