Hello, everyone!
Could anyone please answer me the aforementioned question? I know, that semihosting is usually blamed for being too slow and because it blocks firmware when no debugger is connected and other stuff. But I found it quite useful when running unit tests for distinct parts of software. For example, I have a WiFi module on board and while evaluating it, I perform numerous scenarios like "Connect to a given network", "Connect to a given network and the to this socket", "Become and access point and wait for connection" and so on. To automate and manage all these cases I took a Unity test framework, which fit pretty well on resource-constrained platform. So when I fix/implement some code and decide to check nothing has been broken, I just run all tests I have and see the report given to me by semihosting's printf implementations.
Anyway sometimes I need to give some input to tests, like IP address of the server, or amount of data to get from or software under tests needs to tell me something so I could behave respectively. It would be nice to automate it as well. And here I recalled about SYS_SYSTEM command. According to documentation, it pass a command to host command-line interface. Neat feature, I though. Some scripts in Python plus command to run them and that's all.
Unfortunately, Ozone reported to me that this feature is blocked due to security concerns (huh?! well, at least it recognizes it). So is there a way to somehow enable it or it's blocked once and forever? Yes, I know it's possible to implement it using UART and some sort of RPC server on host PC, but it takes some pins and some code to be written, so I put it to backlog for some time, if SYS_SYSTEM is really inaccessible.
Best regards!
Could anyone please answer me the aforementioned question? I know, that semihosting is usually blamed for being too slow and because it blocks firmware when no debugger is connected and other stuff. But I found it quite useful when running unit tests for distinct parts of software. For example, I have a WiFi module on board and while evaluating it, I perform numerous scenarios like "Connect to a given network", "Connect to a given network and the to this socket", "Become and access point and wait for connection" and so on. To automate and manage all these cases I took a Unity test framework, which fit pretty well on resource-constrained platform. So when I fix/implement some code and decide to check nothing has been broken, I just run all tests I have and see the report given to me by semihosting's printf implementations.
Anyway sometimes I need to give some input to tests, like IP address of the server, or amount of data to get from or software under tests needs to tell me something so I could behave respectively. It would be nice to automate it as well. And here I recalled about SYS_SYSTEM command. According to documentation, it pass a command to host command-line interface. Neat feature, I though. Some scripts in Python plus command to run them and that's all.
Unfortunately, Ozone reported to me that this feature is blocked due to security concerns (huh?! well, at least it recognizes it). So is there a way to somehow enable it or it's blocked once and forever? Yes, I know it's possible to implement it using UART and some sort of RPC server on host PC, but it takes some pins and some code to be written, so I put it to backlog for some time, if SYS_SYSTEM is really inaccessible.
Best regards!