antmicro / litex-vexriscv-tensorflow-lite-demo

TF Lite demo on LiteX/VexRiscv soft RISC-V SoC on a Digilent Arty board
https://antmicro.com/blog/2019/12/tflite-in-zephyr-on-litex-vexriscv/
Apache License 2.0
62 stars 21 forks source link

Tried to load assembly that has been already loaded, LiteX_I2C_Zephyr.cs #32

Open mofanv opened 2 years ago

mofanv commented 2 years ago

Hi,

When I start with renode litex-vexriscv-tflite.resc, it shows with the error

(monitor) s @litex-vexriscv-tflite.resc
No such file Users/litex-vexriscv-tensorflow-lite-demo/renode/LiteX_I2C_Zephyr.cs.
(monitor) 

. I checked that there is no such file even in github repo. So I guess it is generated during building or compiling? Can I ask where to find this file?

Thank you!

mofanv commented 2 years ago

Update:

After I copy-pasted https://github.com/renode/renode-infrastructure/blob/master/src/Emulator/Peripherals/Peripherals/I2C/LiteX_I2C_Zephyr.cs into the folder and run, now the error is:

(monitor) i $CWD/litex-vexriscv-tflite.resc
Errors during compilation or loading:
Tried to load assembly that has been already loaded. Aborting operation.
mateusz-holenko commented 2 years ago

Hi @mofanv, thanks for reporting the issue.

This file was intiialy hosted in this repository and later moved to Renode itself. https://github.com/antmicro/litex-vexriscv-tensorflow-lite-demo/commit/3f1dac40935fb8b996e982163970ce347c1263a9 should fix the problem.

mofanv commented 2 years ago

Thanks @mateusz-holenko .

Above error disappeared, but seems there is another problem. At the machine--0:sysbus.uart, there is only one line, nothing else.

*** Booting Zephyr OS build 0.6.0-98949-gfc8918faa9fa  ***

I guess it is due to that in the host terminal, it shows a non existing peripheral.

~/D/G/l/renode (master)> renode -e "s @litex-vexriscv-tflite.resc"                                         (base)
14:56:00.1530 [INFO] Loaded monitor commands from: /Applications/Renode.app/Contents/MacOS/scripts/monitor.py
Font 'Roboto Mono' not available in the system. Using '.AppleSystemUIFont' instead
14:56:00.4587 [WARNING] The font 'Roboto Mono' defined in the config file cannot be loaded.
14:56:01.3112 [INFO] Including script: ~/litex-vexriscv-tensorflow-lite-demo/renode/litex-vexriscv-tflite.resc
14:56:01.3445 [INFO] System bus created.
Font 'Roboto Mono' not available in the system. Using '.AppleSystemUIFont' instead
14:56:02.8829 [WARNING] The font 'Roboto Mono' defined in the config file cannot be loaded.
14:56:03.1006 [INFO] sysbus: Loading segment of 270960 bytes length at 0x40000000.
14:56:03.2965 [INFO] cpu: Setting PC value to 0x40000000.
14:56:03.3945 [INFO] machine-0: Machine started.
14:56:03.5606 [WARNING] sysbus: [cpu: 0x4002E704] ReadDoubleWord from non existing peripheral at 0xE0005000.
14:56:03.5626 [WARNING] sysbus: [cpu: 0x4002E710] WriteDoubleWord to non existing peripheral at 0xE0005000, value 0x7.
14:56:03.5638 [WARNING] sysbus: [cpu: 0x4002E790] WriteDoubleWord to non existing peripheral at 0xE0007000, value 0x1.

Can you please kindly point out is this also a problem caused by the LiteX_I2C_Zephyr.cs file? or another file.