IP Over Lasers September 29, 2025 Introduction A typical computer is connected to the local network using either an Ethernet cable or WiFi. This project connects two computers together through lasers. This project takes advantage of the Linux support for a tun (tunnel) network device. Like any other network device, it gets its own IP address. The difference is, when network traffic is routed to it, a user land computer reads in the data and from there can do whatever it wants with it. Likewise, packets can be written to the tunnel device and the kernel will use it the same as if it came from a hardware network card. Explanation, video, pictures, and source code below. Related Projects @mikekohn.net Video VIDEO YouTube: https://youtu.be/U-pM_YwO_94 Explanation Both computers (in this case a laptop and a Raspberry Pi 5) have USB-UART cables connected to them. Those cables are connected to two pins on ATtiny85s. The ATtiny85s on two other pins have a laser and a phototransitors. Each laser is pointed to the phototransistor on the opposite microcontroller. Originally, the plan was to try to use a 38kHz IR sensor, so the lasers would flicker at 38kHz when they were on and light "noise" would therefore not affect the system. It actually seemed to detect the laser sometimes, but it was kind of obvious it wasn't going to work so instead a phototransistor is used. I did use these lasers for other projects, including the Drag Racing Tree circuit and never used eye protection. Kind of realized that was probably a really stupid idea so I ordered some cheap $10 goggles. It made working on the project more difficult, but better to be safe than blind. Using minicom, data could be transferred character by character over the lasers at 4800 baud. At 9600 baud only garbage was transfered. I was having trouble with the relay of IP data so I dropped it down to 2400 baud. There were some bugs in the code at that time so maybe it could be bumped back up to 4800. Either way, ping time isn'...
First seen: 2025-10-01 17:44
Last seen: 2025-10-02 11:48