fork download
  1. #include <string>
  2. struct IICBus {
  3. IICBus(const std::string&, int, const std::string&) {}
  4. IICBus(const IICBus&);
  5. };
  6.  
  7. struct IICStepper {
  8. IICStepper(IICBus&, int, const std::string&) {}
  9. IICStepper(const IICStepper&) {}
  10. };
  11.  
  12. class Motor_control
  13. {
  14. public:
  15. Motor_control();
  16. /* ... */
  17. private:
  18. IICBus bus ;
  19. IICStepper stepper ;
  20. IICStepper stepper_r ;
  21. IICStepper stepper_l ;
  22. };
  23.  
  24. Motor_control::Motor_control() :
  25. bus ("/dev/i2c-2",0,""),
  26. stepper (bus,0x00, "Global addr"),
  27. stepper_r (bus,0x6e, "Stepper Modul"),
  28. stepper_l (bus,0x66, "Stepper Modul")
  29. {
  30. }
  31.  
  32. int main () {}
  33.  
Success #stdin #stdout 0.02s 2720KB
stdin
Standard input is empty
stdout
Standard output is empty