Skip to content

Commit

Permalink
fixed for physical devices
Browse files Browse the repository at this point in the history
  • Loading branch information
mehrdadh committed May 21, 2021
1 parent 90ae471 commit 8c7a4be
Show file tree
Hide file tree
Showing 8 changed files with 15 additions and 122 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
# For intrinsics used by generated optimized operators.
CONFIG_CMSIS_DSP=y

# Required for Cortex-M33 devices.
# For AOT runtime which requires lots of function call.
CONFIG_MAIN_STACK_SIZE=18000

# For random number generation.
Expand Down
30 changes: 0 additions & 30 deletions apps/microtvm/zephyr/aot_demo/boards/nucleo_f746zg.conf

This file was deleted.

29 changes: 0 additions & 29 deletions apps/microtvm/zephyr/aot_demo/boards/qemu_riscv32.conf

This file was deleted.

25 changes: 0 additions & 25 deletions apps/microtvm/zephyr/aot_demo/boards/qemu_riscv64.conf

This file was deleted.

5 changes: 2 additions & 3 deletions apps/microtvm/zephyr/aot_demo/boards/qemu_x86.conf
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,5 @@
CONFIG_TEST_RANDOM_GENERATOR=y
CONFIG_TIMER_RANDOM_GENERATOR=y

# Default stack size is 1k, this is required for debug mode and
# for AOT mode.
CONFIG_MAIN_STACK_SIZE=18000
# Default stack size is 1k, this is required for debug mode.
CONFIG_MAIN_STACK_SIZE=2000
28 changes: 0 additions & 28 deletions apps/microtvm/zephyr/aot_demo/boards/stm32f746g_disco.conf

This file was deleted.

2 changes: 1 addition & 1 deletion apps/microtvm/zephyr/aot_demo/src/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ void main(void) {
write_serial(g_wakeup_sequence, 12);

// Wait for start command
while(true) {
while (true) {
int bytes_read = uart_rx_buf_read(main_rx_buf, sizeof(main_rx_buf));
if (bytes_read > 0) {
memcpy((char*)cmd_buf + g_cmd_buf_ind, main_rx_buf, bytes_read);
Expand Down
16 changes: 11 additions & 5 deletions tests/micro/zephyr/test_zephyr_aot.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,11 +142,17 @@ def _create_header_file(tensor_name, npy_data, output_path):

def _read_line(fd):
data = ""
new_c = ""
while new_c != "\n":
new_c = fd.read(1, timeout_sec=10)
new_c = new_c.decode("ascii")
data = data + new_c
new_line = False
while True:
if new_line:
break
new_data = fd.read(1, timeout_sec=10)
for item in new_data:
new_c = chr(item)
data = data + new_c
if new_c == "\n":
new_line = True
break
return data


Expand Down

0 comments on commit 8c7a4be

Please sign in to comment.