Arduino Tutorial 46: HOMEWORK- Create a Binary Bit Flipper with the 74HC595

preview_player
Показать описание
You guys can help me out over at Patreon, and that will help me keep my gear updated, and help me keep this quality content coming:

You can get the kit I am using for this series at the following link:

You can follow these lessons at our WEB site:

#Arduino
Рекомендации по теме
Комментарии
Автор

After failing the last two assignments (although learning a lot doing so), I actually had the idea of how to do this homework assignment while you were still talking. My skills are definitely improving!

lordstelanthin
Автор

Woo! I managed to make a functional bit flipper! It popped into my head while eating dinner, lol!

hedgewicksattempts
Автор

Thank very much! The idea had been absolutely deepened and even more clear. The magic numbers for flipping are(2, 4, 8, 16, 32, 64, 128).

Octopus-
Автор

Dear Paul,
Thank you for giving the assignment. I have completed it. Your lessons are great and made me nothing to novice in Arduino programming circuit building and mathematics.

md.mizanurrahman
Автор

Doer, although the temptation to fold like a cheep lawn chair and watch the next lesson was hard to resist. Managed to do this one on my own. BOOM.

alanfowler
Автор

Finally got some time to, myself. I used two methods 1) used the tilde (~) 2) used XOR with the mask 0xff. Love to see things working like they should.

opalprestonshirley
Автор

Hi Paul, couldn’t sleep last night because this was going through my head, then I suddenly remembered ( from my old Tech days), that you could flip bits by subtracting them from or FF, and as you say, Boom! There it was. Good job it’s the weekend.
I shall now go to sleep and watch the video later to see if i did it your way or another.

leebasham
Автор

With a little tinkering I was able to get this one. I started by printing the Binary, DEC, and HEX numbers from the setup and then watching what it would do in the loop. In the loop i set myByte = 0x0F + myByte and saw how it looped. Then tried setting myByte = 255 - myByte and vuala!!! it did the opposite of what i put in the setup code. On to the next one! Thank you Paul for many many great lessons. My wife just asked me to send her the first one so she can start on them too. Hopefully her and I can build something together one day.

chrisb
Автор

I instinctively arrived at the solution to this one (even though I couldn't get the homework to lessons 44 and 45 without being a watcher.) Evaluating a couple of binary byte examples on paper led me to confirm what to try in the software. Feeling pleased with my abilities again. Thanks for being an awesome teacher and willing us all to do well.

richardalexander
Автор

Last couple of lessons I was a doer that could not get it done so I became a watcher for those lessons. This one I finally (fairly quickly) figured out on my own. Now to see if my solution matches your. Thank you!

pokerface
Автор

Hello Paul, my first idea was correct. This assignment was solved quickly :-)
Thanks for all. I have learnt so much from You. It's always a pleasure to watch Your videos.

GeoGebweiler
Автор

Funny, I was already doing this in the first 74HC595 lesson, while you were talking after making yours work!! Guess I wasn't paying attention to the teacher and playing with my new skills in class!! HAHA!! You make it so fun to learn this stuff!!

gilnasty
Автор

I've learned a lot with your teachings and the arduino cookbook. Thank you.

meach
Автор

Did this assignment easily. Thanks Paul.

hasan-motam
Автор

First try I switched the parameter in the shiftOut(dataPin, clockPin, LSBFIRST, myByte); to shiftOut(dataPin, clockPin, MSBFIRST, myByte); Works but sort of a cheat. took more time to get thee 255-mByte.
Thank you Paul!

lewisencompos
Автор

An easy task for Paul's Protege : running in loop byte value and ff-byte 😁

laxmanrao
Автор

Yes Paul, I've done the homework above though it took me sometime to figure out the math involved.
At first I was only able to make the last four bits(LEDs) complement the first four bits by multiplying the value of the byte by 16( 2 raised to the power of 4. ) In this manner any value between binary 0 to binary 1111 that you put in be be replicated in the four higher bits. Beyond that it was all garbage.
Then I begin to think of deducting a given value from 255( all LEDs lit ). For example if the value given is 250( binary ) and you deduct that from 255( binary you get 5 ( binary )which is the complementary symmetry resultant.
Used this in the formula and voila it works !!! Now to check out Tutorial 47 on how you did it.

sssagc
Автор

Hi Paul, yes, was able to do the bit flipper very quickly because of your previous lessons. Like others, had trouble with doing tutorial 44 and 45 HW on my own, but it is coming together now. :-)

panzerblitz
Автор

After being unable to do the circular shift I am back and was able to do this on my own, addedmyByte= 255-myByte as my logic of shifting and it worked

polito-ydfp
Автор

I figured out the homework!!! And it didn't take me very long! It was obvious once I looked at it long enough. Once again, it was SOOOO simple and right in front of me! The MOST hardest part was the LEAST difficult. <wink>

charlielowell