diff --git a/firmware/OPENMV1/openmv.bin b/firmware/OPENMV1/openmv.bin deleted file mode 100755 index 427b350e9..000000000 Binary files a/firmware/OPENMV1/openmv.bin and /dev/null differ diff --git a/firmware/OPENMV1/openmv.dfu b/firmware/OPENMV1/openmv.dfu deleted file mode 100644 index 250c9101c..000000000 Binary files a/firmware/OPENMV1/openmv.dfu and /dev/null differ diff --git a/firmware/OPENMV1/openmv.elf b/firmware/OPENMV1/openmv.elf deleted file mode 100755 index beb61a724..000000000 Binary files a/firmware/OPENMV1/openmv.elf and /dev/null differ diff --git a/firmware/OPENMV2/bootloader.bin b/firmware/OPENMV2/bootloader.bin deleted file mode 100755 index 42275208e..000000000 Binary files a/firmware/OPENMV2/bootloader.bin and /dev/null differ diff --git a/firmware/OPENMV2/bootloader.dfu b/firmware/OPENMV2/bootloader.dfu deleted file mode 100644 index 506d9c274..000000000 Binary files a/firmware/OPENMV2/bootloader.dfu and /dev/null differ diff --git a/firmware/OPENMV2/bootloader.elf b/firmware/OPENMV2/bootloader.elf deleted file mode 100755 index 05ae70504..000000000 Binary files a/firmware/OPENMV2/bootloader.elf and /dev/null differ diff --git a/firmware/OPENMV2/firmware.bin b/firmware/OPENMV2/firmware.bin deleted file mode 100755 index d3625ab52..000000000 Binary files a/firmware/OPENMV2/firmware.bin and /dev/null differ diff --git a/firmware/OPENMV2/firmware.dfu b/firmware/OPENMV2/firmware.dfu deleted file mode 100644 index b0fa44af9..000000000 Binary files a/firmware/OPENMV2/firmware.dfu and /dev/null differ diff --git a/firmware/OPENMV2/firmware.elf b/firmware/OPENMV2/firmware.elf deleted file mode 100755 index de8bf9f89..000000000 Binary files a/firmware/OPENMV2/firmware.elf and /dev/null differ diff --git a/firmware/OPENMV2/openmv.bin b/firmware/OPENMV2/openmv.bin deleted file mode 100755 index 957dbf854..000000000 Binary files a/firmware/OPENMV2/openmv.bin and /dev/null differ diff --git a/firmware/OPENMV2/openmv.dfu b/firmware/OPENMV2/openmv.dfu deleted file mode 100644 index 0a48cd641..000000000 Binary files a/firmware/OPENMV2/openmv.dfu and /dev/null differ diff --git a/firmware/OPENMV2/uvc.bin b/firmware/OPENMV2/uvc.bin deleted file mode 100755 index 9f886f901..000000000 Binary files a/firmware/OPENMV2/uvc.bin and /dev/null differ diff --git a/firmware/OPENMV2/uvc.dfu b/firmware/OPENMV2/uvc.dfu deleted file mode 100644 index be42d30dc..000000000 Binary files a/firmware/OPENMV2/uvc.dfu and /dev/null differ diff --git a/firmware/OPENMV2/uvc.elf b/firmware/OPENMV2/uvc.elf deleted file mode 100755 index 13553bbd8..000000000 Binary files a/firmware/OPENMV2/uvc.elf and /dev/null differ diff --git a/firmware/OPENMV3/bootloader.bin b/firmware/OPENMV3/bootloader.bin deleted file mode 100755 index dd1264869..000000000 Binary files a/firmware/OPENMV3/bootloader.bin and /dev/null differ diff --git a/firmware/OPENMV3/bootloader.dfu b/firmware/OPENMV3/bootloader.dfu deleted file mode 100644 index 9ae7572ed..000000000 Binary files a/firmware/OPENMV3/bootloader.dfu and /dev/null differ diff --git a/firmware/OPENMV3/bootloader.elf b/firmware/OPENMV3/bootloader.elf deleted file mode 100755 index 3a30d270b..000000000 Binary files a/firmware/OPENMV3/bootloader.elf and /dev/null differ diff --git a/firmware/OPENMV3/firmware.bin b/firmware/OPENMV3/firmware.bin deleted file mode 100755 index f7712383e..000000000 Binary files a/firmware/OPENMV3/firmware.bin and /dev/null differ diff --git a/firmware/OPENMV3/firmware.dfu b/firmware/OPENMV3/firmware.dfu deleted file mode 100644 index 00c7bb4f1..000000000 Binary files a/firmware/OPENMV3/firmware.dfu and /dev/null differ diff --git a/firmware/OPENMV3/firmware.elf b/firmware/OPENMV3/firmware.elf deleted file mode 100755 index 96e9af57d..000000000 Binary files a/firmware/OPENMV3/firmware.elf and /dev/null differ diff --git a/firmware/OPENMV3/openmv.bin b/firmware/OPENMV3/openmv.bin deleted file mode 100644 index 0dd2aec6f..000000000 Binary files a/firmware/OPENMV3/openmv.bin and /dev/null differ diff --git a/firmware/OPENMV3/openmv.dfu b/firmware/OPENMV3/openmv.dfu deleted file mode 100644 index ab772d17c..000000000 Binary files a/firmware/OPENMV3/openmv.dfu and /dev/null differ diff --git a/firmware/OPENMV3/uvc.bin b/firmware/OPENMV3/uvc.bin deleted file mode 100755 index 6afed6a35..000000000 Binary files a/firmware/OPENMV3/uvc.bin and /dev/null differ diff --git a/firmware/OPENMV3/uvc.dfu b/firmware/OPENMV3/uvc.dfu deleted file mode 100644 index 4c26227bd..000000000 Binary files a/firmware/OPENMV3/uvc.dfu and /dev/null differ diff --git a/firmware/OPENMV3/uvc.elf b/firmware/OPENMV3/uvc.elf deleted file mode 100755 index 4e0d004e6..000000000 Binary files a/firmware/OPENMV3/uvc.elf and /dev/null differ diff --git a/firmware/OPENMV4/bootloader.bin b/firmware/OPENMV4/bootloader.bin deleted file mode 100755 index 1e9e876b2..000000000 Binary files a/firmware/OPENMV4/bootloader.bin and /dev/null differ diff --git a/firmware/OPENMV4/bootloader.dfu b/firmware/OPENMV4/bootloader.dfu deleted file mode 100644 index cecd3b54f..000000000 Binary files a/firmware/OPENMV4/bootloader.dfu and /dev/null differ diff --git a/firmware/OPENMV4/bootloader.elf b/firmware/OPENMV4/bootloader.elf deleted file mode 100755 index 919dcab85..000000000 Binary files a/firmware/OPENMV4/bootloader.elf and /dev/null differ diff --git a/firmware/OPENMV4/firmware.bin b/firmware/OPENMV4/firmware.bin deleted file mode 100755 index ef65da923..000000000 Binary files a/firmware/OPENMV4/firmware.bin and /dev/null differ diff --git a/firmware/OPENMV4/firmware.dfu b/firmware/OPENMV4/firmware.dfu deleted file mode 100644 index 75cc5046c..000000000 Binary files a/firmware/OPENMV4/firmware.dfu and /dev/null differ diff --git a/firmware/OPENMV4/firmware.elf b/firmware/OPENMV4/firmware.elf deleted file mode 100755 index 073590f7f..000000000 Binary files a/firmware/OPENMV4/firmware.elf and /dev/null differ diff --git a/firmware/OPENMV4/openmv.bin b/firmware/OPENMV4/openmv.bin deleted file mode 100644 index 07d178d9b..000000000 Binary files a/firmware/OPENMV4/openmv.bin and /dev/null differ diff --git a/firmware/OPENMV4/openmv.dfu b/firmware/OPENMV4/openmv.dfu deleted file mode 100644 index e0cd376de..000000000 Binary files a/firmware/OPENMV4/openmv.dfu and /dev/null differ diff --git a/firmware/OPENMV4/uvc.bin b/firmware/OPENMV4/uvc.bin deleted file mode 100755 index c3e994487..000000000 Binary files a/firmware/OPENMV4/uvc.bin and /dev/null differ diff --git a/firmware/OPENMV4/uvc.dfu b/firmware/OPENMV4/uvc.dfu deleted file mode 100644 index 59e1dbf98..000000000 Binary files a/firmware/OPENMV4/uvc.dfu and /dev/null differ diff --git a/firmware/OPENMV4/uvc.elf b/firmware/OPENMV4/uvc.elf deleted file mode 100755 index 07b1bea6a..000000000 Binary files a/firmware/OPENMV4/uvc.elf and /dev/null differ diff --git a/firmware/OPENMV4R/bootloader.bin b/firmware/OPENMV4R/bootloader.bin deleted file mode 100755 index 1e9e876b2..000000000 Binary files a/firmware/OPENMV4R/bootloader.bin and /dev/null differ diff --git a/firmware/OPENMV4R/bootloader.dfu b/firmware/OPENMV4R/bootloader.dfu deleted file mode 100644 index cecd3b54f..000000000 Binary files a/firmware/OPENMV4R/bootloader.dfu and /dev/null differ diff --git a/firmware/OPENMV4R/bootloader.elf b/firmware/OPENMV4R/bootloader.elf deleted file mode 100755 index 2e1a46168..000000000 Binary files a/firmware/OPENMV4R/bootloader.elf and /dev/null differ diff --git a/firmware/OPENMV4R/firmware.bin b/firmware/OPENMV4R/firmware.bin deleted file mode 100755 index 62f7b4b39..000000000 Binary files a/firmware/OPENMV4R/firmware.bin and /dev/null differ diff --git a/firmware/OPENMV4R/firmware.dfu b/firmware/OPENMV4R/firmware.dfu deleted file mode 100644 index f4b764033..000000000 Binary files a/firmware/OPENMV4R/firmware.dfu and /dev/null differ diff --git a/firmware/OPENMV4R/firmware.elf b/firmware/OPENMV4R/firmware.elf deleted file mode 100755 index 0e2ae49c9..000000000 Binary files a/firmware/OPENMV4R/firmware.elf and /dev/null differ diff --git a/firmware/OPENMV4R/openmv.bin b/firmware/OPENMV4R/openmv.bin deleted file mode 100644 index 75ff22d94..000000000 Binary files a/firmware/OPENMV4R/openmv.bin and /dev/null differ diff --git a/firmware/OPENMV4R/openmv.dfu b/firmware/OPENMV4R/openmv.dfu deleted file mode 100644 index 9b588ceb3..000000000 Binary files a/firmware/OPENMV4R/openmv.dfu and /dev/null differ diff --git a/firmware/OPENMV4R/uvc.bin b/firmware/OPENMV4R/uvc.bin deleted file mode 100755 index 916e698ac..000000000 Binary files a/firmware/OPENMV4R/uvc.bin and /dev/null differ diff --git a/firmware/OPENMV4R/uvc.dfu b/firmware/OPENMV4R/uvc.dfu deleted file mode 100644 index f5c11fdb7..000000000 Binary files a/firmware/OPENMV4R/uvc.dfu and /dev/null differ diff --git a/firmware/OPENMV4R/uvc.elf b/firmware/OPENMV4R/uvc.elf deleted file mode 100755 index 29a5a73d5..000000000 Binary files a/firmware/OPENMV4R/uvc.elf and /dev/null differ diff --git a/firmware/README.md b/firmware/README.md deleted file mode 100644 index e658bcdc6..000000000 --- a/firmware/README.md +++ /dev/null @@ -1,11 +0,0 @@ -To update the firmware using the IDE follow these steps: - -* Plug in the OpenMV Cam to a USB port. -* Use the IDE built-in dfu tool to update the firmware. - -To update the firmware manually follow these steps: - -* Connect BOOT0 to VCC on the debugging header. -* Plug in the OpenMV Cam to a USB port. -* Type make flash, wait until it's done. -* Remove the jumper and reset the board. diff --git a/src/Makefile b/src/Makefile index ed3f20112..408b28d14 100755 --- a/src/Makefile +++ b/src/Makefile @@ -34,6 +34,7 @@ MAKE = $(Q)make CAT = $(Q)cat # Targets +TARGET ?= OPENMV3 OPENMV = openmv BOOTLOADER = bootloader UVC = uvc @@ -42,6 +43,7 @@ FIRMWARE = firmware # Directories TOP_DIR=$(shell pwd) BUILD=$(TOP_DIR)/build +FW_DIR=$(BUILD)/bin CMSIS_DIR=cmsis STUSB_DIR=stusb MICROPY_DIR=micropython @@ -51,16 +53,12 @@ MLX_DIR=mlx WINC1500_DIR=winc1500 BOOTLDR_DIR=bootloader UVC_DIR=uvc +OMV_BOARD_CONFIG_DIR=$(TOP_DIR)/$(OMV_DIR)/boards/$(TARGET)/ +MP_BOARD_CONFIG_DIR=$(TOP_DIR)/$(MICROPY_DIR)/ports/stm32/boards/$(TARGET)/ # Additional qstr definitions for OpenMV OMV_QSTR_DEFS = $(TOP_DIR)/$(OMV_DIR)/py/qstrdefsomv.h -# Target -TARGET ?= OPENMV3 -FW_DIR=$(TOP_DIR)/../firmware/$(TARGET) -OMV_BOARD_CONFIG_DIR=$(TOP_DIR)/$(OMV_DIR)/boards/$(TARGET)/ -MP_BOARD_CONFIG_DIR=$(TOP_DIR)/$(MICROPY_DIR)/ports/stm32/boards/$(TARGET)/ - # Debugging/Optimization ifeq ($(DEBUG), 1) CFLAGS += -O0 -ggdb3 -DPENDSV_DEBUG @@ -514,6 +512,9 @@ all: $(OPENMV) $(BUILD): $(MKDIR) -p $@ +$(FW_DIR): + $(MKDIR) -p $@ + BOOTLOADER_OBJS: FIRMWARE_OBJS $(MAKE) -C $(BOOTLDR_DIR) BUILD=$(BUILD)/$(BOOTLDR_DIR) CFLAGS="$(BOOTLDR_CFLAGS) -MMD" @@ -554,7 +555,7 @@ $(UVC): FIRMWARE_OBJS UVC_OBJS $(PYTHON) $(MKDFU) -b $(MAIN_APP_ADDR):$(FW_DIR)/$(UVC).bin $(FW_DIR)/$(UVC).dfu # This target generates a combined bootloader+main firmware image. -$(OPENMV): $(BOOTLOADER) $(UVC) $(FIRMWARE) | $(BUILD) +$(OPENMV): $(BOOTLOADER) $(UVC) $(FIRMWARE) | $(BUILD) $(FW_DIR) $(CAT) $(FW_DIR)/$(BOOTLOADER).bin $(FW_DIR)/$(FIRMWARE).bin > $(FW_DIR)/$(OPENMV).bin $(PYTHON) $(MKDFU) -b 0x08000000:$(FW_DIR)/$(BOOTLOADER).bin -b $(MAIN_APP_ADDR):$(FW_DIR)/$(FIRMWARE).bin $(FW_DIR)/$(OPENMV).dfu $(SIZE) $(FW_DIR)/$(BOOTLOADER).elf