aboutsummaryrefslogtreecommitdiffstats
path: root/firmware/microblaze/usrp2p/bootloader_utils.h
diff options
context:
space:
mode:
authorNick Foster <nick@nerdnetworks.org>2010-07-26 15:33:30 -0700
committerNick Foster <nick@nerdnetworks.org>2010-07-26 15:33:30 -0700
commitf72ad02f5ec370f45995ecd2b3e8b322e9a7e4dc (patch)
tree069b728b6e44a5db8607a8c5815e3a2d50a114ac /firmware/microblaze/usrp2p/bootloader_utils.h
parentf86c25317b457b280c697fc47905c79bdbbc0c93 (diff)
downloaduhd-f72ad02f5ec370f45995ecd2b3e8b322e9a7e4dc.tar.gz
uhd-f72ad02f5ec370f45995ecd2b3e8b322e9a7e4dc.tar.bz2
uhd-f72ad02f5ec370f45995ecd2b3e8b322e9a7e4dc.zip
New branch with firmware dir from USRP2P branch.
Diffstat (limited to 'firmware/microblaze/usrp2p/bootloader_utils.h')
-rw-r--r--firmware/microblaze/usrp2p/bootloader_utils.h21
1 files changed, 21 insertions, 0 deletions
diff --git a/firmware/microblaze/usrp2p/bootloader_utils.h b/firmware/microblaze/usrp2p/bootloader_utils.h
new file mode 100644
index 000000000..c72128f43
--- /dev/null
+++ b/firmware/microblaze/usrp2p/bootloader_utils.h
@@ -0,0 +1,21 @@
+/* -*- c++ -*- */
+/*
+ * Copyright 2010 Ettus Research LLC
+ *
+ */
+
+#include <stdint.h>
+
+//we're working in bytes and byte addresses so we can run the same code with Flash chips of different sector sizes.
+#define FPGA_IMAGE_SIZE_BYTES 2097152
+//instead of 32K, we write 31K because we're using the top 1K for stack space!
+#define FW_IMAGE_SIZE_BYTES 31744
+
+#define SAFE_FPGA_IMAGE_LOCATION_ADDR 0x00000000
+#define SAFE_FW_IMAGE_LOCATION_ADDR 0x007F0000
+#define PROD_FPGA_IMAGE_LOCATION_ADDR 0x00200000
+#define PROD_FW_IMAGE_LOCATION_ADDR 0x00400000
+
+int is_valid_fpga_image(uint32_t addr);
+int is_valid_fw_image(uint32_t addr);
+void start_program(uint32_t addr);