Esempio n. 1
0
 public function home($axis = 'ALL')
 {
     $cr = 0;
     $this->load->helper(array('printerstate', 'errorcode'));
     $axis = strtoupper($axis);
     $cr = PrinterState_homing($axis);
     if ($cr == ERROR_OK) {
         $this->output->set_status_header(200);
         return;
     }
     $this->output->set_status_header(403);
     return;
 }
Esempio n. 2
0
 public function home()
 {
     $cr = 0;
     $abb_axis = $this->input->get('a');
     $this->load->helper('printerstate');
     if ($abb_axis) {
         $cr = PrinterState_homing($abb_axis);
     } else {
         $cr = PrinterState_homing('all');
     }
     $this->_return_cr($cr);
     return;
 }