diff options
author | Jonathon Pendlum <jonathon.pendlum@ettus.com> | 2016-07-29 22:40:35 -0700 |
---|---|---|
committer | Martin Braun <martin.braun@ettus.com> | 2016-08-09 10:21:52 -0700 |
commit | 1356f89fbf3cc8deb770f6532f9d887567dc3668 (patch) | |
tree | 89dbef9a278aeefcea7528d48bb601043d3b0933 | |
parent | 0433e740bcab28e92f386a9af767710c7677a112 (diff) | |
download | uhd-1356f89fbf3cc8deb770f6532f9d887567dc3668.tar.gz uhd-1356f89fbf3cc8deb770f6532f9d887567dc3668.tar.bz2 uhd-1356f89fbf3cc8deb770f6532f9d887567dc3668.zip |
cores: GPIO core gets explicit DDR setting
-rw-r--r-- | host/lib/usrp/cores/gpio_core_200.cpp | 5 | ||||
-rw-r--r-- | host/lib/usrp/cores/gpio_core_200.hpp | 2 |
2 files changed, 7 insertions, 0 deletions
diff --git a/host/lib/usrp/cores/gpio_core_200.cpp b/host/lib/usrp/cores/gpio_core_200.cpp index 8223a0bbf..8ada95b1f 100644 --- a/host/lib/usrp/cores/gpio_core_200.cpp +++ b/host/lib/usrp/cores/gpio_core_200.cpp @@ -174,9 +174,14 @@ public: gpio_core_200_32wo_impl(wb_iface::sptr iface, const size_t base): _iface(iface), _base(base) { + set_ddr_reg(); + } + + void set_ddr_reg(){ _iface->poke32(REG_GPIO_DDR, 0xffffffff); } + void set_atr_reg(const atr_reg_t atr, const boost::uint32_t value){ if (atr == gpio_atr::ATR_REG_IDLE) _iface->poke32(REG_GPIO_IDLE, value); diff --git a/host/lib/usrp/cores/gpio_core_200.hpp b/host/lib/usrp/cores/gpio_core_200.hpp index 67aa8bde8..c697f0e77 100644 --- a/host/lib/usrp/cores/gpio_core_200.hpp +++ b/host/lib/usrp/cores/gpio_core_200.hpp @@ -77,6 +77,8 @@ public: static sptr make(uhd::wb_iface::sptr iface, const size_t); + virtual void set_ddr_reg() = 0; + virtual void set_atr_reg(const atr_reg_t atr, const boost::uint32_t value) = 0; virtual void set_all_regs(const boost::uint32_t value) = 0; |