diff options
| author | Daniel Campora <daniel@wipy.io> | 2015-05-26 17:23:52 +0200 |
|---|---|---|
| committer | Daniel Campora <daniel@wipy.io> | 2015-05-27 09:45:27 +0200 |
| commit | 9414f92fa9675cf2ba27b7700173c690bf7c1f37 (patch) | |
| tree | 12b2a54d0e0a159801aa1b45223211e5f51aac5e /cc3200/mods/pybi2c.c | |
| parent | 8096be089e39363cdd688a6e4e185484aaa06b1c (diff) | |
cc3200: Fix I2C and SPI module references.
Diffstat (limited to 'cc3200/mods/pybi2c.c')
| -rw-r--r-- | cc3200/mods/pybi2c.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/cc3200/mods/pybi2c.c b/cc3200/mods/pybi2c.c index 1b9c6ca16..8d0e5f962 100644 --- a/cc3200/mods/pybi2c.c +++ b/cc3200/mods/pybi2c.c @@ -56,10 +56,10 @@ /// /// from pyb import I2C /// -/// i2c = I2C(1) # create -/// i2c = I2C(1, 50000) # create and init with a 50KHz baudrate -/// i2c.init(100000) # init with a 100KHz baudrate -/// i2c.deinit() # turn off the peripheral +/// i2c = I2C(1) # create +/// i2c = I2C(1, I2C.MASTER, baudrate=50000) # create and init with a 50KHz baudrate +/// i2c.init(I2C.MASTER, baudrate=100000) # init with a 100KHz baudrate +/// i2c.deinit() # turn off the peripheral /// /// Printing the i2c object gives you information about its configuration. /// @@ -76,7 +76,6 @@ /// /// A master must specify the recipient's address: /// -/// i2c.init(1, 100000) /// i2c.send('123', 0x42) # send 3 bytes to slave with address 0x42 /// i2c.send(b'456', addr=0x42) # keyword for address /// |
