Problem in running a IoT Simulation using micro:bit
enter image description here
This is the simulation
enter image description here
And this is the block code.
When I run the simulation it reads the analog pin p0 and start the motor when reading is below 300 but when reading is above 300 the dc motor rotates anti-clockwise