discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Discuss-gnuradio] Read file metadata


From: Yan Huang
Subject: [Discuss-gnuradio] Read file metadata
Date: Thu, 14 Apr 2016 11:44:39 +0000

Hi all,

 

I’m using Message Strobe to control UHD: USRP Source to receive signal with specified frequency(2.4GHz), but I find flow graph start running before Message Strobe set the frequency as 2.4 GHz.

 

Message Strobe -> UHD: USRP Source ->File Sink

 

So I want to use stream tag to know the time of first item with 2.4GHz. I think I can change File Sink to File Meta Sink to receive the ‘rx_time’ stored in ‘tag_sense1.hdr’ file(attached), and I use the existing program called ‘gr_read_file_metadata’ to read out the header information, but it comes out an error:

 

File "tag_sense1.hdr", line 1

SyntaxError: Non-ASCII character '\xb5' in file tag_sense1.hdr on line 2, but no encoding declared; see http://www.python.org/peps/pep-0263.html for details

 

I have checked the link, but I don’t understand what’s the encoding information of the python source file. Do need to add # -*- coding: <encoding name> -*- to the source file?

 

I problems are:

 

1.       How can I read the’ .hdr’ file?

2.       Am I right to use file meta sink to get the start receiving time?

3.       Do I need to add stream tag and then read it out using other blocks in this scenario?

 

Any advice will be appreciated. Many thanks in advance.

 

Best Regards,

 

Yan

 



This message and any attachment are intended solely for the addressee
and may contain confidential information. If you have received this
message in error, please send it back to me, and immediately delete it. 

Please do not use, copy or disclose the information contained in this
message or in any attachment.  Any views or opinions expressed by the
author of this email do not necessarily reflect the views of the
University of Nottingham.

This message has been checked for viruses but the contents of an
attachment may still contain software viruses which could damage your
computer system, you are advised to perform your own checks. Email
communications with the University of Nottingham may be monitored as
permitted by UK legislation.

Attachment: tag_sense1.hdr
Description: tag_sense1.hdr

Attachment: gr_read_file_metadata
Description: gr_read_file_metadata


reply via email to

[Prev in Thread] Current Thread [Next in Thread]