Google searches have only yielded 5th grade level examples (“the modem talks between your ISP and your home network!”) or articles I would need a degree to understand. Can anyone provide an explanation that’s somewhere in between the two? I understand the fundamentals of how the Internet works, and how LAN works regarding a router and individual devices, but I’m curious to know more about the link between those.

  • venquessa@alien.topB
    link
    fedilink
    English
    arrow-up
    3
    ·
    8 months ago

    It used to be a lot simpler. The “Modem” received a stream of serial data (UART/RS232 + AT control codes).

    The digital stream needed to be “encoded” and converted to electrical signals which could be sent on a physical wire… most often the PSTN network (Public service telephone network)… aka “the phone line”.

    The audio/analoge technique used to produce the electrical signals was not as you might expect sending “blips” for 1s and silence for 0s. For way out of scope reasons that isn’t efficient. Techniques like PCM or PWM, Pulse code/width modulation. Beyond the scope. However this gets you the “MODulator”, “DEModulator”. Which is you “MoDem”

    Today, these still exist. Most would refer to them as “dial up modems”. Rare. We tend to have “home broadband” technologies today which range from plain old twisted pair phone lines carrying 100s of times more bandwidth than an “analogu phone line”, but over the same wires. We have old “Coax” cable for “Cable TV” carrying high speed internet. We even now have pure optical fibre connections in to the home.

    At this point, really, it can be argued there is no modem. Certainly not in the terminology used to previously describe one. What often gets refered to as the “Modem” is usually an ONT or similar ePon/docsis device controlled by an ISP which “converts” or “bridges” the optical (or other broadband signal) to “Ethernet”. Most, not all then additionally handle the authentication and “PPP” Peer to peer protocol used to transmit your data over this “You-ISP network”. In larger enterprise these components can be broken down into individual (or multitudes of) different boxes. ONT, PPPoE client, Router, Firewall, Switch, Wifi Access point. In most homes they will either be a single box provided by the ISP or 2 boxes with one provided by the “Network operator” and the other by your “Internet retailer.”

  • Glaborage@alien.topB
    link
    fedilink
    English
    arrow-up
    3
    ·
    8 months ago

    I’ll give it a shot.

    In the past, before the internet existed, homes were connected to the national phone system. The national phone system is a bunch of interconnected electric lines that are designed to transport electricity in the frequencies used for speech / sound.

    When internet became a thing, people needed electric lines to transport data from their internet providers to their home. Instead of building new electric lines, which would be very expensive, tech companies created a technique called “modem”.

    A modem transforms computer data into sound data, which can travel through phone lines. Once the sound data reaches the internet provider, another modem turns it back into computer data.

  • LRS_David@alien.topB
    link
    fedilink
    English
    arrow-up
    2
    ·
    8 months ago

    As others have noted a modem is a modulator / demodulator.

    Most modems are designed into other things. Like cable coax modem/router/switch/wi-fi access point. Or other things. Or in a cell phone it converts bits internal to the phone into radio signals or back the other way. Many things people call a modem is really a more complicated box with a modem built into it.

    In the basic definition of the term it is bits <-> analog wave forms. Back in the day it was land line modems and the wave forms could be heard by most people if they listened “in”. Actual FAX machines (not email pretending to be a FAX) still do this. Connected to the “bits” side of a modem is usually a circuit that takes those bits and organizes them in agreement with the other end of the connection. Mostly these days Ethernet.

    Most Fiber setups do NOT have a modem as they have networking bits already in the light in the fiber. They do “media conversion” between fiber and copper.

    And if you want to dig deeper look into how DSP (Digital Signal Processing) works, Fourier Transforms, and how Wi-Fi radios encode things, and so on.

  • fasta_guy88@alien.topB
    link
    fedilink
    English
    arrow-up
    2
    ·
    8 months ago

    Take a look at old issues of Byte Magazine where they will explain how to make a cassette tape backup system for your 1975 computer. Basically, you need to turn ones and zeros into tones that can be recorded on cassette tape, and you need to do it in a way that strings of 111111’s and 00000’s get the right count of '1’s and '0’s. There are a bunch of different ways of mapping tone changes to '1’s and '0’s, (frequency shift keying, phase shift keying, etc) and it’s pretty amazing all the ways to pack bits into tones (how many tones do you want to distinguish - 2? 4? more?).

    You could also look up how the old 300 baud (essentially bits per second) modems encoded bits over telephone lines that only provided 3Khz of bandwidth, and how more sophisticated encodings allowed 1200 baud, 2400 baud, and ultimately 56K baud.

  • Circuit_Guy@alien.topB
    link
    fedilink
    English
    arrow-up
    1
    ·
    8 months ago

    You’ll get a better answer on something like r/embedded. I.e. seek out the people who work on them.

    Here’s the less-then-degree answer: Think about a telephone dial tone or key press sound. That’s sending a digital command over audio. You’re sending a tone that the other side can pick up and turn back into a number. You can step up higher and higher in frequency to send more information. This was originally what they called broadband, when it got high enough in frequency to go outside the audible range. There’s other techniques besides just tones, like phase differences between two signals (think how headsets can mimic directional sound). You could use this to encode much more information than just frequency alone. As modems get “faster” we’re moving to more complicated algorithms to send data.

  • BlueKnight87125@alien.topB
    link
    fedilink
    English
    arrow-up
    1
    ·
    8 months ago

    Let’s use a non-techy example. I speak English (your home network for this analogy), and I’m trying to converse with a person who speaks Chinese (the wider internet). Neither of us understands the other’s language, leading me to find someone who speaks both to interpret (the modem). The interpreter listens to what I have to say and then repeats it to the other party in Chinese. The Chinese person gives a response, which the interpreter repeats back to me in English.

  • Busy_Reporter4017@alien.topB
    link
    fedilink
    English
    arrow-up
    1
    ·
    8 months ago

    The modem device bridges between the local network and the WAN. The physical medium of the WAN is designed to cover longer distances.

    Modems used to use audio signaling to send data over phone lines. Nowadays they generally use higher frequencies such as radio signals or optical to send data over radio link, DSL, cable, or fiber media.

    The modem device encodes and error checks/corrects, converts and transmits the data – between the different LAN-WAN protocols / physical layers.

    MoDem stands for modulator-demodulator. That implies an audio or RF “baseband” signal being “modulated” (the carrier frequency shifted) to encode the data onto the physical layer.

    However, modern modems use DAC/ADC (analog-digital/digital-analog converter) modules to transmit/receive the analog signals and directly convert to/from digital (logic level) signals. They don’t need the intermediate step of generating a baseband carrier frequency and then modulating it. Hence the modern modem may actually be an SDR (software-defined radio). SDR can cover a huge frequency range and any encoding/modulation – defined only by the software!

    In fact, some newer radio transceivers use SDR for its flexibility. For example, Flex / Anan radio transceivers. Some designers have repurposed commodity modem chips to create less expensive SDR transceivers. There are now Ham Radio transceivers based on this concept.

    • LRS_David@alien.topB
      link
      fedilink
      English
      arrow-up
      2
      ·
      8 months ago

      A modem device bridges between the local area network (LAN) and the wide area network (WAN).

      Nope. A modem can be a part of a box doing this but not always.

  • One_Sense_5007@alien.topB
    link
    fedilink
    English
    arrow-up
    1
    ·
    8 months ago

    It just changes the way the data looks so it can travel on a different cable. Modulates/demodulates the data/signal. The ISP doesn’t use Ethernet to transmit the data so to transmit the same data it needs to change they way it look. Kind of like taking normal book text and converting it into braille so a blind person can read it.

  • neon_overload@alien.topB
    link
    fedilink
    English
    arrow-up
    1
    ·
    8 months ago

    Modem stands for modulator-demodulator. Modulation is the encoding of information into a signal, especially when it involves combining of different frequencies into a complex analog waveform. The demodulation is the opposite, extracting the original information back out by separating out the various parts of the signal that were encoded.

    You can imagine that a very simple stand-in for a modem might just be to take every bit (binary digit) of input and encode as either a low or high voltage on output. That is a very basic way of encoding data for sending as voltage down a wire and works really well down short wires at reasonable speeds. You do need some way of synchronising both ends, and without a separate wire for a synchronization clock you need to agree on a communication speed and periodically interrupt the encode with a particular pattern so that the receiver can re-synchronize itself.

    So, the above describes how 1-wire serial communication works, basically a UART which is the fundamentals behind RS-232, but this tends to be useful for short lengths of wire only.

    When you want to send over long distances then effects in the wire start becoming a problem, like the capacitance of the wire, or its voltage loss over its length, or the interference it can pick up. If the signal in the wire doesn’t have certain properties, such as being cyclical, the signal can be flattened out or suffer other artifacts that destroy the ability to tell what input it had.

    So you encode the data in different ways that make it resistant to these effects. You take analog waves of one or more carrier frequencies, and encode the data as slight changes in these frequencies such as frequency or phase changes. Modulating data into a carrier wave makes it much more tolerant to capacitance and loss on a long bit of wire (or indeed, over the air waves).

    In order to counter interference, you need to either slow down your communication or build in some ability for itself to either detect errors, or correct errors. A simple form of error detection, for example, would be to transmit everything twice - if the same thing wasn’t received twice, then you have detected an error. This unfortunately doubles the amount of data you need to transmit, just to detect errors, but the good news is complex mathematics can reduce this inefficiency down to just a few percent of overhead, by transmitting an error detection code calculated based on the data, such that if the receiver receives the data and the code, and gets the same result from the algorithm, they know it has transmitted safely. Modern systems also expand this to error detection and correction where a little more redundancy is built in to be able to not only detect errors but correct most of them, and clever mathematics, again, helps us to minimise the amount of redundant data required to do this.

    Finally, the quest for greater and greater transmission speed has driven us to find creative ways of getting the most data transmission through a given wire length possible, by using multiple carriers, multiple ways of modifying them to encode data into them, and use special mathematical algorithms to work out the encoding and decoding of such a scheme.

  • vhdl23@alien.topB
    link
    fedilink
    English
    arrow-up
    1
    ·
    8 months ago

    How deep are you willing to go.

    I’m a computer engineer, I design and develop embedded systems like modems, TCU, ECU and many others.

    If you want to understand how a modem works, truly understand everything. You need to first understand some basic physics primarily electromagnetism and the property of waves.

    From there you can jump to a higher abstracted level such as amplitude modulation, frequency modulation and phase modulation. From this you can try to read up on Quadrature amplitude modulation.

    You can also use this to understand demodulation.

    Then jump back to the lower level and study up signal theory and how these things work.

    Honestly the level of information to fully understand how a device like a modem is huge.

    If you love this stuff and you’re still young I would encourage you to become a computer engineer with a focus in asic. It’s not easy but the stuff you work on is rewarding.

  • TheRealFailtester@alien.topB
    link
    fedilink
    English
    arrow-up
    1
    ·
    8 months ago

    I feel your pain on that,there are many rabbit holes about many different ones out in the wild.
    Either gonna find a plug in power plug in cable plug in computer description, or every math formula in existance to describe how it sent one of ten trillion packets that one unique time to the billion different ways it can send them.