Nessuna descrizione
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

data.h 1.1KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. #ifndef _DATA_H_
  2. #define _DATA_H_
  3. #define DATA_SCHEMA_VERSION 1
  4. struct data_config_options {
  5. // in mm/s (%/s for e)
  6. float speed_x, speed_y, speed_z, speed_e;
  7. // in mm/s^2 (%/s^2 for e)
  8. float accel_x, accel_y, accel_z, accel_e;
  9. };
  10. struct data_config_preset {
  11. // number of containers
  12. uint8_t count_x, count_y;
  13. // distance between containers
  14. float distance_x, distance_y; // in mm
  15. // offset of first container
  16. float offset_x, offset_y; // in mm
  17. // height for moves between extrusions
  18. float move_z; // in mm
  19. // height while extruding
  20. float bottom_z, top_z; // in mm
  21. float extrusion_length; // in mm
  22. float extrusion_bottom_wait; // in s
  23. float extrusion_top_wait; // in s
  24. };
  25. void data_init(void);
  26. void data_clear(void);
  27. void data_eeprom_write(void);
  28. bool data_eeprom_read(void);
  29. const char *data_eeprom_error(void);
  30. struct data_config_options *data_options(void);
  31. unsigned int data_preset_count(void);
  32. struct data_config_preset *data_preset(unsigned int i);
  33. bool data_preset_add(struct data_config_preset preset);
  34. bool data_preset_remove(unsigned int i);
  35. #endif // _DATA_H_