Trees | Indices | Help |
---|
|
Implementation of the .mem sub-object for modules that provide the generic IO memory interface
Instances of this class are created by the module subclass constructor, for those module software versions that actually implement the interface.
Typical usage, assuming m is a module: >>> m.mem[0xBAD] = 0xC0ED >>> print m.mem[0xDEAD] >>> m.mem[[0xBAD, 0xD00D]] = [0xBE, 0xEF] >>> print m.mem[[0xC0ED, 0xBABE]] >>> m.mem[0xF00] |= (1<<5) # set bit 5 >>> m.mem[0xF00] &= ~(1<<5) # clear bit 5 >>> m.mem[0xF00] ^= (1<<5) # toggle bit 5
If the module also has a .mcu sub-object, it will typically provide the constants needed instead of the literals in the example above.
|
|||
|
|||
|
|||
|
|||
Inherited from |
|
|||
Inherited from |
|
Attach memory sub-object to this module
|
Read memory from microcontroller. key can either be an integer memory address, or a list of such addresses. When a list is used, returns a list of the results |
Write memory values in microcontroller key can be an address and val a byte value, or key is a list of addresses, and val a sequence of values (i.e. val can also be a tuple, or any other sequence type). |
Trees | Indices | Help |
---|
Generated by Epydoc 3.0.1 on Thu Jan 4 16:46:17 2018 | http://epydoc.sourceforge.net |