mobilspy
Üye
- Katılım
- 13 Eki 2006
- Mesajlar
- 122
- Puanları
- 1
- Yaş
- 45
Arkadaslar suan için bu çalışmayı sonlandırdım. Çünki amacıma ulastım. suan baskı devreyi hazırlıyorum ve devrenin calışmayacağını duşunen varsa yazsın calıştıgını kanıtlayan videoyuda eklerim çalışmamı sizinlede paylaşmak istedim baskı devre ve pbp kodları asada, hepinize iyi çalışmalar.
belki hex koduda lazım olur:
Kod:
TRISA=%00001111
TRISB=0
TRISD=%00000000
TRISC=%00000011
PORTD=0
PORTC=0
INPUT PORTC.0
INPUT PORTC.1
OUTPUT PORTC.7
OUTPUT PORTD.2
OUTPUT PORTD.1
OUTPUT PORTD.0
LOW PORTC.7
DEFINE LCD_DREG PORTB
DEFINE LCD_DBIT 4
DEFINE LCD_EREG PORTB
DEFINE LCD_EBIT 3
DEFINE LCD_RSREG PORTB
DEFINE LCD_RSBIT 2
DEFINE LCD_BITS 4
DEFINE LCD_LINES 2
DEFINE ADC_BITS 10
DEFINE ADC_CLOCK 1000
DEFINE ADC_SAMPLEUS 1000
ADCON1=%10000010
A VAR WORD
B VAR WORD
C VAR WORD
I VAR BYTE
ZMN VAR BYTE
FNC VAR BYTE
STRT VAR BYTE
STP VAR BYTE
TARA:
FNC = 0
IF PORTC.0 = 1 THEN CALIS
IF PORTC.1 = 1 THEN GOTO DUR
BUTTON PORTC.2, 1, 250, 250, FNC, 1, FUNC
ADCIN 0,A
ADCIN 1,B
ADCIN 2,C
A = ((A / 8) * 300) / 127
B = ((B / 8) * 300) / 127
C = ((C / 8) * 300) / 127
LCDOUT $FE,1
LCDOUT "1= ",DEC A,"V."
LCDOUT "2= ",DEC B, "V."
LCDOUT $FE,$C0
LCDOUT "3= ",DEC C, "V."
IF A < 170 THEN GOTO HATA
IF B < 170 THEN GOTO HATA
IF C < 170 THEN GOTO HATA
IF PORTD.0 = 1 THEN LCDOUT " START"
IF PORTD.0 = 0 THEN LCDOUT " STOP"
GOTO TARA
CALIS:
IF A < 170 THEN GOTO HATA
IF B < 170 THEN GOTO HATA
IF C < 170 THEN GOTO HATA
IF PORTD.0=1 THEN GOTO TARA
IF PORTD.1=1 THEN GOTO TARA
IF PORTD.2=1 THEN GOTO TARA
HIGH PORTD.0
HIGH PORTD.1
HIGH PORTD.2
HIGH PORTC.7
LCDOUT $FE,1
LCDOUT "START - YILDIZ"
GOTO YILUC
DUR:
IF PORTD.0 = 0 THEN GOTO TARA
IF PORTD.1 = 0 THEN GOTO TARA
IF PORTD.2 = 0 THEN GOTO TARA
LOW PORTD.0
LOW PORTD.1
LOW PORTD.2
LOW PORTC.7
LOW PORTD.3
LOW PORTD.4
LOW PORTD.5
LOW PORTC.3
LOW PORTC.4
LOW PORTC.5
GOTO TARA
YILUC:
I = 0
READ 4, ZMN
HIGH PORTD.3
HIGH PORTD.4
HIGH PORTD.5
FOR I = 0 TO 1000
I = I + 1
PAUSE ZMN
NEXT
LOW PORTD.0
LOW PORTD.1
LOW PORTD.2
LOW PORTD.3
LOW PORTD.4
LOW PORTD.5
PAUSE 700
HIGH PORTD.0
HIGH PORTD.1
HIGH PORTD.2
HIGH PORTC.3
HIGH PORTC.4
HIGH PORTC.5
LCDOUT $FE,1
LCDOUT "START - UCGEN"
PAUSE 100
GOTO TARA
HATA :
IF A < 170 THEN GOTO HATA1
IF B < 170 THEN GOTO HATA2
IF C < 170 THEN GOTO HATA3
GOTO TARA
HATA1:
LCDOUT $FE,1
LCDOUT "HATA1.HATDUSUKV."
LCDOUT $FE,$C0
IF B > 170 THEN LCDOUT "2= ",DEC B,"V."
IF C > 170 THEN LCDOUT "3= ",DEC C,"V."
PAUSE 500
GOTO DUR
HATA2:
LCDOUT $FE,1
LCDOUT "HATA2.HATDUSUKV."
LCDOUT $FE,$C0
IF A > 170 THEN LCDOUT "1= ",DEC A,"V."
IF C > 170 THEN LCDOUT "3= ",DEC C,"V."
PAUSE 500
GOTO DUR
HATA3:
LCDOUT $FE,1
LCDOUT "HATA3.HATDUSUKV."
LCDOUT $FE,$C0
IF A > 170 THEN LCDOUT "1= ",DEC A,"V."
IF B > 170 THEN LCDOUT "2= ",DEC B,"V."
PAUSE 500
GOTO DUR
FUNC:
PAUSE 100
LCDOUT $FE,1
LCDOUT " AYAR MENU "
GOTO MENU
MENU :
PAUSE 500
FNC = 0
STRT = 0
STP = 0
LCDOUT $FE,1
LCDOUT "FUNC - START"
LCDOUT $FE,$C0
LCDOUT "ZAMANLA FAB.AYAR"
BUTTON PORTC.0, 1, 254, 254, STRT, 1, FABAY
BUTTON PORTC.1, 1, 254, 254, STP, 1, TARA
BUTTON PORTC.2, 1, 254, 254, FNC, 1, ZAMANLA
GOTO MENU
FABAY:
ZMN = 7
WRITE 4, ZMN
LCDOUT $FE,1
PAUSE 500
GOTO MENU
ZAMANLA:
STRT = 0
STP = 0
FNC = 0
PAUSE 100
LCDOUT $FE,1
LCDOUT " ZAMAN AYARI "
LCDOUT $FE,$C0
LCDOUT " ", #ZMN, " SANIYE"
BUTTON PORTC.2, 1, 254, 254, FNC, 1, MENU
BUTTON PORTC.1, 1, 254, 254, STP, 1, DOWN
BUTTON PORTC.0, 1, 254, 254, STRT, 1, UP
GOTO ZAMANLA
UP :
ZMN = ZMN + 1
WRITE 4, ZMN
PAUSE 100
GOTO ZAMANLA
DOWN:
ZMN = ZMN - 1
WRITE 4, ZMN
PAUSE 100
GOTO ZAMANLA
END
belki hex koduda lazım olur:
Kod:
:10000000B601FE280408A700861106110611831602
:100010008611061106110F30860583122708B618BF
:100020002F283A30A1009830A1203330A600432079
:100030001330A1008830A12043206430A020432049
:100040006430A0202230A600432028302E200C301F
:100050002E2006302E20B61427082F283614A6008E
:10006000361C3D280611033C031C42284220073061
:10007000A100D030A120031408003614FE3C03195F
:10008000F9280615361C361086150F308605260809
:10009000F03986048611A60E361843283230A02087
:1000A00003140800B71329080319B7170530A8006F
:1000B0002730A300103068200330A300E830682008
:1000C000A30164306820A3010A30682024086F2847
:1000D000A2002508A1002408A000D8202008A00024
:1000E000A8030319B713290803197928280203184C
:1000F00008002008031DB713B71B0800303EF42882
:10010000A000A00DA00D200D383901389F0003304C
:10011000A100E830A1201F151F198C281E08A1007E
:1001200083161E08F928A301A200FF30A207031CB2
:10013000A307031CF9280330A100DF30A120952874
:10014000A101E83EA000A109FC30031CAA28A007D9
:100150000318A728A0076400A10FA7282018B0281B
:10016000A01CB4280000B4280800A2000330C12855
:10017000A2000130C128A2000630C128A20004302C
:10018000C128A80023082102031DC8282208200234
:10019000043003180130031902302805031DFF3015
:1001A000F9280038031DFF300405031DFF30F9282E
:1001B000A501A4011030A600210DA40DA50D220853
:1001C000A4022308031C230FA5020318EE2822080B
:1001D000A40723080318230FA5070310A00DA10DE2
:1001E000A60BDC282008F928840031088A00300892
:1001F00082008313031383126400080083160F30F8
:1002000085008601880103308700831288018701F9
:10021000831682309F0007148714871308118810F3
:1002200008108312871383168713831264008A11C0
:100230000A120718F22D64008A110A12871C23295A
:100240008A110A12442E8A110A1228298A011629B3
:1002500000308A018020BC002108BD0001308A01E5
:100260008020BE002108BF0002308A018020C0002B
:100270002108C1003C08A0003D08A100A3010230F4
:100280008A01B5208A110A12031D4829BC01BD014B
:100290003C08A0003D08A100A30167308A01BE20F0
:1002A000B2003C08A0003D08A100A30101308A0172
:1002B000B820B4003208840034088A01D120B40088
:1002C000B5006400340835048A110A1203196B2939
:1002D0001630BC00BD013C08A0003D08A100A301F0
:1002E000CE308A01BE20B2003C08A0003D08A1002B
:1002F000A30166308A01B820B400320884003408B3
:100300008A01D120B400B5006400340835048A1194
:100310000A1203198E292C30BC00BD013C08A00034
:100320003D08A1000130A30034308A01BE20B20094
:100330003C08A0003D08A100A301CD308A01B820EF
:10034000B4003208840034088A01D120B400B5001A
:100350006400340835048A110A120319B2294230A4
:10036000BC00BD013C08A0003D08A1000130A30075
:100370009A308A01BE20B2003C08A0003D08A100CE
:100380000130A30033308A01B820B4003208840061
:1003900034088A01D120B400B50064003408350463
:1003A0008A110A120319D7295830BC00BD013C0834
:1003B000A0003D08A1000230A30000308A01BE2049
:1003C000B2003C08A0003D08A1000130A300993014
:1003D0008A01B820B4003208840034088A01D12090
:1003E000B400B5006400340835048A110A120319F8
:1003F000FC296E30BC00BD013C08A0003D08A100F6
:100400000230A30067308A01BE20B2003C08A00081
:100410003D08A1000130A300FF308A01B820B400DC
:100420003208840034088A01D120B400B500640089
:10043000340835048A110A120319212A8430BC00B9
:10044000BD013C08A0003D08A1000230A300CD3052
:100450008A01BE20B2003C08A0003D08A100023085
:10046000A30066308A01B820B40032088400340842
:100470008A01D120B400B5006400340835048A1123
:100480000A120319462A9A30BC00BD013C08A0009C
:100490003D08A1000330A30034308A01BE20B20021
:1004A0003C08A0003D08A1000230A300CC308A0126
:1004B000B820B4003208840034088A01D120B40086
:1004C000B5006400340835048A110A1203196B2A36
:1004D000B030BC00BD013C08A0003D08A1000330C5
:1004E000A3009A308A01BE20B2003C08A0003D085B
:1004F000A1000330A30033308A01B820B4003208D1
:10050000840034088A01D120B400B50064003408A6
:1005100035048A110A120319902AC630BC00BD01A5
:100520003C08A0003D08A1000330A30099308A01D7
:10053000BB208A110A12031DA02ADC30BC00BD01B9
:100540003E08A0003F08A100A30102308A01B520A7
:100550008A110A12031DAE2ABE01BF013E08A00087
:100560003F08A100A30167308A01BE20B2003E0807
:10057000A0003F08A100A30101308A01B820B40007
:100580003208840034088A01D120B400B500640028
:10059000340835048A110A120319D12A1630BE0014
:1005A000BF013E08A0003F08A100A301CE308A0190
:1005B000BE20B2003E08A0003F08A100A3016630A3
:1005C0008A01B820B4003208840034088A01D1209E
:1005D000B400B5006400340835048A110A12031906
:1005E000F42A2C30BE00BF013E08A0003F08A10045
:1005F0000130A30034308A01BE20B2003E08A000C2
:100600003F08A100A301CD308A01B820B400320810
:10061000840034088A01D120B400B5006400340895
:1006200035048A110A120319182B4230BE00BF018B
:100630003E08A0003F08A1000130A3009A308A01C3
:10064000BE20B2003E08A0003F08A1000130A30078
:1006500033308A01B820B4003208840034088A019B
:10066000D120B400B5006400340835048A110A12A0
:1006700003193D2B5830BE00BF013E08A0003F08C3
:10068000A1000230A30000308A01BE20B2003E0863
:10069000A0003F08A1000130A30099308A01B820D2
:1006A000B4003208840034088A01D120B400B500B7
:1006B0006400340835048A110A120319622B6E3063
:1006C000BE00BF013E08A0003F08A1000230A30009
:1006D00067308A01BE20B2003E08A0003F08A1009A
:1006E0000130A300FF308A01B820B4003208840032
:1006F00034088A01D120B400B50064003408350400
:100700008A110A120319872B8430BE00BF013E08EC
:10071000A0003F08A1000230A300CD308A01BE2016
:10072000B2003E08A0003F08A1000230A3006630DE
:100730008A01B820B4003208840034088A01D1202C
:10074000B400B5006400340835048A110A12031994
:10075000AC2B9A30BE00BF013E08A0003F08A100AC
:100760000330A30034308A01BE20B2003E08A0004E
:100770003F08A1000230A300CC308A01B820B400A9
:100780003208840034088A01D120B400B500640026
:10079000340835048A110A120319D12BB030BE0077
:1007A000BF013E08A0003F08A1000330A3009A301B
:1007B0008A01BE20B2003E08A0003F08A10003301D
:1007C000A30033308A01B820B40032088400340812
:1007D0008A01D120B400B5006400340835048A11C0
:1007E0000A120319F62BC630BE00BF013E08A00056
:1007F0003F08A1000330A30099308A01BB208A1171
:100800000A12031D062CDC30BE00BF014008A00008
:100810004108A100A30102308A01B5208A110A1201
:10082000031D142CC001C1014008A0004108A10013
:10083000A30167308A01BE20B2004008A000410831
:10084000A100A30101308A01B820B400320884005D
:1008500034088A01D120B400B5006400340835049E
:100860008A110A120319372C1630C000C101400842
:10087000A0004108A100A301CE308A01BE20B20031
:100880004008A0004108A100A30166308A01B820F9
:10089000B4003208840034088A01D120B400B500C5
:1008A0006400340835048A110A1203195A2C2C30BA
:1008B000C000C1014008A0004108A1000130A30010
:1008C00034308A01BE20B2004008A0004108A100D7
:1008D000A301CD308A01B820B40032088400340866
:1008E0008A01D120B400B5006400340835048A11AF
:1008F0000A1203197E2C4230C000C1014008A0003A
:100900004108A1000130A3009A308A01BE20B20044
:100910004008A0004108A1000130A30033308A0143
:10092000B820B4003208840034088A01D120B40011
:10093000B5006400340835048A110A120319A32C87
:100940005830C000C1014008A0004108A100023099
:10095000A30000308A01BE20B2004008A000410878
:10096000A1000130A30099308A01B820B4003208F8
:10097000840034088A01D120B400B5006400340832
:1009800035048A110A120319C82C6E30C000C10147
:100990004008A0004108A1000230A30067308A018E
:1009A000BE20B2004008A0004108A1000130A30011
:1009B000FF308A01B820B4003208840034088A016C
:1009C000D120B400B5006400340835048A110A123D
:1009D0000319ED2C8430C000C1014008A00041087B
:1009E000A1000230A300CD308A01BE20B200400831
:1009F000A0004108A1000230A30066308A01B8209F
:100A0000B4003208840034088A01D120B400B50053
:100A10006400340835048A110A120319122D9A3021
:100A2000C000C1014008A0004108A1000330A3009C
:100A300034308A01BE20B2004008A0004108A10065
:100A40000230A300CC308A01B820B4003208840000
:100A500034088A01D120B400B5006400340835049C
:100A60008A110A120319372DB030C000C1014008A5
:100A7000A0004108A1000330A3009A308A01BE20E3
:100A8000B2004008A0004108A1000330A3003330A9
:100A90008A01B820B4003208840034088A01D120C9
:100AA000B400B5006400340835048A110A12031931
:100AB0005C2DC630C000C1014008A0004108A10063
:100AC0000330A30099308A01BB208A110A12031D4A
:100AD0006C2DDC30C000C101FE308A0103200130E2
:100AE0008A01032031308A0103203D308A0103202E
:100AF00020308A010320A9013C08A4003D08A5007C
:100B00000230B000B1018A01522076308A01032000
:100B10002E308A01032032308A0103203D308A01C1
:100B2000032020308A010320A9013E08A4003F08C9
:100B3000A5000230B000B1018A01522076308A014E
:100B400003202E308A010320FE308A010320C030AA
:100B50008A01032033308A0103203D308A010320BB
:100B600020308A010320A9014008A4004108A50003
:100B70000230B000B1018A01522076308A01032090
:100B80002E308A0103203C08A0003D08A100A301EB
:100B900078308A01B5208A110A12031DD22D8A11DC
:100BA0000A12442E3E08A0003F08A100A30178309D
:100BB0008A01B5208A110A12031DE12D8A110A1239
:100BC000442E4008A0004108A100A30178308A010A
:100BD000B5208A110A12031DF02D8A110A12442E23
:100BE0008A0116293C08A0003D08A100A301783025
:100BF0008A01B5208A110A12031D002E8A011629C6
:100C00003E08A0003F08A100A30178308A01B5206A
:100C10008A110A12031D0E2E8A0116294008A0000F
:100C20004108A100A30178308A01B5208A110A1277
:100C3000031D1C2E8A01162964008A110A12081C41
:100C4000232E8A01162964008A110A12881C2A2E72
:100C50008A01162964008A110A12081D312E8A01A0
:100C60001629081483160810831288148316881016
:100C700083120815831608118312871783168713AA
:100C800083128A110A12832E64008A110A1208182C
:100C90004B2E8A01162964008A110A128818522ED6
:100CA0008A01162964008A110A120819592E8A012C
:100CB00016290810831608108312881083168810CE
:100CC0008312081183160811831287138316871362
:100CD0008312881183168811831208128316081252
:100CE0008312881283168812831287118316871144
:100CF0008312071283160712831287128316871234
:100D000083128A0116298815831688118312081602
:100D100083160812831288168316881283121B30DA
:100D2000A30058308A0194200810831608108312FB
:100D300088108316881083120811831608118312F5
:100D400088118316881183120812831608128312E1
:100D500088128316881283120230A300BC308A01E5
:100D600094200814831608108312881483168810A0
:100D700083120815831608118312871583168711AD
:100D8000831207168316071283128716831687129B
:0C0D900083128A01162963008A01CB2E11
:02400E00753FFC
:00000001FF