From 5c286a76d73f6c43690b76d169930c249147798e Mon Sep 17 00:00:00 2001 From: error Date: Mon, 29 Aug 2022 09:44:02 +0200 Subject: [PATCH] fix typos --- content/posts/scroip.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/content/posts/scroip.md b/content/posts/scroip.md index 3490d8b..cd12817 100644 --- a/content/posts/scroip.md +++ b/content/posts/scroip.md @@ -9,9 +9,9 @@ License: CC-BY-NC ## The Idea When I was a child, I used to play a lot with my slot car racing track. -After stubling upon it again recently, I started wondering if I could build something to control it over the network. +After stumbling upon it again recently, I started wondering if I could build something to control it over the network. Not that I needed a remote control for it, but it seemed like a fun project. -However, simply creating an API that offers precise control over the device seemed way to sriaght forward - the controling mechanism itself should add its challenges. +However, simply creating an API that offers precise control over the device seemed way to straight forward - the controlling mechanism itself should add its challenges. So I came up with the idea to control it with the traffic itself. The more traffic is sent to the remote control, the faster the car is supposed to go.[°Use more bandwidth!!!] @@ -21,7 +21,7 @@ In order to build the remote control, the first step was to figure out how the s ![Simplified circuit diagram for a slot car racing system]({static}/posts/scroip/carrera.svg "Simplified circuit diagram of a slot car racing system") -The underlying mechanism is fairly simple. The power supply provides about 14.8 V DC voltage, which a used to power the car's motor. +The underlying mechanism is fairly simple. The power supply provides about 14.8 V DC voltage, which is used to power the car's motor. The speed of the car is controlled by a variable resistor within the controller, which allows to control the voltage the car receives. Pushing the controller further down lowers the resistance, which raises the voltage available to the car and makes is go faster. A third wire is used to brake the car when the controller is in its neutral position by utilizing the current generated by the motor when the car is rolling out. @@ -48,7 +48,7 @@ By default, it only supports IPv4, but IPv6 support can be added by setting `add self.address_family = AF_INET6 super(SCRoIPServer, self).__init__((address, port), SCRoIPRequestHandler) -The server's logic itself is implemented in the method `handle()` of the class `SCRoIPRequestHandler`. While there is an active connection, it reads from the socket and sums up the ammount of data that was received. +The server's logic itself is implemented in the method `handle()` of the class `SCRoIPRequestHandler`. While there is an active connection, it reads from the socket and sums up the amount of data that was received. Once every 100 ms, it then calculates the average throughput for that time period and sets the raspi's GPIO pins accordingly. while self.data != b'':