I have a variant of Datalog with an explicit model of time (like statelog or dedalus) and action atoms/external atoms from HEX (asp). Then I extract partial programs that provably use finite memory and construct finite state machines. Combined with a bit of runtime framework, I can compile to C which I actually run on arduino or lego ev3.
Usually something what I call a "decision core" is embedded in every interactive program. Deciding what to do with input. Sometimes this is just an if-else-tree, sometimes a statistical model, sometimes a logic program. Execution is done in an imperative fashion.
Usually on microcontrollers you don't have enough space to have a control system and a logic program. So I extend LP with IO and compile efficient code.
Partial programs are basically extracted using the Datalog research about parallelism and distribution over components. Queries evaluated in parallel/distribute can be compiled to separate programs. And if the program is bounded, through an abstract execution we can basically generate all possible extentions (parameterized) of the minimal model.
Where the proof can not be obtained, we compile a small embedded deductive database.
I have to look at the stuff you've linked. Interesting and adjacent. Is the github in your profile an appropriate way to contact you? I'll shoot you an email in a few days.