#include #include #include #include #include int main() { using namespace simon::a4988; a4988_settings_t a4988_set{ .gpio_en = 17, .gpio_step = 18, .gpio_dir = 22, .gpio_microsteps{ true, true, true } }; c_allegro_4988 a4988(&a4988_set); auto move(std::make_shared()); move->steps = 32768; move->dir = true; move->period_us = 1000; auto cmd = std::static_pointer_cast(move); std::thread t1(std::bind(&c_allegro_4988::run, &a4988)); a4988.post(cmd); t1.join(); std::cout << "Hello camera" << std::endl; return 0; }