Bit Rotation and Shifting: Simple Explanation!

Поділитися
Вставка
  • Опубліковано 13 січ 2020
  • What is bit-shifting and bit-rotation?
    Find it out here!
    Downloadlink TIA V16 (you need to register on the website):
    support.industry.siemens.com/...
    Find a lot of content about TIA Portal on my channel!
    New programming videos every tuesday and thursday.
    If this video helped you, please consider helping me by joining my "GoFundMe" and donating a small amount to my cause. Link here:
    www.gofundme.com/f/let039s-fi...
  • Наука та технологія

КОМЕНТАРІ • 26

  • @simonmax3901
    @simonmax3901 4 роки тому +3

    That was great....... especially shifting for integer values.
    That was very new to me

  • @messizqin9603
    @messizqin9603 3 роки тому +1

    That's clean and easy to understand. Spot on.

  • @saeed2tube
    @saeed2tube 4 роки тому +1

    Its usefull to turm on something one after one by adressing output as qw with just one block. Thanks for continuance effort.🙏

  • @Vozzhd
    @Vozzhd 4 роки тому +1

    Thank you))) perfect video. 3k people already subscribe, congratulations!! Waiting for TIA Thursday))

  • @skilz8098
    @skilz8098 Рік тому

    Very nice and clear example of bit shifting. Your video demonstration and simplicity is spot on especially for beginners. For me this video was just a really good refresher while already being familiar with them and their differences from working within the C/C++ languages. From a programming perspective they're easy to understand and use and I know most of their basic uses yet I would find it very useful to have a solid explanation of how they're used within Assembly.
    As for their use within Assembly, I'm not referring to just their use from a programming perspective of using assembly to write programs but more on the lines of how they are used within the design of an assembler and its instruction set architecture.
    Let's consider already having them implemented in the hardware as physical components within an ALU that can be invoked from OPCodes - Assembly Mnemonics - instructions. At this stage of the game everything is relatively good and straightforward.
    Now having their functionality and being able to use them within the architecture is one thing, but knowing what their main purposes are or more to the lines of when they are needed and why, when and how you should use them is closer to the point.
    For example, I can call them through existing opcodes within a simple 8-bit architect. The current implementation of the architect is taking 4 8-bit or words from each instruction cycle. The first byte is the OPCODE or Instruction, the 2 and 3rd bytes are two source lines that are fed to the registers, as well as other hardware devices such as the ALU, RAM, the Stack and I/O as input A and B, being SRC1, SRC2 respectively and the 4th byte is the destination DEST respectively.
    I currently have the Stack Working and I'm in the process of implementing the "call" and "ret" instructions within the assembler to use the stack to push and pop addresses for procedure - subroutine calls. Implementing this shouldn't be to difficult as it's a simple stack frame.
    However, having a good clean and clear explanation of what their main uses are at the ISA - to Assembly stage would be very beneficial and useful information just to add another tool into the toolbox. Something to this effect could make for a good video resource.

  • @FraztheWizard
    @FraztheWizard 2 роки тому

    Great explanation! Thanks!

  • @dukenuke2690
    @dukenuke2690 4 роки тому +5

    and btw shifting Left by 1 position equals multiplying the value by 2 :D

  • @muhammadferdiansyah2473
    @muhammadferdiansyah2473 Рік тому

    Excelent explanation! Thankyou Sir!

  • @prabhjotsingh6731
    @prabhjotsingh6731 4 роки тому

    thank you..very good explanations

  • @framos9991
    @framos9991 Рік тому

    Thank you! Best video!

  • @ndongminkolandry4443
    @ndongminkolandry4443 4 роки тому

    Hi I do appreciate and like what you do. You help me with my Tia programming but I would like to know if you also do video on scada

  • @mahdidavari8094
    @mahdidavari8094 Рік тому

    Thanks

  • @muhammadkhalid8374
    @muhammadkhalid8374 4 роки тому

    Great to know

  • @lordcuc1
    @lordcuc1 4 роки тому

    Good work,thanks for you videos.I had a question for you. I had S300 system,TIA 14,WinCC Advanced,and want 16 separate bits(discrete input signals) convert to Word format in DB. Please help me with this problem.Thank you.

  • @simonmax3901
    @simonmax3901 4 роки тому

    In the future videos please assist in loop(LOOP) program and jump to label instruction(JL).
    Thanks in advance

  • @johanneskampfl6794
    @johanneskampfl6794 Рік тому

    Best!

  • @Motoko-en3kd
    @Motoko-en3kd 2 роки тому

    hi hegamurl. i'm reading some cpu arch doc. i'm beginner of Assembly Language. when i saw the rotate right operation, i can't think of any use for it, i google it , but only found how to implement it in high level language. it's there have secret between native system internal and bit rotate operation. I hope you can help me get some prompt information(🙇‍thanks).

  • @mlikiachref5228
    @mlikiachref5228 4 роки тому

    could you make a video about safety Plc

  • @patilprashanth1
    @patilprashanth1 4 роки тому +2

    good explanation....practicle example wound have been more efficient.

  • @johanneskampfl6794
    @johanneskampfl6794 Рік тому

    Best

  • @rtlinsn5085
    @rtlinsn5085 2 роки тому

    In ARM, we only have ROR, no ROL!!

  • @abdallahsani5658
    @abdallahsani5658 3 роки тому +1

    I can tell he is German 😁, thanks a lot sir.

    • @hegamurl7434
      @hegamurl7434  3 роки тому

      Not trying to hide it 😁 you are welcome and thank you!

  • @sarahlabidi6558
    @sarahlabidi6558 10 місяців тому

    Great explanation! Thanks!