Skip to content

Commit

Permalink
add .cvsignore
Browse files Browse the repository at this point in the history
git-svn-id: file:///home/svn/nwr/trunk@48 103c2249-d0a5-da11-ade6-0050bffea3d9
  • Loading branch information
greg committed Mar 22, 2003
1 parent ec76f99 commit 58eab35
Show file tree
Hide file tree
Showing 5 changed files with 124 additions and 0 deletions.
30 changes: 30 additions & 0 deletions .cvsignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
Makefile.in
aclocal.m4
autom4te.cache
configure
config.log
config.h
config.status
Makefile
stamp-h1
.deps

rec
play
squelch
encode
plot
log
streamer
splitter
monitor
downsample
capture
demux
emailer
insertdb

*.html
fips.inc

nwr-*.tar.gz
17 changes: 17 additions & 0 deletions downsample.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#include <stdio.h>

int main(int, char *[])
{
for (;;) {
char buf[4096];
int n = fread(buf, 1, sizeof(buf), stdin);
if (n == 0) {
break;
}
for (int i = 0; i < n/2; i += 2) {
*(short *)(buf+i) = *(short *)(buf+i*2);
}
fwrite(buf, 1, n/2, stdout);
}
return 0;
}
47 changes: 47 additions & 0 deletions eas.xsl
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
<?xml version="1.0"?>
<xsl:stylesheet
version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:xhtml="http://www.w3.org/1999/xhtml"
xmlns="http://www.w3.org/1999/xhtml">

<xsl:output indent="yes" />

<xsl:template match="eas">
<xsl:variable name="station" select="station" />
<xsl:variable name="ustation" select="translate($station, 'abcdefghijklmnopqrstuvwxyz', 'ABCDEFGHIJKLMNOPQRSTUVWXYZ')" />
<html xml:lang="en" lang="en">
<head>
<title><xsl:value-of select="$ustation" />: NOAA Weather Radio</title>
<link href="/style.css" rel="stylesheet" type="text/css" />
</head>
<body>
<h1><xsl:value-of select="$ustation" />: NOAA Weather Radio</h1>
<table border="1">
<tr>
<th>Originator</th>
<th>Event</th>
<th>Issued</th>
<th>Audio</th>
<th>Counties</th>
</tr>
<xsl:for-each select="message">
<tr>
<td><xsl:value-of select="originator" /></td>
<td><xsl:value-of select="event" /></td>
<td><xsl:value-of select="issued" /></td>
<td><a href="{$station}/{filename}">Listen</a></td>
<td>
<xsl:for-each select="area">
<xsl:value-of select="@county" />
<xsl:if test="position() != last()">, </xsl:if>
</xsl:for-each>
</td>
</tr>
</xsl:for-each>
</table>
</body>
</html>
</xsl:template>

</xsl:stylesheet>
10 changes: 10 additions & 0 deletions fips2inc.pl
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/usr/bin/perl -w

my %fips;
while (<>) {
my @a = split /\t/;
$fips{$a[4]*1000+$a[5]} = $a[6];
}
foreach (sort { $a <=> $b } keys %fips) {
print "{$_, \"$fips{$_}\"},\n";
}
20 changes: 20 additions & 0 deletions schema.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
create table message (
id integer primary key,
station varchar(8),
raw varchar(300),
originator char(3),
event char(3),
issued timestamp without time zone,
received timestamp without time zone,
purge timestamp without time zone,
sender varchar(20),
filename varchar(30)
);

create table message_area (
message_id integer references message on delete cascade,
code char(6),
part integer,
state integer,
county integer
);

0 comments on commit 58eab35

Please sign in to comment.