Problem with Rigol DG1022Z SCPI - Page 1
Forum section: electronics / testgear

author: Ohmy
author_rank: Newbie
timestamp: February 21, 2025, 10:24:20 pm
content: I'm not sure if my question belongs here, or in the 'programming' sub, but here goes.I got a bunch of Rigol instruments like the DHO900, DP832 and a DG1022Z. They are all connected to LAN and I have had no issues with the first two instruments, but thesignal generator has got me a bit confused. I am following the documentation in the programming manual here:https://rigolshop.eu/products/waveform-generators/dg1000z/dg1022z.htmlI have an issue with the signal generator that it doesn’t seem to want to update the output after I load it with new output parameters.I set the instruments channel 1 and channel 2 to:SOUR1:APPL:SIN 1000,2.5,0,0 #1kHz, 2.5Vpp, 0 offset and phase:SOUR2:APPL:SIN 1000,1,0,0 #1kHz, 1Vpp, 0 offset and phaseBut I can see on the scope that the output doesn’t update for some reason, but when I inspect the signal generator manually I can see in the display thatIt has received the correct settings and I can force it to update the output by changing any output setting at which point it will put out the correct output.The communication log with the instrument looks like this.VISA Connection TCPIP::10.172.116.57::INSTR successful, CMD; *OPC? passed to instrument Signal Generator: DG1022ZVISA Connection TCPIP::10.172.116.57::INSTR query successful, REPLY; 1VISA Connection TCPIP::10.172.116.57::INSTR successful, CMD; :OUTP1:IMP INF passed to instrument Signal Generator: DG1022ZVISA Connection TCPIP::10.172.116.57::INSTR successful, CMD; *OPC? passed to instrument Signal Generator: DG1022ZVISA Connection TCPIP::10.172.116.57::INSTR query successful, REPLY; 1VISA Connection TCPIP::10.172.116.57::INSTR successful, CMD; :OUTP2:IMP INF passed to instrument Signal Generator: DG1022ZVISA Connection TCPIP::10.172.116.57::INSTR successful, CMD; *OPC? passed to instrument Signal Generator: DG1022ZVISA Connection TCPIP::10.172.116.57::INSTR query successful, REPLY; 1VISA Connection TCPIP::10.172.116.57::INSTR successful, CMD; :SOUR1:APPL:SIN 1000,2.5,0,0 passed to instrument Signal Generator: DG1022ZVISA Connection TCPIP::10.172.116.57::INSTR successful, CMD; *OPC? passed to instrument Signal Generator: DG1022ZVISA Connection TCPIP::10.172.116.57::INSTR query successful, REPLY; 1VISA Connection TCPIP::10.172.116.57::INSTR successful, CMD; :SOUR2:APPL:SIN 1000,1,0,0 passed to instrument Signal Generator: DG1022ZVISA Connection TCPIP::10.172.116.57::INSTR successful, CMD; *OPC? passed to instrument Signal Generator: DG1022ZVISA Connection TCPIP::10.172.116.57::INSTR query successful, REPLY; 1VISA Connection TCPIP::10.172.116.57::INSTR successful, CMD; :OUTP1 ON passed to instrument Signal Generator: DG1022ZVISA Connection TCPIP::10.172.116.57::INSTR successful, CMD; *OPC? passed to instrument Signal Generator: DG1022ZVISA Connection TCPIP::10.172.116.57::INSTR query successful, REPLY; 1VISA Connection TCPIP::10.172.116.57::INSTR successful, CMD; :OUTP2 ON passed to instrument Signal Generator: DG1022ZVISA Connection TCPIP::10.172.116.57::INSTR successful, CMD; :SOUR1:APPL? passed to instrument Signal Generator: DG1022ZVISA Connection TCPIP::10.172.116.57::INSTR query successful, REPLY; "SIN,1.000000E+03,2.500000E+00,0.000000E+00,0.000000E+00"VISA Connection TCPIP::10.172.116.57::INSTR successful, CMD; :SOUR2:APPL? passed to instrument Signal Generator: DG1022ZVISA Connection TCPIP::10.172.116.57::INSTR query successful, REPLY; "SIN,1.000000E+03,1.000000E+00,0.000000E+00,0.000000E+00"VISA Connection TCPIP::10.172.116.57::INSTR successful, CMD; :SYSTem:ERRor? passed to instrument Signal Generator: DG1022ZVISA Connection TCPIP::10.172.116.57::INSTR query successful, REPLY; 0,"No error"For good measure here is the *IDN? ResponseVISA Connection TCPIP::10.172.116.57::INSTR successful, CMD; *IDN? passed to instrument Signal Generator: DG1022ZVISA Connection TCPIP::10.172.116.57::INSTR query successful, REPLY; Rigol Technologies,DG1022Z,DG1ZA195106508,03.01.12I tried to put in some delays between each SCPI write andthis causes it to work, so I assumed the instrument can't keep up, but I am checking the *OPC flag after every write to ensure it is ready for the next command and it always returns 1, so that should be good. The system also shows no errors as can be seen in the last log entry. Is there a way I can force it to update the output with some command?I've tried updating to the latest firmware available, but that didn't fix anything.I’ve looked everywhere for how to fix this so I’m hoping you guys know. Any ideas?

author: thm_w
author_rank: Super Contributor
timestamp: February 22, 2025, 12:34:57 am
content: Yes this is the right forum.Sounds like its possibly a bug:https://www.reddit.com/r/AskElectronics/comments/10kk4kr/trouble_controlling_a_rigol_dg1022z_using_scpi/Maybe you can try USB as a comparison?https://hackaday.io/page/13357-diving-into-scpiEither work around it like you have, or look for another tool. They seem to fetch good money on ebay.

author: Ohmy
author_rank: Newbie
timestamp: February 22, 2025, 12:52:13 am
content: Quote from: thm_w on February 22, 2025, 12:34:57 amAlright, great.Quote from: thm_w on February 22, 2025, 12:34:57 amThat guy on Reddit seems to have the exact same issue that I have. Damn that really sucks, that post is 2 years old, so maybe the DG1022Z's firmware is actually just super janky.I've reached out to Rigol support on email but, judging by what other people are saying, I'm not gonna hold my breath. I may have to replace the instrument if there is no proper fix for this as I really can't stand the workaround that I found, it rubs me in all the wrong ways.