Autonomous rover code by Chris Anderson image.draw_lines error

Here is the code that I am trying to run on a h7 plus which had some addons by Kwageman.

Here is the error I am receiving when trying to run the code.

Traceback (most recent call last):
File “”, line 47, in
OSError: Not enough positional arguments!

img.draw_line((l), color=(127)) # Draw lines on line 47 seems to be causing the issue. Is this because the IDE and the modules have been changed?

I am very much going to keep trying to get a simple differential drive robot going with this wonderful hardware you guys have created. I was not able to get the pyb servo api to work with the flagship color line following code you guys created together a few years ago. I have been diligently studying python because I am greatly inspired by your project and all of its potential to make a real difference in the tinyML vision space. Still, it seems, I have much to learn, and SO MUCH!

Does the openmv team have any plans to include code that makes the creation of the line following script a little more beginner friendly? Perhaps I am kidding myself about the progress i have made in studying python and the answer is obvious to someone more experienced than myself.

Thank you

Hi, you need to update the code to work with the latest API.

As for making the code more simple… you really need to understand Python. You can literally Google almost any answer you need for python. Asking us about syntax issues is not a great use of time.


1 Like

Like some wise sage once said, perhaps it was the Buddha but it has been lost to time, “Its never the code, its always the coder”

I understand what you mean about syntax issues and thanks for clarifying that I will take those questions elsewhere.

One last clarification Kwagyeman and I will leave the you to your work which we all appreciate very much.

So it’s not that the ide update stopped the code from working it’s that the code still works fine it is only my lack of knowledge about the Servo api that is stopping me from getting the code to work? Please forgive if this is an annoying newb question. I will continue my studies with the aim of one day making a meaningful contribution to your work in an open source fashion.

Peace and cheers

Hi permahuman,

I just don’t have so much time to be able to debug python syntax issues.

So “l” needs to be “l.line()”

Thank you kwabena,

Please keep up the awesome work. I got your flagship color line following code to work and will implement that line object on zlites code even though the code isn’t as polished as the color line following you guys worked on. It’s just fun to see the different approach to line following.

My mind is only just beginning to grasp the power of this little machine eyeball.


P.s. I am taking notes on my learning path with openMV and my plan is to publish that here so others will complete newb status such as I will have a vague roadmap. It appears that there truly is no single info source to scoop up this generalized hardware software skillset.