Skip to content

Detect tiles using light sensors#17

Closed
Mrdizzy14-Deklen wants to merge 74 commits intomainfrom
light-sensors
Closed

Detect tiles using light sensors#17
Mrdizzy14-Deklen wants to merge 74 commits intomainfrom
light-sensors

Conversation

@Mrdizzy14-Deklen
Copy link

No description provided.

@Mrdizzy14-Deklen Mrdizzy14-Deklen linked an issue Mar 31, 2025 that may be closed by this pull request
…reading 20 ticks before and finding the difference, will change to be more reliable soon
@jasonappah jasonappah changed the title preliminary push Detect tiles using light sensors Apr 1, 2025
@jasonappah jasonappah marked this pull request as draft April 1, 2025 04:21
MahdMalik and others added 25 commits April 7, 2025 16:24
…f possible I'd want to see if I can detect the speed of the robot when it first detects a change, as then deceleration would be fairly easy to find and I can tell the exact distance moved by the bot, and then reverse that exact direction
… to be douched anymore. Next on my task should be making the robot move until both front motors cross, and getting the different in (say ticks) between their crossing. Then, I reverse the forward motor by that amount. Shouldn't be too hard (famous last words).
…lso made it so bot only stops when both front ones pass
MahdMalik added 23 commits May 10, 2025 15:06
…ead of moving it continuously, stop after crossing
…ful, such that both wheels are at least turning they way they should be. They're not turning at the same time though, so I have to check that
…ARGHHH. Seems that they're just not reading properly, it might be because the ESP is trying to handle the encoder at the same time is what I'd guess.
…orrelated with complex code like PID, so when the code is very simple the light sensors work fine. Either they're not getting enough voltage when the esp is focused on other things like the light sensors, or more likely there's some issue in the code such that the light sensors can't read properly due to being say interrupted. Now I just have to actually figure out what's the issue. So once that's done, I just need to perfect the angle alignment, and after that centering is just combining everything I have together so that shouldn't be too bad (hopefully). Ima head out now
…hich is really weird, I don't think it's the lighting cause on the black fabric tiles it crashes out but on a black table it works fine. i'm guessing it has to do with how smooth the surface is, so that if it's very smooth the PID doesn't face friction. For now i'll just get my stuff done on the surface where it works. Besides that I think I made changes to the trapezoidal curve to make it work better but it seems to not really be working as well, gonna try to get that done in the next 2 hours
… removing the part of the code that kickstarts velocity, now it seems pretty stable. Going to now test angle alignment
…AINS THE EDGE GRAHHHHHH, THE TASK BOUTA GET LOW DIFFED BEFORE THE END OF MONDAY
… 2, but... it works, so who cares. Now just need to complete centering code and this task should be done
… forgotten.' - Mahd Malik on what to expect from him in the next 12 hours.
…eensy tiny issue though: the third IR blaster no worky on chessbot #4, so I can't really check the back sensors. Gonna take a break and then ask if any other robots work
…unable to get perfectly towards the target. I should try to debug that
…it seems sometimes the turn isn't exactly right, might wanna check that. Also want to see if PID really is straigtht
…the angle is way off but it only pops up rarely like a boss event or something
…each the value. For now gotta head out, besides minor bugs this task is mostly done at least

int delayMilliseconds = 20;

//alright SCREW YOU serial monitor i won't print every frame then if you wanna play that game
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this line made me audibly chuckle. nice

MahdMalik and others added 4 commits May 14, 2025 22:17
…t step. Now must fix a bug where the robot army-crawls.
…t when the robot army crawls, its because the velocity calculkated for each motor is rightm but its just that for one of the motors it's not really changing its position to the degree that is specified by the velocity that the trap profile returns. This is either a problem with teh PID not getting the correct motor power, or may be a problem with something like traction. I'll see what pid outputs as the motor power
… to be reworked to be activated by command from server
@democat3457 democat3457 closed this Sep 9, 2025
@democat3457 democat3457 deleted the light-sensors branch September 9, 2025 20:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Detect Tile Changes using the Light Sensors

4 participants