File tree Expand file tree Collapse file tree 1 file changed +30
-30
lines changed Expand file tree Collapse file tree 1 file changed +30
-30
lines changed Original file line number Diff line number Diff line change @@ -599,30 +599,30 @@ void adamNetwork::do_inquiry(fujiCommandID_t inq_cmd)
599599 {
600600 switch (inq_cmd)
601601 {
602- case 0x20 :
603- case 0x21 :
604- case 0x23 :
605- case 0x24 :
606- case 0x2A :
607- case 0x2B :
608- case 0x2C :
609- case 0xFD :
610- case 0xFE :
602+ case FUJICMD_RENAME :
603+ case FUJICMD_DELETE :
604+ case FUJICMD_LOCK :
605+ case FUJICMD_UNLOCK :
606+ case FUJICMD_MKDIR :
607+ case FUJICMD_RMDIR :
608+ case FUJICMD_CHDIR :
609+ case FUJICMD_SCAN_NETWORKS :
610+ case FUJICMD_GET_SSID :
611611 inq_dstats = 0x80 ;
612612 break ;
613- case 0x30 :
613+ case FUJICMD_GETCWD :
614614 inq_dstats = 0x40 ;
615615 break ;
616- case ' Z ' : // Set interrupt rate
616+ case FUJICMD_TIMER : // Set interrupt rate
617617 inq_dstats = 0x00 ;
618618 break ;
619- case ' T ' : // Set Translation
619+ case FUJICMD_TRANSLATION:
620620 inq_dstats = 0x00 ;
621621 break ;
622- case 0x80 : // JSON Parse
622+ case FUJICMD_JSON_PARSE:
623623 inq_dstats = 0x00 ;
624624 break ;
625- case 0x81 : // JSON Query
625+ case FUJICMD_JSON_QUERY:
626626 inq_dstats = 0x80 ;
627627 break ;
628628 default :
@@ -741,49 +741,49 @@ void adamNetwork::adamnet_control_ack()
741741void adamNetwork::adamnet_control_send ()
742742{
743743 uint16_t s = adamnet_recv_length (); // receive length
744- uint8_t c = adamnet_recv (); // receive command
744+ fujiCommandID_t c = adamnet_recv (); // receive command
745745
746746 s--; // Because we've popped the command off the stack
747747
748748 switch (c)
749749 {
750- case ' ' :
750+ case FUJICMD_RENAME :
751751 rename (s);
752752 break ;
753- case ' ! ' :
753+ case FUJICMD_DELETE :
754754 del (s);
755755 break ;
756- case ' * ' :
756+ case FUJICMD_MKDIR :
757757 mkdir (s);
758758 break ;
759- case ' , ' :
759+ case FUJICMD_CHDIR :
760760 set_prefix (s);
761761 break ;
762- case ' 0 ' :
762+ case FUJICMD_GETCWD :
763763 get_prefix ();
764764 break ;
765- case ' E ' :
765+ case FUJICMD_GET_ERROR :
766766 get_error ();
767767 break ;
768- case ' O ' :
768+ case FUJICMD_OPEN :
769769 open (s);
770770 break ;
771- case ' C ' :
771+ case FUJICMD_CLOSE :
772772 close ();
773773 break ;
774- case ' S ' :
774+ case FUJICMD_STATUS :
775775 status ();
776776 break ;
777- case ' W ' :
777+ case FUJICMD_WRITE :
778778 write (s);
779779 break ;
780- case 0xFC :
780+ case FUJICMD_JSON :
781781 channel_mode ();
782782 break ;
783- case 0xFD : // login
783+ case FUJICMD_USERNAME : // login
784784 set_login (s);
785785 break ;
786- case 0xFE : // password
786+ case FUJICMD_PASSWORD : // password
787787 set_password (s);
788788 break ;
789789 default :
@@ -805,10 +805,10 @@ void adamNetwork::adamnet_control_send()
805805 case JSON:
806806 switch (c)
807807 {
808- case ' P ' :
808+ case FUJICMD_PARSE :
809809 json_parse ();
810810 break ;
811- case ' Q ' :
811+ case FUJICMD_QUERY :
812812 json_query (s);
813813 break ;
814814 }
You can’t perform that action at this time.
0 commit comments