NOVA Technical Note 14 About the Build text command Case study: how can I use the Build text command in my procedure? 1 – Exporting data to ASCII The Export ASCII data command can be added to any NOVA procedure to export the data to an ASCII file. This provides a convenient way to automatically prepare the measured data points for data analysis in another application. The use of the Export ASCII data command has been illustrated in a previous technical note (see Technical note #6). In this technical note, the use of another command, Build text, will be detailed in combination with the Export ASCII data command. 2 – The Build text command The Build text command is a very useful command which can be used to generate a string using a user-defined format. The user can add free parameters in the string which in turn can be linked to command parameters in the procedure. To illustrate this case study, a .nox procedure is provided (NOVA technical note 14 – Build text [NOVA 1.10].nox). Import this file using the Import procedure option available in the File menu in NOVA (see Figure 1). 1|Page NOVA Technical note 14 Figure 1 – The procedure used in Technical note #14 This procedure performs a total of 9 cyclic voltammetry scans on the Autolab dummy cell. The Repeat for multiple values command is used to change the Upper vertex potential and the scan rate for each consecutive scan. When this procedure is executed, the applied potential will change as shown in Figure 2. 2|Page NOVA Technical Note 14 Figure 2 – The potential profile used in the Technical note #14 procedure 2.1 – Using the Build text command In this technical note, the initial procedure will be modified in order to export every single cyclic voltammogram to a unique ASCII file. The name of the ASCII file will be automatically generated during the measurement using the following template: TN#14 CV Upper Vertex X Scan rate Y.txt Where the values X and Y will be automatically generated by the procedure. In order to define the name of the file for this technical note, the command Build text will be used. This command is located in the Control group of command (see Figure 3). 3|Page NOVA Technical note 14 Figure 3 – The Build text command is located in the Control group of commands Select the Build text command from the command browser and add it to the procedure, at the end of the repeat loop (see Figure 4). Figure 4 – The Build text added to the procedure The Build text command has two parameters: • • Format: this defines the template of the text string to be generated by the command. Text: this is the output text of the command. 4|Page NOVA Technical Note 14 Edit the Format parameter of the Build text command by typing the following string into the editor frame (see Figure 5): C:\TN#14 CV Upper Vertex {0} Scan rate {1}.txt Figure 5 – The string format to be generated by the Build text command is defined in the Format parameter Note You can copy and paste the string from this document into the command directly. Press enter to validate the format of the string to be generated. The procedure editor frame will be updated as shown in Figure 5, adding two free parameters, {0} and {1} to the Build text command. These two parameters can be linked to other procedure parameters in order to generate a variable text string, in which the values of the parameters {0} and {1} of the Build text command will be replaced by the values of the parameters they are linked to. For the parameter {0} we want to use the values of the upper vertex potential. Select the {0} parameter and while holding the CTRL key pressed, click the upper vertex potential in the CV staircase command. Click the button to link both parameters (see Figure 6). Figure 6 – Linking the values of the upper vertex potential to the Build text command 5|Page NOVA Technical note 14 For the parameter {1} we want to use the values of the scan rate. Select the {1} parameter and while holding the CTRL key pressed, click the scan rate in the CV staircase command. Click the button to link both parameters (see Figure 7). Figure 7 – Linking the values of the scan rate to the Build text command The Build text string format is now properly defined. Select the Export ASCII data command from the Data handling group of commands and add it to the procedure editor, below the Build text command (see Figure 8). Figure 8 – Adding the Export ASCII data command to the procedure Note An error symbol ( ) is displayed next to the Export ASCII data command because no filename has been specified yet. 6|Page NOVA Technical Note 14 Select the Text parameter of the Build text command and, while holding the CTRL key, click the Filename parameter of the Export ASCII data command. Click the button to link both parameters (see Figure 9). Figure 9 – Linking the Text parameter of the Build text command to the Filename parameter of the Export ASCII data command Before the measurement can be started, the signals to be exported must be defined. In this example, we are going to export the Potential applied and WE(1).Current signals to the ASCII file. Select the Potential applied signal in the CV staircase command and link it to the Column 1 parameter of the Export ASCII data command. Repeat this for the WE(1).Current signal, which should be linked to the Column 2 parameter (see Figure 10). 7|Page NOVA Technical note 14 Figure 10 – Linking the Potential applied and WE(1).Current signals to the Export ASCII data command 2.2 – Running the experiment Connect dummy cell (a) and press the start button to begin the measurement. During a validation, a warning will be displayed (see Figure 11). Since no file is specified when the measurement is started, this warning is normal and it can be ignored. The filenames will be generated by the Build text command during the experiment. 8|Page NOVA Technical Note 14 Figure 11 – A warning is displayed during validation The procedure will display the recorded current values on plot#1 and the potential applied on plot#2. Both signals are plotted versus time (see Figure 12). Figure 12 – The data recorded during the measurement on dummy cell (a) At the end of the measurement, open the destination folder (in this technical note it is the root folder of the C:\ drive). A total of nine ASCII files should be stored in the folder using predefined name (see Figure 13): TN#14 CV Upper Vertex X Scan rate Y.txt 9|Page NOVA Technical note 14 Figure 13 – The final exported ASCII files 3 – Conclusion The Build text command is a very useful general purpose command. It provides the means to create automatic strings for data exporting applications as illustrated in this technical note. It can also be used in combination with a Message box or Input box command in order to interact with the user and provide context dependent information (see Figure 14). Figure 14 – Using the Build text command in combination with the Message box command can be useful to remind the user about the experimental conditions during long measurement Note The example shown in Figure 14 can be obtained by linking the Text parameter of the Build text command to the Message parameter of the Message box command, as shown in Figure 15. 10 | P a g e NOVA Technical Note 14 Figure 15 – Linking the Build text to a Message box 11 | P a g e
© Copyright 2024