Class Interface#
Defined in File acam_interface.h
Class Documentation#
-
class Interface#
interface class for acam
This class defines the interface for the acam system and contains the functions used to communicate with it. The Target class is my friend so I share an instance of my *this pointer so that he can call my functions.
Public Functions
-
inline Interface()#
-
inline bool is_target_acquired()#
-
inline std::string get_imagename()#
-
inline std::string get_wcsname()#
-
inline void set_imagename(std::string name_in)#
-
inline void set_wcsname(std::string name_in)#
-
inline long init_pubsub(const std::initializer_list<std::string> &topics = {})#
for calling Python fpoffsets, defined in ~/Software/common/skyinfo.h
-
inline void start_subscriber_thread()#
-
inline void stop_subscriber_thread()#
-
void handletopic_snapshot(const nlohmann::json &jmessage)#
-
void handletopic_tcsd(const nlohmann::json &jmessage)#
-
void handletopic_targetinfo(const nlohmann::json &jmessage)#
-
void handletopic_slitd(const nlohmann::json &jmessage)#
-
long bin(std::string args, std::string &retstring)#
-
void publish_snapshot()#
-
void publish_status(bool force = false)#
-
void publish_temperature()#
publish only the andor temperature on Topic::ACAMD (periodic)
-
void request_snapshot()#
-
bool wait_for_snapshots()#
-
long initialize_python_objects()#
-
long test_image()#
provides interface to initialize all Python modules for objects in this class
-
long open(std::string args, std::string &help)#
-
long isopen(std::string component, bool &state, std::string &help)#
wrapper to open all acam-related hardware components
-
bool isopen(std::string component)#
wrapper for acam-related hardware components
-
void close()#
wrapper for acam-related hardware components
-
long close(std::string component, std::string &help)#
-
long tcs_init(std::string args, std::string &retstring)#
-
long framegrab(std::string args, std::string &retstring)#
initialize connection to TCS
-
long framegrab_fix(std::string args, std::string &retstring)#
wrapper to control Andor frame grabbing
-
long saveframes(std::string args, std::string &retstring)#
wrapper to control Andor frame grabbing
-
long skipframes(std::string args, std::string &retstring)#
set/get number of frame grabgs to save during acquisition
-
long image_quality(std::string args, std::string &retstring)#
set/get number of frame grabgs to skip before target acquisition
-
long solve(std::string args, std::string &retstring)#
wrapper for Astrometry::image_quality
-
long guider_settings_control()#
wrapper for Astrometry::solve
-
long guider_settings_control(std::string args, std::string &retstring)#
get guider settings and push to Guider GUI display
-
long avg_frames(std::string args, std::string &retstring)#
set or get and push to Guider GUI display
-
long offset_period(std::string args, std::string &retstring)#
-
long acquire(std::string args, std::string &retstring)#
-
long target_coords(std::string args, std::string &retstring)#
-
long offset_cal(const std::string args, std::string &retstring)#
set or get target coords for acquire
-
long offset_goal(const std::string args, std::string &retstring)#
-
long put_on_slit(const std::string args, std::string &retstring)#
-
void preserve_framegrab()#
-
long shutdown(std::string args, std::string &retstring)#
-
long test(std::string args, std::string &retstring)#
-
long exptime(const std::string args, std::string &retstring)#
-
long fan_mode(std::string args, std::string &retstring)#
-
long assemble_header_info()#
-
inline void init_names()#
Public Members
-
std::string acquire_mode = ""#
-
bool is_acquired = false#
-
int nacquired = 0#
-
int attempts = 0#
-
std::string filter = ""#
-
std::string cover = ""#
-
std::string motion_host#
-
int motion_port#
-
std::atomic<bool> should_framegrab_run#
set if framegrab loop should run
-
std::atomic<bool> is_framegrab_running#
set if framegrab loop is running
-
std::atomic<bool> is_shutting_down#
set during shutdown
-
std::atomic<int> nskip_before_acquire#
number of frame grabs to skip before using for target acquisition
-
std::atomic<int> nsave_preserve_frames#
number of frames to preserve (normally overwritten)
these are set by Interface::saveframes()
-
std::atomic<int> nskip_preserve_frames#
number of frames to skip before saving nsave⦠frames
-
std::condition_variable newframe#
-
std::mutex newframe_mutex#
-
std::atomic<bool> newframe_ready#
-
std::string tcsname#
-
bool is_tcs_open#
-
double angle_scope#
-
std::string ra_scope_hms#
-
std::string dec_scope_dms#
-
double ra_scope_h#
-
double dec_scope_d#
-
double offsetra#
-
double offsetdec#
-
double az#
-
double telfocus#
-
double airmass#
-
std::mutex tcsdata_mtx#
-
std::mutex snapshot_mtx#
-
std::unordered_map<std::string, bool> snapshot_status#
-
nlohmann::json tcs_jmessage#
JSON message containing TCS telemetry.
-
std::string publisher_address#
publish socket endpoint
-
std::string publisher_topic#
my default topic for publishing
-
std::string subscriber_address#
subscribe socket endpoint
-
std::vector<std::string> subscriber_topics#
list of topics I subscribe to
-
std::atomic<bool> is_subscriber_thread_running#
is my subscriber thread running?
-
std::atomic<bool> should_subscriber_thread_run#
should my subscriber thread run?
-
std::unordered_map<std::string, std::function<void(const nlohmann::json&)>> topic_handlers#
maps a handler function to each topic
-
GuideManager guide_manager#
-
MotionInterface motion#
-
Astrometry astrometry#
this object provides the interface to the filter and dust cover
-
TcsDaemonClient tcsd#
instantiate a FITS container object
-
inline Interface()#