I am fairly new user of Waveforms 2015 and I have both an Analog Discovery 2 and a Digital Discovery that I am trying to use for some for some tests with custom scripts. I am having difficulty finding the documentation or some example code that instructs me how to assign the pins I want to use for the Select, Clock, DQ0 (write), and DQ1 (read) functions. I have two different devices I need to communicate with through SPI but there is only one "select" line.
I have two transceiver/MCU nodes connected together in a system and I need to communicate with the SPI port of one node to have it send a data packet to the second node, and then I need to switch my SPI bus pins to the second board and read verify it received the data I just sent from the first node.
I am able to script up a sequence of Read/Write transactions using the pin assignments set in the Waveforms GUI for my first device, but I now need to re-assign the pins in the script so that I can configure my second device without having to manually change the pin assignments in the Waveforms GUI.
For example, if I use my Digital Discovery, the SPI pin assignments I would like to use are:
Node 1: Select = DIO 24, Clock = DIO 25, DQ0 = DIO 26, and DQ1 = DIO 27.
Node 2: Select = DIO 28, Clock = DIO 29, DQ0 = DIO 30, and DQ1 = DIO 31.
Could I get some example code to show how to assign the DIO pins for the various SPI signals Select, Clock, DQ0, DQ1 in both the Protocol/SPI/Custom script and the general Script tool in Waveforms 2015? I'm sorry if this is a newbie question or documented somewhere already, but this has been elusive to me.
Question
Jonboy
I am fairly new user of Waveforms 2015 and I have both an Analog Discovery 2 and a Digital Discovery that I am trying to use for some for some tests with custom scripts. I am having difficulty finding the documentation or some example code that instructs me how to assign the pins I want to use for the Select, Clock, DQ0 (write), and DQ1 (read) functions. I have two different devices I need to communicate with through SPI but there is only one "select" line.
I have two transceiver/MCU nodes connected together in a system and I need to communicate with the SPI port of one node to have it send a data packet to the second node, and then I need to switch my SPI bus pins to the second board and read verify it received the data I just sent from the first node.
I am able to script up a sequence of Read/Write transactions using the pin assignments set in the Waveforms GUI for my first device, but I now need to re-assign the pins in the script so that I can configure my second device without having to manually change the pin assignments in the Waveforms GUI.
For example, if I use my Digital Discovery, the SPI pin assignments I would like to use are:
Node 1: Select = DIO 24, Clock = DIO 25, DQ0 = DIO 26, and DQ1 = DIO 27.
Node 2: Select = DIO 28, Clock = DIO 29, DQ0 = DIO 30, and DQ1 = DIO 31.
Could I get some example code to show how to assign the DIO pins for the various SPI signals Select, Clock, DQ0, DQ1 in both the Protocol/SPI/Custom script and the general Script tool in Waveforms 2015? I'm sorry if this is a newbie question or documented somewhere already, but this has been elusive to me.
Thanks!
Link to comment
Share on other sites
3 answers to this question
Recommended Posts
Archived
This topic is now archived and is closed to further replies.