libgs.database.CommsLog¶
-
class
libgs.database.CommsLog(db='sqlite:///libgs.db', binary_fmt='hex', disk_path='.', **kwargs)[source]¶ Database class for storing communications with the satellite.
The columns are:
nid The norad id of the object that is being communicated with pass_id The current pass ID orig The actorthat sent the messagedest The actorthat received the messagemsg The message itself Additionally a primary key and timestamp is automatically added to each record.
See
Databasefor description of available argumentsMethods
get([limit, tstamps])Get the communication log. put(nid, pass_id, orig, dest, msg)Add new item to the log Attributes
ACTORSName of the various actors that send or receive communications Inherited from base class
count_rows(table)Return the number of rows in a table create_table(name, *columns, **kwargs)Set up the columns and add a unique key. get_df(table[, where, limit, orderby, …])Get data from communications database as a pandas.DataFrameobjectget_file(fname)Grab a file resource and return the bytes or string (.bin or .txt) put_df(table, df[, index, if_exists])Add dataframe to database, appending metadata for when it was added