mirror of
https://github.com/ttrftech/NanoVNA.git
synced 2025-12-06 03:31:59 +01:00
make working area of shell thread static
This commit is contained in:
parent
9a63892480
commit
1f64bb759b
9
main.c
9
main.c
|
|
@ -1061,7 +1061,8 @@ static void cmd_stat(BaseSequentialStream *chp, int argc, char *argv[])
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#define SHELL_WA_SIZE THD_WORKING_AREA_SIZE(454)
|
#define SHELL_WA_SIZE THD_WORKING_AREA_SIZE(400)
|
||||||
|
static THD_WORKING_AREA(waThread2, SHELL_WA_SIZE);
|
||||||
|
|
||||||
static const ShellCommand commands[] =
|
static const ShellCommand commands[] =
|
||||||
{
|
{
|
||||||
|
|
@ -1178,9 +1179,9 @@ int main(void)
|
||||||
while (1) {
|
while (1) {
|
||||||
if (SDU1.config->usbp->state == USB_ACTIVE) {
|
if (SDU1.config->usbp->state == USB_ACTIVE) {
|
||||||
//palSetPad(GPIOC, GPIOC_LED);
|
//palSetPad(GPIOC, GPIOC_LED);
|
||||||
thread_t *shelltp = chThdCreateFromHeap(NULL, SHELL_WA_SIZE,
|
thread_t *shelltp = chThdCreateStatic(waThread2, sizeof(waThread2),
|
||||||
"shell", NORMALPRIO + 1,
|
NORMALPRIO + 1,
|
||||||
shellThread, (void *)&shell_cfg1);
|
shellThread, (void *)&shell_cfg1);
|
||||||
chThdWait(shelltp); /* Waiting termination. */
|
chThdWait(shelltp); /* Waiting termination. */
|
||||||
//palClearPad(GPIOC, GPIOC_LED);
|
//palClearPad(GPIOC, GPIOC_LED);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue