{"id":17731,"date":"2023-05-19T14:37:24","date_gmt":"2023-05-19T14:37:24","guid":{"rendered":"https:\/\/wolles-elektronikkiste.de\/?p=17731"},"modified":"2024-06-06T20:39:45","modified_gmt":"2024-06-06T20:39:45","slug":"lgt8f328p-lqfp32-boards","status":"publish","type":"post","link":"https:\/\/wolles-elektronikkiste.de\/en\/lgt8f328p-lqfp32-boards","title":{"rendered":"LGT8F328P &#8211; LQFP32 Boards"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\">About this post<\/h2>\n\n<p>In this post, I introduce the LGT8F328P MCU and show how you can program boards based on it (version LQFP32) in the Arduino environment. Since the LGT8F328P is not only close to the ATmega328P in name, I will mainly explain the differences.<\/p>\r\n<p>These are the topics I will discuss:<\/p>\r\n<ul>\r\n<li><a href=\"#overview\">Overview<\/a><\/li>\r\n<li><a href=\"#advantages\">Advantages compared to the Atmega328P<\/a><\/li>\r\n<li><a href=\"#pinout\">Pinout of the LGT8F328P-LQFP32 based boards<\/a><\/li>\r\n<li><a href=\"#installation\">Installation of the board package<\/a><\/li>\r\n<li><a href=\"#in_action\">LGT8F328P-LQFP32 Boards in action<\/a>\r\n<ul>\r\n<li><a href=\"#adc\">Analog to digital converter<\/a>\r\n<ul>\r\n<li><a href=\"#quality_adc\">AD converter quality<\/a><\/li>\r\n<li><a href=\"#diff_measurement_and_gain\">Analog differential measurements and gain<\/a><\/li>\r\n<\/ul>\r\n<\/li>\r\n<li><a href=\"#dac\">Digital to analog converter<\/a>\r\n<ul>\r\n<li><a href=\"#accuracy_dac\">Accuracy of the DAC<\/a><\/li>\r\n<\/ul>\r\n<\/li>\r\n<li><a href=\"#80mA_output\">Using 80 mA outputs<\/a><\/li>\r\n<li><a href=\"#wdt\">Watchdog timer<\/a><\/li>\r\n<li><a href=\"#sleep_power\">Sleep and power modes<\/a><\/li>\r\n<li><a href=\"#fastio\">Fastio functions<\/a><\/li>\r\n<li><a href=\"#timer_pwm\">Timer and PWM<\/a><\/li>\r\n<\/ul>\r\n<\/li>\r\n<li><a href=\"#programming_l_pro_mini\">Programming the LGT8F328P based &#8220;Pro Mini&#8221;<\/a>\r\n<ul>\r\n<li><a href=\"#usb_2_ttl\">Upload via USB-to-TTL Adapter (with bootloader)<\/a><\/li>\r\n<li><a href=\"#larduinoisp\">Upload via LarduinoISP (without Bootloader)<\/a><\/li>\r\n<\/ul>\r\n<\/li>\r\n<li><a href=\"#conclusion\">Conclusion<\/a><\/li>\r\n<\/ul>\r\n\n<h2 class=\"wp-block-heading\" id=\"overview\">Overview<\/h2>\n\n<p>The LGT8F328P is manufactured by the Chinese company <a href=\"http:\/\/www.lgtic.com\/\" target=\"_blank\" rel=\"noopener\">LogicGreen<\/a> (rebranded to: Prodesign Semiconductor). It is widely compatible with the AVR instruction set and the ATmega328P. The LGT8F328P is cheaper and has some technical advantages and additional functions compared to the ATmega328P. Therefore, it is not surprising that it was used to develop counterparts to the Arduino UNO R3, Arduino Nano 3 and Arduino Pro Mini. And it is these boards that I cover in this post.<\/p>\r\n<p>The most common are the Arduino Nano and Pro Mini compatible boards, which can be found as &#8220;LGT8F328P LQFP32 MiniEVB&#8221; in online stores for a few Euros. The Arduino UNO compatible board I tested is from <a href=\"https:\/\/www.az-delivery.de\/\" target=\"_blank\" rel=\"noopener\">AZ-Delivery<\/a>. It is a bit different from the other boards in some aspects.<\/p>\r\n\n<p>The LGT8F238P IC is available as an SSOP version with 20 pins (SSOP20), as QFP with 48 pins (QFP48L) or as QFP with 32 pins (QFP32L). In this article, I only deal with QFP32L based boards, which are closest to the ATmega328P based representatives. Mostly, they are labeled with &#8220;LQFP32&#8221;. I will discuss all three versions in a follow-up article. They have the same registers and essentially only differ in which functions are actually accessible through pins.\r\n<\/p>\r\n<p>The pinout scheme of the QFP32L shows many similarities to that of the ATmega328P, but also a few additional features.<\/p>\r\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full is-resized\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/pinout_lgt8f328p_ic.png\"><img loading=\"lazy\" decoding=\"async\" width=\"736\" height=\"667\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/pinout_lgt8f328p_ic.png\" alt=\"\" class=\"wp-image-17541\" style=\"width:552px;height:500px\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/pinout_lgt8f328p_ic.png 736w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/pinout_lgt8f328p_ic-300x272.png 300w\" sizes=\"auto, (max-width: 736px) 100vw, 736px\" \/><\/a><\/figure>\n<\/div>\n<p>A certain disadvantage when working with the LGT8F328P is that the manufacturer does not provide an English data sheet. However, thanks to some hardworking contributors, translations are available, for example <a href=\"https:\/\/github.com\/watterott\/LGT8F328P-Testing\/raw\/master\/LGT8FX8P_databook_v1.0.5-English.pdf\" target=\"_blank\" rel=\"noopener\">here<\/a> on GitHub.&nbsp;<\/p>\r\n\n<h2 class=\"wp-block-heading\" id=\"advantages\">Advantages compared to the ATmega328P<\/h2>\n\n<p>I don&#8217;t want to list here all the technical features of the LGT8F328P. Like the ATmega328P it has 2 KB SRAM, 32 KB flash, the supply voltage is from 1.8 to 5.5 volts etc.<\/p>\r\n<p>These are some important differences to the ATmega328P:<\/p>\r\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/06\/atmega328_vs_lgt8f328p_eng.png\"><img decoding=\"async\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/06\/atmega328_vs_lgt8f328p_eng-1-1024x539.png\" alt=\"LGT328P vs. ATmega328P: most significant differences\" class=\"wp-image-18272\"\/><\/a><figcaption class=\"wp-element-caption\">LGT328P vs. ATmega328P: some important differences<\/figcaption><\/figure>\n\n<h2 class=\"wp-block-heading\" id=\"pinout\">Pinout of the LGT8F328P-LQFP32 based boards<\/h2>\n\n<p>When comparing the LGT8F328P boards with their ATmega328P counterparts, you have to look twice to see differences. This applies in particular to the pin labels. Here you can see an original Arduino Nano (blue), next to two LGT8F328P Nano boards:<\/p>\r\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/nano_328p_lgt8f328p-1024x161.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"161\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/nano_328p_lgt8f328p-1024x161.jpg\" alt=\"\" class=\"wp-image-17558\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/nano_328p_lgt8f328p-1024x161.jpg 1024w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/nano_328p_lgt8f328p-300x47.jpg 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/nano_328p_lgt8f328p-768x121.jpg 768w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/nano_328p_lgt8f328p-1320x207.jpg 1320w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/nano_328p_lgt8f328p.jpg 1400w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/a><figcaption class=\"wp-element-caption\">Arduino Nano (ATmega328P) between two LGT8F328P Nano boards <\/figcaption><\/figure>\n\n<p>There are also great similarities with the originals in terms of pin functions:<\/p>\r\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/05\/lgt8f328p_nano_qfp32l_pinout-1-1024x627.jpg\"><img decoding=\"async\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/05\/lgt8f328p_nano_qfp32l_pinout-1-1024x627.jpg\" alt=\"Pinout LGT8F32P based Nano board\" class=\"wp-image-18034\"\/><\/a><figcaption class=\"wp-element-caption\">Pinout LGT8F32P based Nano board<\/figcaption><\/figure>\n\n<p>A corresponding diagram for the LGT8F328P based Pro Mini can be found <a href=\"https:\/\/user-images.githubusercontent.com\/777196\/222880206-57e643d7-d955-4025-9e0d-541b5e960230.png\" target=\"_blank\" rel=\"noopener\">here<\/a>, for example. For UNO-like board I tested (source: <a href=\"https:\/\/www.azdelivery.de\/\" target=\"_blank\" rel=\"noopener\">AZ-Delivery<\/a>) I did not find such a scheme. But this should not be a problem because the UNO has the same in- and outputs. Only SWC and SWD are missing. <\/p>\r\n\n<h2 class=\"wp-block-heading\" id=\"installation\">Installation of the board package<\/h2>\n\n<h4 class=\"wp-block-heading\">Nano- \/ Pro Mini-like boards<\/h4>\n\n<p>To be able to program the LGT8F328P boards with the Arduino IDE, you must first install a suitable board package. For the &#8220;L-Nano&#8221; (as an abbreviation for &#8220;LGT8F328P based&#8221;) and the &#8220;L-Pro Mini&#8221; I used the great board package <a href=\"https:\/\/github.com\/dbuezas\/lgt8fx\" target=\"_blank\" rel=\"noopener\">lgt8fx<\/a> from <a href=\"https:\/\/github.com\/dbuezas\" target=\"_blank\" rel=\"noopener\">David Buezas<\/a>. It is based on the packages <a href=\"https:\/\/github.com\/LGTMCU\/Larduino_HSP\" target=\"_blank\" rel=\"noopener\">Larduino_HSP<\/a> and <a href=\"https:\/\/github.com\/Edragon\/LGT\/tree\/master\/1-LGT8F328\/SDK\/Arduino\/HSP\/HSP%20Patch%20File\/Larduino_HSP_3.6c\/Larduino_HSP_v3.6c\" target=\"_blank\" rel=\"noopener\">LGT<\/a> but is easier to handle, takes better advantage of the LGT8F328P and is better documented. You can learn more about the differences <a href=\"https:\/\/github.com\/dbuezas\/lgt8fx#differences-to-original-core-larduino_hsp-v36c\" target=\"_blank\" rel=\"noopener\">here<\/a>.<\/p>\r\n<p>A detailed installation guide for the board package with screenshots can be found <a href=\"https:\/\/github.com\/dbuezas\/lgt8fx#how-to-install\" target=\"_blank\" rel=\"noopener\">here<\/a>. The short version is:<\/p>\r\n<ul>\r\n<li>Go to File \u2192 Preferences.<\/li>\r\n<li>Click the button behind &#8220;Additional Board Manager URLs&#8221;.<\/li>\r\n<li>Enter there the line &#8220;https:\/\/raw.githubusercontent.com\/dbuezas\/lgt8fx\/master\/package_lgt8fx_index.json&#8221; (without quotes).<\/li>\r\n<li>Navigate to Tools \u2192 Board: &#8220;xxx&#8221; \u2192 Boards Manager.<\/li>\r\n<li>Search for &#8220;lgt8fx&#8221; and install the package &#8220;LGT8fx Boards&#8221; by dbuezas.<\/li>\r\n<\/ul>\r\n<p>After successful installation, select &#8220;LGT8F328&#8221; as the board. As &#8220;Variant&#8221; I have selected &#8220;328P-LQFP32 (e.g. MiniEVB nano-style or WAVGAT)&#8221;.&nbsp;<\/p>\r\n\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/04\/lgt8f328p_board_selection.png\"><img loading=\"lazy\" decoding=\"async\" width=\"771\" height=\"234\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/04\/lgt8f328p_board_selection.png\" alt=\"LGT8F328P Board options\" class=\"wp-image-17961\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/04\/lgt8f328p_board_selection.png 771w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/04\/lgt8f328p_board_selection-300x91.png 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/04\/lgt8f328p_board_selection-768x233.png 768w\" sizes=\"auto, (max-width: 771px) 100vw, 771px\" \/><\/a><figcaption class=\"wp-element-caption\">LGT8F328P Board options<\/figcaption><\/figure>\n\n<h4 class=\"wp-block-heading\">UNO-like board<\/h4>\n\n<p>For AZ-Delivery&#8217;s UNO-like board, the procedure is similar. The entry for the board manager URL is:<\/p>\r\n<ul>\r\n<li>http:\/\/www.az-arduino.de\/package_AZ-Boards_index.json<\/li>\r\n<\/ul>\r\n<p>In the board manager menu, search for &#8220;AZ boards&#8221;. You can find a detailed description in the free e-book from AZ-Delivery.<\/p>\r\n\n<h4 class=\"wp-block-heading\">Checking the installation<\/h4>\n\n<p>Take any sketch, for example Blink.ino from the &#8220;Basics&#8221; example sketches of the Arduino IDE and upload it. The board LED should flash every second.<\/p>\r\n<p>How to upload sketches via an USB-to-TTL adapter (e.g. for the Pro Mini) or via <a href=\"https:\/\/github.com\/dbuezas\/lgt8fx\/tree\/master\/lgt8f\/libraries\/LarduinoISP#lgtisp\" target=\"_blank\" rel=\"noopener\">LGTISP<\/a> and how to burn the bootloader, I explain at the end of the article (here).&nbsp;<\/p>\r\n\n<h2 class=\"wp-block-heading\" id=\"in_action\">LGT8F328P-LQFP32 boards in action<\/h2>\n\n<p>Enough of the preparations and general explanations &#8211; now we come to the more interesting, practical part.<\/p>\r\n<p>I have tried many Arduino sketches with all kinds of functions unchanged on the LGT8F328P boards. Only sketches that use the watchdog timer and sleep functions had to be adapted. Everything else worked 1:1. So we can essentially focus on the <em>additional<\/em> functions.<\/p>\r\n\n<h3 class=\"wp-block-heading\" id=\"adc\">Analog to digital converter <\/h3>\n\n<p>You can read the voltage at an analog pin via <code>analogRead()<\/code> as you are used to from the ATmega328P based boards. The default resolution is 10 bit. The standard reference voltage is the operating voltage (VCC).<\/p>\r\n<p>It should be noted that the &#8220;Nano-like&#8221; board has a diode built into the 5 volt line to protect the USB port. The effective operating voltage is therefore about 4.6 volts when powered via USB. You can find the diode above the pins D10 \/ D11.<\/p>\r\n<p>As with the conventional ATmega328P boards, you can use external voltage references. If you do this, connect it to the REF input. Alternatively, the LGT8F328P provides internal references of 1.024, 2.048 or 4.096 volts. Furthermore, the LGT8F328P allows you to increase the resolution to 11 or 12 bits. The following sketch shows how it works:<\/p>\r\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-group=\"lgt8f328p_analogRead.ino\" data-enlighter-title=\"lgt8f328p_analogRead.ino\">\/*\r\n    Parameter:      Reference:\r\n    DEFAULT         VCC\r\n    EXTERNAL        External Reference (REF)\r\n    INTERNAL1V024   Internal 1.024 volts\r\n    INTERNAL2V048   Internal 2.048 volts\r\n    INTERNAL4V096   Internal 4.096 volts\r\n*\/\r\n\r\nvoid setup(){\r\n    Serial.begin(9600);\r\n    analogReference(INTERNAL4V096);\r\n    analogReadResolution(10); \/\/ Resolution = 10, 11 or 12 Bit\r\n}\r\nvoid loop(){\r\n    int adcValue = analogRead(A1);  \/\/ Raw value \r\n    float voltage = adcValue * 4.096\/1024.0;  \/\/ Voltage calculation\r\n    Serial.print(\"Analog Value: \");\r\n    Serial.println(adcValue);\r\n    Serial.print(\"Voltage [V]: \");\r\n    Serial.println(voltage,3);\r\n    delay(1000);      \r\n}<\/pre>\r\n\n<h4 class=\"wp-block-heading\" id=\"quality_adc\">AD converter quality<\/h4>\n\n<p>The good news: The LGT8F328P&#8217;s ADC works quite linearly. The bad news is that the noise is at least as high as with the AVR-based boards. Even in the 10-bit resolution, I had to average at least 100 readings to get stable values. Unfortunately, this makes an 11- or 12-bit resolution of limited use! Maybe the noise can be reduced by stabilizing the supply voltage &#8211; I have to experiment a bit more. <\/p>\r\n<p>Let&#8217;s focus on the positive. I tested the ADC by applying voltages with my lab power supply and converting them with the LGT8F328P. I checked the voltages with a reliable multimeter. The internal 4,096-volt reference was used for A\/D conversion, and 100 readings were averaged for each data point. I did the test with different several boards. This is a typical result:<\/p>\r\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/04\/lgt8f328p_adc_check-1024x599.png\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"599\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/04\/lgt8f328p_adc_check-1024x599.png\" alt=\"Testing the ADC - blue: given voltage, orange: measured value\" class=\"wp-image-17670\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/04\/lgt8f328p_adc_check-1024x599.png 1024w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/04\/lgt8f328p_adc_check-300x176.png 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/04\/lgt8f328p_adc_check-768x450.png 768w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/04\/lgt8f328p_adc_check.png 1107w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/a><figcaption class=\"wp-element-caption\">Testing the ADC &#8211; blue: given voltage, orange: measured value<\/figcaption><\/figure>\n\n<p>Each board had an individual, small and reproducible deviation. So if you need very accurate results, you can use Excel or similar programs to create a best-fit curve.<\/p>\r\n\n<h4 class=\"wp-block-heading\" id=\"diff_measurement_and_gain\">Analog differential measurements and gain<\/h4>\n\n<p>The LGT8F328P allows you to perform differential measurements between specific analog inputs. You can amplify the differential voltages by a factor of 1, 8, 16 or 32. The function for this is <code>analogDiffRead()<\/code>. It expects the negative input, the positive input and the gain factor as arguments. To use the function, you have to include the differential_amplifier.h library file.<\/p>\r\n<p>Here is an example sketch:<\/p>\r\n\n<div class=\"scroll-paragraph\">\r\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-group=\"lgt8f328p_differential_analog_read.ino\" data-enlighter-title=\"lgt8f328p_differential_analog_read.ino\">#include&lt;differential_amplifier.h&gt;\r\n\/*\r\n    Parameter:      Reference:\r\n    DEFAULT         VCC\r\n    EXTERNAL        External Reference (REF)\r\n    INTERNAL1V024   Internal 1.024 volts\r\n    INTERNAL2V048   Internal 2.048 volts\r\n    INTERNAL4V096   Internal 4.096 volts\r\n\r\n Available combinations:\r\n| -\\+ | A0  | A1  | A2  | A3  | A4  | A5  | A6  | A7  |\r\n| --- | --- | --- | --- | --- | --- | --- | --- | --- | \r\n| A0  |     |  +  |     |     |     |     |     |     |\r\n| A1  |  +  |     |     |     |     |     |     |     |\r\n| A2  |  +  |  +  |     |  +  |  +  |  +  |  +  |  +  |\r\n| A3  |  +  |  +  |  +  |     |  +  |  +  |  +  |  +  |\r\n| A4  |  +  |  +  |     |     |     |     |     |     |\r\n| A5  |  +  |  +  |     |     |     |     |     |     |\r\n| A6  |  +  |  +  |     |     |     |     |     |     |\r\n| A7  |  +  |  +  |     |     |     |     |     |     |\r\n*\/\r\n\r\nvoid setup(){\r\n    Serial.begin(9600);\r\n    analogReference(INTERNAL4V096); \r\n}\r\nvoid loop(){\r\n    int raw = analogDiffRead(A2,A3,GAIN_16); \/\/ GAIN_x mit x = 1, 8, 16, 32\r\n    float voltage = raw \/ 1024.0 * 4096.0 \/ 16.0; \/\/ considers resolution, reference and gain\r\n    Serial.println(voltage);\r\n    delay(1000);      \r\n}<\/pre>\r\n<\/div>\r\n\n<p>As you can see from the table in the sketch, only certain combinations of analog inputs are allowed for differential measurements. If you choose an invalid combination, you will get a raw value of -1.<\/p>\r\n<p>To use differential_amplifier.h with AZ-Delivery&#8217;s LGT8F328P based UNO, the easiest way is to download the lgt8fx package from here and extract the corresponding &#8220;.cpp&#8221; and &#8220;h.&#8221; files from the lgt8f\/libraries\/differential_amplifier folder and save them to the sketch&#8217;s folder. In this case, the header file in <code>#include<\/code> needs to be put in quotation marks.<\/p>\r\n\n<h3 class=\"wp-block-heading\" id=\"dac\">Digital to analog converter <\/h3>\n\n<h4 class=\"wp-block-heading\">&#8220;Quasi-analog&#8221; PWM signals<\/h4>\n\n<p>As known from the ATmega328P boards, you can tap a PWM signal at (Arduino) pins 3, 5, 6, 9, 10 and 11 with <code>analogWrite()<\/code>. Likewise, the PWM frequency on pins 5 and 6 is twice as high as on the other pins. It should be noted that the frequencies depend on the clock rate. At 16 MHz they correspond to those of the ATmega328P boards, namely 490 and 980 Hertz respectively. The frequency changes proportionally with the clock rate.<\/p>\r\n<p>I will explain how to generate PWM signals at pins 1 (TX) and 2 (D2) when we get to the timers. Some pinout schemes found on the net additionally mark pin 8 as PWM pin. However, this is wrong.<\/p>\r\n\n<h4 class=\"wp-block-heading\">Generating a real analog signal<\/h4>\n\n<p>At pin 4 (D4 \/ PD4 \/ DAO) you can generate a real analog signal with a resolution of 8 bit. By default, VCC is the reference, i.e. 255 \u2259 VCC. Alternatively, you can use an external reference or the internal references 1,024, 2,048 or 4,096 volts. The following little sketch shows how it works:<\/p>\r\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">\/*\r\n    Parameter:      Reference:\r\n    DEFAULT         VCC\r\n    EXTERNAL        External Reference (REF)\r\n    INTERNAL1V024   Internal 1.024 volts\r\n    INTERNAL2V048   Internal 2.048 volts\r\n    INTERNAL4V096   Internal 4.096 volts\r\n*\/\r\n\r\nvoid setup(){\r\n    analogReference(DEFAULT); \r\n    pinMode(DAC0, ANALOG);\r\n    analogWrite(DAC0, 125); \/\/ 0...255\r\n}\r\nvoid loop(){}<\/pre>\r\n\n<h4 class=\"wp-block-heading\" id=\"accuracy_dac\">Accuracy of the DAC<\/h4>\n\n<p>I checked the accuracy of the analog signal with the 4.096 volt reference and was quite impressed with the correlation between the calculated and measured value:<\/p>\r\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/dac_check-1024x599.png\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"599\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/dac_check-1024x599.png\" alt=\"Analog output test using the internal reference\" class=\"wp-image-17576\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/dac_check-1024x599.png 1024w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/dac_check-300x176.png 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/dac_check-768x450.png 768w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/dac_check.png 1107w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/a><figcaption class=\"wp-element-caption\">Analog output test using the internal reference<\/figcaption><\/figure>\n\n<h3 class=\"wp-block-heading\" id=\"80mA_output\">Using the 80 mA outputs<\/h3>\n\n<p>Because of the ambiguity of the different pin designations (e.g. 1 vs. TX vs. PD1 vs. D1), I use the labels on the LGT8F328P Nano board in the following when referring to the board pins.<\/p>\r\n\n<p>The pins TX,&nbsp; D2, D5 and D6 can supply up to 80 mA. However, you must first enable this &#8220;high current&#8221; feature by setting the appropriate bits in the HDR register. Then you can &#8211; at least for the pins D5 and D6 &#8211; use the outputs with <code>pinMode()<\/code> and <code>digitalWrite()<\/code>. Here is an example:<\/p>\r\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-group=\"lgt8f328p_hdr.ino\" data-enlighter-title=\"lgt8f328p_hdr.ino\">\/*\r\n       HDR      Port\/Pin     Pin Label (Nano)\r\n       HDR0 --&gt; PD5       --&gt; D5\r\n       HDR1 --&gt; PD6       --&gt; D6\r\n       HDR2 --&gt; PF1       --&gt; TX\r\n       HDR3 --&gt; PF2       --&gt; D2 \r\n       HDR4 --&gt; PE4 \/ PF4 --&gt; none\r\n       HDR5 --&gt; PE5 \/ PF5 --&gt; none \r\n*\/\r\n\r\nvoid setup(){    \r\n    HDR |= (1&lt;&lt;HDR0); \/\/ Activate high current for Pin 5\r\n    pinMode(5,OUTPUT);\r\n    digitalWrite(5, HIGH);\r\n}\r\n  \r\nvoid loop(){}<\/pre>\r\n\n<p>If you want to enable the 80 mA option on pins TX and D2, there is a small complication. PD1 and PF1 share TX, PD2 and PF2 share D2 (which makes naming the pins uniquely even more difficult). However, the high current option is only provided via PF1 and PF2 and not via PD1 or PD2. But since PF1 and PF2 are not implemented as Arduino pins (on the QFP32L), you have to address them directly via the ports. Here is a &#8220;high current blink sketch&#8221; for PF2:<\/p>\r\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-group=\"lgt8f328p_hdr_portmanipuation.ino\" data-enlighter-title=\"lgt8f328p_hdr_portmanipuation.ino\">\/*\r\n       HDR     Port\/Pin      Pin Label (Nano)\r\n       HDR0 --&gt; PD5       --&gt; D5\r\n       HDR1 --&gt; PD6       --&gt; D6\r\n       HDR2 --&gt; PF1       --&gt; TX\r\n       HDR3 --&gt; PF2       --&gt; D2 \r\n       HDR4 --&gt; PE4 \/ PF4 --&gt; none\r\n       HDR5 --&gt; PE5 \/ PF5 --&gt; none \r\n*\/\r\n\r\n\r\nvoid setup(){    \r\n\/* example for activating PF2 for high current *\/\r\n    HDR |= (1&lt;&lt;HDR3);\r\n    DDRF = (1&lt;&lt;PF2);  \/\/ ~ pinMode OUTPUT\r\n}\r\n  \r\nvoid loop(){\r\n    PORTF |= (1&lt;&lt;PF2); \/\/ Pin HIGH\r\n    delay(1000);\r\n    PORTF &amp;= ~(1&lt;&lt;PF2); \/\/ Pin LOW\r\n    delay(1000); \r\n}<\/pre>\r\n\n<p><strong>But here you have to be careful<\/strong>: If PF1 or PF2 are in OUTPUT \/ HIGH state and PD1 or PD2 are in OUTPUT \/ LOW state you could cause a short circuit (I didn&#8217;t try it). And PD1 could be accidentally set to this state by its TX function.\r\n<\/p>\r\n<p>If you are not familiar with bit operations and port manipulations such as <code>PORTF &amp;= ~(1&lt;&lt;PF2)<\/code>, I recommend reading my <a href=\"https:\/\/wolles-elektronikkiste.de\/en\/logical-operations-and-port-manipulation\" target=\"_blank\" rel=\"noopener\">post on this topic<\/a>.&nbsp;<\/p>\r\n\n<h3 class=\"wp-block-heading\" id=\"wdt\">Watchdog Timer (WDT)<\/h3>\n\n<p>Maybe one or the other has read my <a href=\"https:\/\/wolles-elektronikkiste.de\/en\/watchdog-timer\" target=\"_blank\" rel=\"noopener\">post about the watchdog timer<\/a> of the ATmega328P. The sketches I published there, work only to a limited extent on the LGT8F328P boards. If you want to use the WDT, it is best to use the library <a href=\"https:\/\/github.com\/dbuezas\/lgt8fx\/tree\/master\/lgt8f\/libraries\/WDT\" target=\"_blank\" rel=\"noopener\">WDT<\/a> included in the board package <a href=\"https:\/\/github.com\/dbuezas\/lgt8fx\" target=\"_blank\" rel=\"noopener\">lgt8fx<\/a> (instead of avr\/wdt.h). Here is an example sketch:<\/p>\r\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">\/*\r\n    Parameter   WDT Reset Period\r\n    WTO_64MS         64 ms   \r\n    WTO_128MS       128 ms\r\n    WTO_256MS       256 ms\r\n    WTO_512MS       512 ms\r\n    WTO_1S            1 s\r\n    WTO_2S            2 s\r\n    WTO_4S            4 s\r\n    WTO_8S            8 s\r\n    WTO_16S          16 s\r\n    WTO_32S          32 s\r\n*\/\r\n\r\n#include &lt;WDT.h&gt;\r\n\r\nvoid setup() {\r\n    Serial.begin(9600);\r\n    Serial.println(\"Sketch started\");\r\n    wdt_enable(WTO_8S);\r\n}\r\n\r\nvoid loop() {\r\n    for(int i=0; i&lt;1000; i++){\r\n        Serial.print(\"Runtime [s]: \");\r\n        Serial.println(i);\r\n        delay(1000);\r\n\/\/        wdt_reset();\r\n    }\r\n}<\/pre>\r\n\n<p>A restart is triggered after every eight seconds. However, if you uncomment line 28, the sketch will run forever.<\/p>\r\n\n<h4 class=\"wp-block-heading\">WDT Interrupt<\/h4>\n\n<p>To use the WDT ISR, take the function wdt_ienable(). Here is an example:<\/p>\r\n\n<div class=\"scroll-paragraph\">\r\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-group=\"wdt_interrupt.ino\" data-enlighter-title=\"wdt_interrupt.ino\">#include &lt;WDT.h&gt;\r\n\r\nvolatile boolean isrflag;\r\n\r\nvoid setup() {\r\n    pinMode(LED_BUILTIN, OUTPUT);\r\n    digitalWrite(LED_BUILTIN, LOW);\r\n    Serial.begin(9600);\r\n    Serial.println(\"Sketch started.\");\r\n    isrflag = false;\r\n    wdt_ienable(WTO_4S);\r\n}\r\n\r\nvoid loop() {\r\n    int n = 0;\r\n    do {\r\n        Serial.print(\"Elapsed time: \");\r\n        Serial.print(n);\r\n        Serial.println(\" s\");\r\n        delay(1000);\r\n        if (digitalRead(LED_BUILTIN)) \r\n            digitalWrite(LED_BUILTIN, LOW );\r\n        else\r\n            digitalWrite(LED_BUILTIN, HIGH);\r\n        if (isrflag) {\r\n            Serial.println(\"--There was a wdt interrupt.--\");\r\n            isrflag = false;\r\n            wdt_enable(WTO_4S); \/\/ uncomment this line...\r\n            \/\/ wdt_ienable(WTO_4S);   \/\/ ...comment this line and see the change\r\n        }\r\n        \/\/ wdt_reset(); \/\/ if uncommented, no interrupt will occur\r\n    } while( n++ &lt; 1000 );\r\n}\r\n\r\nISR (WDT_vect)\r\n{\r\n    isrflag = true;\r\n    wdt_reset();\r\n}<\/pre>\r\n<p>&nbsp;<\/p>\r\n<\/div>\r\n\n<p>If you don&#8217;t want to reset the LGT8F328P after the interrupt, then change lines 28 and 29 from wdt_enable() to wdt_ienable().<\/p>\r\n\n<h3 class=\"wp-block-heading\" id=\"sleep_power\">Sleep and power modes<\/h3>\n\n<p>If you want to put your LGT8F328P board into sleep mode, it is best to use the <a href=\"https:\/\/github.com\/dbuezas\/lgt8fx\/tree\/master\/lgt8f\/libraries\/PMU\" target=\"_blank\" rel=\"noopener\">PMU library<\/a> included in the board package.<\/p>\r\n<p>To try out the following example sketch, connect pin 2 (D2) to GND via a push button. With the settings selected in the sketch, your board will be sent to sleep, wake up after four seconds, then be sent to sleep again, and so on. If you press the push button, your board wakes up immediately due to the external interrupt.<\/p>\r\n\n<div class=\"scroll-paragraph\">\r\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-group=\"lgt8f328p_sleep_power_modes.ino\" data-enlighter-title=\"lgt8f328p_sleep_power_modes.ino\">\/*\r\n    Power Modes\r\n    PM_IDLE0:     disable core clock only\r\n    PM_POWERDOWN: disable most clocks and switch main clock to rc32k\r\n    PM_POFFS0:    power off all core functions (digital and analog)\r\n                  wake up by external interrupt or periodly\r\n    PM_POFFS1:    the lowest power mode which close all modules and clocks \r\n                  wake up by external interrupt only\r\n\r\n    Sleep Duration:\r\n    SLEEP_xMS with x = 64, 128, 256, 512 (milliseconds), e.g. SLEEP_256MS\r\n    SLEEP_yS  with y = 1, 2, 4, 8, 16, 32 (seconds), e.g. SLEEP_4S\r\n    SLEEP_FOREVER\r\n*\/\r\n\r\n#include &lt;PMU.h&gt;\r\nconst int interruptPin = 2;\r\n\r\nvoid setup(){\r\n    Serial.begin(9600);\r\n    Serial.println(\"Sketch started!\");\r\n    pinMode(interruptPin, INPUT);\r\n    digitalWrite(interruptPin, HIGH); \r\n    attachInterrupt(digitalPinToInterrupt(interruptPin), noAction, FALLING); \r\n}\r\n \r\nvoid loop(){\r\n    Serial.flush();\r\n    PMU.sleep(PM_POWERDOWN, SLEEP_4S);\r\n    Serial.println(\"Woke Up!\");\r\n    delay(200); \/\/ for debouncing \r\n}\r\n\r\nvoid noAction(){} \/\/ dummy<\/pre>\r\n<\/div>\r\n\n<h3 class=\"wp-block-heading\" id=\"fastio\">Fastio &#8211; Functions<\/h3>\n\n<p>The functions <code>pinMode()<\/code>, <code>digitalWrite()<\/code> and <code>digitalRead()<\/code> have a lot of ballast that you don&#8217;t need in most cases. If you want to save a few microseconds, you can use port manipulation. If this is too cryptic for you, <code>fastioMode()<\/code>, <code>fastioWrite()<\/code>, <code>fastioRead()<\/code> and <code>fastioToggle()<\/code> are available as alternatives.<\/p>\r\n<p>The disadvantage of the functions is that you cannot pass them variable names, only the pin as a number. If you try it anyway, you will get error messages.<\/p>\r\n<p>Here is an example of correct usage:<\/p>\r\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">void setup() {\r\n    fastioMode(8, OUTPUT); \/\/ equals: DDRB |= (1&lt;&lt;PB0);\r\n}\r\n\r\nvoid loop() {\r\n    fastioWrite(8, HIGH); \/\/ equals (in essence): PORTB |= (1&lt;&lt;PB0);\r\n    delay(100);\r\n    fastioWrite(8, LOW);  \/\/ equals (in essence): PORTB &amp;= ~(1&lt;&lt;PB0);\r\n    delay(100);\r\n    fastioToggle(8); \/\/ equals: PINB = (1 &lt;&lt; PB0);\r\n    delay(1000);\r\n    fastioToggle(8); \/\/ equals: PINB = (1 &lt;&lt; PB0);\r\n    delay(1000);\r\n}<\/pre>\r\n\n<p>Using <code>fastioRead()<\/code> is just as easy:<\/p>\r\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">int status = fastioRead(8); \/\/ equals: int status = (PINB &gt;&gt; PB0) &amp; 1;<\/pre>\r\n<p>The fastio functions are not a special feature of the LGT8F328P, but just a nice feature of the board package.<\/p>\r\n\n<h3 class=\"wp-block-heading\" id=\"timer_pwm\">Timer and PWM<\/h3>\n\n<p>The LGT8F328P has two 8-bit and <strong>two<\/strong> 16-bit timers, so one 16-bit timer more (Timer3) than the ATmega328P. Timers 0 to 2 include two output compare registers each, which you can use to generate PWM signals at the assigned outputs OCxA\/OCxB. I have explained how this works in my posts about <a href=\"https:\/\/wolles-elektronikkiste.de\/en\/timer-and-pwm-part-1-8-bit-timer0-2\" target=\"_blank\" rel=\"noopener\">Timer0 and Timer1<\/a> and about <a href=\"https:\/\/wolles-elektronikkiste.de\/en\/timer-and-pwm-part-2-16-bit-timer1\" target=\"_blank\" rel=\"noopener\">Timer2<\/a>. All sketches used there also work on the LGT8F328P.<\/p>\r\n<p>Three output compare registers and the three outputs OC3A, OC3B and OC3C belong to the Timer3. <\/p>\r\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_timer-1024x356.png\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"356\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_timer-1024x356.png\" alt=\"The timers and associated outputs of the LGT8F328P\" class=\"wp-image-17605\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_timer-1024x356.png 1024w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_timer-300x104.png 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_timer-768x267.png 768w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_timer.png 1250w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/a><figcaption class=\"wp-element-caption\">The timers and associated outputs of the LGT8F328P<\/figcaption><\/figure>\n\n<p>The pinout diagram of the LGT8F328P-QFP32L (see at the very top) is somewhat misleading in this regard. It is correct that OC3C has no output pin. It is also true that OC3A and OC3B are accessible at the pins for PD1 and PD2. However, to obtain a PWM signal, you have to set PF1 and PF2 to OUTPUT. PF1 and PF2 share their outputs with PD1 and PD2, as already mentioned.<\/p>\r\n\n<p>Here is an example of a fast PWM signal at PF1 (board pin: TX) with a duty cycle of 25% and a frequency of 2 kHz (when the LGT8F328P is running at 32 MHz):<\/p>\r\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-group=\"lgt8f328p_fast_pwm_pf1_dc_25\" data-enlighter-title=\"lgt8f328p_fast_pwm_pf1_dc_25\">void setup(){ \r\n  \/\/ Clear OC3A on Compare Match \/ Set OC3A at Bottom; Wave Form Generator: Fast PWM 14, Top = ICR3\r\n  TCCR3A = (1&lt;&lt;COM3A1) + (1&lt;&lt;WGM31); \r\n  TCCR3B = (1&lt;&lt;WGM33) + (1&lt;&lt;WGM32) + (1&lt;&lt;CS30); \/\/ prescaler = 1; \r\n  ICR3 = 15999;\r\n  OCR3A = 3999;\r\n  DDRF |= (1&lt;&lt;PF1);\r\n} \r\n\r\nvoid loop() {} <\/pre>\r\n\n<p>Further explanations would lead too far here &#8211; if you are interested, have a look at the already mentioned articles about the timers of the ATmega328P. Or, if you don&#8217;t feel like calculating and picking all the bits out of the tables, you might want to try this great tool by David Buezas:<a href=\"https:\/\/dbuezas.github.io\/arduino-web-timers\/#mcu=LGT8F328P&amp;timer=0\" target=\"_blank\" rel=\"noopener\">Arduino Web Timers<\/a>. You find the documentation <a href=\"https:\/\/github.com\/dbuezas\/arduino-web-timers\" target=\"_blank\" rel=\"noopener\">here<\/a> on GitHub.<\/p>\r\n<p>By the way, you can set the Timer0 and Timer1 counter to double the system frequency, i.e. up to <strong>64 MHz<\/strong>! For this, you have to set the F2XEN bit in the &#8220;Timer Counter Clock Control and Status Register&#8221; (TCKCSR). By setting the bits TC2XS0 for Timer0 or TC2XS1 for Timer1 you tell the LGT8F328P which timer should run at double speed. E.g.:<\/p>\r\n<p><code class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\"> TCKCSR = (1 &lt;&lt; F2XEN) | (1 &lt;&lt; TC2XS0);<\/code><\/p>\r\n<p>One more reason to use David Buezas&#8217; tool.<\/p>\r\n\n<h2 class=\"wp-block-heading\" id=\"programming_l_pro_mini\">Programming the LGT8F328P based Pro Mini<\/h2>\n\n<h3 class=\"wp-block-heading\" id=\"usb_2_ttl\">Upload via USB-to-TTL adapter<\/h3>\n\n<p>The counterpart to the Arduino Pro Mini (&#8220;L-Pro Mini&#8221;) lacks, just like the original, the on-board USB-to-TTL adapter. So, you need to attach one as an external module. Programming is most convenient if you take an adapter which has a DTR pin.&nbsp;<\/p>\r\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_with_usb2ttl-1024x254.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"254\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_with_usb2ttl-1024x254.jpg\" alt=\"\" class=\"wp-image-17611\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_with_usb2ttl-1024x254.jpg 1024w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_with_usb2ttl-300x74.jpg 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_with_usb2ttl-768x191.jpg 768w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_with_usb2ttl.jpg 1100w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/a><figcaption class=\"wp-element-caption\">Left: USB-to-TTL adapter, right: LGT8F328P based Pro Mini<\/figcaption><\/figure>\n<div class=\"wp-block-image\">\n<figure class=\"alignright size-full is-resized\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_serial_programming.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"626\" height=\"1000\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_serial_programming.jpg\" alt=\"\" class=\"wp-image-17613\" style=\"width:157px;height:250px\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_serial_programming.jpg 626w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_serial_programming-188x300.jpg 188w\" sizes=\"auto, (max-width: 626px) 100vw, 626px\" \/><\/a><\/figure>\n<\/div>\n<p>The adapter shown here also has the advantage that you can plug it directly onto the &#8220;L-Pro Mini&#8221;, as long as you have soldered on a pin header beforehand.<\/p>\r\n<p>If you connect everything by cable, you have to make sure that you connect RX to TX and TX to RX.<\/p>\r\n<p>Uploading is simple: select the port your adapter is connected to, and then simply upload.<\/p>\r\n<p>If you have a USB-to-TTL adapter without a DTR pin, it&#8217;s a little bit more complicated. When you initiate the upload process, press the reset button of the board you want to program. Release the button when the compilation is completed and the actual upload should start.<\/p>\r\n\n<h3 class=\"wp-block-heading\" id=\"larduinoisp\">Upload via LArduinoISP (without bootloader)<\/h3>\n\n<p>As we have already seen, the LGT8F328P has significant differences &#8220;under the hood&#8221; despite all compatibility with the ATmega328P. This is also shown by the fact that it is not programmable via its pins 11, 12 and 13 by ISP. Instead, it has two pins, SWC and SWD, for this purpose.<\/p>\r\n<p>But as with the ATmega328P, you can also convert a LGT8F328P based board to an ISP programmer.<\/p>\r\n<p>For the &#8220;LGT8F328P &#8211; UNO&#8221; from AZ-Delivery this makes little sense because this board does not have the SWC and SWD pin accessible.&nbsp;<\/p>\r\n\n<h4 class=\"wp-block-heading\">Turning an LGT8F328P board into a programmer<\/h4>\n\n<p>Connect the LGT8F328P based board that will serve as a programmer to your computer. It is best not to connect anything else to the board. Then you perform the following steps:<\/p>\r\n<ul>\r\n<li>Select the connected board in the Arduino IDE.<\/li>\r\n<li>Under Tools \u2192 &#8220;Arduino as ISP&#8221; you set the option &#8220;[To burn an ISP] SERIAL_RX_BUFFER_SIZE to 250&#8221; (see below, blue selection).<\/li>\r\n<li>Go to File \u2192 Examples \u2192 &#8220;Examples for LGT8F328&#8221; in the menu and select the sketch LarduinoISP.<\/li>\r\n<li>Upload the sketch.<\/li>\r\n<li>Set &#8220;Arduino as ISP&#8221; in Tools back to default (64).<\/li>\r\n<\/ul>\r\n<p>&nbsp;<\/p>\r\n\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/larduinoisp_setting.png\"><img loading=\"lazy\" decoding=\"async\" width=\"783\" height=\"60\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/larduinoisp_setting.png\" alt=\"\" class=\"wp-image-17630\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/larduinoisp_setting.png 783w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/larduinoisp_setting-300x23.png 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/larduinoisp_setting-768x59.png 768w\" sizes=\"auto, (max-width: 783px) 100vw, 783px\" \/><\/a><figcaption class=\"wp-element-caption\">Settings for Arduino as ISP<\/figcaption><\/figure>\n\n<p>The programmer is ready!<\/p>\r\n\n<h4 class=\"wp-block-heading\">Uploading sketches<\/h4>\n\n<p>Connect your new programming device to the board to be programmed (&#8220;target&#8221;) as follows:<\/p>\r\n<table style=\"height: 138px; width: 46.3095%; border-collapse: collapse; border-style: solid; border-color: #121212;\">\r\n<tbody>\r\n<tr style=\"height: 23px;\">\r\n<td style=\"width: 50%; height: 23px; text-align: center; border-style: solid; border-color: #363636;\"><span style=\"color: #000000;\"><strong>Programmer<\/strong><\/span><\/td>\r\n<td style=\"width: 50%; height: 23px; text-align: center; border-style: solid; border-color: #363636;\"><span style=\"color: #000000;\"><strong>Target<\/strong><\/span><\/td>\r\n<\/tr>\r\n<tr style=\"height: 23px;\">\r\n<td style=\"width: 50%; height: 23px; text-align: center; border-style: solid; border-color: #363636;\"><span style=\"color: #4d4d4d;\">GND<\/span><\/td>\r\n<td style=\"width: 50%; height: 23px; text-align: center; border-style: solid; border-color: #363636;\"><span style=\"color: #4d4d4d;\">GND<\/span><\/td>\r\n<\/tr>\r\n<tr style=\"height: 23px;\">\r\n<td style=\"width: 50%; height: 23px; text-align: center; border-style: solid; border-color: #363636;\"><span style=\"color: #4d4d4d;\">5V<\/span><\/td>\r\n<td style=\"width: 50%; height: 23px; text-align: center; border-style: solid; border-color: #363636;\"><span style=\"color: #4d4d4d;\">VCC<\/span><\/td>\r\n<\/tr>\r\n<tr style=\"height: 23px;\">\r\n<td style=\"width: 50%; height: 23px; text-align: center; border-style: solid; border-color: #363636;\"><span style=\"color: #4d4d4d;\">Pin 12 (D12)<br><\/span><\/td>\r\n<td style=\"width: 50%; height: 23px; text-align: center; border-style: solid; border-color: #363636;\"><span style=\"color: #4d4d4d;\">SWD<\/span><\/td>\r\n<\/tr>\r\n<tr style=\"height: 23px;\">\r\n<td style=\"width: 50%; height: 23px; text-align: center; border-style: solid; border-color: #363636;\"><span style=\"color: #4d4d4d;\">Pin 10 (D10)<br><\/span><\/td>\r\n<td style=\"width: 50%; height: 23px; text-align: center; border-style: solid; border-color: #363636;\"><span style=\"color: #4d4d4d;\">RST<\/span><\/td>\r\n<\/tr>\r\n<tr style=\"height: 23px;\">\r\n<td style=\"width: 50%; height: 23px; text-align: center; border-style: solid; border-color: #363636;\"><span style=\"color: #4d4d4d;\">Pin 13 (D13)<br><\/span><\/td>\r\n<td style=\"width: 50%; height: 23px; text-align: center; border-style: solid; border-color: #363636;\"><span style=\"color: #4d4d4d;\">SWC<\/span><\/td>\r\n<\/tr>\r\n<\/tbody>\r\n<\/table>\r\n\n<p>To prevent a reset of the programmer when uploading to the target, connect the RST pin of the programmer via a 10 \u00b5F capacitor to the 5 V pin. If you don&#8217;t have a capacitor, you can connect the two pins directly, but then you must not press the reset button of the programmer (short circuit!).<\/p>\r\n<p>This is how the setup looks, for example, with an &#8220;L-Nano&#8221; as the programming device and an &#8220;L-Pro Mini&#8221; as the target device:<\/p>\r\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_nano_isp_programmer-1024x353.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"353\" src=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_nano_isp_programmer-1024x353.jpg\" alt=\"LarduinoISP Programming: &quot;L-Nano&quot; Programmer and &quot;L-Pro Mini&quot; Target\" class=\"wp-image-17638\" srcset=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_nano_isp_programmer-1024x353.jpg 1024w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_nano_isp_programmer-300x104.jpg 300w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_nano_isp_programmer-768x265.jpg 768w, https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/lgt8f328p_nano_isp_programmer.jpg 1200w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/a><figcaption class=\"wp-element-caption\">LarduinoISP Programming: &#8220;L-Nano&#8221; as programming device and &#8220;L-Pro Mini&#8221; as target<\/figcaption><\/figure>\n\n<p>Choose the following settings in the Arduino IDE:<\/p>\r\n<ul>\r\n<li>Select the target as board.<\/li>\r\n<li>Under Tools \u2192 Programmer you set &#8220;AVR ISP&#8221;.<\/li>\r\n<\/ul>\r\n<p>To upload, choose Sketch \u2192 Upload with Programmer or use the key combination: Ctrl + Shift + U.<\/p>\r\n\n<h4 class=\"wp-block-heading\">Bring back the bootloader<\/h4>\n\n<p>If you upload a sketch via LarduinoISP, the bootloader will be deleted. To program the board again directly via USB or USB-to-TTL adapter, you have to burn the bootloader first. Nothing easier than that: Use the same settings as when uploading via LarduinoISP and click on Tools \u2192 Burn Bootloader.<\/p>\r\n\n<h4 class=\"wp-block-heading\">Problems with the purple LQFP32 board as LArduinoISP programmer<\/h4>\n\n<p>The purple LQFP32 board with the CH9340C USB-to-TTL chip cannot be used as a LArduinoISP programmer for reasons unknown to me so far.<\/p>\r\n\n<h2 class=\"wp-block-heading\" id=\"conclusion\">Conclusion<\/h2>\n\n<p>LGT8F328P based boards are a high-performance alternative to their ATmega328P counterparts. Thanks to the available board packages, the LGT8F328P boards are easy to handle. Sketches you have written for ATmega328P boards can be used in most cases without any changes. The LGT8F328P offers some additional, useful features.<\/p>\r\n\n<h2 class=\"wp-block-heading\">Acknowledgement<\/h2>\n\n<p>I&#8217;d like to thank <a href=\"https:\/\/github.com\/dbuezas\" target=\"_blank\" rel=\"noopener\">David Buezas<\/a>, <a href=\"https:\/\/github.com\/LaZsolt\" target=\"_blank\" rel=\"noopener\">LaZsolt<\/a> and <a href=\"https:\/\/github.com\/dwillmore\" target=\"_blank\" rel=\"noopener\">dwillmore<\/a> for the excellent work on the board package lgt8fx and for the review of this article. <\/p>\r\n\r\n","protected":false},"excerpt":{"rendered":"<p>The LGT8F328P is a microcontroller compatible with the ATmega328P, but cheaper and even more powerful. I show how to program LGT8F328P based boards in the Arduino environment. <\/p>\n","protected":false},"author":1,"featured_media":17540,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[543],"tags":[556,1069,1499,2073,2075,2074,2069,2060,2072,2068,2064,2067,2076,2077,1497,2066,735,983,2061,2063,2062,2070,2071,973,2065],"class_list":["post-17731","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-boards-and-microcontrollers","tag-arduino-en-2","tag-bootloader-en-2","tag-dac-en","tag-dac0-en","tag-fastio-en","tag-hdr-en","tag-larduinoisp-en","tag-lgt8f328p-en","tag-lgt8fx-en","tag-lgtisp-en","tag-lqfp32-en","tag-nano-en","tag-pf1-en","tag-pf2-en","tag-pinout-en","tag-pro-mini-en","tag-programmer-en-2","tag-pwm-en","tag-qfp32l-en","tag-qfp48l-en","tag-ssop20-en","tag-swc-en","tag-swd-en","tag-timer-en","tag-uno-en"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>LGT8F328P - LQFP32 Boards &#8226; Wolles Elektronikkiste<\/title>\n<meta name=\"description\" content=\"The LGT8F328P is a microcontroller which is widely compatible with the ATmega328P. I show how to program boards based on it.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/wolles-elektronikkiste.de\/en\/lgt8f328p-lqfp32-boards\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"LGT8F328P - LQFP32 Boards &#8226; Wolles Elektronikkiste\" \/>\n<meta property=\"og:description\" content=\"The LGT8F328P is a microcontroller which is widely compatible with the ATmega328P. I show how to program boards based on it.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/wolles-elektronikkiste.de\/en\/lgt8f328p-lqfp32-boards\" \/>\n<meta property=\"og:site_name\" content=\"Wolles Elektronikkiste\" \/>\n<meta property=\"article:published_time\" content=\"2023-05-19T14:37:24+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-06-06T20:39:45+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/postimage_lgt8f328p.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"950\" \/>\n\t<meta property=\"og:image:height\" content=\"950\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Wolfgang Ewald\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Wolfgang Ewald\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"20 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/lgt8f328p-lqfp32-boards#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/lgt8f328p-lqfp32-boards\"},\"author\":{\"name\":\"Wolfgang Ewald\",\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en#\\\/schema\\\/person\\\/b774e4d64b4766889a2f7c6e5ec85b46\"},\"headline\":\"LGT8F328P &#8211; LQFP32 Boards\",\"datePublished\":\"2023-05-19T14:37:24+00:00\",\"dateModified\":\"2024-06-06T20:39:45+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/lgt8f328p-lqfp32-boards\"},\"wordCount\":3291,\"commentCount\":41,\"publisher\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en#\\\/schema\\\/person\\\/b774e4d64b4766889a2f7c6e5ec85b46\"},\"image\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/lgt8f328p-lqfp32-boards#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/wp-content\\\/uploads\\\/2023\\\/03\\\/postimage_lgt8f328p.jpg\",\"keywords\":[\"Arduino\",\"Bootloader\",\"DAC\",\"DAC0\",\"fastio\",\"HDR\",\"LarduinoISP\",\"LGT8F328P\",\"lgt8fx\",\"LGTISP\",\"LQFP32\",\"Nano\",\"PF1\",\"PF2\",\"Pinout\",\"Pro Mini\",\"programmer\",\"PWM\",\"QFP32L\",\"QFP48L\",\"SSOP20\",\"SWC\",\"SWD\",\"timer\",\"UNO\"],\"articleSection\":[\"Boards and Microcontrollers\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/lgt8f328p-lqfp32-boards#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/lgt8f328p-lqfp32-boards\",\"url\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/lgt8f328p-lqfp32-boards\",\"name\":\"LGT8F328P - LQFP32 Boards &#8226; Wolles Elektronikkiste\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/lgt8f328p-lqfp32-boards#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/lgt8f328p-lqfp32-boards#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/wp-content\\\/uploads\\\/2023\\\/03\\\/postimage_lgt8f328p.jpg\",\"datePublished\":\"2023-05-19T14:37:24+00:00\",\"dateModified\":\"2024-06-06T20:39:45+00:00\",\"description\":\"The LGT8F328P is a microcontroller which is widely compatible with the ATmega328P. I show how to program boards based on it.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/lgt8f328p-lqfp32-boards#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/lgt8f328p-lqfp32-boards\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/lgt8f328p-lqfp32-boards#primaryimage\",\"url\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/wp-content\\\/uploads\\\/2023\\\/03\\\/postimage_lgt8f328p.jpg\",\"contentUrl\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/wp-content\\\/uploads\\\/2023\\\/03\\\/postimage_lgt8f328p.jpg\",\"width\":950,\"height\":950},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\\\/lgt8f328p-lqfp32-boards#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Startseite\",\"item\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"LGT8F328P &#8211; LQFP32 Boards\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en#website\",\"url\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en\",\"name\":\"Wolles Elektronikkiste\",\"description\":\"Die wunderbare Welt der Elektronik\",\"publisher\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en#\\\/schema\\\/person\\\/b774e4d64b4766889a2f7c6e5ec85b46\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/en#\\\/schema\\\/person\\\/b774e4d64b4766889a2f7c6e5ec85b46\",\"name\":\"Wolfgang Ewald\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/wp-content\\\/uploads\\\/2019\\\/03\\\/cropped-Logo-1.png\",\"url\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/wp-content\\\/uploads\\\/2019\\\/03\\\/cropped-Logo-1.png\",\"contentUrl\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/wp-content\\\/uploads\\\/2019\\\/03\\\/cropped-Logo-1.png\",\"width\":512,\"height\":512,\"caption\":\"Wolfgang Ewald\"},\"logo\":{\"@id\":\"https:\\\/\\\/wolles-elektronikkiste.de\\\/wp-content\\\/uploads\\\/2019\\\/03\\\/cropped-Logo-1.png\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"LGT8F328P - LQFP32 Boards &#8226; Wolles Elektronikkiste","description":"The LGT8F328P is a microcontroller which is widely compatible with the ATmega328P. I show how to program boards based on it.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/wolles-elektronikkiste.de\/en\/lgt8f328p-lqfp32-boards","og_locale":"en_US","og_type":"article","og_title":"LGT8F328P - LQFP32 Boards &#8226; Wolles Elektronikkiste","og_description":"The LGT8F328P is a microcontroller which is widely compatible with the ATmega328P. I show how to program boards based on it.","og_url":"https:\/\/wolles-elektronikkiste.de\/en\/lgt8f328p-lqfp32-boards","og_site_name":"Wolles Elektronikkiste","article_published_time":"2023-05-19T14:37:24+00:00","article_modified_time":"2024-06-06T20:39:45+00:00","og_image":[{"width":950,"height":950,"url":"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/postimage_lgt8f328p.jpg","type":"image\/jpeg"}],"author":"Wolfgang Ewald","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Wolfgang Ewald","Est. reading time":"20 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/wolles-elektronikkiste.de\/en\/lgt8f328p-lqfp32-boards#article","isPartOf":{"@id":"https:\/\/wolles-elektronikkiste.de\/en\/lgt8f328p-lqfp32-boards"},"author":{"name":"Wolfgang Ewald","@id":"https:\/\/wolles-elektronikkiste.de\/en#\/schema\/person\/b774e4d64b4766889a2f7c6e5ec85b46"},"headline":"LGT8F328P &#8211; LQFP32 Boards","datePublished":"2023-05-19T14:37:24+00:00","dateModified":"2024-06-06T20:39:45+00:00","mainEntityOfPage":{"@id":"https:\/\/wolles-elektronikkiste.de\/en\/lgt8f328p-lqfp32-boards"},"wordCount":3291,"commentCount":41,"publisher":{"@id":"https:\/\/wolles-elektronikkiste.de\/en#\/schema\/person\/b774e4d64b4766889a2f7c6e5ec85b46"},"image":{"@id":"https:\/\/wolles-elektronikkiste.de\/en\/lgt8f328p-lqfp32-boards#primaryimage"},"thumbnailUrl":"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/postimage_lgt8f328p.jpg","keywords":["Arduino","Bootloader","DAC","DAC0","fastio","HDR","LarduinoISP","LGT8F328P","lgt8fx","LGTISP","LQFP32","Nano","PF1","PF2","Pinout","Pro Mini","programmer","PWM","QFP32L","QFP48L","SSOP20","SWC","SWD","timer","UNO"],"articleSection":["Boards and Microcontrollers"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/wolles-elektronikkiste.de\/en\/lgt8f328p-lqfp32-boards#respond"]}]},{"@type":"WebPage","@id":"https:\/\/wolles-elektronikkiste.de\/en\/lgt8f328p-lqfp32-boards","url":"https:\/\/wolles-elektronikkiste.de\/en\/lgt8f328p-lqfp32-boards","name":"LGT8F328P - LQFP32 Boards &#8226; Wolles Elektronikkiste","isPartOf":{"@id":"https:\/\/wolles-elektronikkiste.de\/en#website"},"primaryImageOfPage":{"@id":"https:\/\/wolles-elektronikkiste.de\/en\/lgt8f328p-lqfp32-boards#primaryimage"},"image":{"@id":"https:\/\/wolles-elektronikkiste.de\/en\/lgt8f328p-lqfp32-boards#primaryimage"},"thumbnailUrl":"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/postimage_lgt8f328p.jpg","datePublished":"2023-05-19T14:37:24+00:00","dateModified":"2024-06-06T20:39:45+00:00","description":"The LGT8F328P is a microcontroller which is widely compatible with the ATmega328P. I show how to program boards based on it.","breadcrumb":{"@id":"https:\/\/wolles-elektronikkiste.de\/en\/lgt8f328p-lqfp32-boards#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/wolles-elektronikkiste.de\/en\/lgt8f328p-lqfp32-boards"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/wolles-elektronikkiste.de\/en\/lgt8f328p-lqfp32-boards#primaryimage","url":"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/postimage_lgt8f328p.jpg","contentUrl":"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2023\/03\/postimage_lgt8f328p.jpg","width":950,"height":950},{"@type":"BreadcrumbList","@id":"https:\/\/wolles-elektronikkiste.de\/en\/lgt8f328p-lqfp32-boards#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Startseite","item":"https:\/\/wolles-elektronikkiste.de\/en"},{"@type":"ListItem","position":2,"name":"LGT8F328P &#8211; LQFP32 Boards"}]},{"@type":"WebSite","@id":"https:\/\/wolles-elektronikkiste.de\/en#website","url":"https:\/\/wolles-elektronikkiste.de\/en","name":"Wolles Elektronikkiste","description":"Die wunderbare Welt der Elektronik","publisher":{"@id":"https:\/\/wolles-elektronikkiste.de\/en#\/schema\/person\/b774e4d64b4766889a2f7c6e5ec85b46"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/wolles-elektronikkiste.de\/en?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":["Person","Organization"],"@id":"https:\/\/wolles-elektronikkiste.de\/en#\/schema\/person\/b774e4d64b4766889a2f7c6e5ec85b46","name":"Wolfgang Ewald","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2019\/03\/cropped-Logo-1.png","url":"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2019\/03\/cropped-Logo-1.png","contentUrl":"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2019\/03\/cropped-Logo-1.png","width":512,"height":512,"caption":"Wolfgang Ewald"},"logo":{"@id":"https:\/\/wolles-elektronikkiste.de\/wp-content\/uploads\/2019\/03\/cropped-Logo-1.png"}}]}},"_links":{"self":[{"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/posts\/17731","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/comments?post=17731"}],"version-history":[{"count":0,"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/posts\/17731\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/media\/17540"}],"wp:attachment":[{"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/media?parent=17731"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/categories?post=17731"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/wolles-elektronikkiste.de\/en\/wp-json\/wp\/v2\/tags?post=17731"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}