Skip to content

Commit

Permalink
Add -v stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
ka9q committed Apr 18, 2023
1 parent 4addf28 commit 8605553
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions powers.c
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,8 @@ int main(int argc,char *argv[]){

}
resolve_mcast(argv[optind],&Metadata_dest_address,DEFAULT_STAT_PORT,Iface,sizeof(Iface));
if(Verbose)
fprintf(stderr,"%s -> %s\n",argv[optind],formatsock(&Metadata_dest_address));
Status_fd = listen_mcast(&Metadata_dest_address,Iface);
if(Status_fd == -1){
fprintf(stderr,"Can't listen to mcast status %s\n",argv[optind]);
Expand Down Expand Up @@ -124,6 +126,8 @@ int main(int argc,char *argv[]){

encode_eol(&bp);
int const command_len = bp - buffer;
if(Verbose > 1)
dump_metadata(buffer+1,command_len-1);
if(send(Ctl_fd, buffer, command_len, 0) != command_len){
perror("command send");
usleep(1000000);
Expand Down Expand Up @@ -163,6 +167,9 @@ int main(int argc,char *argv[]){
// This is needed because an initial delay in joining multicast groups produces a burst of buffered responses; investigate this
} while(length < 2 || buffer[0] != 0 || Ssrc != get_ssrc(buffer+1,length-1) || tag != get_tag(buffer+1,length-1));

if(Verbose > 1)
dump_metadata(buffer+1,length-1);

float powers[65536];
uint64_t time;
double r_freq;
Expand Down

0 comments on commit 8605553

Please sign in to comment.