Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| test-and-measurement:analog-discovery-2:ad2-motor-debugger:start [2021/05/14 23:04] – ↷ Page moved from reference:test-and-measurement:analog-discovery-2:ad2-motor-debugger:start to test-and-measurement:analog-discovery-2:ad2-motor-debugger:start Arthur Brown | test-and-measurement:analog-discovery-2:ad2-motor-debugger:start [2022/10/04 11:38] (current) – external edit 127.0.0.1 | ||
|---|---|---|---|
| Line 11: | Line 11: | ||
| <WRAP group> | <WRAP group> | ||
| == Hardware == | == Hardware == | ||
| - | * [[https://store.digilentinc.com/ | + | * [[https://digilent.com/shop/ |
| == Software == | == Software == | ||
| - | * [[reference:software: | + | * [[software: |
| * [[https:// | * [[https:// | ||
| * C/C++ compiler (this might be included in your IDE) | * C/C++ compiler (this might be included in your IDE) | ||
| Line 20: | Line 20: | ||
| </ | </ | ||
| - | **Note:** //WaveForms can be installed by following the [[reference:software: | + | **Note:** //WaveForms can be installed by following the [[software: |
| ---- | ---- | ||
| Line 54: | Line 54: | ||
| ===== Functions for Controlling Different Instruments ===== | ===== Functions for Controlling Different Instruments ===== | ||
| - | In the following, the functions used for controlling the instruments in this example are discussed. For details about other available functions in the WaveForms SDK, check the [[reference:software: | + | In the following, the functions used for controlling the instruments in this example are discussed. For details about other available functions in the WaveForms SDK, check the [[software: |
| --> Connecting and Disconnecting the Analog Discovery 2 # | --> Connecting and Disconnecting the Analog Discovery 2 # | ||
| Line 400: | Line 400: | ||
| <WRAP group>< | <WRAP group>< | ||
| - | In the main function, the first step is to connect the Analog Discovery 2. If it can't be connected, the program must be finished, as the rest of the functions can't be called. The function init_AD2() is discussed under the [[reference:test-and-measurement: | + | In the main function, the first step is to connect the Analog Discovery 2. If it can't be connected, the program must be finished, as the rest of the functions can't be called. The function init_AD2() is discussed under the [[test-and-measurement: |
| </ | </ | ||
| //main function | //main function | ||
| Line 420: | Line 420: | ||
| <WRAP group>< | <WRAP group>< | ||
| - | To test the motor drivers, the microcontroller must be turned off by setting it's RESET pin to low. After that, the voltages on the potentiometers can be read, and the digital_write() and PWM generation functions can be used to test both motors with varying speeds, in both directions. Details about the used functions can be found under the [[reference:test-and-measurement: | + | To test the motor drivers, the microcontroller must be turned off by setting it's RESET pin to low. After that, the voltages on the potentiometers can be read, and the digital_write() and PWM generation functions can be used to test both motors with varying speeds, in both directions. Details about the used functions can be found under the [[test-and-measurement: |
| </ | </ | ||
| //main function | //main function | ||
| Line 450: | Line 450: | ||
| <WRAP group>< | <WRAP group>< | ||
| - | To record the signals coming from the MCU, it must be turned on, by setting its RESET pin to logic high. After this, the number of samples to record must be specified (data_size), | + | To record the signals coming from the MCU, it must be turned on, by setting its RESET pin to logic high. After this, the number of samples to record must be specified (data_size), |
| </ | </ | ||
| printf(" | printf(" | ||
| Line 493: | Line 493: | ||
| <WRAP group>< | <WRAP group>< | ||
| - | When the program is finished, the Analog Discovery 2 must be closed, to make it available to other software. Details about the close_AD2() function can be found under the [[reference:test-and-measurement: | + | When the program is finished, the Analog Discovery 2 must be closed, to make it available to other software. Details about the close_AD2() function can be found under the [[test-and-measurement: |
| </ | </ | ||
| // close opened device | // close opened device | ||
| Line 517: | Line 517: | ||
| ===== Final Notes ===== | ===== Final Notes ===== | ||
| - | For more guides and example projects for your Analog Discovery 2, please visit its [[reference:test-and-measurement: | + | For more guides and example projects for your Analog Discovery 2, please visit its [[test-and-measurement: |
| - | For more information about how to use WaveForms SDK, please visit the [[reference:software: | + | For more information about how to use WaveForms SDK, please visit the [[software: |
| For technical support, please visit the [[https:// | For technical support, please visit the [[https:// | ||
| {{tag> | {{tag> | ||

