Commit ceda0a24 authored by xtof's avatar xtof

initial commit

parent 892b15bd
This diff is collapsed.
This diff is collapsed.
<xs:schema attributeFormDefault="unqualified" elementFormDefault="qualified" xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="AmsatList" type="AmsatListType"/>
<xs:element name="Speed">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="2400"/>
<xs:enumeration value="1200"/>
<xs:enumeration value="9600"/>
<xs:enumeration value="38400"/>
<xs:enumeration value="400"/>
<xs:enumeration value="19200"/>
<xs:enumeration value="4800 9600"/>
<xs:enumeration value="1000"/>
<xs:enumeration value="4800"/>
<xs:enumeration value="256000"/>
<xs:enumeration value="230000"/>
</xs:restriction>
</xs:simpleType>
<xs:element name="Status">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="Operational"/>
<xs:enumeration value="decayed"/>
<xs:enumeration value="No operational"/>
</xs:restriction>
</xs:simpleType>
</xs:element>
<xs:element name="SatelliteInformationStatus">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="Draft"/>
<xs:enumeration value="Verified"/>
</xs:restriction>
</xs:simpleType>
</xs:element>
<xs:element name="Mode" minOccurs="0">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="SSB/CW"/>
<xs:enumeration value="FM"/>
<xs:enumeration value="SSB PSK31"/>
</xs:restriction>
</xs:simpleType>
</xs:element>
<xs:complexType name="ModesType">
<xs:sequence>
<xs:element type="xs:string" name="Mode"/>
<xs:element type="xs:string" name="Speed" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="BeaconsType">
<xs:sequence>
<xs:element type="xs:string" name="Name"/>
<xs:element type="xs:string" name="Frequency"/>
<xs:element type="ModesType" name="Modes" maxOccurs="unbounded" minOccurs="0"/>
<xs:element type="xs:short" name="Speed" minOccurs="0"/>
<xs:element type="xs:string" name="CallSign" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="RadioDataType">
<xs:sequence>
<xs:element type="BeaconsType" name="Beacons" maxOccurs="unbounded" minOccurs="0"/>
<xs:element type="TranspondersType" name="Transponders" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="SatellitesType">
<xs:choice maxOccurs="unbounded" minOccurs="0">
<xs:element type="xs:string" name="Name"/>
<xs:element type="xs:string" name="NasaID"/>
<xs:element type="xs:string" name="Status"/>
<xs:element type="LaunchDataType" name="LaunchData"/>
<xs:element type="RadioDataType" name="RadioData"/>
<xs:element type="xs:string" name="OSCARNumber"/>
<xs:element type="xs:date" name="UpdateDate"/>
<xs:element type="xs:string" name="SatelliteInformationStatus"/>
<xs:element type="InformationType" name="Information"/>
<xs:element type="TelemetryDataType" name="TelemetryData"/>
<xs:element type="xs:string" name="Description"/>
</xs:choice>
</xs:complexType>
<xs:complexType name="LaunchDataType">
<xs:sequence>
<xs:element type="xs:date" name="LaunchDate"/>
<xs:element type="xs:string" name="LaunchingSite"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="InformationType">
<xs:sequence>
<xs:element type="xs:string" name="Title"/>
<xs:element type="xs:string" name="Value"/>
<xs:element name="Description" maxOccurs="unbounded" minOccurs="0">
<xs:complexType>
<xs:simpleContent>
<xs:extension base="xs:string">
<xs:attribute type="xs:string" name="lang" use="optional"/>
</xs:extension>
</xs:simpleContent>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
<xs:complexType name="DescriptionType">
<xs:simpleContent>
<xs:extension base="xs:string">
<xs:attribute type="xs:string" name="lang" use="optional"/>
</xs:extension>
</xs:simpleContent>
</xs:complexType>
<xs:complexType name="FrequencyUplinkType">
<xs:sequence>
<xs:element type="xs:int" name="FrequencyBegin"/>
<xs:element type="xs:int" name="FrequencyEnd" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="FrequencyDownlinkType">
<xs:sequence>
<xs:element type="xs:int" name="FrequencyBegin"/>
<xs:element type="xs:int" name="FrequencyEnd" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="TranspondersType">
<xs:sequence>
<xs:element type="xs:string" name="Name"/>
<xs:element type="FrequencyUplinkType" name="FrequencyUplink"/>
<xs:element type="FrequencyDownlinkType" name="FrequencyDownlink"/>
<xs:element type="xs:string" name="Mode" minOccurs="0"/>
<xs:element type="xs:string" name="Inverted" minOccurs="0"/>
<xs:element type="xs:float" name="Tone" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="DescriptionURLType">
<xs:sequence>
<xs:element type="xs:string" name="Title"/>
<xs:element type="xs:string" name="Value"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ReportURLType">
<xs:sequence>
<xs:element type="xs:string" name="Title"/>
<xs:element type="xs:string" name="Value"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="TelemetryDataType">
<xs:sequence>
<xs:element type="DescriptionURLType" name="DescriptionURL" maxOccurs="unbounded" minOccurs="0"/>
<xs:element type="ReportURLType" name="ReportURL" minOccurs="0"/>
<xs:element type="xs:string" name="ReportEmail" minOccurs="0"/>
<xs:element type="xs:string" name="SoftwareURL" minOccurs="0"/>
<xs:element type="xs:string" name="Description" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="AmsatListType">
<xs:sequence>
<xs:element type="SatellitesType" name="Satellites" maxOccurs="unbounded" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
</xs:schema>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd">
<book lang="en">
<!-- Please remark the "lang" attribute here -->
<bookinfo>
<title>AMATEUR SATELLITE XML Schema</title>
</bookinfo>
<chapter id="Overview">
<title>Overview</title>
<para>"AMATEUR SATELLITE XML Schema" project is to define a data structure in order to help Satellite hamradio people to share information about Amateur Satellites. </para>
<para> Amateur Satellites description is embedded in an XML file. AMATEUR SATELLITE XML Schema defined the way to organise data. It could be used to validate an Amateur Satellites description. The project also maintains a reference Amateur Satellites description (XML format). It also provide some XLT file in order to build HTML file as a sample.</para>
</chapter>
<chapter id="Needs">
<title>Needs</title>
<section>
<title>Issue</title>
<para>When you want to exploit amateur satellite, you have a lot of information available on internet, but this information is often partial and spread. It is difficult to answer to some basic question like : </para>
<itemizedlist>
<listitem><para>What is the current status of the satellite ?</para></listitem>
<listitem><para>What is the frequency, mode ... ? </para></listitem>
<listitem><para>How to obtain QSL ? </para></listitem>
<listitem><para>What is the telemetry format ? </para></listitem>
<listitem><para>Where to send report ? </para></listitem>
</itemizedlist>
<para> Some ham radio people exploit amateur satellite outside. An off-line data referential is needed. </para>
</section>
<section>
<title>requirements</title>
<para>From issue and main uses cases, the goal of the project is not to provide an application but a way to manage an amateur satellite data referential.
main requirements are :
</para>
<itemizedlist>
<listitem><para>[req-001] Amateur satellite data referential structure shall be defined </para></listitem>
<listitem><para>[req-002] Amateur satellite data referential shall be human readable (eg txt, html, pdf..)</para></listitem>
<listitem><para>[req-003] Amateur satellite data referential shall be extensible</para></listitem>
<listitem><para>[req-004] Amateur satellite data referential shall allows to exchange data with amateur radio application (eg prediction satellite tools) </para></listitem>
<listitem><para>[req-005] Amateur satellite data referential shall be used off-line</para></listitem>
<listitem><para>[req-006] Amateur satellite data referential shall be based on open sources tools and format</para></listitem>
</itemizedlist>
</section>
</chapter>
<chapter id="Technicalsolution">
<title>Technical solution</title>
<section>
<title>Technical choice</title>
<para>After different test and POC (proof of Concept), the final choice is a solution based on XML technology. In order to answer to the main requirements [req-001] to [req-006]. In detail, the technical solution is </para>
<itemizedlist>
<listitem><para> XML Schema file in order to define data referential structure [req-001] [req-003]</para></listitem>
<listitem><para> XSLT in order to manipulate data [req-002] [req-004]</para></listitem>
<listitem><para> XML File for data [req-005]</para></listitem>
</itemizedlist>
<para>All artefact produce for this project are publish on open source licences [TBD] - [req-006] </para>
</section>
</chapter>
<chapter id="Deliverable">
<title>Deliverable</title>
<section>
<title>AMSATSaletlliteList XML Schema file </title>
<para> XML Schema file describe the definition of the data structure used for the satellite description. This definition is a guideline for anybody who want to describe a satellite in the XML database.
</para>
</section>
<section>
<title>AMSATSaletlliteList XML File </title>
<para>AMSATSaletlliteList XML File contents the description of the Amateur satellite. The syntax of the file is validated with the AMSATSaletlliteList XML Schema file. The file contents only satellite using frequency allocated to Hamradio.
</para>
</section>
<section>
<title>AMSATSaletlliteList XSD Files </title>
<para> AMSATSaletlliteList XSD Files give example in order to produce human readable output or configuration file for Ham radio tools (eg satellite prediction tools). With the current version, following XSD files is: </para>
<itemizedlist>
<listitem><para>HTML5.XSD : generate one web page by satellite</para></listitem>
<listitem><para>Gpredict.XSD : generate one configuration file by satellite for Gpredict</para></listitem>
</itemizedlist>
</section>
</chapter>
<chapter id="Tools">
<title>Tools</title>
<section>
<para> Following tools are used by the project: </para>
<itemizedlist>
<listitem><para><ulink url="http://www.ora.com/catalog/tex/"><citetitle>Notepad++</citetitle></ulink>.</para></listitem>
<listitem><para><ulink url="http://eclipse.org"><citetitle>Eclipse</citetitle></ulink></para></listitem>
<listitem><para><ulink url="http://eclipse.org"><citetitle>Eclipse</citetitle></ulink></para></listitem>
</itemizedlist>
</section>
<section>
<para> Following technology is used by the project:</para>
<itemizedlist>
<listitem><para><ulink url="http://www.w3.org/XML/"><citetitle>XML</citetitle></ulink>.</para></listitem>
<listitem><para><ulink url="http://www.w3.org/TR/xmlschema11-1"><citetitle>XML Schema</citetitle></ulink></para></listitem>
<listitem><para><ulink url="http://www.w3.org/Style/XSL/"><citetitle> Extensible Stylesheet Language Family (XSL)</citetitle></ulink></para></listitem>
</itemizedlist>
</section>
</chapter>
</book>
\ No newline at end of file
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="2.0" exclude-result-prefixes="#all" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:csv="csv:csv" xmlns:pdts="pdts:pdts">
<xsl:strip-space elements="*"/>
<xsl:output name="text" method="text" indent="no" omit-xml-declaration="yes" encoding="UTF-8"/>
<xsl:template match="/"> <!-- Match the root -->
<xsl:for-each select="AmsatList/Satellites">
<xsl:variable name="code" select="@Code"/>
<xsl:result-document href="SatellitePage/{NasaID}.txt" format="text">
<xsl:apply-templates select="RadioData/Beacons"/>
<xsl:apply-templates select="RadioData/Transponders"/>
</xsl:result-document>
</xsl:for-each>
</xsl:template>
<xsl:template match="RadioData/Beacons">
<xsl:text>[</xsl:text><xsl:value-of select="Name"/><xsl:text>]</xsl:text><xsl:text>&#xA;</xsl:text>
<xsl:text>DOWN_LOW=</xsl:text> <xsl:value-of select='format-number(number(Frequency), "########")' /> <xsl:text>&#xA;</xsl:text>
</xsl:template>
<xsl:template match="RadioData/Transponders">
<xsl:text>[</xsl:text><xsl:value-of select="Name"/> <xsl:text> </xsl:text><xsl:apply-templates select="Mode"/> <xsl:text>]</xsl:text><xsl:text>&#xA;</xsl:text>
<xsl:text>UP_LOW=</xsl:text> <xsl:value-of select='format-number(number(FrequencyUplink/FrequencyBegin), "########")' /> <xsl:text>&#xA;</xsl:text>
<xsl:if test="FrequencyUplink/FrequencyEnd">
<xsl:text>UP_HIGH=</xsl:text><xsl:value-of select='format-number(number(FrequencyUplink/FrequencyEnd), "########")' /> <xsl:text>&#xA;</xsl:text>
</xsl:if>
<xsl:text>DOWN_LOW=</xsl:text> <xsl:value-of select='format-number(number(FrequencyDownlink/FrequencyBegin), "########")' /> <xsl:text>&#xA;</xsl:text>
<xsl:if test="FrequencyDownlink/FrequencyEnd">
<xsl:text>DOWN_HIGH=</xsl:text> <xsl:value-of select='format-number(number(FrequencyDownlink/FrequencyEnd), "########")' /> <xsl:text>&#xA;</xsl:text>
</xsl:if>
<xsl:if test="Inverted">
<xsl:text>INVERT=</xsl:text><xsl:apply-templates select="Inverted"/> <xsl:text>&#xA;</xsl:text>
</xsl:if>
<xsl:if test="Tone">
<xsl:text>Tone=</xsl:text><xsl:apply-templates select="Tone"/> <xsl:text>&#xA;</xsl:text>
</xsl:if>
</xsl:template>
</xsl:stylesheet>
\ No newline at end of file
This diff is collapsed.
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="2.0" exclude-result-prefixes="#all" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:csv="csv:csv" xmlns:pdts="pdts:pdts">
<xsl:template match="/"> <!-- Match the root -->
<xsl:for-each select="AmsatList/Satellites">
<xsl:result-document method="xml" href="satellite_{NasaID}_{Name}.xml">
<xsl:copy-of select="../@* | ." />
</xsl:result-document>
</xsl:for-each>
</xsl:template>
</xsl:stylesheet>
\ No newline at end of file
java -jar C:\projet\SaxonHE9-8-0-14J\saxon9he.jar -s:../Documentation/AMSATLIST_docbook.xml -xsl:../Templates/XSLT/SplitAmsatListFile.xsl -o:../DatabaseFile/out.txt
\ No newline at end of file
java -jar C:\projet\SaxonHE9-8-0-14J\saxon9he.jar -s:../data/AmateurSatellites.xml -xsl:../Templates/XSLT/HtmlFileDescription.xsl -o:../site/index.html
\ No newline at end of file
java -jar C:\projet\SaxonHE9-8-0-14J\saxon9he.jar -s:../data/AmateurSatellites.xml -xsl:../Templates/XSLT/SplitAmsatListFile.xsl -o:../DatabaseFile/out.txt
\ No newline at end of file
java -jar C:\Applications\SaxonHE9-6-0-5J\saxon9he.jar -s:../data/AmateurSatellites.xml -xsl:../Templates/XSLT/GpredictTRSPDatabase.xsl -o:../GpredictTRSPDatabase/out.txt
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment