![]() ![]() This is a simple example using LEDs, which shows that communication is being done between the boards. (There are workarounds, like the SoftwareSerial library or the. and though it is possible to implement an I2C protocol in that chip, using a shift register is probably easier. ![]() With pins being reserved for power supply and reset, there are in fact only 5 pins left to use. ![]() The following video shows the boards making the communication. Theres no hardware serial port or I2C port (Wire library), making communication trickier. If there is a chip that will benefit from needing only 2 pins for the LCD, it is the 8 pin Attiny85/45/25. E lights a blue LED connected to pin 8 stating that it receives data from the Master card. In turn, the Slave or Reciever card flashes a yellow LED connected to pin 7 to show that it is alive. The Master card flashes a yellow LED connected to pin 7 to show that it is alive and sending data. Since attiny44 does not support the serial monitor, I could not figure out if the communication was being made, so I used leds for that purpose. I wrote the very simple program to see if the boards were communicating between them.Īttention, in the code it is necessary to set the same I2c adress for the two boards: Master and Slave (you can choose any adress, it does not matter) So I used the USI i2C library, which uses "#include USIWire.h" and the commands are identical to the common Wire library for arduino. The previous library only works for Slave and I could not find any library for the Master. In my searches I found a TinyWireS that works with attiny 44. The code had only been tested for ATtiny85 and might work with other attinys, so I relied on this code to try to reproduce for my attiny44.įirst you need to install and include TinyWire libraries. I've seen a very good example that explains the communication between atias 85, see here: I found some projects but none of the projects uses an attiny 44, which is very annoying. To start programming my board I started by investigating on the internet projects that use i2c communication between two attiny boards. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |