Code Monkey home page Code Monkey logo

Comments (9)

zappybiby avatar zappybiby commented on August 27, 2024

A couple questions:

  1. Should we consider changing ld.setMinVote(55) to a higher value?
  2. Does anyone know how to move the "imshow" window? (I tried)
  3. Dividing the average here gives wildly different results in terms of the truck compensating correctly. 13 works decently, but there is probably a better way to do this.
  4. I'm still not sure if this centers the mouse correctly. Ideally it would move mouse to center, but its inconsistent.

from chosuntruck.

zappybiby avatar zappybiby commented on August 27, 2024

Update: worked on it more ajchili@99fa517

It's actually more broken then when I started this. That is pretty impressive.

I think I have the general idea of what I need it to do now. I'm optimistic :)

from chosuntruck.

chi3236 avatar chi3236 commented on August 27, 2024
  1. We can consider that, but any specific reasons to change the value?
  2. I hope this can be the solution

from chosuntruck.

zappybiby avatar zappybiby commented on August 27, 2024

Well I was testing a couple different things to try to see if I could make the program detect lines in different light conditions. Also when I posted that comment it was extremely dark and the program wasn't seeing any lines. I just turned on the lights of the truck to fix this.

setting setMinVote to 60 seemed to work better but I've changed it back down to 55 for now. I am still testing it.

I thought that changing the threshold values may help since it always seems to be a little darker than it should.

I tried AdaptiveThreshold to see if I can adapt to the brightness dynamically but this made it find too many lines instead. It was a fun experiment though!

Edit: was able to move windows, thank you! ajchili@e980f95

from chosuntruck.

zappybiby avatar zappybiby commented on August 27, 2024

Made more progress:
ajchili@564b178

See video here: https://www.youtube.com/watch?v=rqyvoFuGKKk&feature=youtu.be
(I crashed many times while doing this, now my engine stalls. lol)
I feel like the best way to get this to work would probably be dividing by an incremental amount.
For example, between 5 and -5 it divides by 10, between 5 to 10 and -5 to -10 it divides by 9...etc.

from chosuntruck.

chi3236 avatar chi3236 commented on August 27, 2024

Looks great! If the steering wheel recovers to the center quickly, it will move better.

from chosuntruck.

zappybiby avatar zappybiby commented on August 27, 2024

Input is working a lot better now! ajchili@fe4759d

I don't have the time right now to manually fine-tune parameters of the PID controller, but it's working great so far.

See new video here: https://www.youtube.com/watch?v=iL2F__ENx5s&feature=youtu.be

The truck crashed at the end, but I think this is easily fixable.

from chosuntruck.

zappybiby avatar zappybiby commented on August 27, 2024

New PID implementation ajchili@eb601b4

I will need to add Integral term in order to automatically determine the other terms (proportional + derivative)

from chosuntruck.

zappybiby avatar zappybiby commented on August 27, 2024

Video of the new PID: https://www.youtube.com/watch?v=DYe3aTquavc&feature=youtu.be

Should be almost perfect with adaptive IPM.

from chosuntruck.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.