So I am trying to stop my mbot after I finish following the blackline make it walk straight for a little more and than stop it. I tried to do it with line follower using the number 3 that works when the mbot cant find the blackline but it didn`t work.
Hi, can you send me your program uploaded?
i dont actually know how to send you the code cuz im still trying to learn how to use this website.
But if you know any way to do what I asked you would helped me a lot
mbot.sb2 (75.0 KB)
Hope you can see the codein the way that I send it cuz I couldn`t do it in another way.
If you know any other code that will work please tell and thanks for trying to help me
If I understand your need correctly: Do you want the Panda sprite to follow a black line until the end of the course ???
Not an mBot? Just a sprite?
I use mblock for robotics but if you use scratch, just take the background. Then we code if it’s your need?
mbot2.sb2 (934,8 Ko)
I want the mbot (not a sprite) to follow the line and at the end of the blackline I want to make the mbot do other things like:
Run foward or stop and set led on board red. I’m just taking these as an example.
If you could help that would mean a lot to me!!!
Sorry, never misunderstood. The mBot can do one execution at a time so you have to think about the logic of the code.
We can start following the lines. Ignore it the best way, but I’ll send you an example tonight. I’m going to leave space in the code for the ultrasonic and we’ll make it more fun.
Hi Crackel, thanks for replying and trying to help me,
I know how to stop the mbot with ultrasonic but I want to stop it without using ultrasonic.
This is just an example that I got to show you want I need.
Example: As in the picture the mbot starts normaly, but at the end it needs to stop only programing it, not getting any help from other things such as barriers (ultrasonic sensor).
I still have to make my way because the 8-shaped path does not meet the need. It’ll take me another night.
I made the code and the path but the lineflower works quite badly. on my journey. It is probably a reflection of the paper. I saw an anti-reflex module on the Makeblock site but I can’t find it anymore.
I’ll be back to you tomorrow.
Sorry for taking your time and thanks a lot for trying to help me!!!
I’m waiting for your response.
I had some problems with my trip. The mBot is a bit finicky because the black line is not very defined. I will send you the code in two steps.
- Line tracking and Ultrasonic
- Stop at the end of the route
If it is possible then we will succeed. I’ll be back in 2 days.
I had to take black tape because the black pencil did not work very well. Conclusion: A good black tape and the mBot follows the path perfectly.