<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[forum.rcl-radio.ru &mdash; Частотомер FGT8F328 MAX7219 8 разрядов]]></title>
		<link>http://forum.rcl-radio.ru/viewtopic.php?id=535</link>
		<atom:link href="http://forum.rcl-radio.ru/extern.php?action=feed&amp;tid=535&amp;type=rss" rel="self" type="application/rss+xml" />
		<description><![CDATA[Недавние сообщения в теме «Частотомер FGT8F328 MAX7219 8 разрядов».]]></description>
		<lastBuildDate>Wed, 19 Feb 2025 14:23:32 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: Частотомер FGT8F328 MAX7219 8 разрядов]]></title>
			<link>http://forum.rcl-radio.ru/viewtopic.php?pid=11418#p11418</link>
			<description><![CDATA[<p>Приветсвую всех уч.форума!Ребята,кто поможет?!!,подправить скейч,что бы можно было бы,изменять К дел. для входного делителя частоты и вносить поправку на величину( +-IF пч) и включать\выключать эти величины через внешние кнопки/перемычки,&nbsp; для цифровой шкалы Р.приёмника как сделано здесь:https://www.kn34pc.com/construct/lz2wsg_arduino_ds_sm.html. На МАХ 7219 смотриться гораздо круче!!! Сам в прог. только начинаю разбираться...</p>]]></description>
			<author><![CDATA[null@example.com (ED)]]></author>
			<pubDate>Wed, 19 Feb 2025 14:23:32 +0000</pubDate>
			<guid>http://forum.rcl-radio.ru/viewtopic.php?pid=11418#p11418</guid>
		</item>
		<item>
			<title><![CDATA[Re: Частотомер FGT8F328 MAX7219 8 разрядов]]></title>
			<link>http://forum.rcl-radio.ru/viewtopic.php?pid=10537#p10537</link>
			<description><![CDATA[<div class="quotebox"><cite>liman324 пишет:</cite><blockquote><p>Возможно не верны настройки платы, тактовая вместо 32 МГц работает на частоте 16 МГц</p></blockquote></div><p>В настройках стоял Internal 32 MHz, поменял на External 32MHz- всё стало на свои места. Благодарю!</p>]]></description>
			<author><![CDATA[null@example.com (grass)]]></author>
			<pubDate>Mon, 17 Jun 2024 17:39:39 +0000</pubDate>
			<guid>http://forum.rcl-radio.ru/viewtopic.php?pid=10537#p10537</guid>
		</item>
		<item>
			<title><![CDATA[Re: Частотомер FGT8F328 MAX7219 8 разрядов]]></title>
			<link>http://forum.rcl-radio.ru/viewtopic.php?pid=10536#p10536</link>
			<description><![CDATA[<p>Возможно не верны настройки платы, тактовая вместо 32 МГц работает на частоте 16 МГц</p>]]></description>
			<author><![CDATA[null@example.com (liman324)]]></author>
			<pubDate>Mon, 17 Jun 2024 17:22:41 +0000</pubDate>
			<guid>http://forum.rcl-radio.ru/viewtopic.php?pid=10536#p10536</guid>
		</item>
		<item>
			<title><![CDATA[Re: Частотомер FGT8F328 MAX7219 8 разрядов]]></title>
			<link>http://forum.rcl-radio.ru/viewtopic.php?pid=10535#p10535</link>
			<description><![CDATA[<p>Да.</p>]]></description>
			<author><![CDATA[null@example.com (grass)]]></author>
			<pubDate>Mon, 17 Jun 2024 17:20:25 +0000</pubDate>
			<guid>http://forum.rcl-radio.ru/viewtopic.php?pid=10535#p10535</guid>
		</item>
		<item>
			<title><![CDATA[Re: Частотомер FGT8F328 MAX7219 8 разрядов]]></title>
			<link>http://forum.rcl-radio.ru/viewtopic.php?pid=10534#p10534</link>
			<description><![CDATA[<p>используете FGT8F328?</p>]]></description>
			<author><![CDATA[null@example.com (liman324)]]></author>
			<pubDate>Mon, 17 Jun 2024 17:09:18 +0000</pubDate>
			<guid>http://forum.rcl-radio.ru/viewtopic.php?pid=10534#p10534</guid>
		</item>
		<item>
			<title><![CDATA[Re: Частотомер FGT8F328 MAX7219 8 разрядов]]></title>
			<link>http://forum.rcl-radio.ru/viewtopic.php?pid=10533#p10533</link>
			<description><![CDATA[<p>Здравствуйте! Повторил данную конструкцию, но возник вопрос. При замере контрольной штатной частоты на D11 OUTPUT 8 MHz, показания верны, но при замере меандра из другого источника(генератор Ардуино с управлением через com-порт) показания занижены в 2 раза. Пытался посмотреть осциллограмму на D11 OUTPUT 8 MHz, не смог засинхронизироваться, смесь синусоиды и меандра. И ещё, частотомер(как отдельный узел) из Вашей конструкции <a href="http://rcl-radio.ru/?p=66450">http://rcl-radio.ru/?p=66450</a> частоту 8 MHz от генератора Ардуино показывает корректно. В чем может быть проблема? С уважением!</p>]]></description>
			<author><![CDATA[null@example.com (grass)]]></author>
			<pubDate>Mon, 17 Jun 2024 17:06:06 +0000</pubDate>
			<guid>http://forum.rcl-radio.ru/viewtopic.php?pid=10533#p10533</guid>
		</item>
		<item>
			<title><![CDATA[Re: Частотомер FGT8F328 MAX7219 8 разрядов]]></title>
			<link>http://forum.rcl-radio.ru/viewtopic.php?pid=9738#p9738</link>
			<description><![CDATA[<p>Подскажите- а как регулировать диапазон яркости в строке&nbsp; WriteBit16(0x0A, 0);// яркость</p>]]></description>
			<author><![CDATA[null@example.com (eugen-la)]]></author>
			<pubDate>Mon, 18 Mar 2024 18:30:40 +0000</pubDate>
			<guid>http://forum.rcl-radio.ru/viewtopic.php?pid=9738#p9738</guid>
		</item>
		<item>
			<title><![CDATA[Re: Частотомер FGT8F328 MAX7219 8 разрядов]]></title>
			<link>http://forum.rcl-radio.ru/viewtopic.php?pid=7998#p7998</link>
			<description><![CDATA[<p>oled 0.91&#039; 128x32 i2c</p><p>внести изменения в библиотеку, в файл OLED_I2C.cpp</p><p><span class="postimg"><img src="http://forum.rcl-radio.ru/uploads/images/2023/07/380f4b86669a1c83d1f065233a0025ff.png" alt="http://forum.rcl-radio.ru/uploads/images/2023/07/380f4b86669a1c83d1f065233a0025ff.png" /></span> </p><br /><div class="codebox"><pre><code>#define CAL 62502; //62499 = 1 sec 
#define LED 1
#include &lt;Wire.h&gt; 
#include &lt;OLED_I2C.h&gt;           // http://rcl-radio.ru/wp-content/uploads/2022/01/OLED_I2C.zip

  OLED  myOLED(SDA, SCL, 8);
  extern uint8_t SmallFont[],BigNumbers[];
  unsigned long f_out,tic,n;
 
void setup(){
  PORTD |= (1 &lt;&lt; PD5); // подтягивающий резистор на PD5 (вход T1)
  DDRB |= (1 &lt;&lt; PB3); // D11 OUTPUT 8 MHz
  delay(200);
  noInterrupts();
// TIMER_1 INPUT T1
  TCCR1A = 0;TCCR1B = 0;TCNT1=0;
  TCCR1B = (1 &lt;&lt; CS12) | (1 &lt;&lt; CS11) | (1 &lt;&lt; CS10);
  TIMSK1 = (1 &lt;&lt; TOIE1);
  TCKCSR = (1 &lt;&lt; F2XEN) | (1 &lt;&lt; TC2XS1);
// TIMER_3 1 SEC
  TCCR3A = 0;
  TCCR3B = 0;
  TCNT3=0;
  TCCR3B = (1 &lt;&lt; CS32) | (1 &lt;&lt; WGM32);
  TIMSK3 = (1 &lt;&lt; OCIE3A);
  OCR3A = CAL;
// TIMER_2 OUTPUT 8 MHz
TCCR2A = 0;TCCR2B = 0;TCNT2=0;
  TCCR2A = 1 &lt;&lt; COM2A0 |1 &lt;&lt; WGM21;
  TCCR2B = 1 &lt;&lt; CS20;
  OCR2A = 0;
  interrupts();
  Wire.begin();
  myOLED.begin();
  myOLED.setBrightness(100);
  myOLED.clrScr();
  myOLED.update();
  delay(1000);
  }

void loop(){
  myOLED.clrScr();
  myOLED.setFont(BigNumbers);
if(f_out&gt;=10000000)  myOLED.printNumI(f_out/10000000%10, 0, 35);
if(f_out&gt;=1000000)  myOLED.printNumI(f_out/1000000%10, 15, 35);
if(f_out&gt;=100000)  myOLED.printNumI(f_out/100000%10, 35, 35);
if(f_out&gt;=10000)  myOLED.printNumI(f_out/10000%10, 50, 35);
if(f_out&gt;=1000)  myOLED.printNumI(f_out/1000%10, 65, 35);
if(f_out&gt;=100)  myOLED.printNumI(f_out/100%10, 85, 35);
if(f_out&gt;=10)  myOLED.printNumI(f_out/10%10, 100, 35);
  myOLED.printNumI(f_out/1%10, 115, 35);
  myOLED.update();
  delay(1000);
  if(LED==1){
  if(f_out==0){n++;}else{n=0;}
  if(n&gt;=10){myOLED.setBrightness(0);}else{myOLED.setBrightness(100);}
  }else{myOLED.setBrightness(100);}
  }

ISR(TIMER1_OVF_vect) {tic++;}

ISR(TIMER3_vect) {
  if (TIFR3 &amp; (1 &lt;&lt; OCF3A)){
      TIFR3 = 1 &lt;&lt; OCF3A;
      f_out = tic*0xFFFF + TCNT1;
      tic=0;TCNT1=0;
  }}  </code></pre></div>]]></description>
			<author><![CDATA[null@example.com (liman324)]]></author>
			<pubDate>Fri, 30 Jun 2023 03:14:58 +0000</pubDate>
			<guid>http://forum.rcl-radio.ru/viewtopic.php?pid=7998#p7998</guid>
		</item>
		<item>
			<title><![CDATA[Re: Частотомер FGT8F328 MAX7219 8 разрядов]]></title>
			<link>http://forum.rcl-radio.ru/viewtopic.php?pid=7997#p7997</link>
			<description><![CDATA[<p>Я подумаю над этим вопросом.</p>]]></description>
			<author><![CDATA[null@example.com (liman324)]]></author>
			<pubDate>Sun, 25 Jun 2023 07:23:05 +0000</pubDate>
			<guid>http://forum.rcl-radio.ru/viewtopic.php?pid=7997#p7997</guid>
		</item>
		<item>
			<title><![CDATA[Re: Частотомер FGT8F328 MAX7219 8 разрядов]]></title>
			<link>http://forum.rcl-radio.ru/viewtopic.php?pid=7996#p7996</link>
			<description><![CDATA[<p>А можно сделать версию на OLED&nbsp; дисплее по i2c?</p>]]></description>
			<author><![CDATA[null@example.com (eugen-la)]]></author>
			<pubDate>Sun, 25 Jun 2023 06:25:06 +0000</pubDate>
			<guid>http://forum.rcl-radio.ru/viewtopic.php?pid=7996#p7996</guid>
		</item>
		<item>
			<title><![CDATA[Частотомер FGT8F328 MAX7219 8 разрядов]]></title>
			<link>http://forum.rcl-radio.ru/viewtopic.php?pid=7300#p7300</link>
			<description><![CDATA[<p>Основная статья - <a href="http://rcl-radio.ru/?p=130049">http://rcl-radio.ru/?p=130049</a></p><p><span class="postimg"><img src="http://forum.rcl-radio.ru/uploads/images/2023/01/6b56d6babfa8054d8e0a77523678a040.png" alt="http://forum.rcl-radio.ru/uploads/images/2023/01/6b56d6babfa8054d8e0a77523678a040.png" /></span> </p><br /><div class="codebox"><pre><code>#define DIN PD4
#define CLK PD2
#define CS  PD3
#define CAL 62502; //62499 = 1 sec 

static unsigned long tic,freq;
bool w=1;
byte fq[8],pd,x;

void setup(){
  PORTD |= (1 &lt;&lt; PD5); // подтягивающий резистор на PD5 (вход T1)
  DDRB |= (1 &lt;&lt; PB3); // D11 OUTPUT 8 MHz
  _delay_ms(2);
  DDRD |= (1 &lt;&lt; DIN) | (1 &lt;&lt; CS) | (1 &lt;&lt; CLK);
  PORTD |= (1 &lt;&lt; CS);
  WriteBit16(0x0F, 0);// тест выкл.
  WriteBit16(0x0C, 1);// вкл. индик.
  WriteBit16(0x0A, 0);// яркость
  WriteBit16(0x09, 0xFF);// дешифраторы вкл.
  WriteBit16(0x0B, 7);// кол-во разрядов
  cl();
  _delay_ms(2);
  noInterrupts();
// TIMER_1 INPUT T1
  TCCR1A = 0;TCCR1B = 0;TCNT1=0;
  TCCR1B = (1 &lt;&lt; CS12) | (1 &lt;&lt; CS11) | (1 &lt;&lt; CS10);
  TIMSK1 = (1 &lt;&lt; TOIE1);
  TCKCSR = (1 &lt;&lt; F2XEN) | (1 &lt;&lt; TC2XS1);
// TIMER_3 1 SEC
  TCCR3A = 0;
  TCCR3B = 0;
  TCNT3=0;
  TCCR3B = (1 &lt;&lt; CS32) | (1 &lt;&lt; WGM32);
  TIMSK3 = (1 &lt;&lt; OCIE3A);
  OCR3A = CAL;
// TIMER_2 OUTPUT 8 MHz
TCCR2A = 0;TCCR2B = 0;TCNT2=0;
  TCCR2A = 1 &lt;&lt; COM2A0 |1 &lt;&lt; WGM21;
  TCCR2B = 1 &lt;&lt; CS20;
  OCR2A = 0;
  interrupts();
}

void loop(){
 if(w==1){w=0;
  if(freq&gt;=10000000){WriteBit16(0x0B, 7);x=8;}
  if(freq&lt;10000000&amp;&amp;freq&gt;=1000000){WriteBit16(0x0B, 6);x=7;}
  if(freq&lt;1000000&amp;&amp;freq&gt;=100000){WriteBit16(0x0B, 5);x=6;}
  if(freq&lt;100000&amp;&amp;freq&gt;=10000){WriteBit16(0x0B, 4);x=5;}
  if(freq&lt;10000&amp;&amp;freq&gt;=1000){WriteBit16(0x0B, 3);x=4;}
  if(freq&lt;1000&amp;&amp;freq&gt;=100){WriteBit16(0x0B, 2);x=3;}
  if(freq&lt;100&amp;&amp;freq&gt;=10){WriteBit16(0x0B, 1);x=2;}
  if(freq&lt;10){WriteBit16(0x0B, 0);x=1;}

  fq[7]= freq/10000000%10;
  fq[6]= freq/1000000%10|0b10000000;
  fq[5]= freq/100000%10;
  fq[4]= freq/10000%10;
  fq[3]= freq/1000%10|0b10000000;
  fq[2]= freq/100%10;
  fq[1]= freq/10%10;
  fq[0]= freq%10%10;

  for(int i=0;i&lt;8;i++){WriteBit16(i+1, fq[i]);}
  }
}

ISR(TIMER1_OVF_vect) {tic++;}

ISR(TIMER3_vect) {
  if (TIFR3 &amp; (1 &lt;&lt; OCF3A)){
      TIFR3 = 1 &lt;&lt; OCF3A;
      freq = tic*0xFFFF + TCNT1;
      tic=0;TCNT1=0;
      w=1;
  }
}
void cl(){for(char i=1;i&lt;=8;i++){WriteBit16(i, 0);}}
void WriteBit16(byte reg, byte data){  
     PORTD &amp;= ~(1 &lt;&lt; CLK);PORTD &amp;= ~(1 &lt;&lt; CS);
     for(int i = 7; i &gt;= 0; i--){
        if(((reg &gt;&gt; i) &amp; 1) == 1){PORTD |= (1 &lt;&lt; DIN);}else{PORTD &amp;= ~(1 &lt;&lt; DIN);}
        PORTD |=(1 &lt;&lt; CLK);PORTD &amp;= ~(1 &lt;&lt; CLK);
        }
     for(int i = 7; i &gt;= 0; i--){
        if(((data &gt;&gt; i) &amp; 1) == 1){PORTD |= (1 &lt;&lt; DIN);}else{PORTD &amp;= ~(1 &lt;&lt; DIN);}
        PORTD |=(1 &lt;&lt; CLK);PORTD &amp;= ~(1 &lt;&lt; CLK);
        }
     PORTD &amp;= ~(1 &lt;&lt; CLK);PORTD &amp;= ~(1 &lt;&lt; DIN);PORTD |=(1 &lt;&lt; CS);
  }</code></pre></div>]]></description>
			<author><![CDATA[null@example.com (liman324)]]></author>
			<pubDate>Tue, 24 Jan 2023 09:43:57 +0000</pubDate>
			<guid>http://forum.rcl-radio.ru/viewtopic.php?pid=7300#p7300</guid>
		</item>
	</channel>
</rss>
