FMUSER Wirless Transmit Video And Audio More Easier !

[email protected] WhatsApp +8618078869184
Language

    Single chip program TH0 = (65536-50000) / 256; what does it mean?

     

    TL0 = (65536-50000)% 256; What does these two mean? ? Why is it 256, is it fixed? ? ? I know the answer, but I still don't understand. This is online: Standard answer: When the timer 0 is set to mode 1, the count register is 16-bit mode, consisting of two 8-bit registers of 8 bit TH0 and low 8-bit TL0, when the set calculation value is 65536-50000 = 15536 ​​(d) When converting to hexadecimal is 3CB0 (h), at this time, TH0 = 3c, TL0 = B0 is loaded, and many programmers use "TH0 = (65536-50000) / 256, in order to avoid these calculations. ; TL0 = (65536-50000)% 256 "programming, let the microcontroller to calculate the results, then why do you want to intervene 256? In fact, it is not difficult to understand. If you do 10--16, you will know that 256 (d) = 0100 (h), where 01 is high 8-bit data, 00 is the low 8-bit data, popular point How many 256 is 156 in 15536 ​​(d), it is equivalent to high 8 digits, which is the relationship, and the remaining number of stores in the high 8-bit register is 8 digits, and the merchant calculation is TH0 = (65536-50000) / 256; Taking a payment is TL0 = (65536-50000)% 256. Answer: The timer operates in the mode. The counter is 16-bit, and the 16-bit binary can represent 0 ~ 2 ^ 16 (65535), and the counter is counted, one number of plus, first of all, to set its count initial value (Do not set the default 0), if you want to have an interrupt every 50000 times overflow, then the initial value is 2 ^ 16-50000 + 1 = 15536, now put 15536 ​​this initial value into TH0 and TL0, but Since 51 is an 8-bit microcontroller, only 8-bit data can be handled each time, so it is to give TH0 and TL0, 15536/256, respectively, to TH0 and TL0, 15536/256, respectively, 15536% 256 is Low octave is taken out, similar to 25/10 = 2 in decimal. ... .5, the ten digits 2 and the bit 5 are taken out. To put it bluntly, it is a correlation. Read more

     

     

     

     

    List all Question

    Nickname

    Email

    Questions

    Our other product:

    Professional FM Radio Station Equipment Package

     



     

    Hotel IPTV Solution

     


      Enter email  to get a surprise

      fmuser.org

      es.fmuser.org
      it.fmuser.org
      fr.fmuser.org
      de.fmuser.org
      af.fmuser.org ->Afrikaans
      sq.fmuser.org ->Albanian
      ar.fmuser.org ->Arabic
      hy.fmuser.org ->Armenian
      az.fmuser.org ->Azerbaijani
      eu.fmuser.org ->Basque
      be.fmuser.org ->Belarusian
      bg.fmuser.org ->Bulgarian
      ca.fmuser.org ->Catalan
      zh-CN.fmuser.org ->Chinese (Simplified)
      zh-TW.fmuser.org ->Chinese (Traditional)
      hr.fmuser.org ->Croatian
      cs.fmuser.org ->Czech
      da.fmuser.org ->Danish
      nl.fmuser.org ->Dutch
      et.fmuser.org ->Estonian
      tl.fmuser.org ->Filipino
      fi.fmuser.org ->Finnish
      fr.fmuser.org ->French
      gl.fmuser.org ->Galician
      ka.fmuser.org ->Georgian
      de.fmuser.org ->German
      el.fmuser.org ->Greek
      ht.fmuser.org ->Haitian Creole
      iw.fmuser.org ->Hebrew
      hi.fmuser.org ->Hindi
      hu.fmuser.org ->Hungarian
      is.fmuser.org ->Icelandic
      id.fmuser.org ->Indonesian
      ga.fmuser.org ->Irish
      it.fmuser.org ->Italian
      ja.fmuser.org ->Japanese
      ko.fmuser.org ->Korean
      lv.fmuser.org ->Latvian
      lt.fmuser.org ->Lithuanian
      mk.fmuser.org ->Macedonian
      ms.fmuser.org ->Malay
      mt.fmuser.org ->Maltese
      no.fmuser.org ->Norwegian
      fa.fmuser.org ->Persian
      pl.fmuser.org ->Polish
      pt.fmuser.org ->Portuguese
      ro.fmuser.org ->Romanian
      ru.fmuser.org ->Russian
      sr.fmuser.org ->Serbian
      sk.fmuser.org ->Slovak
      sl.fmuser.org ->Slovenian
      es.fmuser.org ->Spanish
      sw.fmuser.org ->Swahili
      sv.fmuser.org ->Swedish
      th.fmuser.org ->Thai
      tr.fmuser.org ->Turkish
      uk.fmuser.org ->Ukrainian
      ur.fmuser.org ->Urdu
      vi.fmuser.org ->Vietnamese
      cy.fmuser.org ->Welsh
      yi.fmuser.org ->Yiddish

       
  •  

    FMUSER Wirless Transmit Video And Audio More Easier !

  • Contact

    Address:
    No.305 Room HuiLan Building No.273 Huanpu Road Guangzhou China 510620

    E-mail:
    [email protected]

    Tel / WhatApps:
    +8618078869184

  • Categories

  • Newsletter

    FIRST OR FULL NAME

    E-mail

  • paypal solution  Western UnionBank OF China
    E-mail:[email protected]   WhatsApp:+8618078869184   Skype:sky198710021 Chat with me
    Copyright 2006-2020 Powered By www.fmuser.org

    Contact Us