Search the Community
Showing results for tags 'adp3250'.
-
嗨阿提拉我现在自豪地拥有3 Digilent肛门og discover devices . ( 2x AD2 & 1x ADP3250 ) I have posted many post on the forum you can just make search for SIB in the forum and you will find all my posts. I would like you help to get this standard driver set up and running using the Java script engine of Waveforms . Below is the script that I want to get working and also is a waveforms work bench file also . This is after all the real power of the waveforms work bench and Analog discovery and professional devices Best wishes Simon --------------------------------------------------- function UART_data_collect() { // ------------------------------------------------------------------------------------------------------------ // // The aim of this script is to collect data from a UART serial stream from a embedded microprocessor board // and process the data from serial stream and display the result on the scope display // // ------------------------------------------------------------------------------------------------------------ // // Status // // 1) Code executes without error // 2) Code does not receive data from the UART serial port // even through the same ports are used manually to recieve data // from MCU using the manual protocol window with the same settings. // Steps to add A) Serial stream Protocol handler B) Scope display script // // ------------------------------------------------------------------------------------------------------------ clear(); // clear Output log Protocol.run() Scope.run() if(!('Protocol' in this)) throw "Please open the Protocol instrument"; if(!('Scope' in this)) throw "Please open the Oscilloscope instrument"; Protocol.Mode.text = "UART"; // make sure UART tab is selected Protocol.UART.TX.value = 0; // Set up UART TX pin on Digilent AD2 :: DIO_0 Pin Protocol.UART.RX.value = 1; // Set up UART RX pin on Digilent AD2 :: DIO_1 Pin Protocol.UART.Bits.value=8; // Sets or gets the UART number of bits. Protocol.UART.Parity.text="None" ;// Sets or gets the parity setting: “None”, “Even”, “Odd”, “Mark (High)”, “Space (Low)”. Protocol.UART.Rate.value=234000; // Sets or gets the baud rate setting Protocol.config(); // apply configuration changes now Protocol.UART.Receiver(); // reset receiver - that is too start receiving data print(" UART Serial Bus initialised . Beware this is 3V3 Logic RS232 & Not True +/- 15V Rs232" + "\n\r" ); print(" UART TX line connect to AD2 DIO Port " + Protocol.UART.TX.value + "\n\r" ) ; print(" UART RX line connect to AD2 DIO Port " + Protocol.UART.RX.value + "\n\r" ) ; print("\n\r"+" UART initialisation complete " + "\n\r" ) ; Scope1.Time.Rate.value = 0.2; Scope1.single(); //Scope1.wait(); Scope1.Ref1.Clone(Scope1.Channel1); Scope1.Ref2.Clone(Scope1.Channel2); Scope1.Ref1.enable = true; Scope1.Ref2.enable = true; var rx = [] var rx_process = [] while(wait(0.2)) { // wait 0.2 sec and repeat while not stopped rx = rx.concat(Protocol.UART.ReceiveArray()) // append new words if(rx.shift()!=0x0A) { continue; } else { // read one of text ; rx_process=rx; rx=[]; Print( rx_process ); } // (rx.length>10) // if(rx.shift()==0xAA) continue; // if (rx[1] == 0xB5 && rx[2]== 0x11 && rx[7] == 0x09) // { // find the temperatures for displaying // // // print ("Temp 1: " + (rx[8]/2).toFixed(1) + " °C Temp 2: " + (rx[9]/2).toFixed(1) + " °C"); // // } // decimal data devided by 2 bring °Celsius // //Scope1.Ref1.data = } // // ref https://forum.digilentinc.com/topic/21308-ad2-protocol-uart-script-reading-vaillant-ebus/ // // https://forum.digilentinc.com/topic/21353-use-of-multiple-protocol-uart-ports-via-script-possible-at-different-times/ // // notes // ===== // // 1. On the AD and AD2 the digital IO pins use LVCMOS 3V3 standard. These are supplied at 3.3V and have 200 Ohm PTC and clamping diodes to GND and to 3.3V for protection. // It will drive the digital wires at 3.3V and connecting 5V signals directly, without series resistor, it will sink about 10mA through the PTC and 3v3 diode. // As for noise, make sure to have ground connection between the two devices. // // 2. The WF/Protocol/UART uses the Stop length option only for transmission, this is not relevant for reception. // // 3. The UART TX filed lets you type in characters, hexadecimal values are not supported here. // Special chars you can copy/paste from other place or send from file. } //************************************************************ // Main program block : Start //************************************************************ clear(); // clear display screen print(" Script Main body start " + "\n\r "); UART_PID_data_collect(); //************************************************************ //************************************************************ // Main program block : Stop End ADP3250_UART_DATA_TO_SCOPE.dwf3work
- 4 replies
-
- analog discovery 2
- uart
- (and 5 more)
Tagged with:
-
Does anyone know which FFT library is good on Waveform SDK? I need to implement the FFT coding into my VC++ program. Please advice me which is good solution for my application as below? -Output is 1kHz sine wave -Using ADP3250 -Measure the THD value less than about -70dB from specification I hope to fine some sample code to use some library and If you need more information, please let me know
-
Hello all, I need to use the AD2 / AD Pro for some analog/digital signal measurements. I have a few questions before I make the purchase. Can I acquire both the Analog as well as Digital input channels simultaneously with MATLAB? Can I change the Gain of an Analog Channel from MATLAB? If so, how? After changing the gain, does the resolution of 14bit apply to this amplified value? i.e. if with 1X gain the input range is +-25V, and the 14 bits are mapped to this voltage range, Does making the gain 10X, make the 14bits map to the new range? i.e. +-2.5V? Thus increasing the precision of the system to low voltages? In my test setup I need to probe (2 analog) signals which will vary in terms of mV (lets say 1-2mVs) and 2 Digital signals simultaneously. Will I be able to measure these small signals with AD2 or AD Pro, If so, which one will be better?
-
你好,我想买一个模拟Discovery Pro oszilloscopes (ADP3250/ADP3450). I want to make sure, that the device is suitable for my measurement application: I want to sample an analog signal with 5 MHz (1 Channel). 14 Bit resolution should be enough. I want to record the signal continiously. If this is not possible, then at least for 5 seconds. Unfortunately this is not possible with a standard oszilloscope. I want to transfer the data to my PC for further processing. According to the specs, both oszilloscopes can work in the so called "record mode" and provide an input buffer of up to 128 MSamples. This should be enough for me. However, it is mentioned, that the record mode is not available in linux mode at sample rates over 1 MS/s. For the normal operation mode there is no limit specified. Anyway, I can not believe, that it is possible to transfer the maximum data rate (100 MS/s / 125 MS/s) to the PC via ethernet. So the maximum possible sampling rate should depend on the ethernet connection between the PC and the device. If I use the WaveForms application in demo mode, I lost samples if the sample rate was higher than 2 MS/s. I dont know, wether this is representative. Does someone has experience what the maximum sample rate in normal record mode is? Is the device capable of measuring 25,000,000 sample points at a sample rate of 5 MHz, with an resolution of 14 Bit? Thank you for your help. Best regards, oeser
-
Hi, The 14-bit resolution analog channels are interesting. Do the ADP3450 combine that resolution with a PGA (programable gain amplifier)? For example, if I"m measuring a 1 mV pk-pk signal, will it be possible to utilize the entire 14-bit resolution on that signal? Thanks
