summaryrefslogtreecommitdiffstats
path: root/firmware/microblaze
diff options
context:
space:
mode:
authorJosh Blum <josh@joshknows.com>2010-07-05 19:12:01 -0700
committerJosh Blum <josh@joshknows.com>2010-07-05 19:12:01 -0700
commita95eaac42f6cc85fd2ad3f32dc29eeab38ef5194 (patch)
treebc1a60e25496a3a1c3ff26f0fc2d3782b6ab191d /firmware/microblaze
parentc2039a8c92561fa5532d87cb9d875a3ad7b875c1 (diff)
downloaduhd-a95eaac42f6cc85fd2ad3f32dc29eeab38ef5194.tar.gz
uhd-a95eaac42f6cc85fd2ad3f32dc29eeab38ef5194.tar.bz2
uhd-a95eaac42f6cc85fd2ad3f32dc29eeab38ef5194.zip
usrp2: Added a peek64 to read pairs of 32 bit numbers such as time64
also added a templated host to/from network conversion in byteswap.hpp (didnt use it though)
Diffstat (limited to 'firmware/microblaze')
-rw-r--r--firmware/microblaze/apps/txrx_uhd.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/firmware/microblaze/apps/txrx_uhd.c b/firmware/microblaze/apps/txrx_uhd.c
index 21803b199..99c149d45 100644
--- a/firmware/microblaze/apps/txrx_uhd.c
+++ b/firmware/microblaze/apps/txrx_uhd.c
@@ -269,6 +269,10 @@ void handle_udp_ctrl_packet(
printf("error! tried to poke into 0x%x\n", ctrl_data_in->data.poke_args.addr);
}
else switch(ctrl_data_in->data.poke_args.num_bytes){
+ case sizeof(uint64_t):
+ *((uint32_t *) ctrl_data_in->data.poke_args.addrhi) = (uint32_t)ctrl_data_in->data.poke_args.datahi;
+ //continue to uint32_t for low addr:
+
case sizeof(uint32_t):
*((uint32_t *) ctrl_data_in->data.poke_args.addr) = (uint32_t)ctrl_data_in->data.poke_args.data;
break;
@@ -287,6 +291,10 @@ void handle_udp_ctrl_packet(
case USRP2_CTRL_ID_PEEK_AT_THIS_REGISTER_FOR_ME_BRO:
switch(ctrl_data_in->data.poke_args.num_bytes){
+ case sizeof(uint64_t):
+ ctrl_data_out.data.poke_args.datahi = *((uint32_t *) ctrl_data_in->data.poke_args.addrhi);
+ //continue to uint32_t for low addr:
+
case sizeof(uint32_t):
ctrl_data_out.data.poke_args.data = *((uint32_t *) ctrl_data_in->data.poke_args.addr);
break;