Changes between Version 2 and Version 3 of WARPLab/Examples/userExtension
- Timestamp:
- May 22, 2013, 3:37:40 PM (11 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
WARPLab/Examples/userExtension
v2 v3 6 6 Note: the example class and the example script must be in the same directory as one another so that MATLAB can identify the location of the example class once the example script is run. 7 7 8 This example shows how custom commands can be added to the WARPLab Reference Design via a custom user extension class. 8 This example shows how custom commands can be added to the WARPLab Reference Design via a custom user extension class. Specifically, this script (with its corresponding user extension class) are capable of writing an arbitrary string to a WARP board's EEPROM. This memory is non-volatile, so this custom string will survive in memory across loss of power (e.g. reprogramming) on the board. 9 9 10 10 '''Requirements:''' … … 22 22 == Observations == 23 23 24 The first time this script is run, it will produce the following output on the MATLAB command line: 25 26 {{{ 27 Current EEPROM Contents: 28 Node 1: '' 29 Node 2: '' 24 30 25 31 26 == Explanation == 32 Writing EEPROM Contents:'Hello World' 33 }}} 34 35 Before this script is run, the contents of the sections of EEPROM used by this example are empty. This is why the current EEPROM contents show a blank string. When run a second time, the following output can be seen on the MATLAB command line: 36 37 {{{ 38 Current EEPROM Contents: 39 Node 1: 'Hello World' 40 Node 2: 'Hello World' 41 42 43 Writing EEPROM Contents:'Hello World' 44 }}} 45 46 This time, "Hello World" was read from the board. 47 48