This documentation is out of date.
The new version of the documentation is here: https://cannylogic.com/docs |
Difference between revisions of "CANNY 7, EEPROM Driver"
[unchecked revision] | [unchecked revision] |
Line 7: | Line 7: | ||
{| | {| | ||
|valign="top" style="padding-left:0.5em;"|''Note:'' | |valign="top" style="padding-left:0.5em;"|''Note:'' | ||
− | |valign="top" style="padding-left:0.5em;"|''Working with non-volatile memory does not require any special pre-configuration.'' | + | |valign="top" style="padding-left:0.5em;"|''Working with non-volatile memory does not require any special pre-configuration. However, in order to avoid loss of information, make sure that all the time between writing new values, the value in the write register of the used non-volatile memory cell is read from the read register of the same cell. See the example.'' |
+ | |} | ||
+ | |||
+ | {| | ||
+ | |valign="top" style="padding-left:0.5em;"|''Note:'' | ||
+ | |valign="top" style="padding-left:0.5em;"|''Changing the value in a nonvolatile memory cell will increase the execution time of the chart cycle at which it occurred for several milliseconds.'' | ||
|} | |} | ||
Line 70: | Line 75: | ||
The number of keystrokes connected to channel No. 0 of the controller is summed with the value of the "counter" previously stored in the named network. At the moment of releasing the buttons, the value of the network "counter" of memory in cell No. 0 of the controller's non-volatile memory. After the controller power is turned off and restored, the value stored in the nonvolatile memory cell reads and transfers the value back to the named network counter. Thus, in order to avoid the loss of information on the number of operations to cut off electricity. | The number of keystrokes connected to channel No. 0 of the controller is summed with the value of the "counter" previously stored in the named network. At the moment of releasing the buttons, the value of the network "counter" of memory in cell No. 0 of the controller's non-volatile memory. After the controller power is turned off and restored, the value stored in the nonvolatile memory cell reads and transfers the value back to the named network counter. Thus, in order to avoid the loss of information on the number of operations to cut off electricity. | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
== See also == | == See also == |
Latest revision as of 19:34, 16 June 2017
General description
To eliminate loss of critical information (state of the controller, external devices status, and so on..) I case of power reset , CANNY7 controller equipped with non-volatile memory. The values saved in EEPROM will be available in special registers after the power is restored.
There are 64 16-bit non-volatile memory cells, which are accessed by corresponding read and write registers.
Note: | Working with non-volatile memory does not require any special pre-configuration. However, in order to avoid loss of information, make sure that all the time between writing new values, the value in the write register of the used non-volatile memory cell is read from the read register of the same cell. See the example. |
Note: | Changing the value in a nonvolatile memory cell will increase the execution time of the chart cycle at which it occurred for several milliseconds. |
Nonvolatile memory registers
Below is a description of permissible values of controller nonvolatile memory setup registers. They are used to store information in the NVRAM cells.
Address | Expected values | ||||||
---|---|---|---|---|---|---|---|
|
|
Below is a description of acceptable values controller non-volatile memory read registers. They are used to restore information from the NVRAM cells.
Address | Return values | ||||||
---|---|---|---|---|---|---|---|
|
|
Examples
An example of a functional diagram with non-volatile memory cells.
The number of keystrokes connected to channel No. 0 of the controller is summed with the value of the "counter" previously stored in the named network. At the moment of releasing the buttons, the value of the network "counter" of memory in cell No. 0 of the controller's non-volatile memory. After the controller power is turned off and restored, the value stored in the nonvolatile memory cell reads and transfers the value back to the named network counter. Thus, in order to avoid the loss of information on the number of operations to cut off electricity.