頠 88,9 -108 , , 頠 ().

() - RS-232 ( ʠ USB , USB RS-232, ).

.1. C 堠 DA2 KP174XA34 ( TDA7021T).   , , www.radio.ru/support/001 ( 廠 17434 .).

.1 -

, 頠 L1, C7, C8, 蠠 DA2 700 , , , , .   . R3  . 9 (GND) .

HL1 , .
() 16 DA2 R7 14 DA4 , K17414 ( TDA2003), 8 12 - 4 5.

VD1. DA3 (78L05) DA1 (78L03) DA2 3B, , 帠 , .
L1 , 3 4,5 -2 젠 0,47 . , 帠 1 젠 ( - 45 ). L2 7,5 , .

堠 ATtiny2313, ʠ RS-232, DD2 (MAX3232) (c ⠠ 2, 3, 5, 6) DB9-F, . -16S2H ( ). ࠠ BASCOM ( 2.0.5.0), . BASCOM λ.

堠 , , 젠 , .. Π (.1) Π (.0) ࠠ ࠠ . ( , .. ) . , R10, CE2, VT1, VT3, CE3, R12, C24. VD1 , , .

BASCOM :
1. ̠ ( Timer1) 255 3,1 -3,2  VD1 .
2. ̠ 150 .
3. , 堠 (, , ) ʠ ( ) , ENTER. : Enter READeeprom (0), > - (1), <- (2), Stop (3):. , 0, ( ) (EEPROM). 1, ̠ 5 , 0,1 . 2 ̠ 5 . 3 , , .

HL1, Ƞ Radio SCAN, 廠 .   Ƞ ̠ ( Timer1), . (. .2).

. 2

ࠠ Retrans 頠 ̠ . www.AVR.ru Bascom ( 13).
.   Timer1 (255). ࠠ , - Compare1A , Pulse 1 (PORTB.3). RxD , , ompare1A.  Ƞ Bascom. INT0 Scan 廠 Ƞ Radio SCAN.

:

$regfile = "attiny2313a.dat"
$crystal = 4000000
$hwstack = 40
$swstack = 16
$framesize = 32
$sim

Config Pind.0 = Input 'UART RxD
Config Pind.1 = Output 'UART TxD
Config Int0 = Falling '
Config Pind.2 = Input ' INT0
Config Portb.3 = Output 'OC1A- TIMER1
Config Debounce = 200 ' 200
Config Timer1 = Pwm , Prescale = 64 , Compare A = Toggle , Clear Timer = 0 '

$eeprom '
Number:
Data 10%

Dim Counters As Word '
Dim N As Byte
Dim Z As Byte
Dim X As Byte

N = 150
Compare1a = N
Cls
Lcd "N=" ; N

On Urxc Rxd '
On Compare1a Pulse
On Int0 Scan

Enable Interrupts '
Enable Urxc
Enable Compare1a
Enable Int0

Stop Timer1 '
Timer1 = 0

Do '
Stop Timer1 '
Counters = Timer1 '
If Counters => 255 Then '
Toggle Portb.3 '
Timer1 = 0 '
End If
Start Timer1 '
Loop

Rxd: '
Do
Wait 1 ' 1
Input "Enter READeeprom-(0),>-(1), <-(2), Stop-(3) :" , X '

If N = 0 Then '
N = N + 5
Cls
Lcd "N=" ; N
Print "N=" ; N
Wait 1
End If

If N => 255 Then '
N = N - 5
Cls
Lcd "N=" ; N
Print "N=" ; N
Wait 1
End If

If X = 0 Then ' Compare1A EEPROM
Readeeprom Z , Number
N = Z
Cls
Lcd "N=" ; N
Print "N=" ; N
Compare1a = N
Wait 1
Exit Do
End If

If X = 1 Then '
N = N + 5
Cls
Lcd "N=" ; N
Print "N=" ; N
Compare1a = N
Wait 1
Exit Do
End If

If X = 2 Then '
N = N - 5
Cls
Lcd "N=" ; N
Print "N=" ; N
Compare1a = N
Wait 1
Exit Do
End If

If X = 3 Then ' EEPROM
Cls
Lcd "N=" ; N
Print "N=" ; N
Z = N
Writeeeprom Z , Number
Compare1a = N
Wait 1
Exit Do
End If
Loop
Return

Pulse: ' 3 Compare1A
Toggle Portb.3
Return

Scan: '
Print "Radio SCAN" '
Lowerline
Lcd "Radio SCAN" '
Return

End 'end program

.

andre