Continue to write USB protocol documentation and fix bugs in code.

This commit is contained in:
2024-08-16 12:37:11 +03:00
parent 018f0d4b33
commit b10fb37c58
19 changed files with 321 additions and 65 deletions

View File

@@ -8,10 +8,10 @@
#define WAL __attribute__ ((weak, alias ("__f1")))
#endif
char lastcmd[CMD_MAXLEN + 1];
static int __f1(uint32_t _U_ h, char _U_ *a){return 1;}
char lastcmd[CMD_MAXLEN + 1];
int fn_abspos(uint32_t _U_ hash, char _U_ *args) WAL; // "abspos" (3056382221)
int fn_accel(uint32_t _U_ hash, char _U_ *args) WAL; // "accel" (1490521981)
@@ -76,6 +76,8 @@ int fn_gpio(uint32_t _U_ hash, char _U_ *args) WAL; // "gpio" (4286324660)
int fn_gpioconf(uint32_t _U_ hash, char _U_ *args) WAL; // "gpioconf" (1309721562)
int fn_help(uint32_t _U_ hash, char _U_ *args) WAL; // "help" (4288288686)
int fn_maxspeed(uint32_t _U_ hash, char _U_ *args) WAL; // "maxspeed" (1498078812)
int fn_maxsteps(uint32_t _U_ hash, char _U_ *args) WAL; // "maxsteps" (1506667002)
@@ -244,6 +246,9 @@ int parsecmd(const char *str){
case CMD_GPIOCONF:
return fn_gpioconf(h, args);
break;
case CMD_HELP:
return fn_help(h, args);
break;
case CMD_MAXSPEED:
return fn_maxspeed(h, args);
break;