Week 13. Networking and communications

In the Makefile I changed --mcu=$(MMCU) --format=avr in the 10th line to -A and I used the commandavrdude -c ? to remind myself the name of the programmer is atmelice_isp then I changed the Makefile to add a new block

program-atmelice_isp: $(PROJECT).hex
      avrdude -p t45 -P usb -c atmelice_isp -U flash:w:$(PROJECT).c.hex

Then I ran make -f hello.bus.45.make which indeed generated the text files, and then make -f hello.bus.45.make program-atmelice_isp to program the board. Seems to have worked without issue!

Worked on the second, but the third I had a t85 rather than a t45. Ooops! For kicks switched t45 to t85 in the Makefile, and that worked! All the nodes light up when a key is pressed. Had the network powered through the FTDI cable.

Oops I gave them all the same node_id of '0'. So then copied the c files and the makefiles. In the c files changed the nodeid, and in the make files changed the first line to PROJECT=hello.bus.45.node1

The network works! It will be fun to play with the protocol or perhaps to add a sensor to query different boards upon pressing a button.