Articles

Example Service About Automatic Restoration of iptables

In some cases, we need to load iptables after everything has started. The following is an example of a service to accomplish this. The service starts when the server is idle, checks for the executable file, and then starts it. [Unit] Description=runs iptables restore on boot ConditionPathExist=/etc/iptables-my/iprestore.sh After=network.target [Service] Type=idle User=root ExecStart=/etc/iptables-my/iprestore.sh RemainAfterExit=yes GuessMainPID=no [Install]

2024-06-29T12:19:38+03:00By |Categories: How To|0 Comments

Experience With Setting Up Ports

Sometimes, when you don't work with a specific system, you can forget how to set it up or check its settings. This happened to me when I set up an Ubuntu server. It had been 6-7 years since I last worked on this type of server, and I missed out on some new features and

2024-06-29T11:45:48+03:00By |Categories: How To|0 Comments

Import JSON file in TypeScript

In this example, I will show you a simple way to import JSON files in TypeScript code. It requires just two simple steps. The first is to change the tsconfig.json file by adding the line: , "resolveJsonModule": true in "compilerOptions" section. { "compilerOptions": { ... , "resolveJsonModule": true ... } ... } After that, you have

2022-09-13T21:14:21+03:00By |Categories: How To|0 Comments

An Introduction to USB Communication (Part 2)

In this article, we will introduce the USB protocol layer. Please see our previous article for information regarding the physical layer and network topology: An Introduction to USB Communication (Part 1). USB is a polled bus where the host initiates all transactions. For the host to receive information from USB devices, it must request it

2021-05-09T23:45:06+03:00By |Categories: Embedded Systems|Tags: |2 Comments

An Introduction to USB Communication (Part 1)

USB (Universal Serial Bus) is an industry-standard used to specify cables, connectors, and protocols that are used for communication between electronic devices. Advantages: Self-configuring interface, no need for user configuration of speed, data protocol, etc.Capable of supplying power to small auxiliary devicesVarious communication speeds are supportedStandard connectorsError checking increases the communication reliability Limitations: Limited cable

2021-03-16T07:14:28+02:00By |Categories: Embedded Systems|Tags: |0 Comments

FreeRTOS: Using MCU Peripheral Drivers

Communication interfaces (I2C, SPI, UART, etc.) are some of the most commonly used microcontroller peripherals in embedded systems. In this introductory article, we will look at how low-level drivers for such peripherals can be used in FreeRTOS. Polled Drivers vs Interrupt-driven Drivers Based on the method used for getting information on events (e.g errors, operation

2021-03-08T06:23:40+02:00By |Categories: Embedded Systems|Tags: , |0 Comments

FreeRTOS: Using Software Timers

In this article, we will take a look at the software timers in FreeRTOS. A software timer allows a function to be executed at a set time in the future.FreeRTOS - RTOS software timer functionality and features description The function that is executed is referred to as a timer's callback function. The interval between starting

2021-01-03T18:53:29+02:00By |Categories: Embedded Systems|Tags: , , |5 Comments

Toolset for Debugging Embedded Programs

Writing programs that just work would make the development of embedded systems a lot easier. In practice, however, a considerable amount of time is devoted to finding and removing bugs from the code. This process is commonly known as debugging and there is no way of avoiding it. In this article, we will give an

2020-11-22T22:35:01+02:00By |Categories: Embedded Systems|Tags: |0 Comments

Install Django and Verify It

Django is a Python framework used to create websites. Installation is easy. The recommended way is to use pip. python -m pip install Django This will install Django and you will see something like this: Django instalation using pip After the installation is complete you can verify it using this code: import django print(django.get_version()) If

2020-11-15T21:15:44+02:00By |Categories: How To|0 Comments

FreeRTOS: LED Blinking And Button Polling

FreeRTOS is one of the most widely used open-source real-time operating systems (RTOS). In this article, we will look at a very simple FreeRTOS program: a push-button will enable/disable the blinking of an LED. The program is developed and tested using the LPCXpresso54102 board with NXP's LPC54102 microcontroller. The program can be easily adapted for

2020-10-20T23:58:11+03:00By |Categories: Embedded Systems|Tags: , |0 Comments
Go to Top