diff options
author | Ayke van Laethem <[email protected]> | 2021-02-06 12:37:15 +0100 |
---|---|---|
committer | Ron Evans <[email protected]> | 2021-03-29 02:02:04 +0200 |
commit | 90b42799a2a91f6614ea86e8650d5fa303bc10b2 (patch) | |
tree | c98d7a684da7c5845571ce06c92d12ed320e243b /src/machine/board_pygamer.go | |
parent | 71bbe93ab2e482239fbab790a83c528bc077d74e (diff) | |
download | tinygo-90b42799a2a91f6614ea86e8650d5fa303bc10b2.tar.gz tinygo-90b42799a2a91f6614ea86e8650d5fa303bc10b2.zip |
machine: make machine.I2C0 and similar objects pointers
This makes it possible to assign I2C objects (machine.I2C0,
machine.I2C1, etc.) without needing to take a pointer.
This is important especially in the future when I2C may be driven using
DMA and the machine.I2C type needs to store some state.
Diffstat (limited to 'src/machine/board_pygamer.go')
-rw-r--r-- | src/machine/board_pygamer.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/machine/board_pygamer.go b/src/machine/board_pygamer.go index 5743ec95d..7e5c08e7e 100644 --- a/src/machine/board_pygamer.go +++ b/src/machine/board_pygamer.go @@ -99,7 +99,7 @@ const ( // I2C on the PyGamer. var ( - I2C0 = I2C{ + I2C0 = &I2C{ Bus: sam.SERCOM2_I2CM, SERCOM: 2, } |