AndrewHolzer

Technical Forum Moderator
  • Content Count

    165
  • Joined

  • Last visited

  • Days Won

    9

Everything posted by AndrewHolzer

  1. Hi @Raghunathan, I took a look into the WPA/WPA2 issue you've been having. In short, the WINC1500 driver doesn't distinguish between WPA & WPA2 from the perspective of the software, in happens internally on the chip. The OpenLogger reports back to WaveForms Live what the WINC1500 is telling it during a WiFi AP scan, which is that a WPA/WPA2 network is just a WPA network. I'm glad to hear that switching to WPA got you to the saving stage, but I urge you to go back to WPA2 instead. You are increasing the vulnerability of your local network. Instead, can you please send a capture of the browser console when you try to connect to the network? Perhaps you can also speak about the router you have? Is it using WPA2 Enterprise?
  2. Hi @orquesea, There are a few things going on that I will try to explain to you, that I hope will help you get things working properly and perhaps impart some info on how WaveForms Live is working. WaveForms-Live calculates the expected acquisition time based off the buffer size and the sampling frequency. After clicking Start, WaveForms-Live waits for this period of time to pass before querying the OpenScope for available data. WaveForms-Live also calculates the sampling frequency from the time per division value in order to fit the entire acquired signal on the chart by default. If we were to set the chart to 10 seconds per division, the sampling rate would be 11.8 S/s, at 2360 samples total (also a default). The expected acquisition time would be (2360 S ) / (11.8 S/s) = 200 seconds. Clicking the lock to the right of either values disables those behaviors and lets you manually specify values, thereby tweaking the acquisition time via these two "knobs". You can decrease the acquisition time by decreasing the buffer size or increasing the sampling frequency. You should note that the acquired signal may not completely fill the chart, or may contain more data that the chart window can't show. The defaults given are supposed to be good estimates of sampling frequency for a given time division and the assumed 2360 Sample buffer size. The idea is to change the Time/Division setting to get as close a fit to the signal under inspection you can get with the given defaults, then tweak the sampling frequency and buffer size manually to really clarify the acquired signal. I hope this helps, and if you still have any questions please do not hesitate to ask them here. Regards, Andrew
  3. Hi @Raghunathan, Is it possible for you to send a capture of the browser console log when you are trying to log to the SD card and get the "Error Starting or Running" message? There should be some more technical information in there that should help in debugging your issues.
  4. You will have to redo the calibration every time you program the OpenScope with the Arduino tools. It isn't preserved through the process. You can possibly re-implement the firmware upgrade flow in WFL, which will allow you to preserve the calibration settings that have been saved in flash. Otherwise you can save to an SD card as well. We intended that user calibration exist on the SD card and manufacturing calibration be kept in flash, but both can be overwritten by the user, anyways.
  5. Hi @Ravi Kumar, Thank you for supplying these log outputs as they've proved helpful in finding a solution that should work for you. I took a look through the source code and found that the OpenScope will attempt to save the calibration configuration to the SD card when using the terminal UI, which fails if you don't supply an SD card . I confirmed that I received the save error as you have demonstrated and after a small change that I'll describe to you I saw the error disappear. If you look at line 811 inside IO.cpp, you will see a call being made to CFGSaveCalibration . You can configure the device to save to the flash by changing the second & third arguments to VOLFLASH and CFGFLASH respectively. Let me know what results you get when you make the same changes here.
  6. Hi @Ravi Kumar, I am going to need some more information from you. What version of the Digilent Agent are you running? Can you connect from your PC to the OpenScope using a terminal application (puTTY, TeraTerm, etc.) and see what the output is booting your compiled firmware, and share the results? How recent was the last time that you synced your copy of the firmware source with the Digilent repo (in case you've had it a while)? Can you enable the console logs, and see the output in your browser's developer tools when you try to calibrate your device? I am curious to see what error code you get when trying trying to do so. I would also like to suggest changing something in the versioning info in Version.c, as an easily verified change in the firmware. It is curious how the issues are presenting themselves. I've tried to replicate your issues as best I can, but I haven't been able to do so. I can confirm, with firmware built on my home desktop, that my device can do what you say yours can't. Either way, together, we'll get to the bottom of this.
  7. Hi @Ravi Kumar, I am going to need more information from you in order to proceed with this issue. I haven't been able to replicate your issue unfortunately; I've made a few additions to the OpenScope source, built and flashed the device and can trigger the scope instrument. Can you tell me what Arduino version you are running? Have you made any changes to the OpenScope source code? After uploading your custom firmware, have you calibrated your OpenScope? Your answers to these questions should form a foundation from which we can build an understanding of the issue you are experiencing. Regards, Andrew
  8. Hi @frokostfredag, That's some odd behavior that you're describing there. There is one thing I'd like you to try to debug this, and that's to enable the console output in WaveForms Live before trying to connect to the device. I'm hoping that this lets us see what command is causing the OpenScope to choke. You can do this by going into the Settings page, opening the Advanced section and clicking on Change Console Log. Set this to Console, then open the developer tools for your browser. For Chrome and Firefox this is Ctrl+Shft+i. The commands and their responses, plus some other additional information will be printed in the console here as you use WaveForms Live to configure the OpenScope. I would appreciate it if you could share the results with me, and together we will get to the bottom of this.
  9. Hi @ravikumargrk, Glad you were able to find your solution! If you need any further help, do not hesitate to reach out. We'd be more than happy to help out! Regards, AndrewHolzer
  10. Hi @ravikumargrk, Can you describe what else you have done to configure the OpenScope, such as trigger conditions, and anything else you are doing? Typically this error is thrown while the instrument being read hasn't idled yet. You'll need to issue another read command in that case until the status code comes back 0, with data, or a terminal error. Let me know the answers the above questions, and we'll get to the bottom of this. Regards, Andrew
  11. Hi @herg, I apologize for the long delay, and want to say that I appreciate your patience. I took a look into the source code to reaffirm my knowledge and found that things are a bit easier than I have previously described to you. I had erroneously assumed that the oscilloscope data is sent to WaveForms Live with the samples interlaced into a binary blob. In short, each channel's databuffer is a contiguous portion of the binary data, whose lengths and positions are known from the JSON portion of the response. The read response is still sent in a chunked-transfer format, and I have included an example response for reference here. Note that I have added newlines in the JSON portion to make it easier to read and they aren't included in the response normally. Each chunk first begins with its length given in a hex format which is followed by a CRLF (\r\n in the example) and then the data portion also followed by a CRLF. The read response consists of the first chunk that contains a JSON data structure, followed by the binary data portion and finally followed by a zero-sized chunk. In the JSON portion, each channel has a binaryOffset which is used to index the byte position in the binary data for that specific channel. The binaryLength details the byte count of that channels data buffer. Each sample consists of 2 bytes, so these binary values can be converted into a sample index and sample count by dividing the binary values by 2. The time step for each channel is also found in the JSON portion, from the actualSampleFreq. This value is in mHz which is noted in the device enumeration as sampleFreqUnits. Also found in the enumeration is the voltageUnits, mV for the OpenScope, so proper scaling is required if you want straight Volt units. The triggerDelay is also needed from the JSON portion, as it is used to ultimately calculate the sample's time value as the trigger position. Trigger position can be found by the following formula: triggerPosition = -1 * triggerDelay / 10^12 + dt * (# of samples in channel buffer) Ideally, you'd use the binaryOffset and binaryLength to separate each channel buffer from the binary data. Then, for each channel buffer, iterate the collection sample by sample, or 2 bytes at a time. If we let idx represent the iteration index/count, the time value for that sample can then be found by the formula t = idx * dt - triggerPosition and the voltage value by dividing the value being indexed by 1000. At this point WaveForms Live packages the point for use with the charting system, but you are free to use it how you see fit. I understand that there is quite a bit being described here at a rather high level, and if there needs to be further clarification I'd be happy to help further. I hope this info does you well and sees you to your goal. Regards, Andrew Example Read Response 1FF\r\n { "osc": { "1": [ { "command": "read", "statusCode": 0, "binaryOffset": 0, "binaryLength": 4724, "acqCount": 36, "actualSampleFreq": 236127508, "pointOfInterest": 1181, "triggerIndex": 1181, "triggerDelay": 0, "actualTriggerDelay": 0, "actualVOffset": -1, "actualGain": 0.25, "wait": 0 } ], "2": [ { "command": "read", "statusCode": 0, "binaryOffset": 4724, "binaryLength": 4724, "acqCount": 36, "actualSampleFreq": 236127508, "pointOfInterest": 1181, "triggerIndex": 1181, "triggerDelay": 0, "actualTriggerDelay": 0, "actualVOffset": -50, "actualGain": 0.25, "wait": 0 } ] } }\r\n 24E8\r\n <ch1-binary><ch2-binary>\r\n 0\r\n \r\n
  12. Hi @alockcal, Thank you for your patience. Can you take a look at the Task Manager and see if the Digilent Agent is still running, or if there's any Digilent-associated process running? You may need to kill them here if you still run into the error when uninstalling. You may also want to give your computer a reboot if the process-killing didn't work. Do you happen to have any other Digilent devices plugged into your computer? Any other software? Regards, AndrewHolzer
  13. Hi @herg! Good to hear from you again. I am happy to hear that you found my response helpful. I want to let you know that I'm working on a description of the de-interlace process and data-point extraction. I'm going to need some time to work on that, but you can be sure that it is in the pipeline. I do want to answer the questions in your second paragraph, however. To start, there isn't currently any functionality the way you've described. The firmware would need some modification to allow the dynamic functionality you describe, or to wire that behavior into the system directly. Now, I came in after OpenScope, but looking at the schematic and the pinout on WaveForms Live, it looks like this functionality was at least planned for with the Trigger Out pin. I dug through the code firmware and found no use of this pin anywhere, unfortunately. I'll continue on the de-interlace explanation, and I appreciate your patience throughout our correspondence. Regards, AndrewHolzer
  14. You can follow along with how WaveForms Live sends the commands to the OpenScope, using the browser tools to inspect the HTTP requests, since the commands are either sent to the agent if using serial communication, or directly to the OpenScope using these requests. For Chrome and Firefox, press Ctrl+Shft+i then navigate to the network tab to see these commands and the responses received to them. You can also get an idea as to what commands to send and in what order by looking at the WaveForms Live GitHub source, however, I am not expecting you to take a dive into that just to figure this out. If you are following along in the browser tools, navigate to the instrument panel, configure the device how you want and then hit run. The first command that you should see sent, will be a multi-command that sets the parameters for channel 1, the "osc" portion below, and then one that sets the trigger. These can be sent as separate commands, but the OpenScope also supports these multi-commands that combine several commands into one HTTP request. The relevant section in the code would be at line 729 in waveforms-live/src/pages/instrument-panel/instrument-panel.ts, where the command is sent to the device after being constructed. I only specified a single channel when running this, but for two channels the "osc" command will have both a "1" and "2" portion detailing the parameters for channel 1 and channel 2 respectively. { "osc": { "1": [ { "command": "setParameters", "vOffset": 0, "gain": 0.25, "sampleFreq": 94000000, "bufferSize": 940, "triggerDelay": 0 } ] }, "trigger": { "1": [ { "command": "setParameters", "source": { "instrument": "osc", "channel": 1, "type": "risingEdge", "lowerThreshold": 470, "upperThreshold": 500 }, "targets": { "osc": [ 1 ] } }, { "command": "single" } ] } } The next command you should see sent is one to read the oscilloscope channels. The response that you get back here depends on the state of the OpenLogger. If the trigger is armed, but hasn't fired, you should get something like { "osc": { "1": [ { "command": "read", "statusCode": 2684354571, "wait": 0 } ] } } where StatusCode 2684354571 corresponds to am InstrumentArmed error. In this case, WaveForms Live re-issues the read command until something else is received. If there is data then you'll get a Chunked Response which looks something like this FF\r\n { "osc": { "1": [ { "command": "read", "statusCode": 0, "binaryOffset": 0, "binaryLength": 1880, "acqCount": 39, "actualSampleFreq": 93984962, "pointOfInterest": 470, "triggerIndex": 470, "triggerDelay": 0, "actualTriggerDelay": 0, "actualVOffset": -1, "actualGain": 0.25, "wait": 0 } ] } }\r\n 758\r\n <binary of length 1880 bytes>\r\n 0\r\n \r\n In short, each chunk is prefixed with the byte length of that chunk in hexadecimal followed by a CRLF, then the data itself, also followed by a CRLF. In our case, the device first sends back the JSON response (I've made this 'pretty' for easier reading). From the above example we know that the JSON portion is 255 bytes long. After the JSON portion comes the data portion. Each sample in the binary data consists of two bytes multiplied by the number of enabled channels. For a run with multiple channels enabled the channels are interlaced into one sample in numeric order, so the first two bytes of the sample correspond to channel 1, and the second two to channel 2. After the binary data is another chunk length specifier, but this will be zero and is signal to you that the transfer has completed. Once you have this response, you need to extract the channel data from each sample by de-interlacing it. I can show you how it's done in WaveForms Live if you are interested. Now, WaveForms Live sets the OpenScope trigger to Single, and resets it if doing a continuous run. There is the option to set the trigger to re-arm after acquisition with a Trigger Run command. I can't make a comment as to why WaveForms Live does it like this, since my time with the software was during OpenLogger development, and I don't know why this design decision was taken. In the case that you let it run continually, you'll just send a read command repeatedly and respond accordingly if the trigger is just armed, if there is data available, or some other state has been reached. I believe this will answer your questions, however if you still need further information and details do ask and I will be happy to provide. Regards, AndrewHolzer
  15. Hey @herg, I am writing you now to let you know that I am working on a response to your previous thread post, but that it will take me some time. You may expect it by the end of the day, but I ask for your patience while I put it together; I have other responsibilities and you deserve an in depth and informative response. Regards, AndrewHolzer
  16. Hi @herg, I think you may be sending a literal '\r\n' instead of the ascii representation for those characters. puTTY will send those line endings automatically, although this may depend on what OS you are running puTTY on. There is an option to send an implicit Line Feed (LF) character whenever a Carriage Return (CR) character is sent, underneath the Terminal category to the left. I am running Win10 and haven't had to enable that option to get things to work, but you context may vary from mine. Now, all you need to do to send a JSON command, for example the JSON mode command, is to send {"mode": "JSON"} and puTTY will take care of the rest. As to information about the OpenScope instruments and functionality, I can give you some information such as what commands WaveForms Live is sending when you make a certain UI action, and what order those commands need to be in for a serial application. If you want anything more specific however, I'm going to need to know exactly what you are looking for. Regards, AndrewHolzer
  17. Thanks you for bringing this to my attention David. Regards, AndrewHolzer
  18. Hi @David B., I ran the utils on a different computer and hit the same results you are. That's no good! I'll take a look at what's going on and see if I can do something to fix it. Regards, AndrewHolzer
  19. Hello Steve, Apologies for this late reply; I've been hard at work. I have made and am still making progress on WaveForms Live, OpenScope and OpenLogger. I've fixed some of the chart issues that you've observed, such as the incorrect channel number and scaling units, removed the character restriction when specifying units and added the DC settings to the profile, and a few other bugs. I still need to work on the firmware side to fix some of the issues you've found. The stuff I have added to WaveForms Live is currently available on the website and I'll keep you posted about the firmware update as well. Regards, Andrew
  20. You're welcome @snes369, anytime! Do not hesitate to post again on the forums if you need any help. We are happy do to so. AndrewHolzer
  21. Hi @snes369, Thank you for reaching out to us about your problem. I am going to ask you to do a few things so that we can try and establish what the real issue is here. First, have you tried a different USB cable, and what sort of USB port are you plugging it into on the PC? Best get this out of the way off the bat. If the cable is sound, has the device appeared in Ports section of the Device Manager? You can easily find this by right clicking the Windows Start menu and selecting 'Device Manager' from the new menu. Unplug the OpenLogger before you open the Manager, then once you've expanded the Ports section, plug the OpenLogger in and see if a new COM device is reported. If we can see the OpenLogger in the Manager, are we able to get some output from a serial terminal? You can use whichever one, I use PuTTY and others here use Tera Term. If you specify a baud rate of 1250000 (1.25 MBaud), the terminal can establish a connection. Once the terminal has connected, press the reset button of the OpenLogger. It should output some information on the terminal after startup, such as calibration state and wifi state among others. Let me know what results you find. Together we'll find the problem and its solution. AndrewHolzer
  22. Hi @twistedsymphony WaveForms Live doesn't support concurrent use of multiple OpenLoggers. The best that you can do is to configure and run one device, re-associate the agent with the second, then configure and run that one. Unfortunately there won't be any sort of synchronization between the devices, and you'll have to re-associate the agent if you want to view the chart for each OpenLogger. You may possibly configure both device to Log on Boot and stream to the SD card. Still, there won't be any synchronization between the OpenLoggers, but you will be able to gather data across your 12 or more channels.
  23. Thank you for pointing out that nowhere does the store page say that the OpenLogger is only supported by Windows. We make statements on the wiki to that effect, but the store page needs to state that as well. I will get the store page updated promptly to state that. To start the returns process, please contact our sales department and we will refund you your purchase.
  24. Hi @mossygreen, The OpenLogger is only supported by Windows and is incompatible with versions of the agent older than 1.2.0. Windows is the only OS that supports changes made to the agent after 1.2.0 hence why the OpenLogger is only supported by it. You could dual boot Windows on your Mac and get it working that way. If this is too tall an order to ask of you, then we will proceed with the returns process and give you a refund.
  25. You need to be using older attributes to set the column sizes. This article has the appropriate attributes to use. I don't think you can specify any sort of width and thus have to stick to the ones specified which is why the previous width-30 & width-70 didn't work.