DIY I2C
Ever want to play with an I2C device, but it doesn't have a library? This Propeller C Tutorial will show you how to use the i2c_out and i2c_in functions for DIY I2C communication.
Ever want to play with an I2C device, but it doesn't have a library? This Propeller C Tutorial will show you how to use the i2c_out and i2c_in functions for DIY I2C communication.
This test program stores a string of seven character values "abcdefg" to the EEPROM. Then, it retrieves them back and prints them in the SimpleIDE Terminal. To do so, the code performs these steps:
Now that we have done some basic communication with simple byte data and one I2C device, let’s expand on that. First, let’s modify the original code to work with other data types besides bytes. Then, if you are interested in going a bit further, the Advanced Topic section will show you a method you could use to put two additional EEPROM DIP chips (plugged into your breadboard) on a second I2C bus.
The term I2C comes from the name Inter-Integrated Circuit, which would be abbreviated IIC. If those three letters were variables in an equation multiplied together, the two I terms would be I x I or I2. So, that’s where I2C comes from. It’s often pronounced I-squared-C, though I-two-C is also understood.
To program your cyber:bot, you will write Python scripts and flash them to the micro:bit as usual. But the micro:bit won't be working alone. The cyber:bot has two key microcontroller chips that communicate via a pair of circuit lines, one for a common clock and one for data, called an I2C bus.
To program your cyber:bot, you will write Python scripts and flash them to the micro:bit as usual. But the micro:bit won't be working alone. The cyber:bot has two key microcontroller chips that communicate via a pair of circuit lines, one for a common clock and one for data, called an I2C bus.
This Micropython library is for the Parallax cyber:bot robot (#32700). It merges a micro:bit module with robot chassis hardware. An onboard Propeller multicore microcontroller pre-loaded with cyber:bot firmware assists the micro:bit, handling real-time servo control and sensor circuits on the breadboard. The micro:bit communicates with the Propeller through an I2C bus, no direct Propeller programming required.