Skip to content
Stanislav Barantsev edited this page Nov 30, 2021 · 4 revisions

The API of the GSC has changed since the time of the Individual Report. In addition to /observation and /calibration, the new calls GET /antenna & POST /antenna have been added. These calls make it possible to send the commands to move the antenna or read its current position. This was done to demonstrate a practical application of Leanspace’s Commands subsystem for customers. The presentation scenario was to send a command to the ISU GS and to see the antenna moving in real-time (as the reader may remember, this is possible due to the web camera on the rooftop of the ISU).


GET /observation

Get a state of all satellites scheduled: their AOS, LOS, date and exact time of the pass, the actual elevation over the horizon


POST /observation

Schedule a satellite with specific parameters

{                              
    "observation": {                   
        "satellite": [          
            {     
                "enabled": true,
                "min_elevation": 10.0,
                "frequency": 145935000,
                "priority": 1,
                "network_port": 7979,
                "name": "FUNCUBE-1",   
                "network_addr": "127.0.0.1",
                "modulation": {             
                    "type": "bpsk",   
                    "bpsk_manchester": false,
                    "bpsk_differential": true,
                    "bandwidth": 20000,
                    "baud_rate": 1200
                },                     
                "deframer": {   
                    "short_frames": false,
                    "crc16": false,
                    "type": "ao-40"
                }
            },
            {
                "enabled": true,     
                "min_elevation": 10.0,      
                "name": "NAYIF-1",    
                "priority": 3,         
                "network_port": 7981,
                "frequency": 145940000,
                "network_addr": "127.0.0.1",
                "modulation": {
                    "bandwidth": 15000,
                    "type": "bpsk",
                    "baud_rate": 1200,
                    "bpsk_differential": true,
                    "bpsk_manchester": false
                },
                "deframer": {
                    "short_frames": false,
                    "crc16": false,
                    "type": "ao-40"
                }
            },            
            {                                
                "frequency": 137620000,          
                "name": "NOAA 15",              
                "network_addr": "127.0.0.1",
                "min_elevation": 30.0,
                                "network_port": 7985,
                "priority": 5,
                "enabled": true,
                "modulation": {
                    "bandwidth": 35000,
                    "type": "fm"
                },
                "deframer": {
                    "type": "fm"
                }
            },
            {
                "frequency": 137912500,
                "name": "NOAA 18",
                "network_addr": "127.0.0.1",
                "min_elevation": 30.0,
                "network_port": 7985,
                "priority": 6,
                "enabled": true,
                "modulation": {
                    "bandwidth": 35000,
                    "type": "fm"
                },
                "deframer": {
                    "type": "fm"
                }
            },
            {
                "network_port": 7985,
                "network_addr": "127.0.0.1",
                "min_elevation": 30.0,
                "frequency": 137100000,
                "priority": 7,
                "enabled": true,
                "name": "NOAA 19",
                "modulation": {
                    "bandwidth": 35000,
                    "type": "fm"
                },
                "deframer": {
                    "type": "fm"
                }
            }
        ]
    }
}

The typical response is:

{
    "satellite": [
        {
            "name": "NOAA 19",
            "max elevation": 73.413566589355469,
            "frequency": 137100000,
            "AOS": "25 November 2021 - 07:08AM GMT",
            "LOS": "25 November 2021 - 07:24AM GMT"
        },
        {
            "name": "NOAA 18",
            "max elevation": 42.980155944824219,
            "frequency": 137912500,
            "AOS": "25 November 2021 - 09:21AM GMT",
            "LOS": "25 November 2021 - 09:37AM GMT"
        },
        {
            "name": "NOAA 15",
            "max elevation": 30.966672897338867,
            "frequency": 137620000,
            "AOS": "25 November 2021 - 06:31AM GMT",
            "LOS": "25 November 2021 - 06:45AM GMT"
        },
        {
            "name": "NAYIF-1",
            "max elevation": 69.686317443847656,
            "frequency": 145940000,
            "AOS": "25 November 2021 - 09:45AM GMT",
            "LOS": "25 November 2021 - 09:57AM GMT"
        },
        {
            "name": "FUNCUBE-1",
            "max elevation": 55.217613220214844,
            "frequency": 145935000,
            "AOS": "25 November 2021 - 03:48AM GMT",
            "LOS": "25 November 2021 - 04:01AM GMT"
        }
    ]
}

POST /calibration
{
    "calibration": {
        "azimuth": true,
        "elevation": true
    }
}

Force trigger of calibration. Used to remove the aggregated error of the antenna rotators


GET /status

The typical response is:

{
    "status": {
        "uptime": 0,
        "satellites_scheduled": 5,
        "satellites_tracked": 0,
        "satellites_preempted": 0,
        "satellites_vhf": 0,
        "satellites_uhf": 0,
        "azimuth": 139.60000610351562,
        "elevation": 0.60000002384185791,
        "satellite_next_aos": "26 November 2021 - 09:31PM GMT",
        "satellite_next_name": "NAYIF-1",
        "state_code": 0,
        "state": "waiting"
    }
}

Current status of the entire ground station. Includes statistics of the operation, state, and the next satellite’s pass. If the pass is in progress, it also sends a percentage of the completed tracking.


GET /antenna

Obtain current antenna position for both azimuth and elevation planes


POST /antenna

Move the antenna to a specified position. Azimuth and elevation are required.

{
    "position": {
        "azimuth": 220.0,
        "elevation": 45.0
    }
}