Using Connected IO mode of Arduino at Reinforcement learning
6 views (last 30 days)
Show older comments
Hello!
I have successfully completed a reinforcement learning simulation using matlab and Simulink (RL Agent block).
For the actual experiment, the sensor value should be sent to simulink. So, I am trying to send the sensor value to Simulink using an arduino uno (analog input or anything else...)
it is not necessary to deploy the entire reinforcement learning on the arduino board, So i just want to receive the sensor values using the Connected IO mode.
To do this, I have to press the [Run with IO] button in the Hardware tab instead of the [Run] in the Simulation tab.
But!! When starting reinforcement learning, instead of pressing the [Run] button directly in simulink, simulink automatically runs due to the code in matlab as follows.
train(agent,env,trainingOptions)
Therefore, I think that the default value of run on simulink should be fixed to [Run with IO] , or the matlab code should be commanded to start simulink with [Run with IO] .
Is there any possible way?
Any other approach is fine, Please help me!!!
(I'm using matlab 2020b and 2021a,b)
Answers (0)
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!