Specifications

When a script is loaded into a node, the script is compiled for the node. At compile time the
platform variable is loaded with the contents of NV parameter 41, which you can use to control
which other SNAPpy modules get imported or what other code will be compiled.
Because the variable is available at compile time (rather than only at run time), the compiler can
optimize its code generation for the platform you are using, decreasing the code size and increasing the
amount of space available for more complex scripts. The pinWakeup.py script, itself imported by the
NewPinWakeupTest.py script, provides an example of this.
If you do not import the synapse.snapsys module, the platform variable will not be defined.
This parameter is not modified when you reset parameters to factory defaults.
ID 42 through 49 – Reserved for Future Use
Reserved for future Synapse use.
ID 50 – Enable Encryption
Control whether encryption is enabled, and what type of encryption is in use for firmware that
supports multiple forms. The options for this field are:
0 = Use no encryption. (This is the default setting.)
1 = Use AES-128 encryption if you have firmware that supports it.
2 = Use Basic encryption.
If you set this to a value that indicates encryption should be used, but either an invalid encryption key
is specified (in NV Parameter #51), or your firmware does not support the encryption mode specified,
your transmissions will not be encrypted.
SNAP versions before 2.4 did not include the option for Basic encryption, and nodes upgraded from
those firmware versions may contain False or True for this parameter. Those values correspond to 0
and 1 and will continue to function correctly. Basic encryption is not as secure as AES-128 encryption,
but it is available in all nodes.
If encryption is enabled and a valid encryption key is specified, all communication from the node will
be encrypted, whether it is sent over the air or over a serial connection. Likewise, the node will expect
that all communication to it is encrypted, and will be unable to respond to unencrypted requests from
other nodes. If you have a node that you cannot contact because of a forgotten encryption key, you
will have to reset the factory parameters on the node to reestablish contact with it.
Even with a valid encryption key, encryption is not enabled until the node is rebooted. See the
Encryption section in Section 6 for more details.
ID 51 – Encryption Key
The encryption key used by either AES-128 encryption or Basic encryption, if enabled. This NV
Parameter is a string with default value of “”. If you are enabling encryption, you must specify an
SNAP Reference Manual Document Number 600-0007K Page 103 of 202