Files
-
nu.ai_motor_controller / battery.sch
-
nu.ai_motor_controller / driver.sch
-
nu.ai_motor_controller / microcontroller.sch
-
nu.ai_motor_controller / nu.ai_motor_controller.kicad_pcb
-
nu.ai_motor_controller / nu.ai_motor_controller.sch
-
nu.ai_motor_controller / power.sch
-
nu.ai_motor_controller / uc_tvs_tps.sch
Last update 5 years 6 months
by
DJ
Filesnu.ai_motor_controller_firmware | |
---|---|
.. | |
Makefile | |
README.txt | |
firmware_design_document.odt | |
flash.sh | |
nu.ai_motor_controller_firmware.c | |
reset.py |
Makefilebaud=57600 avrType=atmega32u4 avrFreq=16000000 # 16 Mhz programmerDev=/dev/ttyACM0 programmerType=avr109 #cflags=-DF_CPU=$(avrFreq) -mmcu=$(avrType) -Wall -Werror -Wextra -Os cflags=-DF_CPU=$(avrFreq) -mmcu=$(avrType) -Wall -Wextra -Os objects=$(patsubst %.c,%.o,$(wildcard *.c)) .PHONY: flash clean all: main.hex %.o: %.c avr-gcc $(cflags) -c $< -o $@ main.elf: $(objects) avr-gcc $(cflags) -o $@ $^ main.hex: main.elf avr-objcopy -j .text -j .data -O ihex $^ $@ flash: main.hex avrdude -p$(avrType) -c$(programmerType) -P$(programmerDev) -b$(baud) -v -U flash:w:$< clean: rm -f main.hex main.elf $(objects)