Networking and Interfaces
Week 10
This project is a culmination of a series of smaller iterations that started with building a micro-controller on a PCB board and culminated with driving a servo motor to control a pump. My project demonstrates how pressing a button by a user triggers a communication between computers, in this case, I2C, to control a motor action.
Tools
SOFTWARE: Arduino library, ProcessingHARDWARE: Arduino, Othermill to print the PCBs, wires, breadboard, servo motor
OVERVIEW OF SYSTEM DIAGRAM
Inspirations
PEOPLE WHOSE WORK I USED AS REFERENCE
I referred to a ton of sites, videos and blogs to understand the concepts. Some people whose documentation was specifically useful include Jordy, Cody and Alejandro.
Steps to Set up
Issues with installing Processing: After I downloaded the Processing software, I ran into an error that prevented me from installing the libraries. So I referred to this link and followed all the instructions, including installing the serial library and control p5.
List of helpful commands
$ python pyupdi.py -d tiny1614 -c COM9 -b 115200 -f /C:/Users/jkrit/OneDrive/Documents/Arduino/build/motor_2.ino.hex
- pymcuprog -d attiny1614 -t uart -u COM9 -c 115200 -v info erase
- $ pymcuprog -d attiny1614 -t uart -u COM9 -c 115200 -v info write -f /C/Users/jkrit/OneDrive/Documents/Arduino/build/motor_2.ino.hex
pymcuprog -d your_processor -t uart -u your_port -c your_baud_rate -v info write -f your_hex_file $ pymcuprog -d attiny1614 -t uart -u COM9 -c 115200 -v info write -f
C:/Users/jkrit/OneDrive/Documents/Arduino/motor_2/motor_2.ino.t1614.20c0.u5V.mD0.hex
$ pymcuprog -d attiny1614 -t uart -u COM9 -c 115200 -v info write -f C:/Users/jkrit/OneDrive/Documents/Arduino/build/motorgui.ino.hex
here's an image of the code for networking: Here's the code for the motor:
Here's the video of the system working: