/branches/V0.63_LED1_LED2/GPS.c |
---|
0,0 → 1,30 |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Copyright (c) 04.2007 Holger Buss |
// + only for non-profit use |
// + www.MikroKopter.com |
// + see the File "License.txt" for further Informations |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
#include "main.h" |
signed int GPS_Nick = 0; |
signed int GPS_Roll = 0; |
long GpsAktuell_X = 0; |
long GpsAktuell_Y = 0; |
long GpsZiel_X = 0; |
long GpsZiel_Y = 0; |
void GPS_Neutral(void) |
{ |
GpsZiel_X = GpsAktuell_X; |
GpsZiel_Y = GpsAktuell_Y; |
} |
void GPS_BerechneZielrichtung(void) |
{ |
GPS_Nick = 0; |
GPS_Roll = 0; |
} |
/branches/V0.63_LED1_LED2/Hex-Files/BootLoader_MEGA644_20MHZ_V0_1.hex |
---|
0,0 → 1,64 |
:10F8000011241FBECFEFD0E1DEBFCDBF11E0A0E0DD |
:10F81000B1E0E0EEFBEF02C005900D92A030B10721 |
:10F82000D9F712E0A0E0B1E001C01D92A230B1070B |
:10F83000E1F70C943B7C0C941D7C0895982F8091EB |
:10F84000C00085FFFCCF9093C60008958091C00052 |
:10F850008823E4F78091C600992708958DE40E94DB |
:10F860001E7C8BE40E941E7C82E40E941E7C8CE441 |
:10F870000E941E7C0895CFEFD0E1DEBFCDBFE0E057 |
:10F88000F0E014915F01772474BE98E10FB6F8940C |
:10F8900090936000109260000FBE7092C5008AE2E3 |
:10F8A0008093C4008091C00082608093C0009093D8 |
:10F8B000C10086E08093C200EF01072D8091C00057 |
:10F8C00087FF0DC0013031F48091C6008A3AB1F152 |
:10F8D00000E005C08091C6008B3109F401E0CE0143 |
:10F8E00021968436910528F11F3F41F0112331F014 |
:10F8F000E0910001F091010109951BC01092C50033 |
:10F900008AE28093C4008AE00E941E7C8DE00E94FF |
:10F910001E7C86E50E941E7C80E30E941E7C8EE297 |
:10F920000E941E7C81E30E941E7C8AE30E941E7C52 |
:10F9300005C080E593EC0197F1F7C0CF0E942E7CC3 |
:10F940000E94267C813611F489E547C1813471F427 |
:10F950000E94267CA82EBB24BA2CAA240E94267CB6 |
:10F960009927A82AB92AB694A79406C1823629F401 |
:10F9700089E50E941E7C81E00BC1823409F083C0BE |
:10F980000E94267C9927D82FCC270E94267C992775 |
:10F99000C82BD92B0E94267C082F12E0812E11E063 |
:10F9A000912EEE24FF2464010894811C911CEC1616 |
:10F9B000FD0618F40E94267C01C08FEFD6018C93BF |
:10F9C0000894E11CF11CBFEFEB16F10461F358F34E |
:10F9D000E4E77E1609F0DEC0063409F03DC0FFEF13 |
:10F9E000AF16F7EFBF0608F033C0DE01A5016627AA |
:10F9F0007727440F551F661F771F6A017B01C2E0FE |
:10FA0000D1E001E08991992729913327322F2227CC |
:10FA1000822B932B0C01FA0100935700E8951124D7 |
:10FA20004E5F5F4F6F4F7F4F129761F785E0F60192 |
:10FA300080935700E89507B600FCFDCF81E18093E5 |
:10FA40005700E89576956795579547955A0194C064 |
:10FA500080E00E941E7C90C0053409F08DC0F50145 |
:10FA60009E01A2E0B1E0E1BD8F2F992782BD8D916B |
:10FA700080BD3196FA9AF99AF999FECF215030401B |
:10FA800091F75F0179C0873609F047C00E94267C54 |
:10FA90009927D82ECC240E94267C9927C82AD92AB7 |
:10FAA0000E94267C863411F5E6016501EE24FF24D0 |
:10FAB000CC0CDD1CEE1CFF1CF60105911491802F6F |
:10FAC0000E941E7C812F99270E941E7C82E090E07C |
:10FAD000A0E0B0E0C80ED91EEA1EFB1E229761F717 |
:10FAE000F694E794D794C79456012ACF853409F049 |
:10FAF00027CF7501E1BC8F2D992782BDF89A089414 |
:10FB0000E11CF11C80B50E941E7C0894C108D1083C |
:10FB1000C114D10479F7570113CF853601F594E765 |
:10FB2000791651F580E090E0A0E0B0E023E0FC0120 |
:10FB300020935700E89507B600FCFDCF80509F4FFB |
:10FB4000AF4FBF4F8F3FE7EF9E07E0E0AE07E0E02B |
:10FB5000BE0768F381E180935700E8950DC08534B6 |
:10FB600069F488E190E02CE00FB6F894A8958093B2 |
:10FB700060000FBE209360008DE02FC08035E1F360 |
:10FB80008C34D1F3803711F483E527C0843721F416 |
:10FB90000E941E7C80E021C0843521F40E94267CD6 |
:10FBA000782EEACF8B3109F4C9CE8A3A09F4C6CE51 |
:10FBB000863529F480E30E941E7C81E30EC08337E2 |
:10FBC00041F489E00E941E7C86E90E941E7C8EE141 |
:10FBD00004C08B3109F4B4CE8FE30E941E7CB0CEFA |
:040000030000F80001 |
:00000001FF |
/branches/V0.63_LED1_LED2/Hex-Files/Flight-Ctrl_MEGA644_V0_63.hex |
---|
0,0 → 1,1533 |
:100000000C94EC010C9407020C9407020C94070268 |
:100010000C9407020C9407020C9407020C9407023C |
:100020000C9407020C94490B0C9407020C940702E1 |
:100030000C94F0150C9407020C9407020C94070220 |
:100040000C9407020C9407020C94530A0C940702B8 |
:100050000C942C040C9407020C94F6030C940702E5 |
:100060000C944E0C0C9407020C941A150C94070275 |
:100070000A0D466C69676874436F6E74726F6C0A20 |
:100080000D48617264776172653A25642E25640AB1 |
:100090000D536F6674776172653A5625642E256438 |
:1000A00020000A0D3D3D3D3D3D3D3D3D3D3D3D3D3D |
:1000B0003D3D3D3D3D3D3D3D3D3D3D3D3D3D3D3D70 |
:1000C0003D3D000A0D496E69742E20454550524F42 |
:1000D0004D3A2047656E65726965726520446566B4 |
:1000E00061756C742D506172616D657465722E2E30 |
:1000F0002E000A0D42656E75747A6520506172613A |
:100100006D657465727361747A202564000A0D410F |
:1001100062676C65696368204C75667464727563A8 |
:100120006B73656E736F722E2E004F4B0A0D000AB3 |
:100130000D537465756572756E673A200048656188 |
:1001400064696E67486F6C64004E65757472616CAB |
:10015000000A0A0D002E005B25695D002B2B204D47 |
:10016000696B726F4B6F70746572202B2B00485750 |
:100170003A5625642E25642053573A25642E25646B |
:100180000053657474696E673A2025642000286303 |
:100190002920486F6C676572204275737300486F41 |
:1001A0006568653A202020202025356900536F6C52 |
:1001B0006C486F6568653A20253569004C75667432 |
:1001C000647275636B3A20253569004F666620209E |
:1001D000202020203A20253569004B65696E652076 |
:1001E0000048F668656E726567656C756E670061DC |
:1001F0006B742E204C616765004E69636B3A20205A |
:100200002020202025356900526F6C6C3A20202078 |
:10021000202020253569004B6F6D706173733A2083 |
:100220002020253569004B313A25346920204B3296 |
:100230003A25346920004B333A25346920204B3469 |
:100240003A25346920004B353A25346920204B3655 |
:100250003A25346920004B373A25346920204B3841 |
:100260003A25346920004E693A2534692020526FBE |
:100270003A253469200047733A25346920204769BC |
:100280003A253469200050313A2534692020503213 |
:100290003A253469200050333A25346920205034FF |
:1002A0003A25346920004779726F202D2053656EFE |
:1002B000736F72004E69636B2025346920282533E3 |
:1002C000692900526F6C6C20253469202825336918 |
:1002D000290047696572202534692028253369295A |
:1002E00000414343202D2053656E736F72004E69A9 |
:1002F000636B2025346920282533692900526F6CEF |
:100300006C2025346920282533692900486F6368EB |
:1003100020253469202825336929005370616E6EC9 |
:10032000756E673A202025356900456D70662E5040 |
:100330006567656C3A253569004B6F6D7061737345 |
:1003400020202020202020005269636874756E6789 |
:100350003A2020253569004D657373776572743ACC |
:1003600020202535690053746172743A20202020C2 |
:100370002025356900506F7469313A202025336992 |
:1003800000506F7469323A202025336900506F7431 |
:1003900069333A202025336900506F7469343A205C |
:1003A0002025336900536572766F202000536574F1 |
:1003B000706F696E742020253369005374656C6C0E |
:1003C000756E673A202533690052616E67653A257C |
:1003D00033692D253369000011241FBECFEFD0E112 |
:1003E000DEBFCDBF11E0A0E0B1E0E0E3FFE502C079 |
:1003F00005900D92A039B107D9F715E0A0E9B1E059 |
:1004000001C01D92A333B107E1F70C9442020C9492 |
:100410000000FB01863008F085E0489FD0011124E0 |
:10042000AC59BF4F842F9927019724F00E94842F45 |
:100430000192FACF0895282FFB01863008F025E0BD |
:10044000429FD0011124AC59BF4F842F99270197A7 |
:1004500024F001900E948C2FFACFA2E0B0E0022E8F |
:100460000E948C2F0895A2E0B0E09D010E94842F8D |
:10047000802D863028F082E0D901082E0E948C2F32 |
:1004800099270895CFEFD0E1DEBFCDBF189B02C002 |
:100490008BE001C08AE08093000181E887B98FEF8B |
:1004A00088B98BE184B981E085B98EE38AB9579A1E |
:1004B00087EF8BB984B7877F84BF809160008861A4 |
:1004C000809360001092600080ED97E09093AA0105 |
:1004D0008093A9011092E3011092E2011092BC04F2 |
:1004E0001092BB041092E5011092E4011092E70112 |
:1004F0001092E601809100018A3011F4289801C021 |
:10050000289A0E940A0B0E94DA060E94DB150E94BC |
:10051000000C0E94E31478941092BA038FE3809346 |
:10052000BB0385E08093BC038FE390E09F938F93A0 |
:100530001F921F92809100016AE00E94142F892F60 |
:1005400099279F938F93809100010E94142F9927E0 |
:100550009F938F9380E790E09F938F931F920E94C9 |
:10056000C9078DB79EB70B960FB6F8949EBF0FBE06 |
:100570008DBF82EA90E09F938F931F920E94C907DC |
:10058000299A0F900F900F90C1E0D0E0DE010E94F9 |
:10059000842F802D8E3329F183EC90E09F938F93ED |
:1005A0001F920E94C9070E94971C10E00F900F90A5 |
:1005B0000F90123011F40E940E1D4AE363EE74E0B6 |
:1005C000812F0E941B021F5F163098F3A2E0B0E05B |
:1005D00082E0082E0E948C2F8EE3DE01082E0E94FE |
:1005E0008C2F0E9433024AE363EE74E00E940902FA |
:1005F0000E94330299279F938F9382EF90E09F93FD |
:100600008F931F920E94C9078091EB040F900F9067 |
:100610000F900F900F9080FF20C08DE091E09F938E |
:100620008F931F920E94C90788EE93E00E94010BEE |
:100630007C010E94060C0F900F900F90C7010E9442 |
:10064000300B8823D9F38AE291E09F938F931F9216 |
:100650000E94C9070F900F900F900E94731880910D |
:1006600000018A3011F4289801C0289A80ED97E0A3 |
:100670009093AA018093A90188EE93E09093B5032B |
:100680008093B40385E58093AF038FE291E09F935D |
:100690008F931F920E94C9078091EB040F900F90D7 |
:1006A0000F9082FF03C08DE391E002C089E491E0E6 |
:1006B0009F938F931F920E94C9070F900F900F90E6 |
:1006C00081E591E09F938F931F920E94C9070E943A |
:1006D000491088E893E190937F0180937E010F9009 |
:1006E0000F900F908091AD01882309F451C01092B2 |
:1006F000AD010E94CD1F0E94501C209100012A30A4 |
:1007000011F4289801C0289A80910101882319F0DA |
:100710008150809301018091E801882329F0809124 |
:10072000E80181508093E80180917E0190917F01E2 |
:10073000892B01F585E090E090937F0180937E0105 |
:100740000E94FD1480910301909104018F5F9F4FDF |
:10075000F9F48091E1018823D9F080E197E2909348 |
:10076000AA018093A90180E890E09093040180930E |
:1007700003010EC080917E0190917F0101979093BB |
:100780007F0180937E012A3011F4289801C0289AB5 |
:100790000E94F8060E941606C7010E94300B8823AB |
:1007A00009F4A0CF8091FB04282F332780910D01FD |
:1007B00090910E01821793079CF480910301909110 |
:1007C00004018F5F9F4F61F480E797E19093AA0146 |
:1007D0008093A90180E093E090930401809303014A |
:1007E00084E690E00E94010B7C017CCF1F920F9267 |
:1007F0000FB60F9211248F939F93EF93FF938091E5 |
:1008000002018823E1F480919E0190919F0101965D |
:1008100090939F0180939E01FC01EF57FD4FE08173 |
:10082000ED3019F08639910539F410929F0110923C |
:100830009E0181E080930201E093C60004C0109203 |
:100840009F0110929E01FF91EF919F918F910F90C8 |
:100850000FBE0F901F9018951F920F920FB60F9218 |
:1008600011242F933F934F935F938F939F93AF9355 |
:10087000BF93EF93FF9390E08091C600809399011E |
:100880005091A401563910F09093A50180919901DF |
:100890008D3009F05FC08091A501823009F05AC007 |
:1008A0009093A501852F99278C539C4FFC0132977B |
:1008B00040812091A0013091A101241B3109DC016C |
:1008C00011978C91281B3109C9019F709093A10148 |
:1008D0008093A00146E0969587954A95E1F7982F79 |
:1008E000935C9093A2012F733070235C2093A3013B |
:1008F0008081981729F48C91281711F491E006C093 |
:1009000090E0809196018F5F80939601809198018D |
:10091000882309F06EC0992309F46BC081E08093AD |
:10092000980150939501E52FFF27EC53FC4F8DE084 |
:1009300080838091C603823509F05BC088E190E036 |
:100940002CE00FB6F894A895809360000FBE20931A |
:1009500060004FC02091A501822F99278130910519 |
:10096000F9F0823091051CF4892B21F040C00297E8 |
:1009700011F13DC080919901833239F48091980141 |
:10098000882319F481E08093A501809199018093D7 |
:10099000C40381E08093A40180919901992722C02A |
:1009A0002F5F2093A501E52FFF27EC53FC4F80918B |
:1009B0009901808309C0E52FFF27EC53FC4F8091FC |
:1009C00099018083563920F45F5F5093A40102C0DF |
:1009D0001092A501209199018091A0019091A1010F |
:1009E000820F911D9093A1018093A00102C01092EB |
:1009F000A501FF91EF91BF91AF919F918F915F9171 |
:100A00004F913F912F910F900FBE0F901F9018950F |
:100A1000AC01A0E0B0E09D01A817B90748F4E1E8F7 |
:100A2000F2E08191280F311D1196A417B507C8F384 |
:100A30003F70FD01EF57FD4FC90156E09695879530 |
:100A40005A95E1F7835C80831196FD01EF57FD4FC6 |
:100A50002F733070822F835C8083AE57BD4F8DE043 |
:100A60008C9310920201809181028093C6000895B8 |
:100A70001F93CF93DF93382FEA01722F10E083E2A8 |
:100A8000809381026093820230938302A3E0B0E0FE |
:100A9000772309F458C0772311F4972F07C0FE017C |
:100AA000E10FF11D1F5F9081715011F4472F0EC0AF |
:100AB000FE01E10FF11D1F5F4081715039F0FE0111 |
:100AC000E10FF11D1F5F6081715001C0672FFD01B3 |
:100AD000EF57FD4F892F86958695835C808311960D |
:100AE000FD01EF57FD4F892F99278370907024E007 |
:100AF000880F991F2A95E1F755279A0194E03695BA |
:100B000027959A95E1F7822B835C80831196FD01EE |
:100B1000EF57FD4F4F705070440F551F440F551F36 |
:100B2000862F992726E0969587952A95E1F7842BBD |
:100B3000835C80831196FD01EF57FD4F6F73635CFB |
:100B400060831196A5CFCD010E940805DF91CF915A |
:100B50001F9108951F93CF93DF93EC0110E066235C |
:100B600009F460C0A22FBB271297E42FFF27EC5394 |
:100B7000FC4F30813D534F5FE42FFF27EC53FC4F78 |
:100B800050815D534F5FE42FFF27EC53FC4F708182 |
:100B90007D534F5FE42FFF27EC53FC4FE081ED5373 |
:100BA0004F5F842F9927A817B907E4F1832F99275E |
:100BB000880F991F880F991F352F32953F70382B5A |
:100BC000852F99278F709070F4E0880F991FFA9500 |
:100BD000E1F7572F56955695582B872F99278370F5 |
:100BE000907076E0880F991F7A95E1F78E2B61500F |
:100BF0006F3FC1F0FE01E10FF11D30831F5F6150B7 |
:100C00006F3F81F0FE01E10FF11D50831F5F6150C6 |
:100C10006F3F41F0FE01E10FF11D80831F5F6623EE |
:100C200009F0A3CFDF91CF911F910895CF93DF9368 |
:100C3000CDB7DEB72B970FB6F894DEBF0FBECDBF92 |
:100C400080919801882309F49AC08FEF8093010165 |
:100C50008091C6039927813791059CF48C369105C4 |
:100C60000CF06EC08736910509F444C088369105B2 |
:100C700024F48336910599F080C088369105D9F027 |
:100C80007CC08437910549F18537910524F481377B |
:100C90009105A1F172C08637910541F16EC0209196 |
:100CA000950143E06BE08FEA93E00E94AA0581E0A2 |
:100CB00080939B0162C02091950143E062E0CE01E8 |
:100CC0000A960E94AA058091CB019A85892B809370 |
:100CD000CB0181E080939C0150C02091950143E0BD |
:100CE00064E080E991E00E94AA0547C081E080931A |
:100CF0009A0143C081E080939D013FC020919501FE |
:100D000043E062E0CE010A960E94AA058A858F3FE1 |
:100D100061F0863010F085E08A874AE363EE74E084 |
:100D20008A850E9409028A8502C00E9433022AE352 |
:100D300043EE54E060918002855B0E9438051DC03F |
:100D40002091950143E06AE383EE94E00E94AA05B6 |
:100D50008091C6034AE363EE74E08B560E941B0247 |
:100D6000A2E0B0E08091C6038B56082E0E948C2F23 |
:100D70000E94330299270E94B416109298012B9674 |
:100D80000FB6F894DEBF0FBECDBFDF91CF910895AF |
:100D9000CF93C82F8A3019F48DE00E94C806809145 |
:100DA000C00085FFFCCFC093C60080E090E0CF91EB |
:100DB0000895089588E18093C1008091C000826009 |
:100DC0008093C0008091C10080688093C1008091B1 |
:100DD000C10080648093C1008AE28093C40088ECE3 |
:100DE00090E00E94010B9093AE038093AD030895B1 |
:100DF00080910201882309F471C080919D018823AC |
:100E000071F080910201882351F02BE04FEA53E00A |
:100E10006091800287E40E94380510929D018091C4 |
:100E2000AD039091AE030E94300B882321F4809192 |
:100E30009B018823B1F080910201882391F022E484 |
:100E40004AE554E06091800284E40E9438051092E3 |
:100E50009B0184EF91E00E94010B9093AE0380937D |
:100E6000AD0380919C01882339F180910201882390 |
:100E700019F10E94521010929C013091A601832F0B |
:100E80008F5F8093A601843059F426E147EB54E04C |
:100E900060E084E30E9438058FEF8093A6010CC0C8 |
:100EA00024E1829FC0011124815F9E4FAC0160E06C |
:100EB000832F8F5C0E94380580919A01882371F0FE |
:100EC00080910201882351F02AE04AEB53E06091BF |
:100ED000800286E50E94380510929A010895982FA5 |
:100EE00080919C04813069F48091CC01E82FFF2728 |
:100EF000E15FFE4F90838F5F8093CC0121E030E073 |
:100F000005C0892F0E94C806282F3327C9010895DC |
:100F10000F931F93CF93DF938C01EB01672B39F075 |
:100F2000F80181918F010E946F072197C9F7DF9126 |
:100F3000CF911F910F9108950F931F93CF93DF933C |
:100F40008C01EB01672B41F0F8010F5F1F4F84917B |
:100F50000E946F072197C1F7DF91CF911F910F91E9 |
:100F60000895CF93C82F181634F480E20E946F07BB |
:100F7000C1501C16D4F3CF910895CF93C82F1816E3 |
:100F800034F480E30E946F07C1501C16D4F3CF9154 |
:100F900008952F923F924F925F926F927F928F921D |
:100FA0009F92AF92BF92CF92DF92EF92FF920F93F8 |
:100FB0001F93CF93DF93CDB7DEB7E0970FB6F894CA |
:100FC000DEBF0FBECDBF26968FAD26972896EEAD1D |
:100FD000FFAD28971CA61DA61EA61FA680939C04E5 |
:100FE000A8E46A2E712C6C0E7D1E5F01C50105C040 |
:100FF000053239F00894A11CB11CF50104910023BD |
:10100000B9F7B501681B790B11F00E949C0700230A |
:1010100009F430C20894A11CB11C552458AA252CEF |
:101020001FEF59A6F5010894A11CB11C04910537C6 |
:1010300021F0802F80628837F1F450FE0EC0F3015A |
:1010400024E030E0620E731E80819181A281B38121 |
:101050008CA79DA7AEA7BFA70EC0F301A2E0B0E08A |
:101060006A0E7B1E808191819C01442755272CA705 |
:101070003DA74EA75FA7003221F489A5882391F6EA |
:101080001BC0033211F438E081C00A3211F00D3276 |
:1010900089F40A3251F4F30142E050E0640E751E07 |
:1010A000208022200CF0BECF219450E1552A8FEDF4 |
:1010B0005822B8CF0B3211F409A7B4CF0E32C1F5C4 |
:1010C000F5010894A11CB11C04910A3279F4F301D2 |
:1010D000A2E0B0E06A0E7B1E60817181BFEF6F3FBE |
:1010E0007B0714F46FEF7FEF162F9CCF60E070E06A |
:1010F000802F80538A30A0F4CB01F3E0880F991F32 |
:10110000FA95E1F7860F971F680F791F600F711D21 |
:1011100060537040F5010894A11CB11C0491E8CF04 |
:10112000EFEF6F3F7E0714F46FEF7FEF162F7FCF47 |
:10113000003329F454FC76CFF0E25F2A73CF802F7E |
:1011400081538930D8F460E070E0CB01E3E0880F90 |
:10115000991FEA95E1F7860F971F680F791F600FB7 |
:10116000711D60537040F5010894A11CB11C0491DD |
:10117000802F80538A3048F3262E59CF083619F431 |
:1011800024E0522A4FCF0C3619F431E0532A4ACFCB |
:10119000033661F44E010894811C911CF30142E076 |
:1011A00050E0640E751E808189831BC1043421F0D8 |
:1011B000043611F00936B1F5043411F451E0552A22 |
:1011C00050FE0AC0F30184E090E0680E791E208191 |
:1011D0003181428153810CC0F30142E050E0640E42 |
:1011E000751E808191819C01442737FD4095542FC5 |
:1011F0002CA73DA74EA75FA78CA59DA5AEA5BFA513 |
:10120000B7FF0DC0B095A095909581959F4FAF4FBA |
:10121000BF4F8CA79DA7AEA7BFA78DE289A77AE095 |
:10122000472E7BC00F3411F00F3639F40F3411F410 |
:1012300091E0592A68E0462E6FC00037A1F4F3010F |
:10124000A2E0B0E06A0E7B1E808191819C01442760 |
:1012500055272CA73DA74EA75FA750E1452E30E4A8 |
:10126000532A08E759C00337C1F5F30142E050E0C3 |
:10127000640E751E808091808114910489F44E0162 |
:101280000894811C911C88E289838EE6F401818395 |
:1012900085E78B838CE68C838D8389E28E831F8226 |
:1012A00017FD13C0812F992787FD9095AC0160E051 |
:1012B00070E0C4010E94802D009729F0D82ED81824 |
:1012C0001D150CF090C0D12E8EC0F40101900020AD |
:1012D000E9F73197DE2ED81886C0053511F00537AD |
:1012E00039F4053511F4F1E05F2A4AE0442E14C0C8 |
:1012F000083519F0083709F06CC030E1432E53FE71 |
:101300000BC02CA53DA54EA55FA5211531054105B6 |
:10131000510511F030E4532A19A618AB17FD02C08D |
:101320004FED542229E2822E912C8C0E9D1E8CA50D |
:101330009DA5AEA5BFA50097A105B10521F498A96B |
:10134000992309F43FC0C42CDD24EE24FF24332468 |
:101350002CA53DA54EA55FA52C153D054E055F05A9 |
:1013600010F091E0392E6CA57DA58EA59FA5A70153 |
:1013700096010E94472FDC01CB01182F8A3010F410 |
:10138000105D04C0195A083509F41F7DD4011E935D |
:101390004D016CA57DA58EA59FA5A70196010E9474 |
:1013A000472F2CA73DA74EA75FA7332081F6B8E0B3 |
:1013B0004B1641F453FE06C0103321F080E3F401D4 |
:1013C00082934F01CE010196D82ED818F8E2DF0E95 |
:1013D0000BC0002309F44EC04E010894811C911CDF |
:1013E000098381E0D82E19A61D2DC8A8CD18C7FCE9 |
:1013F000CC2489A5882311F01F5F02C056FC1E5F14 |
:101400001C0DE52CFF24C70180739070892B21F4FB |
:10141000822D811B0E94B10789A5882329F061E0F4 |
:1014200070E0CE01899609C0E6FE09C080E38AA774 |
:101430000BA762E070E0CE018A960E948807C70180 |
:1014400080739070809721F4822D811B0E94BD07CC |
:101450008C2D0E94BD078D2D992787FD9095BC018D |
:10146000C4010E948807E4FEC1CD822D811B0E9429 |
:10147000B107BCCDE0960FB6F894DEBF0FBECDBF6E |
:10148000DF91CF911F910F91FF90EF90DF90CF9060 |
:10149000BF90AF909F908F907F906F905F904F9094 |
:1014A0003F902F9008951F920F920FB60F92112424 |
:1014B0002F933F935F936F937F938F939F93AF93FC |
:1014C000BF938091B00181508093B0018F3FB9F4F8 |
:1014D00089E08093B001809105018F5F81708093D6 |
:1014E0000501882319F481E08093AD018091AE015C |
:1014F0009091AF0101969093AF018093AE018091DE |
:10150000A9019091AA010297C8F08091A901909138 |
:10151000AA0101979093AA018093A9018091A90142 |
:101520009091AA0120910301309104018223932319 |
:10153000892B11F021E009C020E007C020E08FEFE7 |
:101540009FEF909304018093030180910001222377 |
:1015500031F08A3011F45A9A07C0479A05C08A3090 |
:1015600011F45A9801C047988091EB0483FF3BC067 |
:10157000349B0AC08091AB019091AC01019690938D |
:10158000AC018093AB012FC08091AB019091AC0175 |
:10159000892B79F08091AB019091AC01805A9F40EA |
:1015A00040F48091AB019091AC019093F80180934D |
:1015B000F7018091F7019091F8012091F5013091A8 |
:1015C000F601821B930B845E9D4F68E671E00E94DA |
:1015D000342F845B90409093F4018093F301109238 |
:1015E000AC011092AB01BF91AF919F918F917F9110 |
:1015F0006F915F913F912F910F900FBE0F901F90B1 |
:1016000018952091AE013091AF01280F391FC90103 |
:10161000019608958AE090E00E94010B9093B20138 |
:101620008093B10182E085BD83EA84BD17BC88E761 |
:1016300088BD96E096BD83EC8093B0009093B10096 |
:101640008091700082608093700080916E00816054 |
:1016500080936E008AE08093B3001092B2000895E8 |
:101660002091AE013091AF01821B930B892F9927F6 |
:101670008695807490700895CF93DF930E94010B3C |
:10168000EC01CE010E94300B8823D9F3DF91CF917A |
:1016900008951F920F920FB60F9211242F933F932C |
:1016A0004F935F936F937F938F939F93AF93BF936A |
:1016B000CF93DF93EF93FF93809106018150809346 |
:1016C00006018F3F09F085C083E88093B0008091C8 |
:1016D0006C01C82FDD27D093A801C093A70180918A |
:1016E0000C056091050580FF2AC077278827992778 |
:1016F0002091250230912602409127025091280224 |
:1017000057FF04C021583F4F4F4F5F4FA7E05595FB |
:10171000479537952795AA95D1F70E94F52E97FF03 |
:1017200004C061507E4F8F4F9F4FF9E0959587958C |
:1017300077956795FA95D1F7C60FD71F29C07727F8 |
:10174000882799272091250230912602409127026F |
:101750005091280257FF04C021583F4F4F4F5F4F11 |
:10176000E7E05595479537952795EA95D1F70E947B |
:10177000F52E97FF04C061507E4F8F4F9F4F39E089 |
:1017800095958795779567953A95D1F7C61BD70BB1 |
:10179000D093A801C093A7018091060599272091B5 |
:1017A000A7013091A8012817390734F08091070567 |
:1017B00099278217930724F49093A8018093A70197 |
:1017C0008091A7018093B300809108058093060162 |
:1017D00004C083E08093B0005F98FF91EF91DF91A8 |
:1017E000CF91BF91AF919F918F917F916F915F91B9 |
:1017F0004F913F912F910F900FBE0F901F90189512 |
:1018000010927C008FEE80937A0008950F931F93BF |
:10181000CF93DF9303E010E0D8010E94842F802D46 |
:10182000C82FDD27C531D10508F02A97C7BD84E64A |
:1018300090E00E943C0B8091070190910801825535 |
:10184000934010F4C0E0D0E0CA3FD105C0F4C7BD5A |
:1018500082E390E00E943C0B85E591E09F938F939B |
:101860001F920E94C90780910701909108010F9073 |
:101870000F900F908458934010F02196E5CFD80137 |
:101880000C2E0E948C2FC093AA048CE291E00E943F |
:101890003C0BDF91CF911F910F9108951F920F92F2 |
:1018A0000FB60F921124EF92FF920F931F932F9375 |
:1018B0003F934F935F936F937F938F939F93AF93D8 |
:1018C000BF93CF93DF93EF93FF9310927A008091B1 |
:1018D000CA01682F77278F5F8093CA016330710533 |
:1018E00009F4BCC1643071055CF46130710509F420 |
:1018F00071C0623071050CF00FC1672B91F0A7C366 |
:101900006530710509F4EAC1653071050CF4C1C197 |
:101910006630710509F408C26730710509F417C310 |
:1019200096C3609133027091340280917800909157 |
:101930007900681B790B809100018A3011F0660FE5 |
:10194000771F8091C3019091C401860F971F9093D8 |
:10195000C4018093C3018091BA018F5F8093BA0163 |
:101960009B01442737FD4095542F809101029091AF |
:101970000202A0910302B0910402820F931FA41FE0 |
:10198000B51F8093010290930202A0930302B093CB |
:1019900004028091FD019091FE01A091FF01B091A0 |
:1019A0000002820F931FA41FB51F8093FD01909327 |
:1019B000FE01A093FF01B093000281E08093C90172 |
:1019C0008091B3019091B40101969093B4018093FA |
:1019D000B30141C360917800709179008091350224 |
:1019E00090913602681B790B809100018A3011F0CA |
:1019F000660F771F9B01442737FD4095542F809138 |
:101A0000090290910A02A0910B02B0910C02820F80 |
:101A1000931FA41FB51F8093090290930A02A093FD |
:101A20000B02B0930C028091050290910602A091E6 |
:101A30000702B0910802820F931FA41FB51F809365 |
:101A4000050290930602A0930702B09308028091CA |
:101A5000090290910A02A0910B02B0910C02815FE1 |
:101A60009A4BA440B04064F080E393E9ABEFBFEF42 |
:101A70008093090290930A02A0930B02B0930C0288 |
:101A80008091090290910A02A0910B02B0910C0280 |
:101A900080519544AB4FBF4F64F480ED9CE6A4E0C9 |
:101AA000B0E08093090290930A02A0930B02B093D6 |
:101AB0000C0280917800909179000F9710F468E102 |
:101AC0007CEF8091780090917900079710F460E3A3 |
:101AD00078EF8091780090917900835F934010F0C7 |
:101AE00068EE73E080917800909179008A5F93406E |
:101AF00010F060ED77E08091C5019091C601860FEE |
:101B0000971F9093C6018093C5018091BB018F5FA1 |
:101B10008093BB0182E0DFC0609178007091790012 |
:101B20008091370290913802681B790B80910001F7 |
:101B30008A3011F0660F771F9B01442737FD4095CF |
:101B4000542F8091110290911202A0911302B09132 |
:101B50001402820F931FA41FB51F8093110290934C |
:101B60001202A0931302B093140280910D0290917F |
:101B70000E02A0910F02B0911002820F931FA41FBA |
:101B8000B51F80930D0290930E02A0930F02B093A5 |
:101B900010028091110290911202A0911302B09153 |
:101BA0001402815F9A4BA440B04064F080E393E953 |
:101BB000ABEFBFEF8093110290931202A093130238 |
:101BC000B09314028091110290911202A09113021D |
:101BD000B091140280519544AB4FBF4F64F480ED37 |
:101BE0009CE6A4E0B0E08093110290931202A093CF |
:101BF0001302B093140280917800909179000F97AE |
:101C000010F468E17CEF809178009091790007975B |
:101C100010F460E378EF8091780090917900835F11 |
:101C2000934010F068EE73E0809178009091790015 |
:101C30008A5F934010F060ED77E08091C70190914A |
:101C4000C801860F971F9093C8018093C7018091A8 |
:101C5000BC018F5F8093BC0184E03DC080910D0189 |
:101C600090910E019C01220F331F280F391F809184 |
:101C70007800909179000E94202F260F371F36950B |
:101C800027953695279530930E0120930D0186E018 |
:101C900022C080912F0290913002209178003091E3 |
:101CA0007900821B930B90939E0480939D048091F6 |
:101CB000C1019091C20120919D0430919E04820F38 |
:101CC000931F9093C2018093C1018091B8018F5FEF |
:101CD0008093B80187E08093C901BDC180917800ED |
:101CE000909179002091310230913202821B930B46 |
:101CF0009093A9048093A8048091BF019091C001A2 |
:101D00002091A8043091A904820F931F9093C001E1 |
:101D10008093BF018091B9018F5F8093B90185E005 |
:101D20008093C90186E010C180917800909179007C |
:101D3000AA2797FDA095BA2FBC01CD010E94332E92 |
:101D40007B018C0180912B0290912C02A0912D029D |
:101D5000B0912E029C01AD01C801B7010E948D2DEA |
:101D6000DC01CB01BC01CD010E94162EDC01CB01B0 |
:101D70009093BE018093BD0180919D0490919E043B |
:101D800080919D0490919E0497FF03C0909581954A |
:101D90009F4F97FD0396AC015595479555954795EF |
:101DA0008091A8049091A9048091A8049091A9041D |
:101DB00097FF03C0909581959F4F9C0197FF02C0AC |
:101DC0002D5F3F4F3595279535952795240F351F66 |
:101DD0008091BD019091BE01820F931F9093BE012F |
:101DE0008093BD018091BD019091BE01029724F1C5 |
:101DF00080912B0290912C02A0912D02B0912E0285 |
:101E000020E030E048E454E4BC01CD010E943D2EC6 |
:101E100088230CF044C080912B0290912C02A09159 |
:101E20002D02B0912E022AE037ED43EA5CE3BC01BB |
:101E3000CD010E948E2D29C08091BD019091BE01DF |
:101E40008F5F9F4F64F580912B0290912C02A0919F |
:101E50002D02B0912E0220E030E046E154E4BC01B6 |
:101E6000CD010E94402E1816D4F480912B0290913F |
:101E70002C02A0912D02B0912E022AE037ED43EA08 |
:101E80005CE3BC01CD010E948D2DDC01CB01809370 |
:101E90002B0290932C02A0932D02B0932E0281E08E |
:101EA0008093B70180917800909179009093A0047D |
:101EB00080939F048091BD019091BE019C014427B5 |
:101EC00037FD4095542F8091F9019091FA01A0912E |
:101ED000FB01B091FC01820F931FA41FB51F8093DB |
:101EE000F9019093FA01A093FB01B093FC012091BA |
:101EF000F9013091FA014091FB015091FC0157FF2B |
:101F000004C021503C4F4F4F5F4F7AE055954795A5 |
:101F1000379527957A95D1F78091F9019091FA013B |
:101F2000A091FB01B091FC01821B930BA40BB50B9C |
:101F30008093F9019093FA01A093FB01B093FC0107 |
:101F400083E08093C90187E08093CA0184C08091B7 |
:101F5000AD049091AE042091780030917900820F09 |
:101F6000931F9093AE048093AD048091A5048F5F7E |
:101F70008093A5048091A504853008F468C0809101 |
:101F80007800909179009093080180930701109256 |
:101F9000A5048091A1049091A2042091AD043091F8 |
:101FA000AE04821B930B2091DF013091E001821B74 |
:101FB000930B9093B6018093B5018091AD049091FD |
:101FC000AE04EC01EE27D7FDE095FE2F209109012C |
:101FD00030910A0140910B0150910C01DA01C901C5 |
:101FE000880F991FAA1FBB1F820F931FA41FB51F25 |
:101FF000C80FD91FEA1FFB1FF7FF03C02396E11D7F |
:10200000F11D82E0F595E795D795C7958A95D1F7AB |
:10201000C0930901D0930A01E0930B01F0930C01E6 |
:102020008091090190910A01A0910B01B0910C01DE |
:102030009C018091A1049091A204821B930B909328 |
:10204000E0018093DF011092AE041092AD04109273 |
:10205000C9011092CA018091C90180937C008FEE62 |
:1020600080937A00FF91EF91DF91CF91BF91AF9173 |
:102070009F918F917F916F915F914F913F912F91A0 |
:102080001F910F91FF90EF900F900FBE0F901F9038 |
:10209000189590E2EFE0F1E08FE49193815087FF93 |
:1020A000FCCF08951F93CF93DF938091CB0180FFE6 |
:1020B0000CC08091CF01882311F0815002C0809123 |
:1020C00069018093CF010E9449108091CB0181FF6B |
:1020D00007C08091CF018F5F8093CF010E9449108C |
:1020E0008091CB01992780FF04C081FF02C010922C |
:1020F000CF0181E18093CC018091CF0199279F93FB |
:102100008F9387E591E09F938F9311E01F930E9437 |
:10211000C9070F900F900F900F900F908091CF01F3 |
:10212000C82FDD27C530D10509F459C2C630D10505 |
:10213000ACF4C230D10509F4DEC0C330D10534F4AB |
:10214000209719F1219709F46EC032C4C330D1052C |
:1021500009F43FC1249709F4A7C12AC4C830D105A6 |
:1021600009F43EC3C930D10544F4C630D10509F4A1 |
:10217000A5C2279709F414C31BC4C930D10509F4BB |
:1021800071C32A9709F4C2C313C41092CC018CE521 |
:1021900091E09F938F931F930E94C90784E18093DE |
:1021A000CC010F900F900F908FE390E09F938F934F |
:1021B000DF93CF93809100016AE00E94142F892F52 |
:1021C00099279F938F93809100010E94142F992744 |
:1021D0009F938F938EE691E09F938F931F930E941E |
:1021E000C90788E28093CC018DB79EB70B960FB6D6 |
:1021F000F8949EBF0FBE8DBF0E94330299279F9314 |
:102200008F9381E891E09F938F931F930E94C9075A |
:102210008CE38093CC010F900F900F900F900F9054 |
:102220008EE891E05FC08091EB0480FF49C010927E |
:10223000CC018091DF019091E0019F938F938EE913 |
:1022400091E09F938F931F930E94C90784E180932D |
:10225000CC010F900F900F900F900F908091DD01A7 |
:102260009091DE019F938F938DEA91E09F938F93DE |
:102270001F930E94C90788E28093CC010F900F90B2 |
:102280000F900F900F9080910701909108019F93FC |
:102290008F938CEB91E09F938F931F930E94C907BC |
:1022A0008CE38093CC010F900F900F900F900F90C4 |
:1022B0008091AA0499279F938F938BEC91E01BC385 |
:1022C00084E18093CC018AED91E09F938F931F93DB |
:1022D0000E94C90788E28093CC010F900F900F9065 |
:1022E00081EE91E09F938F931F930E94C9070F90F7 |
:1022F0000F900F9062C31092CC018FEE91E09F93EC |
:102300008F931F930E94C90784E18093CC010F90A3 |
:102310000F900F908091250290912602A0912702A4 |
:10232000B0912802B7FF04C081509C4FAF4FBF4F00 |
:102330003AE0B595A795979587953A95D1F7BF93CC |
:10234000AF939F938F9389EF91E09F938F931F9308 |
:102350000E94C90788E28093CC018DB79EB707968B |
:102360000FB6F8949EBF0FBE8DBF80911D02909155 |
:102370001E02A0911F02B0912002B7FF04C081503D |
:102380009C4FAF4FBF4F2AE0B595A795979587957E |
:102390002A95D1F7BF93AF939F938F9388E092E0F4 |
:1023A0009F938F931F930E94C9078CE38093CC0166 |
:1023B0008DB79EB707960FB6F8949EBF0FBE8DBF20 |
:1023C0008091F7019091F8019F938F9387E192E0BC |
:1023D00092C21092CC018091BB049091BC049F9357 |
:1023E0008F938091B9049091BA049F938F9386E262 |
:1023F00092E09F938F931F930E94C90784E180937B |
:10240000CC018DB79EB707960FB6F8949EBF0FBE4E |
:102410008DBF8091BF049091C0049F938F93809152 |
:10242000BD049091BE049F938F9386E392E09F93A7 |
:102430008F931F930E94C90788E28093CC018DB7C8 |
:102440009EB707960FB6F8949EBF0FBE8DBF8091C2 |
:10245000C3049091C4049F938F938091C104909181 |
:10246000C2049F938F9386E492E09F938F931F9370 |
:102470000E94C9078CE38093CC018DB79EB7079665 |
:102480000FB6F8949EBF0FBE8DBF8091C704909188 |
:10249000C8049F938F938091C5049091C6049F9325 |
:1024A0008F9386E592E076C21092CC018091E4048D |
:1024B000E82FFF27EE0FFF1FE954FB4F808191812A |
:1024C0009F938F938091E304E82FFF27EE0FFF1F68 |
:1024D000E954FB4F808191819F938F9386E692E030 |
:1024E0009F938F931F930E94C90784E18093CC012F |
:1024F0008DB79EB707960FB6F8949EBF0FBE8DBFDF |
:102500008091E604E82FFF27EE0FFF1FE954FB4FF1 |
:10251000808191819F938F938091E504E82FFF271D |
:10252000EE0FFF1FE954FB4F808191819F938F93A2 |
:1025300086E792E09F938F931F930E94C90788E2DA |
:102540008093CC018DB79EB707960FB6F8949EBFC7 |
:102550000FBE8DBF8091E804E82FFF27EE0FFF1F0D |
:10256000E954FB4F808191819F938F938091E70481 |
:10257000E82FFF27EE0FFF1FE954FB4F8081918169 |
:102580009F938F9386E892E09F938F931F930E946F |
:10259000C9078CE38093CC018DB79EB707960FB621 |
:1025A000F8949EBF0FBE8DBF8091EA04E82FFF27ED |
:1025B000EE0FFF1FE954FB4F808191819F938F9312 |
:1025C0008091E904E82FFF27EE0FFF1FE954FB4F2E |
:1025D000808191819F938F9386E992E0DBC1109275 |
:1025E000CC0186EA92E09F938F931F930E94C907C4 |
:1025F00084E18093CC010F900F900F90809137026F |
:10260000909138029F938F938091BC01282F33279C |
:102610008091C7019091C801B9010E94342F7F9326 |
:102620006F9384EB92E09F938F931F930E94C9074F |
:1026300088E28093CC018DB79EB707960FB6F894C9 |
:102640009EBF0FBE8DBF80913502909136029F9341 |
:102650008F938091BB01282F33278091C5019091E2 |
:10266000C601B9010E94342F7F936F9383EC92E0EF |
:102670009F938F931F930E94C9078CE38093CC0193 |
:102680008DB79EB707960FB6F8949EBF0FBE8DBF4D |
:1026900080913302909134029F938F938091BA017D |
:1026A000282F33278091C3019091C401B9010E9462 |
:1026B000342F7F936F9382ED92E06CC11092CC0126 |
:1026C00081EE92E09F938F931F930E94C90784E14C |
:1026D0008093CC010F900F900F90809131029091D8 |
:1026E00032029F938F938091B901282F33278091D5 |
:1026F000BF019091C001B9010E94342F7F936F9365 |
:102700008EEE92E09F938F931F930E94C90788E2F9 |
:102710008093CC018DB79EB707960FB6F8949EBFF5 |
:102720000FBE8DBF80912F02909130029F938F93A7 |
:102730008091B801282F33278091C1019091C20167 |
:10274000B9010E94342F7F936F938DEF92E09F9396 |
:102750008F931F930E94C9078CE38093CC018DB7A0 |
:102760009EB707960FB6F8949EBF0FBE8DBF80919F |
:102770002B0290912C02A0912D02B0912E02BC014F |
:10278000CD010E94162EDC01CB019F938F93809187 |
:102790009F049091A0049F938F938CE093E0FAC0E4 |
:1027A00084E18093CC0180910D0190910E019F9363 |
:1027B0008F938BE193E09F938F931F930E94C907A0 |
:1027C00088E28093CC010F900F900F900F900F90A4 |
:1027D0008091E80199279F938F938AE293E08BC0C1 |
:1027E0001092CC0189E393E09F938F931F930E94F3 |
:1027F000C90784E18093CC010F900F900F908091D6 |
:10280000F3019091F4019F938F9388E493E09F9359 |
:102810008F931F930E94C90788E28093CC010F9089 |
:102820000F900F900F900F908091F7019091F80109 |
:102830009F938F9387E593E09F938F931F930E94BD |
:10284000C9078CE38093CC010F900F900F900F90ED |
:102850000F908091F5019091F6019F938F9386E6FA |
:1028600093E049C01092CC018091EF019091F0016A |
:102870009F938F9385E793E09F938F931F930E947D |
:10288000C90784E18093CC010F900F900F900F90B7 |
:102890000F908091ED019091EE019F938F9381E8CD |
:1028A00093E09F938F931F930E94C90788E28093C0 |
:1028B000CC010F900F900F900F900F908091EB0133 |
:1028C0009091EC019F938F938DE893E09F938F936A |
:1028D0001F930E94C9078CE38093CC010F900F9047 |
:1028E0000F900F900F908091E9019091EA019F93D2 |
:1028F0008F9389E993E09F938F931F930E94C90759 |
:102900000F900F900F900F900F9057C01092CC0126 |
:1029100085EA93E09F938F931F930E94C90784E1F8 |
:102920008093CC010F900F900F9080916C019927AC |
:102930009F938F938DEA93E09F938F931F930E94B1 |
:10294000C90788E28093CC010F900F900F900F90F1 |
:102950000F908091A7019091A8019F938F938BEB8B |
:1029600093E09F938F931F930E94C9078CE38093FA |
:10297000CC010F900F900F900F900F908091070552 |
:1029800099279F938F938091060599279F938F9303 |
:1029900089EC93E09F938F931F930E94C9078DB793 |
:1029A0009EB707960FB6F8949EBF0FBE8DBF05C0A9 |
:1029B0008150809369011092CF011092CB01DF9179 |
:1029C000CF911F9108951092B9008AE28093B800C8 |
:1029D000089585EA8093BC0080E090E0089584E942 |
:1029E0008093BC0008951092B9008093BB0085E8E5 |
:1029F0008093BC0080E090E008950E94EF14109254 |
:102A0000D2018091BB001092D10180E88093BC007C |
:102A10001092BD001092BA001092BB001092B90043 |
:102A20001092B8000E94E3140E94E91480E00E9412 |
:102A3000F31408951F920F920FB60F9211242F9343 |
:102A40003F934F935F936F937F938F939F93AF9336 |
:102A5000BF93EF93FF938091D201282F33278F5F8D |
:102A60008093D2012330310509F446C0243031056A |
:102A70004CF421303105D1F0223031057CF5232B87 |
:102A800081F083C025303105E1F1253031050CF4AA |
:102A900041C026303105F1F12730310509F45AC023 |
:102AA00074C08091D101880F8E5A51C08091D1019C |
:102AB000282F33278F5F8093D1012130310509F40E |
:102AC0003EC0223031051CF4232BB1F15EC0223010 |
:102AD0003105C1F123303105C1F157C00E94EF1417 |
:102AE0008091D101843018F41092D20102C010926A |
:102AF000D1010E94E91449C08091D001880F8D5AFC |
:102B000026C08091D001E82FFF27E155FB4F80912F |
:102B1000BB0080838091D00199278130910579F0A5 |
:102B2000823091051CF4892B39F02FC08230910539 |
:102B300049F0039751F029C08091700208C080913C |
:102B4000710205C08091740202C0809176020E94D9 |
:102B5000F3141BC09091D001E92FFF27E155FB4FE3 |
:102B60008091BB008483892F8F5F8093D001843054 |
:102B700010F01092D0010E94EF148AE090E0909340 |
:102B80007F0180937E011092D2018091BC00806809 |
:102B90008093BC00FF91EF91BF91AF919F918F9176 |
:102BA0007F916F915F914F913F912F910F900FBE49 |
:102BB0000F901F90189583EC8093810080916F0097 |
:102BC000806280936F001092340210923302109250 |
:102BD0003602109235021092380210923702089590 |
:102BE0001F920F920FB60F9211242F933F934F9382 |
:102BF0005F936F937F938F939F93AF93BF93EF9365 |
:102C0000FF9340918600509187008091D30190916D |
:102C1000D401481B590B80918600909187009093B6 |
:102C2000D4018093D301CA018D5D954083569941AB |
:102C300048F481E090E09093D6018093D501109202 |
:102C40006A0181C06091D5017091D6016A30710529 |
:102C50000CF079C0CA018B5F9040845B914008F012 |
:102C600055C0425D5140FB01E60FF71FE954FB4F91 |
:102C7000808191819A01281B390BC90137FF03C05C |
:102C8000909581959F4F06974CF48091E801883C80 |
:102C900028F48091E801865F8093E801FB01E60F4C |
:102CA000F71FE954FB4F808191819C01220F331F54 |
:102CB000280F391F240F351F37FF02C02D5F3F4FEC |
:102CC0003595279535952795CA0101968217930763 |
:102CD0001CF42150304007C04150504024173507A4 |
:102CE00014F42F5F3F4FFB01E60FF71FDF01A954DC |
:102CF000BB4F8D919C911197A901481B590BE35330 |
:102D0000FB4F5183408311963C932E938091D501C4 |
:102D10009091D60101969093D6018093D5010597A5 |
:102D200011F45D9A01C05D988091D5019091D60112 |
:102D30008630910511F45C9A01C05C98079711F4F4 |
:102D40005B9A01C05B98FF91EF91BF91AF919F910A |
:102D50008F917F916F915F914F913F912F910F9044 |
:102D60000FBE0F901F901895CF93C82FC150CF3F23 |
:102D700081F08091E101882361F484E690E09093F2 |
:102D8000AA018093A9018AEF90E00E943C0BC150F8 |
:102D900080F7CF91089510927A008091BC0188232A |
:102DA00079F08091BC01282F33278091C701909141 |
:102DB000C801B9010E94342F7093200560931F054C |
:102DC0008091BB01882379F08091BB01282F3327A4 |
:102DD0008091C5019091C601B9010E94342F709372 |
:102DE0001E0560931D058091BA01882379F08091BA |
:102DF000BA01282F33278091C3019091C401B901F2 |
:102E00000E94342F70932C0560932B058091B9019B |
:102E10008823E1F08091BF019091C001AA2797FD1E |
:102E2000A095BA2F34E0880F991FAA1FBB1F3A95AF |
:102E3000D1F72091B901332744275527BC01CD0193 |
:102E40000E94692F30932905209328058091B801AD |
:102E50008823E1F08091C1019091C201AA2797FDDA |
:102E6000A095BA2F24E0880F991FAA1FBB1F2A958F |
:102E7000D1F72091B801332744275527BC01CD0154 |
:102E80000E94692F30933205209331058091B7015C |
:102E90008823A9F08091BD019091BE01AA2797FDDA |
:102EA000A095BA2F2091B701332744275527BC019D |
:102EB000CD010E94692F30932305209322051092A3 |
:102EC000C8011092C7011092BC011092C601109265 |
:102ED000C5011092BB011092C4011092C30110925F |
:102EE000BA011092C2011092C1011092B801109261 |
:102EF000C0011092BF011092B9011092BE01109250 |
:102F0000BD011092B7018FEE80937A008091E704A3 |
:102F1000E82FFF27EE0FFF1FE954FB4F80819181BF |
:102F200082599F4F2091EF013091F0012817390706 |
:102F30001CF42F5F3F4F0CC08081918182599F4FBD |
:102F4000821793074CF42115310531F021503040A0 |
:102F50003093F0012093EF018091E804E82FFF27E0 |
:102F6000EE0FFF1FE954FB4F8081918182599F4FE3 |
:102F70002091ED013091EE01281739071CF42F5FE5 |
:102F80003F4F0CC08081918182599F4F82179307D8 |
:102F90004CF42115310531F0215030403093EE01D1 |
:102FA0002093ED018091E904E82FFF27EE0FFF1F2A |
:102FB000E954FB4F8081918182599F4F2091EB0111 |
:102FC0003091EC01281739071CF42F5F3F4F0CC0DC |
:102FD0008081918182599F4F821793074CF421156C |
:102FE000310531F0215030403093EC012093EB015A |
:102FF0008091EA04E82FFF27EE0FFF1FE954FB4FF3 |
:103000008081918182599F4F2091E9013091EA019D |
:10301000281739071CF42F5F3F4F0CC08081918126 |
:1030200082599F4F821793074CF42115310531F0D7 |
:10303000215030403093EA012093E9018091EF0163 |
:103040009091F00197FF05C01092F0011092EF01EE |
:103050000AC08F3F910539F034F08FEF90E09093E4 |
:10306000F0018093EF018091ED019091EE0197FFC7 |
:1030700005C01092EE011092ED010AC08F3F91053C |
:1030800039F034F08FEF90E09093EE018093ED01F2 |
:103090008091EB019091EC0197FF05C01092EC013B |
:1030A0001092EB010AC08F3F910539F034F08FEF99 |
:1030B00090E09093EC018093EB018091E901909175 |
:1030C000EA0197FF05C01092EA011092E901089504 |
:1030D0008F3F910539F034F08FEF90E09093EA0143 |
:1030E0008093E9010895CF93DF93109232021092FA |
:1030F00031021092300210922F0280E090E0A0E0A6 |
:10310000B0E080932B0290932C02A0932D02B093F9 |
:103110002E0210923802109237021092360210924C |
:10312000350210923402109233020E94CB1685E0D1 |
:1031300090E00E94010BEC01CE010E94300B88232D |
:10314000D9F30E94CB168091EB0480FF10C08091D0 |
:10315000070190910801875B934038F48091070143 |
:10316000909108018E5E924010F40E94060C8091AE |
:1031700000018A3081F580911F0590912005809192 |
:103180001F059091200597FF03C0909581959F4F53 |
:10319000909338028093370280911D0590911E050F |
:1031A00080911D0590911E0597FF03C09095819514 |
:1031B0009F4F909336028093350280912B0590911A |
:1031C0002C0580912B0590912C0597FF3FC0909581 |
:1031D00081959F4F3BC080911F0590912005809164 |
:1031E0001F059091200597FF03C0909581959F4FF3 |
:1031F00097FD0196959587959093380280933702B5 |
:1032000080911D0590911E0580911D0590911E05D0 |
:1032100097FF03C0909581959F4F97FD01969595D7 |
:103220008795909336028093350280912B0590917B |
:103230002C0580912B0590912C0597FF03C090954C |
:1032400081959F4F97FD01969595879590933402B0 |
:103250008093330280913105909132058091310540 |
:103260009091320597FF03C0909581959F4F97FDF0 |
:103270000F9654E0959587955A95E1F79093300213 |
:1032800080932F028091280590912905809128052F |
:103290009091290597FF03C0909581959F4F97FDC9 |
:1032A0000F9644E0959587954A95E1F79093320201 |
:1032B0008093310280919F049091A004AA2797FDEA |
:1032C000A095BA2FBC01CD010E94332EDC01CB01A9 |
:1032D00080932B0290932C02A0932D02B0932E0288 |
:1032E0001092110210921202109213021092140204 |
:1032F00010920D0210920E0210920F021092100204 |
:103300001092090210920A0210920B0210920C0203 |
:103310001092050210920602109207021092080203 |
:103320001092010210920202109203021092040203 |
:103330001092200510921F0510921E0510921D0577 |
:1033400010922C0510922B058091090190910A0191 |
:10335000A0910B01B0910C019093A2048093A10461 |
:103360001092B6011092B5011092F9011092FA0173 |
:103370001092FB011092FC018091F7019091F801ED |
:103380009093F6018093F5010E94562D82E390E020 |
:103390009093AA018093A901DF91CF910895EF92B4 |
:1033A000FF920F931F9310927A008091BC018823A3 |
:1033B00079F08091BC01282F33278091C70190912B |
:1033C000C801B9010E94342F7093200560931F0536 |
:1033D0008091BB01882379F08091BB01282F33278E |
:1033E0008091C5019091C601B9010E94342F70935C |
:1033F0001E0560931D058091BA01882379F08091A4 |
:10340000BA01282F33278091C3019091C401B901DB |
:103410000E94342F70932C0560932B058091B90185 |
:10342000882309F446C08091280590912905AA2790 |
:1034300097FDA095BA2F7C018D01E3E0EE0CFF1CF7 |
:10344000001F111FEA95D1F7E81AF90A0A0B1B0BA6 |
:103450008091BF019091C001AA2797FDA095BA2F36 |
:1034600074E0880F991FAA1FBB1F7A95D1F720918E |
:10347000B901332744275527BC01CD010E94692F8C |
:10348000E20EF31E041F151F17FF08C087E090E02F |
:10349000A0E0B0E0E80EF91E0A1F1B1F63E01595BF |
:1034A0000795F794E7946A95D1F7F0922905E09291 |
:1034B00028058091B801882309F446C08091310520 |
:1034C00090913205AA2797FDA095BA2F7C018D0116 |
:1034D00053E0EE0CFF1C001F111F5A95D1F7E81A9C |
:1034E000F90A0A0B1B0B8091C1019091C201AA2716 |
:1034F00097FDA095BA2F44E0880F991FAA1FBB1F04 |
:103500004A95D1F72091B801332744275527BC01AC |
:10351000CD010E94692FE20EF31E041F151F17FF35 |
:1035200008C087E090E0A0E0B0E0E80EF91E0A1FB6 |
:103530001B1F33E015950795F794E7943A95D1F75B |
:10354000F0923205E09231058091B701882309F4A9 |
:103550003FC08091220590912305AA2797FDA09551 |
:10356000BA2F7C018D0123E0EE0CFF1C001F111F00 |
:103570002A95D1F7E81AF90A0A0B1B0B8091BD01B5 |
:103580009091BE01AA2797FDA095BA2F2091B7016F |
:10359000332744275527BC01CD010E94692FE20E35 |
:1035A000F31E041F151F17FF08C087E090E0A0E07E |
:1035B000B0E0E80EF91E0A1F1B1FF3E015950795F2 |
:1035C000F794E794FA95D1F7F0922305E09222055B |
:1035D0001092C8011092C7011092BC011092C6014E |
:1035E0001092C5011092BB011092C4011092C30148 |
:1035F0001092BA011092C2011092C1011092B8014A |
:103600001092C0011092BF011092B9011092BE0138 |
:103610001092BD011092B7018091010290910202B7 |
:10362000A0910302B09104028093150290931602B8 |
:10363000A0931702B0931802809111029091120288 |
:10364000A0911302B0911402809325029093260258 |
:10365000A0932702B09328028091090290910A0258 |
:10366000A0910B02B0910C0280931D0290931E0258 |
:10367000A0931F02B093200280910D0290910E0240 |
:10368000A0910F02B0911002809321029093220228 |
:10369000A0932302B0932402809105029091060228 |
:1036A000A0910702B09108028093190290931A0228 |
:1036B000A0931B02B0931C028FEE80937A0080913E |
:1036C000E704E82FFF27EE0FFF1FE954FB4F80812F |
:1036D000918182599F4F2091EF013091F00128177D |
:1036E00039071CF42F5F3F4F0CC0808191818259B4 |
:1036F0009F4F821793074CF42115310531F021506B |
:1037000030403093F0012093EF018091E804E82FDE |
:10371000FF27EE0FFF1FE954FB4F808191818259F3 |
:103720009F4F2091ED013091EE01281739071CF4CD |
:103730002F5F3F4F0CC08081918182599F4F82172C |
:1037400093074CF42115310531F02150304030936E |
:10375000EE012093ED018091E904E82FFF27EE0FA1 |
:10376000FF1FE954FB4F8081918182599F4F209127 |
:10377000EB013091EC01281739071CF42F5F3F4F04 |
:103780000CC08081918182599F4F821793074CF41E |
:103790002115310531F0215030403093EC01209358 |
:1037A000EB018091EA04E82FFF27EE0FFF1FE95499 |
:1037B000FB4F8081918182599F4F2091E901309187 |
:1037C000EA01281739071CF42F5F3F4F0CC0808196 |
:1037D000918182599F4F821793074CF4211531052F |
:1037E00031F0215030403093EA012093E90180917B |
:1037F000EF019091F00197FF05C01092F001109237 |
:10380000EF010AC08F3F910539F034F08FEF90E05F |
:103810009093F0018093EF018091ED019091EE0182 |
:1038200097FF05C01092EE011092ED010AC08F3F84 |
:10383000910539F034F08FEF90E09093EE01809392 |
:10384000ED018091EB019091EC0197FF05C0109282 |
:10385000EC011092EB010AC08F3F910539F034F072 |
:103860008FEF90E09093EC018093EB018091E90160 |
:103870009091EA0197FF05C01092EA011092E901C8 |
:103880000AC08F3F910539F034F08FEF90E09093AC |
:10389000EA018093E9011F910F91FF90EF90089545 |
:1038A0008091E101882301F5809371028093700279 |
:1038B000809374028093760280919001882311F0A6 |
:1038C0008093700280919101882311F0809371029E |
:1038D00080919201882311F0809376028091930168 |
:1038E000882311F08093740280917002992790933D |
:1038F00075048093740480917102992790937704E2 |
:10390000809376048091760299279093790480932E |
:10391000780480917402992790937B0480937A04B1 |
:103920001092D2011092D1010E94E914089581E011 |
:103930008093E30482E08093E40483E08093E504D1 |
:1039400094E09093E60445E04093E70486E080939A |
:10395000E80487E08093E90438E03093EA041092A9 |
:10396000EB048EE18093EC048BEF8093EE048AE00D |
:103970008093EF0422E32093ED042093F1049093CD |
:10398000F0049093F2043093F30480E18093F40404 |
:103990008FE08093F5048AEF8093F6048AE18093A8 |
:1039A000F70480E88093F80488E78093F90496E9A7 |
:1039B0009093FA048EE58093FB0483E28093FC04E9 |
:1039C00084E18093FD041092FE041092FF04109293 |
:1039D000000510920105109202051092030584E67D |
:1039E0008093040588E28093050510920C052093CE |
:1039F00006059093070540930805209309058AE57D |
:103A000080930A0510920B05A1E1B5E0E0E8F1E032 |
:103A10008CE001900D928150E1F7089581E0809350 |
:103A2000E30432E03093E40483E08093E50424E08F |
:103A30002093E60445E04093E70486E08093E804A1 |
:103A400087E08093E90488E08093EA041092EB0415 |
:103A50008EE18093EC048BEF8093EE048AE08093F8 |
:103A6000EF0492E39093ED049093F1043093F0040B |
:103A70002093F2041092F30480E18093F4048FE029 |
:103A80008093F5048AEF8093F6048AE18093F7042B |
:103A900080E88093F8048FEA8093F9048093FA0415 |
:103AA0008EE58093FB0483E28093FC0484E18093A1 |
:103AB000FD041092FE041092FF0410920005109273 |
:103AC0000105109202051092030584E68093040517 |
:103AD00088E28093050510920C059093060586E90F |
:103AE0008093070540930805909309058AE5809324 |
:103AF0000A0510920B05A1E1B5E0E7E8F1E08CE0E2 |
:103B000001900D928150E1F708951F938091EE048A |
:103B10008B3F98F08B3F19F48091EF010EC08C3FE2 |
:103B200019F48091ED0109C08D3F19F48091EB01EA |
:103B300004C08E3F21F48091E9018093740180914B |
:103B40007401882321F08F3F11F4809374018091D8 |
:103B5000ED048B3F98F08B3F19F48091EF010EC07C |
:103B60008C3F19F48091ED0109C08D3F19F48091CB |
:103B7000EB0104C08E3F21F48091E901809375012F |
:103B800080917501882329F0843618F084E68093AB |
:103B900075018091EF048B3F98F08B3F19F4809171 |
:103BA000EF010EC08C3F19F48091ED0109C08D3FEB |
:103BB00019F48091EB0104C08E3F21F48091E9015A |
:103BC0008093730180917301882329F0843618F063 |
:103BD00084E6809373018091F1048B3F98F08B3FD2 |
:103BE00019F48091EF010EC08C3F19F48091ED0122 |
:103BF00009C08D3F19F48091EB0104C08E3F21F480 |
:103C00008091E9018093720180917201882321F0F3 |
:103C10008F3F11F4809372018091F8048B3F98F0EC |
:103C20008B3F19F48091EF010EC08C3F19F4809105 |
:103C3000ED0109C08D3F19F48091EB0104C08E3F66 |
:103C400021F48091E90180937101809171018823B1 |
:103C500021F08F3F11F4809371018091F9048B3F23 |
:103C600098F08B3F19F48091EF010EC08C3F19F44E |
:103C70008091ED0109C08D3F19F48091EB0104C0E2 |
:103C80008E3F21F48091E901809370018091700151 |
:103C90008B3010F48AE002C08F3F11F480937001E2 |
:103CA0008091FA048B3F98F08B3F19F48091EF01DB |
:103CB0000EC08C3F19F48091ED0109C08D3F19F4BD |
:103CC0008091EB0104C08E3F21F48091E901809343 |
:103CD0006F0180916F01882321F08F3F11F4809351 |
:103CE0006F018091FF048B3F98F08B3F19F4809116 |
:103CF000EF010EC08C3F19F48091ED0109C08D3F9A |
:103D000019F48091EB0104C08E3F21F48091E90108 |
:103D100080936D0180916D01882321F08F3F11F414 |
:103D200080936D01809100058B3F98F08B3F19F4D3 |
:103D30008091EF010EC08C3F19F48091ED0109C014 |
:103D40008D3F19F48091EB0104C08E3F21F48091E6 |
:103D5000E9018093DA018091DA01882321F08F3F15 |
:103D600011F48093DA01809101058B3F98F08B3F2D |
:103D700019F48091EF010EC08C3F19F48091ED0190 |
:103D800009C08D3F19F48091EB0104C08E3F21F4EE |
:103D90008091E9018093D9018091D901882321F094 |
:103DA0008F3F11F48093D901809102058B3F98F0E9 |
:103DB0008B3F19F48091EF010EC08C3F19F4809174 |
:103DC000ED0109C08D3F19F48091EB0104C08E3FD5 |
:103DD00021F48091E9018093D8018091D801882352 |
:103DE00021F08F3F11F48093D801809103058B3F20 |
:103DF00098F08B3F19F48091EF010EC08C3F19F4BD |
:103E00008091ED0109C08D3F19F48091EB0104C050 |
:103E10008E3F21F48091E9018093D7018091D701F1 |
:103E2000882321F08F3F11F48093D70190910405EE |
:103E30009B3FB0F09B3F19F48091EF010EC09C3F77 |
:103E400019F48091ED0109C09D3F19F48091EB01B7 |
:103E500004C09E3F39F48091E90180936C0102C057 |
:103E600090936C0180916C01882321F08F3F11F4B5 |
:103E700080936C019B3FB0F09B3F19F48091EF0160 |
:103E80000EC09C3F19F48091ED0109C09D3F19F4CB |
:103E90008091EB0104C09E3F39F48091E901809349 |
:103EA0006C0102C090936C0180916C01882321F019 |
:103EB0008F3F11F480936C019B3FB0F09B3F19F44E |
:103EC0008091EF010EC09C3F19F48091ED0109C073 |
:103ED0009D3F19F48091EB0104C09E3F39F480911D |
:103EE000E90180936C0102C090936C0180916C0198 |
:103EF000882321F08F3F11F480936C018091090594 |
:103F00008B3F98F08B3F19F48091EF010EC08C3FEE |
:103F100019F48091ED0109C08D3F19F48091EB01F6 |
:103F200004C08E3F21F48091E90180936B01809160 |
:103F30006B01882321F08F3F11F480936B01109166 |
:103F40006D01812F992787FD9095A92FB92FBC016D |
:103F5000CD010E94332E17FF06C020E030E040E87C |
:103F600053E40E948E2D27E137EB41ED58E30E9488 |
:103F7000AD2EDC01CB018093760190937701A09365 |
:103F80007801B09379018091F60480932A0580919D |
:103F9000F504809321051F9108953F924F925F92FF |
:103FA0006F927F928F929F92AF92BF92CF92DF9249 |
:103FB000EF92FF920F931F93CF93DF930E94CF193D |
:103FC000299A8091E504E82FFF27EE0FFF1FE9549F |
:103FD000FB4F4080518028E730E0420E531E57FED1 |
:103FE00002C0442455248091E801843608F05EC064 |
:103FF00080910101882399F480910301909104013B |
:104000008F5F9F4F61F488E99AE39093AA018093B0 |
:10401000A90180E09CE090930401809303018091CA |
:104020004D0290914E02009731F0019790934E020D |
:1040300080934D0204C01092E1011092F201809130 |
:1040400000018A3011F4289A01C028988091520208 |
:1040500090915302815D974030F18091FC04482E8D |
:10406000552481E08093F2018091E304E82FFF273B |
:10407000EE0FFF1FE954FB4F118210828091E40480 |
:10408000E82FFF27EE0FFF1FE954FB4F118210822C |
:104090008091E604E82FFF27EE0FFF1FE954FB4F46 |
:1040A00011821082E0C11092E101DDC18091E8012E |
:1040B0008D3808F4D8C11092F2019091FD0482E38A |
:1040C000989FC001112490934E0280934D0259E2B3 |
:1040D000451651046CF080915202909153026FEF9B |
:1040E0008F3F960729F001969093530280935202D6 |
:1040F0008091520290915302883C910520F078E221 |
:104100004716510404F51092390210923A021092A7 |
:104110003B0210923C0210923D0210923E0210921D |
:104120003F0210924002109201021092020210927D |
:104130000302109204021092FD011092FE011092EF |
:10414000FF011092000289EC481651040CF4EBC0F8 |
:104150002091E101222309F0E6C08091E604E82FD6 |
:10416000FF27EE0FFF1FE954FB4F808191818C34B4 |
:1041700091050CF4D6C080914F028F5F80934F025F |
:10418000893C08F4D0C0299820934F021092530222 |
:10419000109252023091E304E32FFF27EE0FFF1F2E |
:1041A000E954FB4F8081918187349105B4F480916B |
:1041B000E404E82FFF27EE0FFF1FE954FB4F808137 |
:1041C00091810190F081E02DF7FF03C0F095E1951A |
:1041D000FF4FE734F1050CF482C02091E404E22F94 |
:1041E000FF27EE0FFF1FE954FB4F80819181873439 |
:1041F000910564F0E32FFF27EE0FFF1FE954FB4FFB |
:1042000080819181863491050CF4C1E0E22FFF2773 |
:10421000EE0FFF1FE954FB4F808191818734910598 |
:1042200074F08091E304E82FFF27EE0FFF1FE9549D |
:10423000FB4F80819181873491050CF0C2E0E22F21 |
:10424000FF27EE0FFF1FE954FB4F808191818634D9 |
:10425000910574F48091E304E82FFF27EE0FFF1F10 |
:10426000E954FB4F80819181873491050CF0C3E0C4 |
:10427000E22FFF27EE0FFF1FE954FB4F8081918152 |
:104280008A5B9F4F74F48091E304E82FFF27EE0FC1 |
:10429000FF1FE954FB4F80819181873491050CF019 |
:1042A000C4E0E22FFF27EE0FFF1FE954FB4F808190 |
:1042B00091818A5B9F4F74F48091E304E82FFF277C |
:1042C000EE0FFF1FE954FB4F8081918186349105E9 |
:1042D0000CF4C5E0A2E0B0E00C2E0E948C2F80917F |
:1042E000EB0480FF10C08091070190910801875B6B |
:1042F000934038F480910701909108018E5E9240BE |
:1043000010F40E94060C0E9433024AE363EE74E04C |
:104310000E9409020E9473180E9433020E94B41680 |
:1043200002C020934F0273E2471651040CF09BC069 |
:104330002091E604E22FFF27EE0FFF1FE954FB4F09 |
:1043400080819181855B9F4F0CF06DC08091500200 |
:104350008F5F80935002893C08F467C088EC80939B |
:10436000500281E090E0909353028093520281E0EA |
:104370008093E10110924102109242021092430296 |
:104380001092440210920102109202021092030253 |
:10439000109204021092FD011092FE011092FF0192 |
:1043A0001092000210921102109212021092130247 |
:1043B000109214021092090210920A0210920B023B |
:1043C00010920C028091250290912602A091270262 |
:1043D000B091280280930D0290930E02A0930F02D9 |
:1043E000B093100280911D0290911E02A0911F02B5 |
:1043F000B09120028093050290930602A0930702D9 |
:10440000B09308021092390210923A0210923B02C5 |
:1044100010923C0210923D0210923E0210923F0216 |
:104420001092400202C010925002E22FFF27EE0FBE |
:10443000FF1FE954FB4F808191818C3491058CF0F2 |
:10444000809151028F5F80935102893C60F01092FD |
:10445000E10188EC809351021092530210925202B3 |
:1044600002C01092510280916A01815080936A01CA |
:1044700080916A018F3F29F08091F201882309F42D |
:10448000AAC10E94851D8091E304E82FFF27EE0F4B |
:10449000FF1FDF01A954BB4FE090F204CE2DDD27B2 |
:1044A0008D919C918C9F40018D9F900C9C9F900CB6 |
:1044B0001124E353FB4F8091F304482F552780814B |
:1044C0009181849FB001859F700D949F700D112480 |
:1044D000860E971E9092E7018092E6018091E40497 |
:1044E000E82FFF27EE0FFF1FDF01A954BB4F8D916F |
:1044F0009C918C9F90018D9F300D9C9F300D1124BD |
:10450000E353FB4F80819181849FB001859F700DA3 |
:10451000949F700D1124260F371F3093E5012093CF |
:10452000E4018091E604E82FFF27EE0FFF1FE95416 |
:10453000FB4F80819181909581959F4F9093E301EE |
:104540008093E20110917001812F992787FD90954A |
:10455000A92FB92FBC01CD010E94332E17FF06C031 |
:1045600020E030E040E853E40E948E2D20E030E06F |
:1045700040E251E40E948E2DDC01CB0120E030E0CE |
:1045800040E85BE3BC01CD010E94AD2E5B016C01F4 |
:1045900060932D0570932E0580932F059093300521 |
:1045A00010916F01812F992787FD9095A92FB92F21 |
:1045B000BC01CD010E94332E17FF06C020E030E081 |
:1045C00040E853E40E948E2D20E030EE4BE257E4A9 |
:1045D0000E94D02DDC01CB0180932405909325050A |
:1045E000A0932605B09327058091EB0482FF0CC0B1 |
:1045F00080E090E0A0E0B0E0809324059093250552 |
:10460000A0932605B093270520E030E040E050E07D |
:10461000C601B5010E943D2E882364F480E090E03D |
:10462000A0E0B0E080932D0590932E05A0932F0578 |
:10463000B09330058091240590912505A091260521 |
:10464000B091270520E030E040E050E0BC01CD0112 |
:104650000E943D2E882364F480E090E0A0E0B0E06A |
:104660008093240590932505A0932605B0932705F4 |
:1046700080910B05992782FDAEC083FDACC080916F |
:10468000250290912602A0912702B091280281561E |
:104690009A4EA040B040DCF0CE0103E0880F991F95 |
:1046A0000A95E1F79401281B390B3093E701209319 |
:1046B000E6018091250290912602A0912702B091F7 |
:1046C000280281589843A140B04094F126C08091BF |
:1046D000250290912602A0912702B0912802805ACB |
:1046E0009541AF4FBF4F24F59E0113E0220F331FBA |
:1046F0001A95E1F7280D391D3093E7012093E60163 |
:104700008091250290912602A0912702B091280263 |
:1047100081589843A140B0405CF0B4E0CC0FDD1F5D |
:10472000BA95E1F72C1B3D0B3093E7012093E6018E |
:1047300080911D0290911E02A0911F02B091200253 |
:1047400081569A4EA040B0407CF04E2D5527CA01AC |
:10475000A3E0880F991FAA95E1F72091E401309119 |
:10476000E501281B390B1BC080911D0290911E0290 |
:10477000A0911F02B0912002805A9541AF4FBF4FC8 |
:1047800054F54E2D5527CA01F3E0880F991FFA956D |
:10479000E1F72091E4013091E501280F391F3093B2 |
:1047A000E5012093E40180911D0290911E02A091E9 |
:1047B0001F02B091200281589843A140B0405CF0A4 |
:1047C000E4E0440F551FEA95E1F7241B350B3093C5 |
:1047D000E5012093E4018091E404E82FFF27EE0F28 |
:1047E000FF1FE954FB4F40910A05242F3327808196 |
:1047F00091812817390724F480910B0582FD0CC0A4 |
:10480000309521953F4F80819181821793077CF4E9 |
:1048100080910B0583FF0BC081E08093DB018091C9 |
:10482000090599278415950524F42C0102C01092DE |
:10483000DB018091E304E82FFF27EE0FFF1FE9540F |
:10484000FB4F242F3327808191812817390724F4C7 |
:1048500080910B0580FD0CC0309521953F4F8081E4 |
:104860009181821793078CF480910B0581FF0DC015 |
:1048700081E08093DC011092DB018091090599278A |
:104880008415950524F42C0102C01092DC013090AF |
:10489000F201332041F11092E3011092E2011092F3 |
:1048A000E7011092E6011092E5011092E4018DEC0F |
:1048B0009CECACECBDE380932D0590932E05A0936A |
:1048C0002F05B09330058AE097EDA3EABBE3809310 |
:1048D000240590932505A0932605B09327051092F3 |
:1048E000DB011092DC018091B3019091B4018D54F1 |
:1048F000914008F499C02091210230912202409108 |
:104900002302509124028091250290912602A091C9 |
:104910002702B0912802281B390B4A0B5B0BC09170 |
:104920001902D0911A02E0911B02F0911C028091B1 |
:104930001D0290911E02A0911F02B0912002C81B7F |
:10494000D90BEA0BFB0B1092B4011092B301273A7A |
:104950003105410551054CF08091370290913802A4 |
:10496000019690933802809337022A553F4F4F4F5C |
:104970005F4F4CF4809137029091380201979093E9 |
:10498000380280933702C73AD105E105F1054CF0B2 |
:104990008091350290913602019690933602809371 |
:1049A0003502CA55DF4FEF4FFF4F4CF4809135026F |
:1049B00090913602019790933602809335021092BF |
:1049C0007A008091250290912602A0912702B09151 |
:1049D000280280930D0290930E02A0930F02B093D1 |
:1049E000100280911D0290911E02A0911F02B091B1 |
:1049F00020028093050290930602A0930702B093D1 |
:104A000008028091150290911602A0911702B091B0 |
:104A100018028093FD019093FE01A093FF01B093D3 |
:104A200000028FEE80937A00609024057090250537 |
:104A3000809026059090270520E030E040E050E08F |
:104A4000C401B3010E943D2E882309F43DC1809129 |
:104A5000DC01882309F038C18091DB01882309F04B |
:104A600033C1C091F7042C2F332744275527809159 |
:104A7000250290912602A0912702B0912802BC0144 |
:104A8000CD010E94692F8091280590912905AA27C0 |
:104A900097FDA095BA2F281B390B4A0B5B0B20936F |
:104AA000450230934602409347025093480280915A |
:104AB000280590912905AA2797FDA095BA2FB7FF41 |
:104AC00007C0B095A095909581959F4FAF4FBF4F70 |
:104AD000883C9105A105B105BCF4DA01C90157FF75 |
:104AE00003C00796A11DB11D73E0B595A7959795D5 |
:104AF00087957A95D1F78093450290934602A093CB |
:104B00004702B093480215C057FF04C0215F3F4FD2 |
:104B10004F4F5F4F64E055954795379527956A95B8 |
:104B2000D1F72093450230934602409347025093B9 |
:104B300048022C2F33274427552780911D0290913E |
:104B40001E02A0911F02B0912002BC01CD010E9463 |
:104B5000692F8091310590913205AA2797FDA09584 |
:104B6000BA2F281B390B4A0B5B0B20934902309359 |
:104B70004A0240934B0250934C0280913105909130 |
:104B80003205AA2797FDA095BA2FB7FF07C0B095A9 |
:104B9000A095909581959F4FAF4FBF4F883C910551 |
:104BA000A105B105BCF4DA01C90157FF03C007969E |
:104BB000A11DB11D23E0B595A795979587952A95D9 |
:104BC000D1F78093490290934A02A0934B02B0938D |
:104BD0004C0215C057FF04C0215F3F4F4F4F5F4F3E |
:104BE00094E055954795379527959A95D1F7209359 |
:104BF000490230934A0240934B0250934C028091F9 |
:104C0000450290914602A0914702B0914802855F0B |
:104C10009140A040B04064F084EF91E0A0E0B0E0AB |
:104C20008093450290934602A0934702B0934802B6 |
:104C30008091450290914602A0914702B0914802AE |
:104C40008C509E4FAF4FBF4F64F48CE09EEFAFEFA0 |
:104C5000BFEF8093450290934602A0934702B09322 |
:104C600048028091490290914A02A0914B02B09172 |
:104C70004C02855F9140A040B04064F084EF91E029 |
:104C8000A0E0B0E08093490290934A02A0934B02C7 |
:104C9000B0934C028091490290914A02A0914B023C |
:104CA000B0914C028C509E4FAF4FBF4FECF48CE054 |
:104CB0009EEFAFEFBFEF8093490290934A02A0931B |
:104CC0004B02B0934C0210C0109245021092460263 |
:104CD00010924702109248021092490210924A0222 |
:104CE00010924B0210924C0210927A0080911102A5 |
:104CF00090911202A0911302B091140220914502EA |
:104D0000309146024091470250914802821B930B1A |
:104D1000A40BB50B8093110290931202A09313027F |
:104D2000B09314028091090290910A02A0910B02A3 |
:104D3000B0910C022091490230914A0240914B02FD |
:104D400050914C02821B930BA40BB50B809309026C |
:104D500090930A02A0930B02B0930C022091E201FF |
:104D60003091E301C90137FF04C088279927821BCE |
:104D7000930B84973CF08091EB0484FD03C081E0A9 |
:104D8000809357028091F404682F7727C90137FF79 |
:104D900004C088279927821B930B289FA001299F75 |
:104DA000500D389F500D1124CA01689FA001699FC2 |
:104DB000500D789F500D1124CA0157FF02C0815039 |
:104DC0009E4FAC01452F550F550B4595629FC00175 |
:104DD000639F900D729F900D112497FD03969595FA |
:104DE000879595958795480F591FCA01AA2797FD62 |
:104DF000A095BA2F8093410290934202A093430260 |
:104E0000B0934402209101023091020240910302CA |
:104E100050910402281B390B4A0B5B0B20930102B3 |
:104E200030930202409303025093040280910102E6 |
:104E300090910202A0910302B0910402895A914616 |
:104E4000A040B04064F088EA91E6A0E0B0E0809332 |
:104E5000010290930202A0930302B0930402809196 |
:104E6000010290910202A0910302B09104028855C0 |
:104E70009E49AF4FBF4F64F488E59EE9AFEFBFEFA7 |
:104E80008093010290930202A0930302B093040264 |
:104E90008FEE80937A008091F7019091F801892B31 |
:104EA00009F4B8C08091EB0483FFB4C0809125025F |
:104EB00090912602A0912702B0912802B7FF04C06A |
:104EC00081509E4FAF4FBF4F19E0B595A79597956D |
:104ED00087951A95D1F79C0197FF03C030952195CE |
:104EE0003F4F80911D0290911E02A0911F02B09130 |
:104EF0002002B7FF04C081509E4FAF4FBF4FC9E0A3 |
:104F0000B595A79597958795CA95D1F7BC0197FF59 |
:104F100003C0709561957F4F261737070CF49B01EE |
:104F200029313105A4F480915702882381F08091C2 |
:104F3000580290915902892B51F48091F701909178 |
:104F4000F8019093F6018093F50110925702809139 |
:104F50007101482F5527249FC001259F900D349F34 |
:104F6000900D112497FDCF969C01B6E035952795BD |
:104F7000BA95E1F7421B530B9A01141615060CF073 |
:104F800043C010927A0060915802709159026115E5 |
:104F9000710569F58091F3019091F401829FA00160 |
:104FA000839F500D929F500D11249A0157FF02C00C |
:104FB000215E3F4FA5E035952795AA95E1F7442757 |
:104FC00037FD4095542F8091010290910202A091EB |
:104FD0000302B0910402820F931FA41FB51F809398 |
:104FE000010290930202A0930302B09304028FEE99 |
:104FF00080937A006115710569F06150704070937B |
:1050000059026093580206C084EF91E090935902D0 |
:1050100080935802809156028150809356028F3FB0 |
:1050200009F06EC081E3809356028091F704E82E68 |
:10503000FF24002711278091250290912602A0913C |
:105040002702B0912802BC01CD01A80197010E945E |
:10505000692F30935D0420935C0480911D02909130 |
:105060001E02A0911F02B0912002BC01CD01A80137 |
:1050700097010E94692F30935F0420935E04809112 |
:105080002805909129059093610480936004809194 |
:10509000310590913205909363048093620480916E |
:1050A0002B0590912C059093650480936404809166 |
:1050B000DF019091E00190936704809366048091F2 |
:1050C000F9019091FA01A091FB01B091FC01B7FFA9 |
:1050D00004C081509E4FAF4FBF4FF9E0B595A795E3 |
:1050E00097958795FA95D1F7909369048093680412 |
:1050F0008091F7019091F80190936D0480936C0476 |
:105100008091DC01A0902D05B0902E05C0902F0558 |
:10511000D09030058823A9F080911F05909120053B |
:10512000AA2797FDA095BA2FBC01CD010E94332E6E |
:10513000DC01CB01A6019501BC01CD010E94AD2E81 |
:1051400032C08091250290912602A0912702B09151 |
:105150002802BC01CD010E94332EDC01CB01A40149 |
:105160009301BC01CD010E94AD2E7B018C01809189 |
:105170001F0590912005AA2797FDA095BA2FBC0185 |
:10518000CD010E94332EDC01CB01A6019501BC01AB |
:10519000CD010E94AD2EDC01CB019C01AD01C80107 |
:1051A000B7010E948E2DDC01CB01BC01CD010E9414 |
:1051B000162EDC01CB019093200580931F05809172 |
:1051C000DB01A0902D05B0902E05C0902F05D0904A |
:1051D00030058823A9F080911D0590911E05AA270E |
:1051E00097FDA095BA2FBC01CD010E94332EDC01A2 |
:1051F000CB01A6019501BC01CD010E94AD2E3AC0A4 |
:1052000080911D0290911E02A0911F02B091200278 |
:10521000BC01CD010E94332E7B018C0180912405BD |
:1052200090912505A0912605B09127059C01AD011F |
:10523000C801B7010E94AD2E7B018C0180911D0534 |
:1052400090911E05AA2797FDA095BA2FBC01CD010C |
:105250000E94332EDC01CB01A6019501BC01CD01DA |
:105260000E94AD2EDC01CB019C01AD01C801B7014C |
:105270000E948E2DDC01CB01BC01CD010E94162EB7 |
:10528000DC01CB0190931E0580931D0580912B05B9 |
:1052900090912C05AA2797FDA095BA2FBC01CD01AE |
:1052A0000E94332E7B018C0180912D0590912E055B |
:1052B000A0912F05B09130059C01AD01C801B70147 |
:1052C0000E94AD2E5B016C01809115029091160237 |
:1052D000A0911702B0911802BC01CD010E94332E9B |
:1052E0007B018C018091240590912505A0912605D4 |
:1052F000B09127059C01AD01C801B7010E94AD2EF8 |
:10530000DC01CB0120E030E040E05FE3BC01CD01F7 |
:105310000E94AD2EDC01CB019C01AD01C601B5019F |
:105320000E948E2DDC01CB01BC01CD010E94162E06 |
:10533000DC01CB0190932C0580932B0580911F05F8 |
:10534000909120058150984034F080E098E090934F |
:10535000200580931F0580911F05909120058050A6 |
:10536000984F34F480E098EF9093200580931F05C8 |
:1053700080911D0590911E058150984034F080E089 |
:1053800098E090931E0580931D0580911D059091D6 |
:105390001E058050984F34F480E098EF90931E05DE |
:1053A00080931D0580912B0590912C05815098408C |
:1053B00034F080E098E090932C0580932B05809149 |
:1053C0002B0590912C058050984F34F480E098EF95 |
:1053D00090932C0580932B058091EB04992780FFF7 |
:1053E000E1C02091740181FF0EC02233B0F480919E |
:1053F000DF019091E00144979093DE018093DD01FD |
:105400001092F1010DC08091F004289FC001112479 |
:1054100044979093DE018093DD0181E08093F10158 |
:10542000332021F01092DE011092DD01C090DF01E7 |
:10543000D090E0012091DD013091DE012C153D0579 |
:105440000CF0B0C08091F101882309F4ABC0C21AFE |
:10545000D30A809173019927C89EB001C99E700D2F |
:10546000D89E700D1124CB0177FD0F966C01E4E0FE |
:10547000D594C794EA95E1F7C2018C199D096C0196 |
:1054800080917501282F33278091B5019091B60145 |
:10549000829FA001839F500D929F500D1124CA013D |
:1054A00057FD079673E0959587957A95E1F7C81AA9 |
:1054B000D90AA091F901B091FA01C091FB01D091F4 |
:1054C000FC01D7FF04C0A150BE4FCF4FDF4F69E0B2 |
:1054D000D595C795B795A7956A95D1F78091720133 |
:1054E000282F332744275527BD01CE010E94F52ED2 |
:1054F00097FF04C0615E7F4F8F4F9F4F55E095959A |
:105500008795779567955A95D1F7633371051CF0A8 |
:1055100062E370E006C05FEF6E3C750714F46EEC5A |
:105520007FEFC61AD70A80915402909155029C01D0 |
:1055300044E0220F331F4A95E1F7281B390B2C0D4D |
:105540003D1D37FF02C0215F3F4F04E03595279591 |
:105550000A95E1F730935502209354028091EC04B0 |
:10556000482F55272417350774F44416550624F0A0 |
:1055700050935502409354024416550624F4509219 |
:10558000550240925402809154029091550248165F |
:10559000590624F45092550240925402409054020D |
:1055A0005090550250926B0440926A04C0912B05B2 |
:1055B000D0912C058091410290914202C81BD90BD9 |
:1055C000CE01AA2797FDA095BA2FBC01CD010E945C |
:1055D000332E7B018C01C201AA2797FDA095BA2F1B |
:1055E000BC01CD010E94332E3B014C0123E333E388 |
:1055F00043EB5FE30E94AD2E5B016C019B01AC01AC |
:10560000C801B7010E94402E18163CF4C601B5012E |
:105610000E94162EDC01CB01EC01CE01AA2797FDDA |
:10562000A095BA2FBC01CD010E94332E7B018C01C5 |
:1056300023E333E343EB5FEBC401B3010E94AD2EE0 |
:105640005B016C019B01AC01C801B7010E943D2EBA |
:1056500088233CF4C601B5010E94162EDC01CB0163 |
:10566000EC016AE04616510414F4C0E0D0E0209149 |
:10567000E6013091E70180916C0290916D02281B48 |
:10568000390B80911F0590912005821B930BAA274F |
:1056900097FDA095BA2FBC01CD010E94332EDC01ED |
:1056A000CB0180907A0190907B01A0907C01B0901A |
:1056B0007D019C01AD01C501B4010E94AD2EDC014C |
:1056C000CB01BC01CD010E94162EDC01CB019093D1 |
:1056D0007302809372028091720290917302AA27E2 |
:1056E00097FDA095BA2F2091390230913A0240914E |
:1056F0003B0250913C02280F391F4A1F5B1F209329 |
:10570000390230933A0240933B0250933C0260913D |
:10571000390270913A021216130614061506C4F4E3 |
:10572000CB0177FF04C088279927861B970B97FF2B |
:1057300002C081509F4F892F990F990B0196AA277C |
:1057400097FDA095BA2F281B390B4A0B5B0B16C08F |
:10575000CB0177FF03C0909581959F4F97FF02C0C3 |
:1057600081509F4F892F990F990B0196AA2797FD7A |
:10577000A095BA2F280F391F4A1F5B1F20933902AB |
:1057800030933A0240933B0250933C02809139029D |
:1057900090913A02A0913B02B0913C0281589E4305 |
:1057A000A040B04064F080E89EE3A0E0B0E08093C9 |
:1057B000390290933A02A0933B02B0933C0280914D |
:1057C000390290913A02A0913B02B0913C0280587C |
:1057D000914CAF4FBF4F64F480E891ECAFEFBFEF57 |
:1057E0008093390290933A02A0933B02B0933C021B |
:1057F00040917202509173026201C40CD51CC41610 |
:10580000D5060CF4A6018EEF9FEF489EB001499E8D |
:10581000700D589E700D1124461757070CF4AB01FC |
:105820009201240F351F2C0F3D1F37FF03C020E0CE |
:1058300030E007C080912A059927821793070CF45E |
:105840009C0110912105812F9927281739070CF405 |
:105850009C01209370029201241B350B2C0F3D1FDD |
:1058600037FF03C020E030E007C080912A05992768 |
:10587000821793070CF49C01812F99272817390769 |
:105880000CF49C01209371022091E4013091E50118 |
:1058900080916A0290916B02281B390B80911D0543 |
:1058A00090911E05821B930BAA2797FDA095BA2FF6 |
:1058B000BC01CD010E94332EDC01CB019C01AD0166 |
:1058C000C501B4010E94AD2EDC01CB01BC01CD01AC |
:1058D0000E94162EDC01CB0190936F0280936E0222 |
:1058E00080916E0290916F02AA2797FDA095BA2F22 |
:1058F00020913D0230913E0240913F025091400282 |
:10590000280F391F4A1F5B1F20933D0230933E0230 |
:1059100040933F025093400260913D0270913E02DD |
:105920001216130614061506C4F4CB0177FF04C043 |
:1059300088279927861B970B97FF02C081509F4F9E |
:10594000892F990F990B0196AA2797FDA095BA2F39 |
:10595000281B390B4A0B5B0B16C0CB0177FF03C02A |
:10596000909581959F4F97FF02C081509F4F892F3F |
:10597000990F990B0196AA2797FDA095BA2F280F8A |
:10598000391F4A1F5B1F20933D0230933E02409314 |
:105990003F025093400280913D0290913E02A091BF |
:1059A0003F02B091400281589E43A040B04064F055 |
:1059B00080E89EE3A0E0B0E080933D0290933E0239 |
:1059C000A0933F02B093400280913D0290913E022D |
:1059D000A0913F02B09140028058914CAF4FBF4F11 |
:1059E00064F480E891ECAFEFBFEF80933D029093B9 |
:1059F0003E02A0933F02B093400240916E0250914C |
:105A00006F02C416D5060CF4A6018EEF9FEF489ED8 |
:105A1000B001499E700D589E700D1124461757070E |
:105A20000CF4AB019201240F351F2C1B3D0B37FFEB |
:105A300003C020E030E007C080912A059927821733 |
:105A400093070CF49C01812F9927281739070CF430 |
:105A50009C01209376029201241B350B2C1B3D0BDD |
:105A600037FF03C020E030E007C080912A05992766 |
:105A7000821793070CF49C01812F99272817390767 |
:105A80000CF49C0120937402DF91CF911F910F9130 |
:105A9000FF90EF90DF90CF90BF90AF909F908F904E |
:105AA0007F906F905F904F903F9008958091660235 |
:105AB00090916702A0916802B091690280935E02A2 |
:105AC00090935F02A0936002B093610280916202A2 |
:105AD00090916302A0916402B091650280935A0292 |
:105AE00090935B02A0935C02B0935D0208951092C4 |
:105AF0006D0210926C0210926B0210926A0208956D |
:105B0000FC014150504030F001900616D1F731971A |
:105B1000CF0108958827992708955058192EEFD05E |
:105B200001D0D2C0BA176207730784079507B1F195 |
:105B300088F40EF410940B2EBA2FA02D062E622F8F |
:105B4000202D072E732F302D082E842F402D092E47 |
:105B5000952F502DFF275523B9F0591B49F0573E7B |
:105B600098F0469537952795A795F0405395C9F736 |
:105B700076F0BA0F621F731F841F30F487957795F4 |
:105B80006795B795F040939517FA0F2E0895BF1BB0 |
:105B9000BB27BA0B620B730B840BF6CFDEF6DBC0B0 |
:105BA000AED001D091C0552359F0992369F09F5789 |
:105BB0005F57951B33F442F4903811F4915805C0A7 |
:105BC0009BC091589F3F09F4C6C0BB2711246217A0 |
:105BD0007307840730F4660F771F881FBB1F91502F |
:105BE00098F311D00F920FD00F920DD0A0E8261786 |
:105BF000370748071B0609F0A048BA2F602D7F9190 |
:105C00008F9100240895A0E8002462177307840789 |
:105C1000B10528F0621B730B840BB1090A2A660FC9 |
:105C2000771F881FBB1FA69581F7089597FB73D038 |
:105C30009F3738F0FEE9F91B982F872F762F6B2FAF |
:105C400005C086C09695879577956795F150D0F7F2 |
:105C50003EF490958095709561957F4F8F4F9F4F43 |
:105C60000895E89403C097FB0EF4F3DFB62F672F77 |
:105C7000782F892F9EE9002427C00ED05EF004C043 |
:105C80000BD026F001C008D019F020F48FEF089552 |
:105C900080E0089581E0089597FB092E052600F81D |
:105CA000689430D0E89407FC07C062177307840734 |
:105CB000950721F008F400940794989408959A9514 |
:105CC000BB0F661F771F881F11249923A1F088231B |
:105CD000B2F79F3F59F0BB0F48F421F4002011F4B4 |
:105CE00060FF04C06F5F7F4F8F4F9F4F881F979556 |
:105CF000879597F908952CC09FEF80EC0895052EA5 |
:105D0000092607FA440F551F5F3F79F0AA27A51708 |
:105D100008F051E04795880F991F9F3F31F0BB274E |
:105D2000B91708F091E0879508959F919F911124EC |
:105D3000E3CF97FB880F991F9F3F31F0BB27B9171F |
:105D400008F091E0879508959F919F911124D4CFF9 |
:105D500066277727882799270895D1DF01D0B4CF08 |
:105D6000992339F0552329F09F575F57950F13F466 |
:105D70009AF1F1CF91589F3FE1F3629FA12D0F92CD |
:105D8000BB27639FA00DB11DEE27729FA00DB11D13 |
:105D9000EE1FAF93AA27649FB00DE11D739FB00D56 |
:105DA000E11DAA1F6627829FB00DE11DA61F552782 |
:105DB000749FE00DA11D551F839FE00DA11D561F6F |
:105DC000849FA00D511D852F7A2F6E2F1F900F904D |
:105DD00088231AF4939539F48FCF000C111CBB1F44 |
:105DE000661F771F881F01280895629FD001739F47 |
:105DF000F001829FE00DF11D649FE00DF11D929F67 |
:105E0000F00D839FF00D749FF00D659FF00D9927A5 |
:105E1000729FB00DE11DF91F639FB00DE11DF91FC9 |
:105E2000BD01CF0111240895991B79E004C0991F89 |
:105E3000961708F0961B881F7A95C9F780950895E4 |
:105E4000AA1BBB1B51E107C0AA1FBB1FA617B707A0 |
:105E500010F0A61BB70B881F991F5A95A9F78095BC |
:105E60009095BC01CD01089597FB092E07260AD015 |
:105E700077FD04D0E5DF06D000201AF47095619517 |
:105E80007F4F0895F6F7909581959F4F0895A1E271 |
:105E90001A2EAA1BBB1BFD010DC0AA1FBB1FEE1FA4 |
:105EA000FF1FA217B307E407F50720F0A21BB30BEF |
:105EB000E40BF50B661F771F881F991F1A9469F76B |
:105EC00060957095809590959B01AC01BD01CF01C7 |
:105ED000089597FB092E05260ED057FD04D0D7DF75 |
:105EE0000AD0001C38F450954095309521953F4FCD |
:105EF0004F4F5F4F0895F6F7909580957095619597 |
:105F00007F4F8F4F9F4F0895F999FECFB2BDA1BD2E |
:105F1000F89A119600B40895F999FECFB2BDA1BDCB |
:105F200000BC11960FB6F894FA9AF99A0FBE08952C |
:105F30000A6401FFFF010AFF03007D0000640048BE |
:105F4000616C6C6F2057656C7400000000000000ED |
:105F50000000000000000000000000000000000041 |
:105F60000000000000000000000000000000000031 |
:105F70000000000000000000000000000000000021 |
:105F80000000000000000000000000000000000110 |
:105F900002030405060708090A0A0146640A029674 |
:105FA00096403A10FB3017B7D1380000803F6400AC |
:105FB00053706F727400004B616D65726100000078 |
:00000001FF |
/branches/V0.63_LED1_LED2/Hex-Files/WasIstWas.txt |
---|
0,0 → 1,15 |
+++++++++++++++++++++++++ |
+ Flight-Ctrl: |
+++++++++++++++++++++++++ |
BootLoader_MEGA644_20MHZ_V0_1.hex |
Der Bootloader wird per ISP eingespielt |
Der Bootloader nur dann eingespielt werden, wenn noch nie ein Bootloader eingespielt wurde! |
Danach können Softwareupdates seriell eingespielt werden. |
Flight-Ctrl_MEGA644_Vx_yy.hex |
Aktuelle Firmware |
Wird per serielle Schnittstelle (durch den Bootloader) eingespielt |
Flight-Ctrl SW > 0.62 benötigt das Kopter-Tool >1.47 |
/branches/V0.63_LED1_LED2/License.txt |
---|
0,0 → 1,52 |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Copyright (c) 04.2007 Holger Buss |
// + Nur für den privaten Gebrauch |
// + www.MikroKopter.com |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Es gilt für das gesamte Projekt (Hardware, Software, Binärfiles, Sourcecode und Dokumentation), |
// + dass eine Nutzung (auch auszugsweise) nur für den privaten und nichtkommerziellen Gebrauch zulässig ist. |
// + Sollten direkte oder indirekte kommerzielle Absichten verfolgt werden, ist mit uns (info@mikrokopter.de) Kontakt |
// + bzgl. der Nutzungsbedingungen aufzunehmen. |
// + Eine kommerzielle Nutzung ist z.B.Verkauf von MikroKoptern, Bestückung und Verkauf von Platinen oder Bausätzen, |
// + Verkauf von Luftbildaufnahmen, usw. |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Werden Teile des Quellcodes (mit oder ohne Modifikation) weiterverwendet oder veröffentlicht, |
// + unterliegen sie auch diesen Nutzungsbedingungen und diese Nutzungsbedingungen incl. Copyright müssen dann beiliegen |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Sollte die Software (auch auszugesweise) oder sonstige Informationen des MikroKopter-Projekts |
// + auf anderen Webseiten oder sonstigen Medien veröffentlicht werden, muss unsere Webseite "http://www.mikrokopter.de" |
// + eindeutig als Ursprung verlinkt und genannt werden |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Keine Gewähr auf Fehlerfreiheit, Vollständigkeit oder Funktion |
// + Benutzung auf eigene Gefahr |
// + Wir übernehmen keinerlei Haftung für direkte oder indirekte Personen- oder Sachschäden |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Die Portierung der Software (oder Teile davon) auf andere Systeme (ausser der Hardware von www.mikrokopter.de) ist nur |
// + mit unserer Zustimmung zulässig |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Die Funktion printf_P() unterliegt ihrer eigenen Lizenz und ist hiervon nicht betroffen |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Redistributions of source code (with or without modifications) must retain the above copyright notice, |
// + this list of conditions and the following disclaimer. |
// + * Neither the name of the copyright holders nor the names of contributors may be used to endorse or promote products derived |
// + from this software without specific prior written permission. |
// + * The use of this project (hardware, software, binary files, sources and documentation) is only permittet |
// + for non-profit use (directly or indirectly) |
// + Commercial use (for excample: selling of MikroKopters, selling of PCBs, assembly, ...) is only permitted |
// + with our written permission |
// + * If sources or documentations are redistributet, our webpage (http://www.MikroKopter.de) must be |
// + clearly linked and named as origin |
// + * porting to systems other than hardware from www.mikrokopter.de is not allowed |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" |
// + AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE |
// + IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE |
// + ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE |
// + LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR |
// + CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF |
// + SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS |
// + INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN |
// + CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) |
// + ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE |
// + POSSIBILITY OF SUCH DAMAGE. |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
/branches/V0.63_LED1_LED2/Settings.h |
---|
--- V0.63_LED1_LED2/_Settings.h (nonexistent) |
+++ V0.63_LED1_LED2/_Settings.h (revision 211) |
@@ -0,0 +1,50 @@ |
+// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Testmodi |
+// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+#define MOTOR_OFF 0 |
+#define MOTOR_TEST 0 |
+ |
+// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Abstimmung |
+// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+#define ACC_AMPLIFY 16 |
+#define FAKTOR_P 1 |
+#define FAKTOR_I 0.0001 |
+ |
+ |
+// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Debug-Interface |
+// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+#define SIO_DEBUG 1 // Soll der Debugger aktiviert sein? |
+#define MIN_DEBUG_INTERVALL 500 // in diesem Intervall werden Degugdaten ohne Aufforderung gesendet |
+ |
+// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Sender |
+// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ #define K_NICK 0 |
+ #define K_ROLL 1 |
+ #define K_GAS 2 |
+ #define K_GIER 3 |
+ #define K_POTI1 4 |
+ #define K_POTI2 5 |
+ #define K_POTI3 6 |
+ #define K_POTI4 7 |
+// +++++++++++++++++++++++++++++++ |
+// + Getestete Settings: |
+// +++++++++++++++++++++++++++++++ |
+// Setting: Kamera |
+// Stick_P:3 |
+// Stick_D:0 |
+// Gyro_P: 175 |
+// Gyro_I: 175 |
+// Ki_Anteil: 10 |
+// +++++++++++++++++++++++++++++++ |
+// + Getestete Settings: |
+// +++++++++++++++++++++++++++++++ |
+// Setting: Normal |
+// Stick_P:2 |
+// Stick_D:8 |
+// Gyro_P: 80 |
+// Gyro_I: 150 |
+// Ki_Anteil: 5 |
+ |
/branches/V0.63_LED1_LED2/analog.c |
---|
0,0 → 1,172 |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Copyright (c) 04.2007 Holger Buss |
// + only for non-profit use |
// + www.MikroKopter.com |
// + see the File "License.txt" for further Informations |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
#include "main.h" |
volatile int Aktuell_Nick,Aktuell_Roll,Aktuell_Gier,Aktuell_ax, Aktuell_ay,Aktuell_az, UBat = 100; |
volatile int AccumulateNick = 0, AccumulateRoll = 0, AccumulateGier = 0; |
volatile int accumulate_AccRoll = 0,accumulate_AccNick = 0,accumulate_AccHoch = 0; |
volatile char MessanzahlNick = 0, MessanzahlRoll = 0, MessanzahlGier = 0; |
volatile char messanzahl_AccNick = 0, messanzahl_AccRoll = 0, messanzahl_AccHoch = 0; |
volatile long Luftdruck = 32000; |
volatile int StartLuftdruck; |
volatile unsigned int MessLuftdruck = 1023; |
unsigned char DruckOffsetSetting; |
volatile int HoeheD = 0; |
volatile char messanzahl_Druck; |
volatile int tmpLuftdruck; |
volatile unsigned int ZaehlMessungen = 0; |
//####################################################################################### |
// |
void ADC_Init(void) |
//####################################################################################### |
{ |
ADMUX = 0;//Referenz ist extern |
ADCSRA=(1<<ADEN)|(1<<ADSC)|(1<<ADATE)|(1<<ADPS2)|(1<<ADPS1)|(1<<ADPS0)|(1<<ADIE); |
//Free Running Mode, Division Factor 128, Interrupt on |
} |
void SucheLuftruckOffset(void) |
{ |
unsigned int off; |
off = eeprom_read_byte(&EEPromArray[EEPROM_ADR_LAST_OFFSET]); |
if(off > 20) off -= 10; |
OCR0A = off; |
Delay_ms(100); |
if(MessLuftdruck < 850) off = 0; |
for(; off < 250;off++) |
{ |
OCR0A = off; |
Delay_ms(50); |
printf("."); |
if(MessLuftdruck < 900) break; |
} |
eeprom_write_byte(&EEPromArray[EEPROM_ADR_LAST_OFFSET], off); |
DruckOffsetSetting = off; |
Delay_ms(300); |
} |
//####################################################################################### |
// |
SIGNAL(SIG_ADC) |
//####################################################################################### |
{ |
static unsigned char kanal=0,state = 0; |
signed int wert; |
ANALOG_OFF; |
switch(state++) |
{ |
case 0: |
wert = (signed int) AdNeutralGier - ADC; |
if(PlatinenVersion != 10) wert *= 2; |
AccumulateGier += wert; // |
MessanzahlGier++; |
Mess_Integral_Gier += wert;// / 16; |
Mess_Integral_Gier2 += wert; |
kanal = 1; |
ZaehlMessungen++; |
break; |
case 1: |
wert = (signed int) ADC - AdNeutralRoll; |
if(PlatinenVersion != 10) wert *= 2; |
Mess_IntegralRoll += wert; |
Mess_IntegralRoll2 += wert; |
if(Mess_IntegralRoll > 310000L) Mess_IntegralRoll = -290000L; |
if(Mess_IntegralRoll <-310000L) Mess_IntegralRoll = 290000L; |
if(ADC < 15) wert = -1000; |
if(ADC < 7) wert = -2000; |
if(ADC > 1010) wert = +1000; |
if(ADC > 1017) wert = +2000; |
AccumulateRoll += wert; |
MessanzahlRoll++; |
kanal = 2; |
break; |
case 2: |
wert = (signed int) ADC - AdNeutralNick; |
if(PlatinenVersion != 10) wert *= 2; |
Mess_IntegralNick += wert; |
Mess_IntegralNick2 += wert; |
if(Mess_IntegralNick > 310000L) Mess_IntegralNick = -290000L; |
if(Mess_IntegralNick <-310000L) Mess_IntegralNick = 290000L; |
if(ADC < 15) wert = -1000; |
if(ADC < 7) wert = -2000; |
if(ADC > 1010) wert = +1000; |
if(ADC > 1017) wert = +2000; |
AccumulateNick += wert; |
MessanzahlNick++; |
kanal = 4; |
break; |
case 3: |
UBat = (3 * UBat + ADC / 3) / 4;//(UBat + ((ADC * 39) / 256) + 19) / 2; |
kanal = 6; |
break; |
case 4: |
Aktuell_ay = NeutralAccY - ADC; |
accumulate_AccRoll += Aktuell_ay; |
messanzahl_AccRoll++; |
kanal = 7; |
break; |
case 5: |
Aktuell_ax = ADC - NeutralAccX; |
accumulate_AccNick += Aktuell_ax; |
messanzahl_AccNick++; |
kanal = 5; |
state = 6; |
break; |
case 6: |
accumulate_AccHoch = (signed int) ADC - NeutralAccZ; |
accumulate_AccHoch += abs(Aktuell_ay) / 4 + abs(Aktuell_ax) / 4; |
if(accumulate_AccHoch > 1) |
{ |
if(NeutralAccZ < 800) NeutralAccZ+= 0.02; |
} |
else if(accumulate_AccHoch < -1) |
{ |
if(NeutralAccZ > 600) NeutralAccZ-= 0.02; |
} |
messanzahl_AccHoch = 1; |
Aktuell_az = ADC; |
Mess_Integral_Hoch += accumulate_AccHoch; // Integrieren |
Mess_Integral_Hoch -= Mess_Integral_Hoch / 1024; // dämfen |
// Mess_Integral_Hoch -= Mess_Integral_Hoch / 512; // dämfen |
/* if(EE_Parameter.GlobalConfig & CFG_HOEHENREGELUNG) |
{ |
kanal = 3; |
state = 7; |
} |
else |
{ |
kanal = 0; |
state = 0; |
}*/ |
kanal = 3; |
state = 7; |
break; |
case 7: |
tmpLuftdruck += ADC; |
if(++messanzahl_Druck >= 5) |
{ |
MessLuftdruck = ADC; |
messanzahl_Druck = 0; |
HoeheD = (int)(StartLuftdruck - tmpLuftdruck - HoehenWert); // D-Anteil = neuerWert - AlterWert |
Luftdruck = (tmpLuftdruck + 3 * Luftdruck) / 4; |
HoehenWert = StartLuftdruck - Luftdruck; |
tmpLuftdruck = 0; |
} |
kanal = 0; |
state = 0; |
break; |
default: |
kanal = 0; |
state = 0; |
break; |
} |
ADMUX = kanal; |
ANALOG_ON; |
} |
/branches/V0.63_LED1_LED2/analog.h |
---|
0,0 → 1,23 |
/*####################################################################################### |
#######################################################################################*/ |
extern volatile int UBat; |
extern volatile int AccumulateNick, AccumulateRoll, AccumulateGier,accumulate_AccRoll,accumulate_AccNick,accumulate_AccHoch; |
extern volatile char MessanzahlNick, MessanzahlRoll, MessanzahlGier,messanzahl_AccNick, messanzahl_AccRoll,messanzahl_AccHoch; |
extern volatile int Aktuell_Nick,Aktuell_Roll,Aktuell_Gier,Aktuell_ax, Aktuell_ay,Aktuell_az; |
extern volatile long Luftdruck; |
extern volatile char messanzahl_Druck; |
extern volatile unsigned int ZaehlMessungen; |
extern unsigned char DruckOffsetSetting; |
extern volatile int HoeheD; |
extern volatile unsigned int MessLuftdruck; |
extern volatile int StartLuftdruck; |
extern unsigned int ReadADC(unsigned char adc_input); |
extern void ADC_Init(void); |
extern void SucheLuftruckOffset(void); |
#define ANALOG_OFF ADCSRA=0 |
#define ANALOG_ON ADCSRA=(1<<ADEN)|(1<<ADSC)|(1<<ADATE)|(1<<ADPS2)|(1<<ADPS1)|(1<<ADPS0)|(1<<ADIE) |
/branches/V0.63_LED1_LED2/eeprom.c |
---|
--- V0.63_LED1_LED2/fc.c (nonexistent) |
+++ V0.63_LED1_LED2/fc.c (revision 211) |
@@ -0,0 +1,910 @@ |
+/*####################################################################################### |
+Flight Control |
+#######################################################################################*/ |
+// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// + Copyright (c) 04.2007 Holger Buss |
+// + Nur für den privaten Gebrauch |
+// + www.MikroKopter.com |
+// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// + Es gilt für das gesamte Projekt (Hardware, Software, Binärfiles, Sourcecode und Dokumentation), |
+// + dass eine Nutzung (auch auszugsweise) nur für den privaten (nicht-kommerziellen) Gebrauch zulässig ist. |
+// + Sollten direkte oder indirekte kommerzielle Absichten verfolgt werden, ist mit uns (info@mikrokopter.de) Kontakt |
+// + bzgl. der Nutzungsbedingungen aufzunehmen. |
+// + Eine kommerzielle Nutzung ist z.B.Verkauf von MikroKoptern, Bestückung und Verkauf von Platinen oder Bausätzen, |
+// + Verkauf von Luftbildaufnahmen, usw. |
+// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// + Werden Teile des Quellcodes (mit oder ohne Modifikation) weiterverwendet oder veröffentlicht, |
+// + unterliegen sie auch diesen Nutzungsbedingungen und diese Nutzungsbedingungen incl. Copyright müssen dann beiliegen |
+// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// + Sollte die Software (auch auszugesweise) oder sonstige Informationen des MikroKopter-Projekts |
+// + auf anderen Webseiten oder sonstigen Medien veröffentlicht werden, muss unsere Webseite "http://www.mikrokopter.de" |
+// + eindeutig als Ursprung verlinkt werden |
+// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// + Keine Gewähr auf Fehlerfreiheit, Vollständigkeit oder Funktion |
+// + Benutzung auf eigene Gefahr |
+// + Wir übernehmen keinerlei Haftung für direkte oder indirekte Personen- oder Sachschäden |
+// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// + Die Portierung der Software (oder Teile davon) auf andere Systeme (ausser der Hardware von www.mikrokopter.de) ist nur |
+// + mit unserer Zustimmung zulässig |
+// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// + Die Funktion printf_P() unterliegt ihrer eigenen Lizenz und ist hiervon nicht betroffen |
+// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// + Redistributions of source code (with or without modifications) must retain the above copyright notice, |
+// + this list of conditions and the following disclaimer. |
+// + * Neither the name of the copyright holders nor the names of contributors may be used to endorse or promote products derived |
+// + from this software without specific prior written permission. |
+// + * The use of this project (hardware, software, binary files, sources and documentation) is only permittet |
+// + for non-commercial use (directly or indirectly) |
+// + Commercial use (for excample: selling of MikroKopters, selling of PCBs, assembly, ...) is only permitted |
+// + with our written permission |
+// + * If sources or documentations are redistributet on other webpages, out webpage (http://www.MikroKopter.de) must be |
+// + clearly linked as origin |
+// + * porting to systems other than hardware from www.mikrokopter.de is not allowed |
+// + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" |
+// + AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE |
+// + IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE |
+// + ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE |
+// + LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR |
+// + CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF |
+// + SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS |
+// + INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN |
+// + CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) |
+// + ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE |
+// + POSSIBILITY OF SUCH DAMAGE. |
+// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ |
+#include "main.h" |
+ |
+unsigned char h,m,s; |
+volatile unsigned int I2CTimeout = 100; |
+volatile int MesswertNick,MesswertRoll,MesswertGier; |
+volatile int AdNeutralNick = 0,AdNeutralRoll = 0,AdNeutralGier = 0; |
+volatile int Mittelwert_AccNick, Mittelwert_AccRoll,Mittelwert_AccHoch, NeutralAccX=0, NeutralAccY=0; |
+volatile float NeutralAccZ = 0; |
+unsigned char CosinusNickWinkel = 0, CosinusRollWinkel = 0; |
+volatile long IntegralNick = 0,IntegralNick2 = 0; |
+volatile long IntegralRoll = 0,IntegralRoll2 = 0; |
+volatile long Integral_Gier = 0; |
+volatile long Mess_IntegralNick = 0,Mess_IntegralNick2 = 0; |
+volatile long Mess_IntegralRoll = 0,Mess_IntegralRoll2 = 0; |
+volatile long Mess_Integral_Gier = 0,Mess_Integral_Gier2 = 0; |
+volatile long Mess_Integral_Hoch = 0; |
+volatile int KompassValue = 0; |
+volatile int KompassStartwert = 0; |
+volatile int KompassRichtung = 0; |
+unsigned char MAX_GAS,MIN_GAS; |
+unsigned char Notlandung = 0; |
+unsigned char HoehenReglerAktiv = 0; |
+ |
+float GyroFaktor; |
+float IntegralFaktor; |
+ |
+volatile int DiffNick,DiffRoll; |
+int Poti1 = 0, Poti2 = 0, Poti3 = 0, Poti4 = 0; |
+volatile unsigned char Motor_Vorne,Motor_Hinten,Motor_Rechts,Motor_Links, Count; |
+unsigned char MotorWert[5]; |
+volatile unsigned char SenderOkay = 0; |
+int StickNick = 0,StickRoll = 0,StickGier = 0; |
+char MotorenEin = 0; |
+int HoehenWert = 0; |
+int SollHoehe = 0; |
+unsigned char Looping_Nick = 0,Looping_Roll = 0; |
+ |
+float Kp = FAKTOR_P; |
+float Ki = FAKTOR_I; |
+ |
+unsigned char Parameter_Luftdruck_D = 48; // Wert : 0-250 |
+unsigned char Parameter_MaxHoehe = 251; // Wert : 0-250 |
+unsigned char Parameter_Hoehe_P = 16; // Wert : 0-32 |
+unsigned char Parameter_Hoehe_ACC_Wirkung = 58; // Wert : 0-250 |
+unsigned char Parameter_KompassWirkung = 64; // Wert : 0-250 |
+unsigned char Parameter_Gyro_P = 150; // Wert : 10-250 |
+unsigned char Parameter_Gyro_I = 150; // Wert : 0-250 |
+unsigned char Parameter_Gier_P = 2; // Wert : 1-20 |
+unsigned char Parameter_I_Faktor = 10; // Wert : 1-20 |
+unsigned char Parameter_UserParam1 = 0; |
+unsigned char Parameter_UserParam2 = 0; |
+unsigned char Parameter_UserParam3 = 0; |
+unsigned char Parameter_UserParam4 = 0; |
+unsigned char Parameter_ServoNickControl = 100; |
+unsigned char Parameter_LoopGasLimit = 70; |
+struct mk_param_struct EE_Parameter; |
+ |
+void Piep(unsigned char Anzahl) |
+{ |
+ while(Anzahl--) |
+ { |
+ if(MotorenEin) return; //auf keinen Fall im Flug! |
+ beeptime = 100; |
+ Delay_ms(250); |
+ } |
+} |
+ |
+//############################################################################ |
+// Nullwerte ermitteln |
+void SetNeutral(void) |
+//############################################################################ |
+{ |
+ unsigned int timer; |
+ NeutralAccX = 0; |
+ NeutralAccY = 0; |
+ NeutralAccZ = 0; |
+ AdNeutralNick = 0; |
+ AdNeutralRoll = 0; |
+ AdNeutralGier = 0; |
+ CalibrierMittelwert(); |
+ timer = SetDelay(5); |
+ while (!CheckDelay(timer)); |
+ CalibrierMittelwert(); |
+ if((EE_Parameter.GlobalConfig & CFG_HOEHENREGELUNG)) // Höhenregelung aktiviert? |
+ { |
+ if((MessLuftdruck > 950) || (MessLuftdruck < 750)) SucheLuftruckOffset(); |
+ } |
+ |
+ if(PlatinenVersion == 10) |
+ { |
+ AdNeutralNick= abs(MesswertNick); |
+ AdNeutralRoll= abs(MesswertRoll); |
+ AdNeutralGier= abs(MesswertGier); |
+ } |
+ else |
+ { |
+ AdNeutralNick= abs(MesswertNick) / 2; |
+ AdNeutralRoll= abs(MesswertRoll) / 2; |
+ AdNeutralGier= abs(MesswertGier) / 2; |
+ } |
+ NeutralAccY = abs(Mittelwert_AccRoll) / ACC_AMPLIFY; |
+ NeutralAccX = abs(Mittelwert_AccNick) / ACC_AMPLIFY; |
+ NeutralAccZ = Aktuell_az; |
+ |
+ Mess_IntegralNick = 0; |
+ Mess_IntegralNick2 = 0; |
+ Mess_IntegralRoll = 0; |
+ Mess_IntegralRoll2 = 0; |
+ Mess_Integral_Gier = 0; |
+ MesswertNick = 0; |
+ MesswertRoll = 0; |
+ MesswertGier = 0; |
+ StartLuftdruck = Luftdruck; |
+ HoeheD = 0; |
+ Mess_Integral_Hoch = 0; |
+ KompassStartwert = KompassValue; |
+ GPS_Neutral(); |
+ beeptime = 50; |
+} |
+ |
+//############################################################################ |
+// Bildet den Mittelwert aus den Messwerten |
+void Mittelwert(void) |
+//############################################################################ |
+{ |
+ // ADC auschalten, damit die Werte sich nicht während der Berechnung ändern |
+ ANALOG_OFF; |
+ if(MessanzahlNick) (MesswertNick = AccumulateNick / MessanzahlNick); |
+ if(MessanzahlRoll) (MesswertRoll = AccumulateRoll / MessanzahlRoll); |
+ if(MessanzahlGier) (MesswertGier = AccumulateGier / MessanzahlGier); |
+ if(messanzahl_AccNick) Mittelwert_AccNick = ((long)Mittelwert_AccNick * 7 + ((ACC_AMPLIFY * (long)accumulate_AccNick) / messanzahl_AccNick)) / 8L; |
+ if(messanzahl_AccRoll) Mittelwert_AccRoll = ((long)Mittelwert_AccRoll * 7 + ((ACC_AMPLIFY * (long)accumulate_AccRoll) / messanzahl_AccRoll)) / 8L; |
+ if(messanzahl_AccHoch) Mittelwert_AccHoch = ((long)Mittelwert_AccHoch * 7 + ((long)accumulate_AccHoch) / messanzahl_AccHoch) / 8L; |
+ AccumulateNick = 0; MessanzahlNick = 0; |
+ AccumulateRoll = 0; MessanzahlRoll = 0; |
+ AccumulateGier = 0; MessanzahlGier = 0; |
+ accumulate_AccRoll = 0;messanzahl_AccRoll = 0; |
+ accumulate_AccNick = 0;messanzahl_AccNick = 0; |
+ accumulate_AccHoch = 0;messanzahl_AccHoch = 0; |
+ Integral_Gier = Mess_Integral_Gier; |
+// Integral_Gier2 = Mess_Integral_Gier2; |
+ IntegralNick = Mess_IntegralNick; |
+ IntegralRoll = Mess_IntegralRoll; |
+ IntegralNick2 = Mess_IntegralNick2; |
+ IntegralRoll2 = Mess_IntegralRoll2; |
+ // ADC einschalten |
+ ANALOG_ON; |
+ |
+/* |
+//------------------------------------------------------------------------------ |
+ if(MesswertNick > 200) MesswertNick += 4 * (MesswertNick - 200); |
+ else |
+ if(MesswertNick < -200) MesswertNick += 4 * (MesswertNick + 200); |
+ if(MesswertRoll > 200) MesswertRoll += 4 * (MesswertRoll - 200); |
+ else |
+ if(MesswertRoll < -200) MesswertRoll += 4 * (MesswertRoll + 200); |
+//------------------------------------------------------------------------------ |
+*/ |
+ if(Poti1 < PPM_in[EE_Parameter.Kanalbelegung[K_POTI1]] + 110) Poti1++; else if(Poti1 > PPM_in[EE_Parameter.Kanalbelegung[K_POTI1]] + 110 && Poti1) Poti1--; |
+ if(Poti2 < PPM_in[EE_Parameter.Kanalbelegung[K_POTI2]] + 110) Poti2++; else if(Poti2 > PPM_in[EE_Parameter.Kanalbelegung[K_POTI2]] + 110 && Poti2) Poti2--; |
+ if(Poti3 < PPM_in[EE_Parameter.Kanalbelegung[K_POTI3]] + 110) Poti3++; else if(Poti3 > PPM_in[EE_Parameter.Kanalbelegung[K_POTI3]] + 110 && Poti3) Poti3--; |
+ if(Poti4 < PPM_in[EE_Parameter.Kanalbelegung[K_POTI4]] + 110) Poti4++; else if(Poti4 > PPM_in[EE_Parameter.Kanalbelegung[K_POTI4]] + 110 && Poti4) Poti4--; |
+ if(Poti1 < 0) Poti1 = 0; else if(Poti1 > 255) Poti1 = 255; |
+ if(Poti2 < 0) Poti2 = 0; else if(Poti2 > 255) Poti2 = 255; |
+ if(Poti3 < 0) Poti3 = 0; else if(Poti3 > 255) Poti3 = 255; |
+ if(Poti4 < 0) Poti4 = 0; else if(Poti4 > 255) Poti4 = 255; |
+} |
+ |
+//############################################################################ |
+// Messwerte beim Ermitteln der Nullage |
+void CalibrierMittelwert(void) |
+//############################################################################ |
+{ |
+ // ADC auschalten, damit die Werte sich nicht während der Berechnung ändern |
+ ANALOG_OFF; |
+ if(MessanzahlNick) (MesswertNick = AccumulateNick / MessanzahlNick); |
+ if(MessanzahlRoll) (MesswertRoll = AccumulateRoll / MessanzahlRoll); |
+ if(MessanzahlGier) (MesswertGier = AccumulateGier / MessanzahlGier); |
+ if(messanzahl_AccNick) Mittelwert_AccNick = ((ACC_AMPLIFY * (long)accumulate_AccNick) / messanzahl_AccNick); |
+ if(messanzahl_AccRoll) Mittelwert_AccRoll = (ACC_AMPLIFY * (long)accumulate_AccRoll) / messanzahl_AccRoll; |
+ if(messanzahl_AccHoch) Mittelwert_AccHoch = ((long)accumulate_AccHoch) / messanzahl_AccHoch; |
+ AccumulateNick = 0; MessanzahlNick = 0; |
+ AccumulateRoll = 0; MessanzahlRoll = 0; |
+ AccumulateGier = 0; MessanzahlGier = 0; |
+ accumulate_AccRoll = 0;messanzahl_AccRoll = 0; |
+ accumulate_AccNick = 0;messanzahl_AccNick = 0; |
+ accumulate_AccHoch = 0;messanzahl_AccHoch = 0; |
+ // ADC einschalten |
+ ANALOG_ON; |
+ if(Poti1 < PPM_in[EE_Parameter.Kanalbelegung[K_POTI1]] + 110) Poti1++; else if(Poti1 > PPM_in[EE_Parameter.Kanalbelegung[K_POTI1]] + 110 && Poti1) Poti1--; |
+ if(Poti2 < PPM_in[EE_Parameter.Kanalbelegung[K_POTI2]] + 110) Poti2++; else if(Poti2 > PPM_in[EE_Parameter.Kanalbelegung[K_POTI2]] + 110 && Poti2) Poti2--; |
+ if(Poti3 < PPM_in[EE_Parameter.Kanalbelegung[K_POTI3]] + 110) Poti3++; else if(Poti3 > PPM_in[EE_Parameter.Kanalbelegung[K_POTI3]] + 110 && Poti3) Poti3--; |
+ if(Poti4 < PPM_in[EE_Parameter.Kanalbelegung[K_POTI4]] + 110) Poti4++; else if(Poti4 > PPM_in[EE_Parameter.Kanalbelegung[K_POTI4]] + 110 && Poti4) Poti4--; |
+ if(Poti1 < 0) Poti1 = 0; else if(Poti1 > 255) Poti1 = 255; |
+ if(Poti2 < 0) Poti2 = 0; else if(Poti2 > 255) Poti2 = 255; |
+ if(Poti3 < 0) Poti3 = 0; else if(Poti3 > 255) Poti3 = 255; |
+ if(Poti4 < 0) Poti4 = 0; else if(Poti4 > 255) Poti4 = 255; |
+} |
+ |
+//############################################################################ |
+// Senden der Motorwerte per I2C-Bus |
+void SendMotorData(void) |
+//############################################################################ |
+{ |
+ if(MOTOR_OFF || !MotorenEin) |
+ { |
+ Motor_Hinten = 0; |
+ Motor_Vorne = 0; |
+ Motor_Rechts = 0; |
+ Motor_Links = 0; |
+ if(MotorTest[0]) Motor_Vorne = MotorTest[0]; |
+ if(MotorTest[1]) Motor_Hinten = MotorTest[1]; |
+ if(MotorTest[2]) Motor_Links = MotorTest[2]; |
+ if(MotorTest[3]) Motor_Rechts = MotorTest[3]; |
+ } |
+ |
+ DebugOut.Analog[12] = Motor_Vorne; |
+ DebugOut.Analog[13] = Motor_Hinten; |
+ DebugOut.Analog[14] = Motor_Links; |
+ DebugOut.Analog[15] = Motor_Rechts; |
+ |
+ //Start I2C Interrupt Mode |
+ twi_state = 0; |
+ motor = 0; |
+ i2c_start(); |
+} |
+ |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// + Konstanten |
+// + 0-250 -> normale Werte |
+// + 251 -> Poti1 |
+// + 252 -> Poti2 |
+// + 253 -> Poti3 |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+void DefaultKonstanten1(void) |
+{ |
+ EE_Parameter.Kanalbelegung[K_NICK] = 1; |
+ EE_Parameter.Kanalbelegung[K_ROLL] = 2; |
+ EE_Parameter.Kanalbelegung[K_GAS] = 3; |
+ EE_Parameter.Kanalbelegung[K_GIER] = 4; |
+ EE_Parameter.Kanalbelegung[K_POTI1] = 5; |
+ EE_Parameter.Kanalbelegung[K_POTI2] = 6; |
+ EE_Parameter.Kanalbelegung[K_POTI3] = 7; |
+ EE_Parameter.Kanalbelegung[K_POTI4] = 8; |
+ EE_Parameter.GlobalConfig = 0;//CFG_HOEHENREGELUNG | /*CFG_HOEHEN_SCHALTER |*/ CFG_KOMPASS_AKTIV | CFG_KOMPASS_FIX;//0x01; |
+ EE_Parameter.Hoehe_MinGas = 30; |
+ EE_Parameter.MaxHoehe = 251; // Wert : 0-32 251 -> Poti1 |
+ EE_Parameter.Hoehe_P = 10; // Wert : 0-32 |
+ EE_Parameter.Luftdruck_D = 50; // Wert : 0-250 |
+ EE_Parameter.Hoehe_ACC_Wirkung = 50; // Wert : 0-250 |
+ EE_Parameter.Hoehe_Verstaerkung = 4; // Wert : 0-50 |
+ EE_Parameter.Stick_P = 4; //2 // Wert : 1-6 |
+ EE_Parameter.Stick_D = 8; //8 // Wert : 0-64 |
+ EE_Parameter.Gier_P = 16; // Wert : 1-20 |
+ EE_Parameter.Gas_Min = 15; // Wert : 0-32 |
+ EE_Parameter.Gas_Max = 250; // Wert : 33-250 |
+ EE_Parameter.GyroAccFaktor = 26; // Wert : 1-64 |
+ EE_Parameter.KompassWirkung = 128; // Wert : 0-250 |
+ EE_Parameter.Gyro_P = 120; //80 // Wert : 0-250 |
+ EE_Parameter.Gyro_I = 150; // Wert : 0-250 |
+ EE_Parameter.UnterspannungsWarnung = 94; // Wert : 0-250 |
+ EE_Parameter.NotGas = 35; // Wert : 0-250 // Gaswert bei Empangsverlust |
+ EE_Parameter.NotGasZeit = 20; // Wert : 0-250 // Zeit bis auf NotGas geschaltet wird, wg. Rx-Problemen |
+ EE_Parameter.UfoAusrichtung = 0; // X oder + Formation |
+ EE_Parameter.I_Faktor = 0; |
+ EE_Parameter.UserParam1 = 0; //zur freien Verwendung |
+ EE_Parameter.UserParam2 = 0; //zur freien Verwendung |
+ EE_Parameter.UserParam3 = 0; //zur freien Verwendung |
+ EE_Parameter.UserParam4 = 0; //zur freien Verwendung |
+ EE_Parameter.ServoNickControl = 100; // Wert : 0-250 // Stellung des Servos |
+ EE_Parameter.ServoNickComp = 40; // Wert : 0-250 // Einfluss Gyro/Servo |
+ EE_Parameter.ServoNickCompInvert = 0; // Wert : 0-250 // Richtung Einfluss Gyro/Servo |
+ EE_Parameter.ServoNickMin = 50; // Wert : 0-250 // Anschlag |
+ EE_Parameter.ServoNickMax = 150; // Wert : 0-250 // Anschlag |
+ EE_Parameter.ServoNickRefresh = 5; |
+ EE_Parameter.LoopGasLimit = 50; |
+ EE_Parameter.LoopThreshold = 90; // Wert: 0-250 Schwelle für Stickausschlag |
+ EE_Parameter.LoopConfig = 0; // Bitcodiert: 0x01=oben, 0x02=unten, 0x04=links, 0x08=rechts / wird getrennt behandelt |
+ memcpy(EE_Parameter.Name, "Sport\0", 12); |
+} |
+ |
+void DefaultKonstanten2(void) |
+{ |
+ EE_Parameter.Kanalbelegung[K_NICK] = 1; |
+ EE_Parameter.Kanalbelegung[K_ROLL] = 2; |
+ EE_Parameter.Kanalbelegung[K_GAS] = 3; |
+ EE_Parameter.Kanalbelegung[K_GIER] = 4; |
+ EE_Parameter.Kanalbelegung[K_POTI1] = 5; |
+ EE_Parameter.Kanalbelegung[K_POTI2] = 6; |
+ EE_Parameter.Kanalbelegung[K_POTI3] = 7; |
+ EE_Parameter.Kanalbelegung[K_POTI4] = 8; |
+ EE_Parameter.GlobalConfig = 0;//CFG_HOEHENREGELUNG | /*CFG_HOEHEN_SCHALTER |*/ CFG_KOMPASS_AKTIV;//0x01; |
+ EE_Parameter.Hoehe_MinGas = 30; |
+ EE_Parameter.MaxHoehe = 251; // Wert : 0-32 251 -> Poti1 |
+ EE_Parameter.Hoehe_P = 10; // Wert : 0-32 |
+ EE_Parameter.Luftdruck_D = 50; // Wert : 0-250 |
+ EE_Parameter.Hoehe_ACC_Wirkung = 50; // Wert : 0-250 |
+ EE_Parameter.Hoehe_Verstaerkung = 2; // Wert : 0-50 |
+ EE_Parameter.Stick_P = 4; //2 // Wert : 1-6 |
+ EE_Parameter.Stick_D = 0; //8 // Wert : 0-64 |
+ EE_Parameter.Gier_P = 16; // Wert : 1-20 |
+ EE_Parameter.Gas_Min = 15; // Wert : 0-32 |
+ EE_Parameter.Gas_Max = 250; // Wert : 33-250 |
+ EE_Parameter.GyroAccFaktor = 26; // Wert : 1-64 |
+ EE_Parameter.KompassWirkung = 128; // Wert : 0-250 |
+ EE_Parameter.Gyro_P = 175; //80 // Wert : 0-250 |
+ EE_Parameter.Gyro_I = 175; // Wert : 0-250 |
+ EE_Parameter.UnterspannungsWarnung = 94; // Wert : 0-250 |
+ EE_Parameter.NotGas = 35; // Wert : 0-250 // Gaswert bei Empangsverlust |
+ EE_Parameter.NotGasZeit = 20; // Wert : 0-250 // Zeit bis auf NotGas geschaltet wird, wg. Rx-Problemen |
+ EE_Parameter.UfoAusrichtung = 0; // X oder + Formation |
+ EE_Parameter.I_Faktor = 0; |
+ EE_Parameter.UserParam1 = 0; //zur freien Verwendung |
+ EE_Parameter.UserParam2 = 0; //zur freien Verwendung |
+ EE_Parameter.UserParam3 = 0; //zur freien Verwendung |
+ EE_Parameter.UserParam4 = 0; //zur freien Verwendung |
+ EE_Parameter.ServoNickControl = 100; // Wert : 0-250 // Stellung des Servos |
+ EE_Parameter.ServoNickComp = 40; // Wert : 0-250 // Einfluss Gyro/Servo |
+ EE_Parameter.ServoNickCompInvert = 0; // Wert : 0-250 // Richtung Einfluss Gyro/Servo |
+ EE_Parameter.ServoNickMin = 50; // Wert : 0-250 // Anschlag |
+ EE_Parameter.ServoNickMax = 150; // Wert : 0-250 // Anschlag |
+ EE_Parameter.ServoNickRefresh = 5; |
+ EE_Parameter.LoopGasLimit = 50; |
+ EE_Parameter.LoopThreshold = 90; // Wert: 0-250 Schwelle für Stickausschlag |
+ EE_Parameter.LoopConfig = 0; // Bitcodiert: 0x01=oben, 0x02=unten, 0x04=links, 0x08=rechts |
+ memcpy(EE_Parameter.Name, "Kamera\0", 12); |
+} |
+ |
+ |
+//############################################################################ |
+// Trägt ggf. das Poti als Parameter ein |
+void ParameterZuordnung(void) |
+//############################################################################ |
+{ |
+ |
+ #define CHK_POTI(b,a,min,max) { if(a > 250) { if(a == 251) b = Poti1; else if(a == 252) b = Poti2; else if(a == 253) b = Poti3; else if(a == 254) b = Poti4;} else b = a; if(b <= min) b = min; else if(b >= max) b = max;} |
+ CHK_POTI(Parameter_MaxHoehe,EE_Parameter.MaxHoehe,0,255); |
+ CHK_POTI(Parameter_Luftdruck_D,EE_Parameter.Luftdruck_D,0,100); |
+ CHK_POTI(Parameter_Hoehe_P,EE_Parameter.Hoehe_P,0,100); |
+ CHK_POTI(Parameter_Hoehe_ACC_Wirkung,EE_Parameter.Hoehe_ACC_Wirkung,0,255); |
+ CHK_POTI(Parameter_KompassWirkung,EE_Parameter.KompassWirkung,0,255); |
+ CHK_POTI(Parameter_Gyro_P,EE_Parameter.Gyro_P,10,255); |
+ CHK_POTI(Parameter_Gyro_I,EE_Parameter.Gyro_I,0,255); |
+ CHK_POTI(Parameter_I_Faktor,EE_Parameter.I_Faktor,0,255); |
+ CHK_POTI(Parameter_UserParam1,EE_Parameter.UserParam1,0,255); |
+ CHK_POTI(Parameter_UserParam2,EE_Parameter.UserParam2,0,255); |
+ CHK_POTI(Parameter_UserParam3,EE_Parameter.UserParam3,0,255); |
+ CHK_POTI(Parameter_UserParam4,EE_Parameter.UserParam4,0,255); |
+ CHK_POTI(Parameter_ServoNickControl,EE_Parameter.ServoNickControl,0,255); |
+ CHK_POTI(Parameter_ServoNickControl,EE_Parameter.ServoNickControl,0,255); |
+ CHK_POTI(Parameter_ServoNickControl,EE_Parameter.ServoNickControl,0,255); |
+ CHK_POTI(Parameter_LoopGasLimit,EE_Parameter.LoopGasLimit,0,255); |
+ |
+ Ki = (float) Parameter_I_Faktor * 0.0001; |
+ MAX_GAS = EE_Parameter.Gas_Max; |
+ MIN_GAS = EE_Parameter.Gas_Min; |
+} |
+ |
+ |
+//############################################################################ |
+// |
+void MotorRegler(void) |
+//############################################################################ |
+{ |
+ int motorwert,pd_ergebnis,h,tmp_int; |
+ int GierMischanteil,GasMischanteil; |
+ static long SummeNick=0,SummeRoll=0; |
+ static long sollGier = 0,tmp_long,tmp_long2; |
+ long IntegralFehlerNick = 0; |
+ long IntegralFehlerRoll = 0; |
+ static unsigned int RcLostTimer; |
+ static unsigned char delay_neutral = 0; |
+ static unsigned char delay_einschalten = 0,delay_ausschalten = 0; |
+ static unsigned int modell_fliegt = 0; |
+ static int hoehenregler = 0; |
+ static char TimerWerteausgabe = 0; |
+ static char NeueKompassRichtungMerken = 0; |
+ Mittelwert(); |
+ |
+ GRN_ON; |
+ |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Gaswert ermitteln |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ GasMischanteil = PPM_in[EE_Parameter.Kanalbelegung[K_GAS]] + 120; |
+ if(GasMischanteil < 0) GasMischanteil = 0; |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Emfang schlecht |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ if(SenderOkay < 100) |
+ { |
+ if(!PcZugriff) |
+ { |
+ if(BeepMuster == 0xffff) |
+ { |
+ beeptime = 15000; |
+ BeepMuster = 0x0c00; |
+ } |
+ } |
+ if(RcLostTimer) RcLostTimer--; |
+ else |
+ { |
+ MotorenEin = 0; |
+ Notlandung = 0; |
+ } |
+ ROT_ON; |
+ if(modell_fliegt > 2000) // wahrscheinlich in der Luft --> langsam absenken |
+ { |
+ GasMischanteil = EE_Parameter.NotGas; |
+ Notlandung = 1; |
+ PPM_in[EE_Parameter.Kanalbelegung[K_NICK]] = 0; |
+ PPM_in[EE_Parameter.Kanalbelegung[K_ROLL]] = 0; |
+ PPM_in[EE_Parameter.Kanalbelegung[K_GIER]] = 0; |
+ } |
+ else MotorenEin = 0; |
+ } |
+ else |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Emfang gut |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ if(SenderOkay > 140) |
+ { |
+ Notlandung = 0; |
+ RcLostTimer = EE_Parameter.NotGasZeit * 50; |
+ if(GasMischanteil > 40) |
+ { |
+ if(modell_fliegt < 0xffff) modell_fliegt++; |
+ } |
+ if((modell_fliegt < 200) || (GasMischanteil < 40)) |
+ { |
+ SummeNick = 0; |
+ SummeRoll = 0; |
+ Mess_Integral_Gier = 0; |
+ Mess_Integral_Gier2 = 0; |
+ } |
+ if((GasMischanteil > 200) && MotorenEin == 0) |
+ { |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// auf Nullwerte kalibrieren |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ if(PPM_in[EE_Parameter.Kanalbelegung[K_GIER]] > 75) // Neutralwerte |
+ { |
+ unsigned char setting; |
+ if(++delay_neutral > 200) // nicht sofort |
+ { |
+ GRN_OFF; |
+ MotorenEin = 0; |
+ delay_neutral = 0; |
+ modell_fliegt = 0; |
+ if(PPM_in[EE_Parameter.Kanalbelegung[K_NICK]] > 70 || abs(PPM_in[EE_Parameter.Kanalbelegung[K_ROLL]]) > 70) |
+ { |
+ if(PPM_in[EE_Parameter.Kanalbelegung[K_ROLL]] > 70 && PPM_in[EE_Parameter.Kanalbelegung[K_NICK]] < 70) setting = 1; |
+ if(PPM_in[EE_Parameter.Kanalbelegung[K_ROLL]] > 70 && PPM_in[EE_Parameter.Kanalbelegung[K_NICK]] > 70) setting = 2; |
+ if(PPM_in[EE_Parameter.Kanalbelegung[K_ROLL]] < 70 && PPM_in[EE_Parameter.Kanalbelegung[K_NICK]] > 70) setting = 3; |
+ if(PPM_in[EE_Parameter.Kanalbelegung[K_ROLL]] <-70 && PPM_in[EE_Parameter.Kanalbelegung[K_NICK]] > 70) setting = 4; |
+ if(PPM_in[EE_Parameter.Kanalbelegung[K_ROLL]] <-70 && PPM_in[EE_Parameter.Kanalbelegung[K_NICK]] < 70) setting = 5; |
+ eeprom_write_byte(&EEPromArray[EEPROM_ADR_ACTIVE_SET], setting); // aktiven Datensatz merken |
+ } |
+ if((EE_Parameter.GlobalConfig & CFG_HOEHENREGELUNG)) // Höhenregelung aktiviert? |
+ { |
+ if((MessLuftdruck > 950) || (MessLuftdruck < 750)) SucheLuftruckOffset(); |
+ } |
+ ReadParameterSet(GetActiveParamSetNumber(), (unsigned char *) &EE_Parameter.Kanalbelegung[0], STRUCT_PARAM_LAENGE); |
+ SetNeutral(); |
+ Piep(GetActiveParamSetNumber()); |
+ } |
+ } |
+ else delay_neutral = 0; |
+ } |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Gas ist unten |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ if(GasMischanteil < 35) |
+ { |
+ // Starten |
+ if(PPM_in[EE_Parameter.Kanalbelegung[K_GIER]] < -75) |
+ { |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Einschalten |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ if(++delay_einschalten > 200) |
+ { |
+ delay_einschalten = 200; |
+ modell_fliegt = 1; |
+ MotorenEin = 1; |
+ sollGier = 0; |
+ Mess_Integral_Gier = 0; |
+ Mess_Integral_Gier2 = 0; |
+ Mess_IntegralNick = 0; |
+ Mess_IntegralRoll = 0; |
+ Mess_IntegralNick2 = IntegralNick; |
+ Mess_IntegralRoll2 = IntegralRoll; |
+ SummeNick = 0; |
+ SummeRoll = 0; |
+ } |
+ } |
+ else delay_einschalten = 0; |
+ //Auf Neutralwerte setzen |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Auschalten |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ if(PPM_in[EE_Parameter.Kanalbelegung[K_GIER]] > 75) |
+ { |
+ if(++delay_ausschalten > 200) // nicht sofort |
+ { |
+ MotorenEin = 0; |
+ delay_ausschalten = 200; |
+ modell_fliegt = 0; |
+ } |
+ } |
+ else delay_ausschalten = 0; |
+ } |
+ } |
+ |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// neue Werte von der Funke |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ if(!NewPpmData-- || Notlandung) |
+ { |
+ ParameterZuordnung(); |
+ StickNick = PPM_in[EE_Parameter.Kanalbelegung[K_NICK]] * EE_Parameter.Stick_P; |
+ StickNick += PPM_diff[EE_Parameter.Kanalbelegung[K_NICK]] * EE_Parameter.Stick_D; |
+ StickRoll = PPM_in[EE_Parameter.Kanalbelegung[K_ROLL]] * EE_Parameter.Stick_P; |
+ StickRoll += PPM_diff[EE_Parameter.Kanalbelegung[K_ROLL]] * EE_Parameter.Stick_D; |
+ StickGier = -PPM_in[EE_Parameter.Kanalbelegung[K_GIER]]; |
+ GyroFaktor = ((float)Parameter_Gyro_P + 10.0) / 256.0; |
+ IntegralFaktor = ((float) Parameter_Gyro_I) / 44000; |
+ |
+ if(EE_Parameter.GlobalConfig & CFG_HEADING_HOLD) IntegralFaktor = 0; |
+ if(GyroFaktor < 0) GyroFaktor = 0; |
+ if(IntegralFaktor < 0) IntegralFaktor = 0; |
+ // greift in den Stick ein, um ungewolltes überschlagen zu verhindern |
+ if(!(EE_Parameter.LoopConfig & CFG_LOOP_LINKS) && !(EE_Parameter.LoopConfig & CFG_LOOP_RECHTS)) |
+ { |
+ if(IntegralNick > 60000) |
+ { |
+ StickNick -= 8 * EE_Parameter.Stick_P; |
+ if(IntegralNick > 80000) StickNick -= 16 * EE_Parameter.Stick_P; |
+ } |
+ else |
+ if(IntegralNick < -60000) |
+ { |
+ StickNick += 8 * EE_Parameter.Stick_P; |
+ if(IntegralNick > 80000) StickNick -= 16 * EE_Parameter.Stick_P; |
+ } |
+ if(IntegralRoll > 60000) |
+ { |
+ StickRoll -= 8 * EE_Parameter.Stick_P; |
+ if(IntegralRoll > 80000) StickRoll -= 16 * EE_Parameter.Stick_P; |
+ } |
+ else |
+ if(IntegralRoll < -60000) |
+ { |
+ StickRoll += 8 * EE_Parameter.Stick_P; |
+ if(IntegralRoll > 80000) StickRoll -= 16 * EE_Parameter.Stick_P; |
+ } |
+ } |
+ |
+ } |
+ |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Looping? |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ if(((PPM_in[EE_Parameter.Kanalbelegung[K_ROLL]] > EE_Parameter.LoopThreshold) && EE_Parameter.LoopConfig & CFG_LOOP_LINKS) || |
+ ((PPM_in[EE_Parameter.Kanalbelegung[K_ROLL]] < -EE_Parameter.LoopThreshold) && EE_Parameter.LoopConfig & CFG_LOOP_RECHTS)) |
+ { |
+ Looping_Roll = 1; |
+ if(GasMischanteil > EE_Parameter.LoopGasLimit) GasMischanteil = EE_Parameter.LoopGasLimit; |
+ } |
+ else Looping_Roll = 0; |
+ |
+ if(((PPM_in[EE_Parameter.Kanalbelegung[K_NICK]] > EE_Parameter.LoopThreshold) && EE_Parameter.LoopConfig & CFG_LOOP_OBEN) || |
+ ((PPM_in[EE_Parameter.Kanalbelegung[K_NICK]] < -EE_Parameter.LoopThreshold) && EE_Parameter.LoopConfig & CFG_LOOP_UNTEN)) |
+ { |
+ Looping_Nick = 1; |
+ Looping_Roll = 0; |
+ if(GasMischanteil > EE_Parameter.LoopGasLimit) GasMischanteil = EE_Parameter.LoopGasLimit; |
+ } |
+ else Looping_Nick = 0; |
+ |
+ |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Bei Empfangsausfall im Flug |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ if(Notlandung) |
+ { |
+ StickGier = 0; |
+ StickNick = 0; |
+ StickRoll = 0; |
+ GyroFaktor = 0.1; |
+ IntegralFaktor = 0.005; |
+ Looping_Roll = 0; |
+ Looping_Nick = 0; |
+ } |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Gyro-Drift kompensieren |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+#define DRIFT_FAKTOR 3 |
+ if(ZaehlMessungen >= 1000 / DRIFT_FAKTOR) |
+ { |
+ IntegralFehlerNick = IntegralNick2 - IntegralNick; |
+ IntegralFehlerRoll = IntegralRoll2 - IntegralRoll; |
+ ZaehlMessungen = 0; |
+ if(IntegralFehlerNick > 500/DRIFT_FAKTOR) AdNeutralNick++; |
+ if(IntegralFehlerNick < -500/DRIFT_FAKTOR) AdNeutralNick--; |
+ if(IntegralFehlerRoll > 500/DRIFT_FAKTOR) AdNeutralRoll++; |
+ if(IntegralFehlerRoll < -500/DRIFT_FAKTOR) AdNeutralRoll--; |
+// if(Mess_Integral_Gier2 > 500/DRIFT_FAKTOR) AdNeutralGier--; // macht nur mit Referenz (Kompass Sinn) |
+// if(Mess_Integral_Gier2 <-500/DRIFT_FAKTOR) AdNeutralGier++; // macht nur mit Referenz (Kompass Sinn) |
+ ANALOG_OFF; // ADC ausschalten, damit die Werte sich nicht während der Berechnung ändern |
+ Mess_IntegralNick2 = IntegralNick; |
+ Mess_IntegralRoll2 = IntegralRoll; |
+ Mess_Integral_Gier2 = Integral_Gier; |
+ ANALOG_ON; // ADC einschalten |
+ } |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Integrale auf ACC-Signal abgleichen |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ if(IntegralFaktor && !Looping_Nick && !Looping_Roll) |
+ { |
+ tmp_long = (long)(IntegralNick / EE_Parameter.GyroAccFaktor - (long)Mittelwert_AccNick); |
+ if(labs(Mittelwert_AccNick) < 200) tmp_long /= 8; |
+ else tmp_long /= 16; |
+ tmp_long2 = (long)(IntegralRoll / EE_Parameter.GyroAccFaktor - (long)Mittelwert_AccRoll); |
+ if(labs(Mittelwert_AccRoll) < 200) tmp_long2 /= 8; |
+ else tmp_long2 /= 16; |
+ |
+ #define AUSGLEICH 500 |
+ if(tmp_long > AUSGLEICH) tmp_long = AUSGLEICH; |
+ if(tmp_long < -AUSGLEICH) tmp_long =-AUSGLEICH; |
+ if(tmp_long2 > AUSGLEICH) tmp_long2 = AUSGLEICH; |
+ if(tmp_long2 <-AUSGLEICH) tmp_long2 =-AUSGLEICH; |
+ } |
+ else |
+ { |
+ tmp_long = 0; |
+ tmp_long2 = 0; |
+ } |
+ ANALOG_OFF; // ADC ausschalten, damit die Werte sich nicht während der Berechnung ändern |
+ Mess_IntegralNick -= tmp_long; |
+ Mess_IntegralRoll -= tmp_long2; |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Gieren |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ if(abs(StickGier) > 35) |
+ { |
+ if(!(EE_Parameter.GlobalConfig & CFG_KOMPASS_FIX)) NeueKompassRichtungMerken = 1; |
+ } |
+ tmp_int = EE_Parameter.Gier_P * (StickGier * abs(StickGier)) / 512; // expo y = ax + bx² |
+ tmp_int += (EE_Parameter.Gier_P * StickGier) / 4; |
+ sollGier = tmp_int; |
+ Mess_Integral_Gier -= tmp_int; |
+ if(Mess_Integral_Gier > 25000) Mess_Integral_Gier = 25000; // begrenzen |
+ if(Mess_Integral_Gier <-25000) Mess_Integral_Gier =-25000; |
+ |
+ ANALOG_ON; // ADC einschalten |
+ |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Kompass |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ if(KompassValue && (EE_Parameter.GlobalConfig & CFG_KOMPASS_AKTIV)) |
+ { |
+ int w,v; |
+ static int SignalSchlecht = 0; |
+ w = abs(IntegralNick /512); // mit zunehmender Neigung den Einfluss drosseln |
+ v = abs(IntegralRoll /512); |
+ if(v > w) w = v; // grösste Neigung ermitteln |
+ if(w < 25 && NeueKompassRichtungMerken && !SignalSchlecht) |
+ { |
+ KompassStartwert = KompassValue; |
+ NeueKompassRichtungMerken = 0; |
+ } |
+ w = (w * Parameter_KompassWirkung) / 64; // auf die Wirkung normieren |
+ w = Parameter_KompassWirkung - w; // Wirkung ggf drosseln |
+ if(w > 0) |
+ { |
+ ANALOG_OFF; // ADC ausschalten, damit die Werte sich nicht während der Berechnung ändern |
+ if(!SignalSchlecht) Mess_Integral_Gier += (KompassRichtung * w) / 32; // nach Kompass ausrichten |
+ ANALOG_ON; // ADC einschalten |
+ if(SignalSchlecht) SignalSchlecht--; |
+ } |
+ else SignalSchlecht = 500; // so lange das Signal taub stellen --> ca. 1 sek |
+ } |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Debugwerte zuordnen |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ if(!TimerWerteausgabe--) |
+ { |
+ TimerWerteausgabe = 49; |
+ DebugOut.Analog[0] = IntegralNick / EE_Parameter.GyroAccFaktor; |
+ DebugOut.Analog[1] = IntegralRoll / EE_Parameter.GyroAccFaktor; |
+ DebugOut.Analog[2] = Mittelwert_AccNick; |
+ DebugOut.Analog[3] = Mittelwert_AccRoll; |
+ DebugOut.Analog[4] = MesswertGier; |
+ DebugOut.Analog[5] = HoehenWert; |
+ DebugOut.Analog[6] = (Mess_Integral_Hoch / 512); |
+ DebugOut.Analog[8] = KompassValue; |
+ |
+/* DebugOut.Analog[16] = motor_rx[0]; |
+ DebugOut.Analog[17] = motor_rx[1]; |
+ DebugOut.Analog[18] = motor_rx[2]; |
+ DebugOut.Analog[19] = motor_rx[3]; |
+ DebugOut.Analog[20] = motor_rx[0] + motor_rx[1] + motor_rx[2] + motor_rx[3]; |
+ DebugOut.Analog[20] /= 14; |
+ DebugOut.Analog[21] = motor_rx[4]; |
+ DebugOut.Analog[22] = motor_rx[5]; |
+ DebugOut.Analog[23] = motor_rx[6]; |
+ DebugOut.Analog[24] = motor_rx[7]; |
+ DebugOut.Analog[25] = motor_rx[4] + motor_rx[5] + motor_rx[6] + motor_rx[7]; |
+*/ |
+// DebugOut.Analog[9] = MesswertNick; |
+// DebugOut.Analog[9] = SollHoehe; |
+// DebugOut.Analog[10] = Mess_Integral_Gier / 128; |
+// DebugOut.Analog[11] = KompassStartwert; |
+// DebugOut.Analog[10] = Parameter_Gyro_I; |
+// DebugOut.Analog[10] = EE_Parameter.Gyro_I; |
+// DebugOut.Analog[9] = KompassRichtung; |
+// DebugOut.Analog[10] = GasMischanteil; |
+// DebugOut.Analog[3] = HoeheD * 32; |
+// DebugOut.Analog[4] = hoehenregler; |
+ } |
+ |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Drehgeschwindigkeit und -winkel zu einem Istwert zusammenfassen |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ if(Looping_Nick) MesswertNick = MesswertNick * GyroFaktor; |
+ else MesswertNick = IntegralNick * IntegralFaktor + MesswertNick * GyroFaktor; |
+ if(Looping_Roll) MesswertRoll = MesswertRoll * GyroFaktor; |
+ else MesswertRoll = IntegralRoll * IntegralFaktor + MesswertRoll * GyroFaktor; |
+// MesswertGier = MesswertGier * (GyroFaktor/2) + Integral_Gier * IntegralFaktor; |
+ MesswertGier = MesswertGier * (GyroFaktor) + Integral_Gier * IntegralFaktor/2; |
+ |
+ // Maximalwerte abfangen |
+ #define MAX_SENSOR 2048 |
+ if(MesswertNick > MAX_SENSOR) MesswertNick = MAX_SENSOR; |
+ if(MesswertNick < -MAX_SENSOR) MesswertNick = -MAX_SENSOR; |
+ if(MesswertRoll > MAX_SENSOR) MesswertRoll = MAX_SENSOR; |
+ if(MesswertRoll < -MAX_SENSOR) MesswertRoll = -MAX_SENSOR; |
+ if(MesswertGier > MAX_SENSOR) MesswertGier = MAX_SENSOR; |
+ if(MesswertGier < -MAX_SENSOR) MesswertGier = -MAX_SENSOR; |
+ |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Höhenregelung |
+// Die Höhenregelung schwächt lediglich das Gas ab, erhöht es allerdings nicht |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+//OCR0B = 180 - (Poti1 + 120) / 4; |
+//DruckOffsetSetting = OCR0B; |
+ if((EE_Parameter.GlobalConfig & CFG_HOEHENREGELUNG)) // Höhenregelung |
+ { |
+ int tmp_int; |
+ if(EE_Parameter.GlobalConfig & CFG_HOEHEN_SCHALTER) // Regler wird über Schalter gesteuert |
+ { |
+ if(Parameter_MaxHoehe < 50) |
+ { |
+ SollHoehe = HoehenWert - 20; // Parameter_MaxHoehe ist der PPM-Wert des Schalters |
+ HoehenReglerAktiv = 0; |
+ } |
+ else |
+ HoehenReglerAktiv = 1; |
+ } |
+ else |
+ { |
+ SollHoehe = Parameter_MaxHoehe * EE_Parameter.Hoehe_Verstaerkung - 20; |
+ HoehenReglerAktiv = 1; |
+ } |
+ |
+ if(Notlandung) SollHoehe = 0; |
+ h = HoehenWert; |
+ if((h > SollHoehe) && HoehenReglerAktiv) // zu hoch --> drosseln |
+ { h = ((h - SollHoehe) * (int) Parameter_Hoehe_P) / 16; // Differenz bestimmen --> P-Anteil |
+ h = GasMischanteil - h; // vom Gas abziehen |
+ h -= (HoeheD * Parameter_Luftdruck_D)/8; // D-Anteil |
+ tmp_int = ((Mess_Integral_Hoch / 512) * (signed long) Parameter_Hoehe_ACC_Wirkung) / 32; |
+ if(tmp_int > 50) tmp_int = 50; |
+ else if(tmp_int < -50) tmp_int = -50; |
+ h -= tmp_int; |
+ hoehenregler = (hoehenregler*15 + h) / 16; |
+ if(hoehenregler < EE_Parameter.Hoehe_MinGas) // nicht unter MIN |
+ { |
+ if(GasMischanteil >= EE_Parameter.Hoehe_MinGas) hoehenregler = EE_Parameter.Hoehe_MinGas; |
+ if(GasMischanteil < EE_Parameter.Hoehe_MinGas) hoehenregler = GasMischanteil; |
+ } |
+ if(hoehenregler > GasMischanteil) hoehenregler = GasMischanteil; // nicht mehr als Gas |
+ GasMischanteil = hoehenregler; |
+ } |
+ } |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// + Mischer und PI-Regler |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ DebugOut.Analog[7] = GasMischanteil; |
+ |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Gier-Anteil |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+#define MUL_G 1.4 |
+ GierMischanteil = MesswertGier - sollGier; // Regler für Gier |
+//GierMischanteil = 0; |
+ if(GierMischanteil > (MUL_G * GasMischanteil)) GierMischanteil = MUL_G * GasMischanteil; |
+ if(GierMischanteil < -(MUL_G * GasMischanteil)) GierMischanteil = -(MUL_G * GasMischanteil); |
+ |
+ if(GasMischanteil < 10) GierMischanteil = 0; |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Nick-Achse |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ |
+ DiffNick = Kp * (MesswertNick - (StickNick - GPS_Nick)); // Differenz bestimmen |
+ SummeNick += DiffNick; // I-Anteil |
+ if(SummeNick > 0) SummeNick-= (abs(SummeNick)/256 + 1); else SummeNick += abs(SummeNick)/256 + 1; |
+ if(SummeNick > 16000) SummeNick = 16000; |
+ if(SummeNick < -16000) SummeNick = -16000; |
+ pd_ergebnis = DiffNick;// + Ki * SummeNick; // PI-Regler für Nick |
+ // Motor Vorn |
+#define MUL 2 |
+ if((pd_ergebnis > MUL * (GasMischanteil))) pd_ergebnis = MUL * (GasMischanteil); |
+ if((pd_ergebnis < -MUL * (GasMischanteil))) pd_ergebnis = -MUL * (GasMischanteil); |
+ |
+ motorwert = GasMischanteil + pd_ergebnis + GierMischanteil; // Mischer |
+ if ((motorwert < 0)) motorwert = 0; |
+ else if(motorwert > MAX_GAS) motorwert = MAX_GAS; |
+ if (motorwert < MIN_GAS) motorwert = MIN_GAS; |
+ Motor_Vorne = motorwert; |
+ // Motor Heck |
+ motorwert = GasMischanteil - pd_ergebnis + GierMischanteil; |
+ if ((motorwert < 0)) motorwert = 0; |
+ else if(motorwert > MAX_GAS) motorwert = MAX_GAS; |
+ if (motorwert < MIN_GAS) motorwert = MIN_GAS; |
+ Motor_Hinten = motorwert; |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+// Roll-Achse |
+// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
+ DiffRoll = Kp * (MesswertRoll - (StickRoll - GPS_Roll)); // Differenz bestimmen |
+ SummeRoll += DiffRoll; // I-Anteil |
+ if(SummeRoll > 0) SummeRoll-= (abs(SummeRoll)/256 + 1); else SummeRoll += abs(SummeRoll)/256 + 1; |
+ if(SummeRoll > 16000) SummeRoll = 16000; |
+ if(SummeRoll < -16000) SummeRoll = -16000; |
+ pd_ergebnis = DiffRoll;// + Ki * SummeRoll; // PI-Regler für Roll |
+ if((pd_ergebnis > MUL * (GasMischanteil))) pd_ergebnis = MUL * (GasMischanteil); |
+ if((pd_ergebnis < -MUL * (GasMischanteil))) pd_ergebnis = -MUL * (GasMischanteil); |
+ // Motor Links |
+ motorwert = GasMischanteil + pd_ergebnis - GierMischanteil; |
+ if ((motorwert < 0)) motorwert = 0; |
+ else if(motorwert > MAX_GAS) motorwert = MAX_GAS; |
+ if (motorwert < MIN_GAS) motorwert = MIN_GAS; |
+ Motor_Links = motorwert; |
+ // Motor Rechts |
+ motorwert = GasMischanteil - pd_ergebnis - GierMischanteil; |
+ if ((motorwert < 0)) motorwert = 0; |
+ else if(motorwert > MAX_GAS) motorwert = MAX_GAS; |
+ if (motorwert < MIN_GAS) motorwert = MIN_GAS; |
+ Motor_Rechts = motorwert; |
+ // +++++++++++++++++++++++++++++++++++++++++++++++ |
+} |
+ |
/branches/V0.63_LED1_LED2/fc.h |
---|
0,0 → 1,119 |
/*####################################################################################### |
Flight Control |
#######################################################################################*/ |
#ifndef _FC_H |
#define _FC_H |
extern volatile unsigned int I2CTimeout; |
extern unsigned char Sekunde,Minute; |
extern volatile long IntegralNick,IntegralNick2; |
extern volatile long IntegralRoll,IntegralRoll2; |
extern volatile long Mess_IntegralNick,Mess_IntegralNick2; |
extern volatile long Mess_IntegralRoll,Mess_IntegralRoll2; |
extern volatile long Mess_Integral_Hoch; |
extern volatile long Integral_Gier,Mess_Integral_Gier,Mess_Integral_Gier2; |
extern volatile int KompassValue; |
extern volatile int KompassStartwert; |
extern volatile int KompassRichtung; |
extern int HoehenWert; |
extern int SollHoehe; |
extern volatile int MesswertNick,MesswertRoll,MesswertGier; |
extern volatile int AdNeutralNick,AdNeutralRoll,AdNeutralGier, Mittelwert_AccNick, Mittelwert_AccRoll; |
extern volatile int NeutralAccX, NeutralAccY,Mittelwert_AccHoch; |
extern volatile float NeutralAccZ; |
void MotorRegler(void); |
void SendMotorData(void); |
void CalibrierMittelwert(void); |
void Mittelwert(void); |
void SetNeutral(void); |
unsigned char h,m,s; |
volatile unsigned char Timeout ; |
unsigned char CosinusNickWinkel, CosinusRollWinkel; |
volatile long IntegralNick,IntegralNick2; |
volatile long IntegralRoll,IntegralRoll2; |
volatile long Integral_Gier; |
volatile long Mess_IntegralNick,Mess_IntegralNick2; |
volatile long Mess_IntegralRoll,Mess_IntegralRoll2; |
volatile long Mess_Integral_Gier; |
volatile int DiffNick,DiffRoll; |
extern int Poti1, Poti2, Poti3, Poti4; |
volatile unsigned char Motor_Vorne,Motor_Hinten,Motor_Rechts,Motor_Links, Count; |
unsigned char MotorWert[5]; |
volatile unsigned char SenderOkay; |
int StickNick,StickRoll,StickGier; |
char MotorenEin; |
extern void DefaultKonstanten(void); |
#define STRUCT_PARAM_LAENGE 58 |
struct mk_param_struct |
{ |
unsigned char Kanalbelegung[8]; // GAS[0], GIER[1],NICK[2], ROLL[3], POTI1, POTI2, POTI3 |
unsigned char GlobalConfig; // 0x01=Höhenregler aktiv,0x02=Kompass aktiv, 0x04=GPS aktiv, 0x08=Heading Hold aktiv |
unsigned char Hoehe_MinGas; // Wert : 0-100 |
unsigned char Luftdruck_D; // Wert : 0-250 |
unsigned char MaxHoehe; // Wert : 0-32 |
unsigned char Hoehe_P; // Wert : 0-32 |
unsigned char Hoehe_Verstaerkung; // Wert : 0-50 |
unsigned char Hoehe_ACC_Wirkung; // Wert : 0-250 |
unsigned char Stick_P; // Wert : 1-6 |
unsigned char Stick_D; // Wert : 0-64 |
unsigned char Gier_P; // Wert : 1-20 |
unsigned char Gas_Min; // Wert : 0-32 |
unsigned char Gas_Max; // Wert : 33-250 |
unsigned char GyroAccFaktor; // Wert : 1-64 |
unsigned char KompassWirkung; // Wert : 0-32 |
unsigned char Gyro_P; // Wert : 10-250 |
unsigned char Gyro_I; // Wert : 0-250 |
unsigned char UnterspannungsWarnung; // Wert : 0-250 |
unsigned char NotGas; // Wert : 0-250 //Gaswert bei Empängsverlust |
unsigned char NotGasZeit; // Wert : 0-250 // Zeitbis auf NotGas geschaltet wird, wg. Rx-Problemen |
unsigned char UfoAusrichtung; // X oder + Formation |
unsigned char I_Faktor; // Wert : 0-250 |
unsigned char UserParam1; // Wert : 0-250 |
unsigned char UserParam2; // Wert : 0-250 |
unsigned char UserParam3; // Wert : 0-250 |
unsigned char UserParam4; // Wert : 0-250 |
unsigned char ServoNickControl; // Wert : 0-250 // Stellung des Servos |
unsigned char ServoNickComp; // Wert : 0-250 // Einfluss Gyro/Servo |
unsigned char ServoNickMin; // Wert : 0-250 // Anschlag |
unsigned char ServoNickMax; // Wert : 0-250 // Anschlag |
unsigned char ServoNickRefresh; // |
unsigned char LoopGasLimit; // Wert: 0-250 max. Gas während Looping |
unsigned char LoopThreshold; // Wert: 0-250 Schwelle für Stickausschlag |
//------------------------------------------------ |
unsigned char LoopConfig; // Bitcodiert: 0x01=oben, 0x02=unten, 0x04=links, 0x08=rechts / wird getrennt behandelt |
unsigned char ServoNickCompInvert; // Wert : 0-250 0 oder 1 // WICHTIG!!! am Ende lassen |
unsigned char Reserved[4]; |
char Name[12]; |
}; |
/* |
unsigned char ServoNickMax; // Wert : 0-250 |
unsigned char ServoNickRefresh; // |
unsigned char LoopGasLimit; // Wert: 0-250 max. Gas während Looping |
unsigned char LoopThreshold; // Wert: 0-250 Schwelle für Stickausschlag |
//------------------------------------------------ |
unsigned char LoopConfig; // Bitcodiert: 0x01=oben, 0x02=unten, 0x04=links, 0x08=rechts / wird getrennt behandelt |
unsigned char ServoNickCompInvert; // Wert : 0-250 0 oder 1 // WICHTIG!!! am Ende lassen |
unsigned char Reserved[4]; |
char Name[12]; |
*/ |
extern struct mk_param_struct EE_Parameter; |
extern unsigned char Parameter_Luftdruck_D; |
extern unsigned char Parameter_MaxHoehe; |
extern unsigned char Parameter_Hoehe_P; |
extern unsigned char Parameter_Hoehe_ACC_Wirkung; |
extern unsigned char Parameter_KompassWirkung; |
extern unsigned char Parameter_Gyro_P; |
extern unsigned char Parameter_Gyro_I; |
extern unsigned char Parameter_Gier_P; |
extern unsigned char Parameter_ServoNickControl; |
#endif //_FC_H |
/branches/V0.63_LED1_LED2/flight.pnproj |
---|
0,0 → 1,0 |
<Project name="Flight-Ctrl"><File path="uart.h"></File><File path="main.c"></File><File path="main.h"></File><File path="makefile"></File><File path="uart.c"></File><File path="printf_P.h"></File><File path="printf_P.c"></File><File path="timer0.c"></File><File path="timer0.h"></File><File path="old_macros.h"></File><File path="twimaster.c"></File><File path="version.txt"></File><File path="twimaster.h"></File><File path="rc.c"></File><File path="rc.h"></File><File path="fc.h"></File><File path="fc.c"></File><File path="menu.h"></File><File path="menu.c"></File><File path="_Settings.h"></File><File path="analog.c"></File><File path="analog.h"></File><File path="GPS.c"></File><File path="gps.h"></File><File path="License.txt"></File></Project> |
/branches/V0.63_LED1_LED2/flight.pnps |
---|
0,0 → 1,0 |
<pd><ViewState><e p="Flight-Ctrl" x="true"></e></ViewState></pd> |
/branches/V0.63_LED1_LED2/gps.h |
---|
0,0 → 1,4 |
extern signed int GPS_Nick; |
extern signed int GPS_Roll; |
extern void GPS_Neutral(void); |
extern void GPS_BerechneZielrichtung(void); |
/branches/V0.63_LED1_LED2/main.c |
---|
0,0 → 1,224 |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Copyright (c) 04.2007 Holger Buss |
// + Nur für den privaten Gebrauch |
// + www.MikroKopter.com |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Es gilt für das gesamte Projekt (Hardware, Software, Binärfiles, Sourcecode und Dokumentation), |
// + dass eine Nutzung (auch auszugsweise) nur für den privaten und nicht-kommerziellen Gebrauch zulässig ist. |
// + Sollten direkte oder indirekte kommerzielle Absichten verfolgt werden, ist mit uns (info@mikrokopter.de) Kontakt |
// + bzgl. der Nutzungsbedingungen aufzunehmen. |
// + Eine kommerzielle Nutzung ist z.B.Verkauf von MikroKoptern, Bestückung und Verkauf von Platinen oder Bausätzen, |
// + Verkauf von Luftbildaufnahmen, usw. |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Werden Teile des Quellcodes (mit oder ohne Modifikation) weiterverwendet oder veröffentlicht, |
// + unterliegen sie auch diesen Nutzungsbedingungen und diese Nutzungsbedingungen incl. Copyright müssen dann beiliegen |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Sollte die Software (auch auszugesweise) oder sonstige Informationen des MikroKopter-Projekts |
// + auf anderen Webseiten oder Medien veröffentlicht werden, muss unsere Webseite "http://www.mikrokopter.de" |
// + eindeutig als Ursprung verlinkt und genannt werden |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Keine Gewähr auf Fehlerfreiheit, Vollständigkeit oder Funktion |
// + Benutzung auf eigene Gefahr |
// + Wir übernehmen keinerlei Haftung für direkte oder indirekte Personen- oder Sachschäden |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Die Portierung der Software (oder Teile davon) auf andere Systeme (ausser der Hardware von www.mikrokopter.de) ist nur |
// + mit unserer Zustimmung zulässig |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Die Funktion printf_P() unterliegt ihrer eigenen Lizenz und ist hiervon nicht betroffen |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Redistributions of source code (with or without modifications) must retain the above copyright notice, |
// + this list of conditions and the following disclaimer. |
// + * Neither the name of the copyright holders nor the names of contributors may be used to endorse or promote products derived |
// + from this software without specific prior written permission. |
// + * The use of this project (hardware, software, binary files, sources and documentation) is only permittet |
// + for non-commercial use (directly or indirectly) |
// + Commercial use (for excample: selling of MikroKopters, selling of PCBs, assembly, ...) is only permitted |
// + with our written permission |
// + * If sources or documentations are redistributet on other webpages, out webpage (http://www.MikroKopter.de) must be |
// + clearly linked as origin |
// + * porting to systems other than hardware from www.mikrokopter.de is not allowed |
// + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" |
// + AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE |
// + IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE |
// + ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE |
// + LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR |
// + CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF |
// + SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS |
// + INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN |
// + CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) |
// + ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE |
// + POSSIBILITY OF SUCH DAMAGE. |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
#include "main.h" |
unsigned char EEPromArray[E2END+1] EEMEM; |
unsigned char PlatinenVersion = 10; |
// -- Parametersatz aus EEPROM lesen --- |
// number [0..5] |
void ReadParameterSet(unsigned char number, unsigned char *buffer, unsigned char length) |
{ |
if (number > 5) number = 5; |
eeprom_read_block(buffer, &EEPromArray[EEPROM_ADR_PARAM_BEGIN + length * number], length); |
} |
// -- Parametersatz ins EEPROM schreiben --- |
// number [0..5] |
void WriteParameterSet(unsigned char number, unsigned char *buffer, unsigned char length) |
{ |
if(number > 5) number = 5; |
eeprom_write_block(buffer, &EEPromArray[EEPROM_ADR_PARAM_BEGIN + length * number], length); |
eeprom_write_byte(&EEPromArray[EEPROM_ADR_ACTIVE_SET], number); // diesen Parametersatz als aktuell merken |
} |
unsigned char GetActiveParamSetNumber(void) |
{ |
unsigned char set; |
set = eeprom_read_byte(&EEPromArray[EEPROM_ADR_ACTIVE_SET]); |
if(set > 5) |
{ |
set = 2; |
eeprom_write_byte(&EEPromArray[EEPROM_ADR_ACTIVE_SET], set); // diesen Parametersatz als aktuell merken |
} |
return(set); |
} |
//############################################################################ |
//Hauptprogramm |
int main (void) |
//############################################################################ |
{ |
unsigned int timer; |
unsigned int timer2 = 0; |
if(PINB & 0x01) PlatinenVersion = 11; else PlatinenVersion = 10; |
DDRC = 0x81; // SCL |
PORTC = 0xff; // Pullup SDA |
DDRB = 0x1B; // LEDs und Druckoffset |
PORTB = 0x01; // LED_Rot |
DDRD = 0x3E; // Speaker & TXD & J3 J4 J5 |
DDRD |=0x80; // J7 |
PORTD = 0xF7; // LED |
MCUSR &=~(1<<WDRF); |
WDTCSR |= (1<<WDCE)|(1<<WDE); |
WDTCSR = 0; |
beeptime = 2000; |
StickGier = 0; PPM_in[K_GAS] = 0;StickRoll = 0; StickNick = 0; |
ROT_OFF; |
Timer_Init(); |
UART_Init(); |
rc_sum_init(); |
ADC_Init(); |
i2c_init(); |
sei(); |
VersionInfo.Hauptversion = VERSION_HAUPTVERSION; |
VersionInfo.Nebenversion = VERSION_NEBENVERSION; |
VersionInfo.PCKompatibel = VERSION_KOMPATIBEL; |
printf("\n\rFlightControl\n\rHardware:%d.%d\n\rSoftware:V%d.%d ",PlatinenVersion/10,PlatinenVersion%10, VERSION_HAUPTVERSION, VERSION_NEBENVERSION); |
printf("\n\r=============================="); |
GRN_ON; |
#define EE_DATENREVISION 62 // wird angepasst, wenn sich die EEPROM-Daten geändert haben |
if(eeprom_read_byte(&EEPromArray[EEPROM_ADR_VALID]) != EE_DATENREVISION) |
{ |
printf("\n\rInit. EEPROM: Generiere Default-Parameter..."); |
DefaultKonstanten1(); |
for (unsigned char i=0;i<6;i++) |
{ |
if(i==2) DefaultKonstanten2(); |
WriteParameterSet(i, (unsigned char *) &EE_Parameter.Kanalbelegung[0], STRUCT_PARAM_LAENGE); |
} |
eeprom_write_byte(&EEPromArray[EEPROM_ADR_ACTIVE_SET], 2); |
eeprom_write_byte(&EEPromArray[EEPROM_ADR_VALID], EE_DATENREVISION); |
} |
ReadParameterSet(GetActiveParamSetNumber(), (unsigned char *) &EE_Parameter.Kanalbelegung[0], STRUCT_PARAM_LAENGE); |
printf("\n\rBenutze Parametersatz %d", GetActiveParamSetNumber()); |
if(EE_Parameter.GlobalConfig & CFG_HOEHENREGELUNG) |
{ |
printf("\n\rAbgleich Luftdrucksensor.."); |
timer = SetDelay(1000); |
SucheLuftruckOffset(); |
while (!CheckDelay(timer)); |
printf("OK\n\r"); |
} |
SetNeutral(); |
ROT_OFF; |
beeptime = 2000; |
DebugIn.Analog[1] = 1000; |
DebugIn.Digital[0] = 0x55; |
printf("\n\rSteuerung: "); |
if (EE_Parameter.GlobalConfig & CFG_HEADING_HOLD) printf("HeadingHold"); |
else printf("Neutral"); |
printf("\n\n\r"); |
LcdClear(); |
I2CTimeout = 5000; |
while (1) |
{ |
if (UpdateMotor) // ReglerIntervall |
{ |
UpdateMotor=0; |
MotorRegler(); |
SendMotorData(); |
ROT_OFF; |
if(PcZugriff) PcZugriff--; |
if(SenderOkay) SenderOkay--; |
if(!I2CTimeout) |
{ |
I2CTimeout = 5; |
i2c_reset(); |
if((BeepMuster == 0xffff) && MotorenEin) |
{ |
beeptime = 10000; |
BeepMuster = 0x0080; |
} |
} |
else |
{ |
I2CTimeout--; |
ROT_OFF; |
} |
} |
if(SIO_DEBUG) |
{ |
DatenUebertragung(); |
BearbeiteRxDaten(); |
} |
else BearbeiteRxDaten(); |
if(CheckDelay(timer)) |
{ |
if(UBat < EE_Parameter.UnterspannungsWarnung) |
{ |
if(BeepMuster == 0xffff) |
{ |
beeptime = 6000; |
BeepMuster = 0x0300; |
} |
} |
timer = SetDelay(100); |
} |
} |
return (1); |
} |
/branches/V0.63_LED1_LED2/main.h |
---|
0,0 → 1,97 |
#ifndef _MAIN_H |
#define _MAIN_H |
//Hier die Quarz Frequenz einstellen |
#if defined (__AVR_ATmega32__) |
#define SYSCLK 20000000L //Quarz Frequenz in Hz |
#endif |
#if defined (__AVR_ATmega644__) |
#define SYSCLK 20000000L //Quarz Frequenz in Hz |
//#define SYSCLK 16000000L //Quarz Frequenz in Hz |
#endif |
// neue Hardware |
#define ROT_OFF {if(PlatinenVersion == 10) PORTB &=~0x01; else PORTB |= 0x01;} |
#define ROT_ON {if(PlatinenVersion == 10) PORTB |= 0x01; else PORTB &=~0x01;} |
#define ROT_FLASH PORTB ^= 0x01 |
#define GRN_OFF PORTB &=~0x02 |
#define GRN_ON PORTB |= 0x02 |
#define GRN_FLASH PORTB ^= 0x02 |
//#ifndef F_CPU |
//#error ################## F_CPU nicht definiert oder ungültig ############# |
//#endif |
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
//#define ANZ_MITTELWERT 4 |
#define EEPROM_ADR_VALID 1 |
#define EEPROM_ADR_ACTIVE_SET 2 |
#define EEPROM_ADR_LAST_OFFSET 3 |
#define EEPROM_ADR_PARAM_BEGIN 100 |
#define CFG_HOEHENREGELUNG 0x01 |
#define CFG_HOEHEN_SCHALTER 0x02 |
#define CFG_HEADING_HOLD 0x04 |
#define CFG_KOMPASS_AKTIV 0x08 |
#define CFG_KOMPASS_FIX 0x10 |
#define CFG_GPS_AKTIV 0x20 |
#define CFG_LOOP_OBEN 0x01 |
#define CFG_LOOP_UNTEN 0x02 |
#define CFG_LOOP_LINKS 0x04 |
#define CFG_LOOP_RECHTS 0x08 |
//#define SYSCLK |
//extern unsigned long SYSCLK; |
extern volatile int i_Nick[20],i_Roll[20],DiffNick,DiffRoll; |
extern volatile unsigned char SenderOkay; |
extern unsigned char CosinusNickWinkel, CosinusRollWinkel; |
extern unsigned char PlatinenVersion; |
extern void ReadParameterSet (unsigned char number, unsigned char *buffer, unsigned char length); |
extern void WriteParameterSet(unsigned char number, unsigned char *buffer, unsigned char length); |
extern unsigned char GetActiveParamSetNumber(void); |
extern unsigned char EEPromArray[]; |
#include <stdlib.h> |
#include <string.h> |
#include <avr/io.h> |
#include <avr/pgmspace.h> |
#include <avr/interrupt.h> |
#include <avr/eeprom.h> |
#include <avr/boot.h> |
#include <avr/wdt.h> |
#include "old_macros.h" |
#include "_settings.h" |
#include "printf_P.h" |
#include "timer0.h" |
#include "uart.h" |
#include "analog.h" |
#include "twimaster.h" |
#include "menu.h" |
#include "rc.h" |
#include "fc.h" |
#include "gps.h" |
#ifndef EEMEM |
#define EEMEM __attribute__ ((section (".eeprom"))) |
#endif |
#define DEBUG_DISPLAY_INTERVALL 123 // in ms |
#define DELAY_US(x) ((unsigned int)( (x) * 1e-6 * F_CPU )) |
#endif //_MAIN_H |
/branches/V0.63_LED1_LED2/makefile |
---|
0,0 → 1,391 |
#-------------------------------------------------------------------- |
# MCU name |
MCU = atmega644 |
F_CPU = 20000000 |
#------------------------------------------------------------------- |
HAUPT_VERSION = 0 |
NEBEN_VERSION = 63 |
VERSION_KOMPATIBEL = 5 # PC-Kompatibilität |
#------------------------------------------------------------------- |
ifeq ($(MCU), atmega32) |
# FUSE_SETTINGS= -u -U lfuse:w:0xff:m -U hfuse:w:0xcf:m |
HEX_NAME = MEGA32 |
endif |
ifeq ($(MCU), atmega644) |
FUSE_SETTINGS = -u -U lfuse:w:0xff:m -U hfuse:w:0xdf:m |
#FUSE_SETTINGS = -U lfuse:w:0xff:m -U hfuse:w:0xdf:m |
# -u bei neuen Controllern wieder einspielen |
HEX_NAME = MEGA644 |
endif |
ifeq ($(F_CPU), 16000000) |
QUARZ = 16MHZ |
endif |
ifeq ($(F_CPU), 20000000) |
QUARZ = 20MHZ |
endif |
# Output format. (can be srec, ihex, binary) |
FORMAT = ihex |
# Target file name (without extension). |
TARGET = Flight-Ctrl_$(HEX_NAME)_V$(HAUPT_VERSION)_$(NEBEN_VERSION) |
# Optimization level, can be [0, 1, 2, 3, s]. 0 turns off optimization. |
# (Note: 3 is not always the best optimization level. See avr-libc FAQ.) |
OPT = s |
########################################################################################################## |
# List C source files here. (C dependencies are automatically generated.) |
SRC = main.c uart.c printf_P.c timer0.c analog.c menu.c |
SRC += twimaster.c rc.c fc.c GPS.c |
########################################################################################################## |
# List Assembler source files here. |
# Make them always end in a capital .S. Files ending in a lowercase .s |
# will not be considered source files but generated files (assembler |
# output from the compiler), and will be deleted upon "make clean"! |
# Even though the DOS/Win* filesystem matches both .s and .S the same, |
# it will preserve the spelling of the filenames, and gcc itself does |
# care about how the name is spelled on its command-line. |
ASRC = |
# List any extra directories to look for include files here. |
# Each directory must be seperated by a space. |
EXTRAINCDIRS = |
# Optional compiler flags. |
# -g: generate debugging information (for GDB, or for COFF conversion) |
# -O*: optimization level |
# -f...: tuning, see gcc manual and avr-libc documentation |
# -Wall...: warning level |
# -Wa,...: tell GCC to pass this to the assembler. |
# -ahlms: create assembler listing |
CFLAGS = -O$(OPT) \ |
-funsigned-char -funsigned-bitfields -fpack-struct -fshort-enums \ |
-Wall -Wstrict-prototypes \ |
-Wa,-adhlns=$(<:.c=.lst) \ |
$(patsubst %,-I%,$(EXTRAINCDIRS)) |
# Set a "language standard" compiler flag. |
# Unremark just one line below to set the language standard to use. |
# gnu99 = C99 + GNU extensions. See GCC manual for more information. |
#CFLAGS += -std=c89 |
#CFLAGS += -std=gnu89 |
#CFLAGS += -std=c99 |
CFLAGS += -std=gnu99 |
CFLAGS += -DVERSION_HAUPTVERSION=$(HAUPT_VERSION) -DVERSION_NEBENVERSION=$(NEBEN_VERSION) -DVERSION_KOMPATIBEL=$(VERSION_KOMPATIBEL) |
# Optional assembler flags. |
# -Wa,...: tell GCC to pass this to the assembler. |
# -ahlms: create listing |
# -gstabs: have the assembler create line number information; note that |
# for use in COFF files, additional information about filenames |
# and function names needs to be present in the assembler source |
# files -- see avr-libc docs [FIXME: not yet described there] |
ASFLAGS = -Wa,-adhlns=$(<:.S=.lst),-gstabs |
# Optional linker flags. |
# -Wl,...: tell GCC to pass this to linker. |
# -Map: create map file |
# --cref: add cross reference to map file |
LDFLAGS = -Wl,-Map=$(TARGET).map,--cref |
# Additional libraries |
# Minimalistic printf version |
#LDFLAGS += -Wl,-u,vfprintf -lprintf_min |
# Floating point printf version (requires -lm below) |
#LDFLAGS += -Wl,-u,vfprintf -lprintf_flt |
# -lm = math library |
LDFLAGS += -lm |
##LDFLAGS += -T./linkerfile/avr5.x |
# Programming support using avrdude. Settings and variables. |
# Programming hardware: alf avr910 avrisp bascom bsd |
# dt006 pavr picoweb pony-stk200 sp12 stk200 stk500 |
# |
# Type: avrdude -c ? |
# to get a full listing. |
# |
#AVRDUDE_PROGRAMMER = stk200 |
AVRDUDE_PROGRAMMER = dt006 |
#AVRDUDE_PROGRAMMER = ponyser |
#falls Ponyser ausgewählt wird, muss sich unsere avrdude-Configdatei im Bin-Verzeichnis des Compilers befinden |
#AVRDUDE_PORT = com1 # programmer connected to serial device |
AVRDUDE_PORT = lpt1 # programmer connected to parallel port |
#AVRDUDE_WRITE_FLASH = -U flash:w:$(TARGET).hex |
AVRDUDE_WRITE_FLASH = -U flash:w:$(TARGET).hex $(FUSE_SETTINGS) |
#AVRDUDE_WRITE_EEPROM = -U eeprom:w:$(TARGET).eep |
AVRDUDE_FLAGS = -p $(MCU) -P $(AVRDUDE_PORT) -c $(AVRDUDE_PROGRAMMER) |
# Uncomment the following if you want avrdude's erase cycle counter. |
# Note that this counter needs to be initialized first using -Yn, |
# see avrdude manual. |
#AVRDUDE_ERASE += -y |
# Uncomment the following if you do /not/ wish a verification to be |
# performed after programming the device. |
AVRDUDE_FLAGS += -V |
# Increase verbosity level. Please use this when submitting bug |
# reports about avrdude. See <http://savannah.nongnu.org/projects/avrdude> |
# to submit bug reports. |
#AVRDUDE_FLAGS += -v -v |
# --------------------------------------------------------------------------- |
# Define directories, if needed. |
DIRAVR = c:/winavr |
DIRAVRBIN = $(DIRAVR)/bin |
DIRAVRUTILS = $(DIRAVR)/utils/bin |
DIRINC = . |
DIRLIB = $(DIRAVR)/avr/lib |
# Define programs and commands. |
SHELL = sh |
CC = avr-gcc |
OBJCOPY = avr-objcopy |
OBJDUMP = avr-objdump |
SIZE = avr-size |
# Programming support using avrdude. |
AVRDUDE = avrdude |
REMOVE = rm -f |
COPY = cp |
HEXSIZE = $(SIZE) --target=$(FORMAT) $(TARGET).hex |
ELFSIZE = $(SIZE) -A $(TARGET).elf |
# Define Messages |
# English |
MSG_ERRORS_NONE = Errors: none |
MSG_BEGIN = -------- begin -------- |
MSG_END = -------- end -------- |
MSG_SIZE_BEFORE = Size before: |
MSG_SIZE_AFTER = Size after: |
MSG_COFF = Converting to AVR COFF: |
MSG_EXTENDED_COFF = Converting to AVR Extended COFF: |
MSG_FLASH = Creating load file for Flash: |
MSG_EEPROM = Creating load file for EEPROM: |
MSG_EXTENDED_LISTING = Creating Extended Listing: |
MSG_SYMBOL_TABLE = Creating Symbol Table: |
MSG_LINKING = Linking: |
MSG_COMPILING = Compiling: |
MSG_ASSEMBLING = Assembling: |
MSG_CLEANING = Cleaning project: |
# Define all object files. |
OBJ = $(SRC:.c=.o) $(ASRC:.S=.o) |
# Define all listing files. |
LST = $(ASRC:.S=.lst) $(SRC:.c=.lst) |
# Combine all necessary flags and optional flags. |
# Add target processor to flags. |
#ALL_CFLAGS = -mmcu=$(MCU) -DF_CPU=$(F_CPU) -I. $(CFLAGS) |
ALL_CFLAGS = -mmcu=$(MCU) -I. $(CFLAGS) |
ALL_ASFLAGS = -mmcu=$(MCU) -I. -x assembler-with-cpp $(ASFLAGS) |
# Default target. |
all: begin gccversion sizebefore $(TARGET).elf $(TARGET).hex $(TARGET).eep \ |
$(TARGET).lss $(TARGET).sym sizeafter finished end |
# Eye candy. |
# AVR Studio 3.x does not check make's exit code but relies on |
# the following magic strings to be generated by the compile job. |
begin: |
@echo |
@echo $(MSG_BEGIN) |
finished: |
@echo $(MSG_ERRORS_NONE) |
end: |
@echo $(MSG_END) |
@echo |
# Display size of file. |
sizebefore: |
@if [ -f $(TARGET).elf ]; then echo; echo $(MSG_SIZE_BEFORE); $(ELFSIZE); echo; fi |
sizeafter: |
@if [ -f $(TARGET).elf ]; then echo; echo $(MSG_SIZE_AFTER); $(ELFSIZE); echo; fi |
# Display compiler version information. |
gccversion : |
@$(CC) --version |
# Convert ELF to COFF for use in debugging / simulating in |
# AVR Studio or VMLAB. |
COFFCONVERT=$(OBJCOPY) --debugging \ |
--change-section-address .data-0x800000 \ |
--change-section-address .bss-0x800000 \ |
--change-section-address .noinit-0x800000 \ |
--change-section-address .eeprom-0x810000 |
coff: $(TARGET).elf |
@echo |
@echo $(MSG_COFF) $(TARGET).cof |
$(COFFCONVERT) -O coff-avr $< $(TARGET).cof |
extcoff: $(TARGET).elf |
@echo |
@echo $(MSG_EXTENDED_COFF) $(TARGET).cof |
$(COFFCONVERT) -O coff-ext-avr $< $(TARGET).cof |
# Program the device. |
program: $(TARGET).hex $(TARGET).eep |
$(AVRDUDE) $(AVRDUDE_FLAGS) $(AVRDUDE_WRITE_FLASH) $(AVRDUDE_WRITE_EEPROM) |
# Create final output files (.hex, .eep) from ELF output file. |
%.hex: %.elf |
@echo |
@echo $(MSG_FLASH) $@ |
$(OBJCOPY) -O $(FORMAT) -R .eeprom $< $@ |
%.eep: %.elf |
@echo |
@echo $(MSG_EEPROM) $@ |
-$(OBJCOPY) -j .eeprom --set-section-flags=.eeprom="alloc,load" \ |
--change-section-lma .eeprom=0 -O $(FORMAT) $< $@ |
# Create extended listing file from ELF output file. |
%.lss: %.elf |
@echo |
@echo $(MSG_EXTENDED_LISTING) $@ |
$(OBJDUMP) -h -S $< > $@ |
# Create a symbol table from ELF output file. |
%.sym: %.elf |
@echo |
@echo $(MSG_SYMBOL_TABLE) $@ |
avr-nm -n $< > $@ |
# Link: create ELF output file from object files. |
.SECONDARY : $(TARGET).elf |
.PRECIOUS : $(OBJ) |
%.elf: $(OBJ) |
@echo |
@echo $(MSG_LINKING) $@ |
$(CC) $(ALL_CFLAGS) $(OBJ) --output $@ $(LDFLAGS) |
# Compile: create object files from C source files. |
%.o : %.c |
@echo |
@echo $(MSG_COMPILING) $< |
$(CC) -c $(ALL_CFLAGS) $< -o $@ |
# Compile: create assembler files from C source files. |
%.s : %.c |
$(CC) -S $(ALL_CFLAGS) $< -o $@ |
# Assemble: create object files from assembler source files. |
%.o : %.S |
@echo |
@echo $(MSG_ASSEMBLING) $< |
$(CC) -c $(ALL_ASFLAGS) $< -o $@ |
# Target: clean project. |
clean: begin clean_list finished end |
clean_list : |
@echo |
@echo $(MSG_CLEANING) |
# $(REMOVE) $(TARGET).hex |
$(REMOVE) $(TARGET).eep |
$(REMOVE) $(TARGET).obj |
$(REMOVE) $(TARGET).cof |
$(REMOVE) $(TARGET).elf |
$(REMOVE) $(TARGET).map |
$(REMOVE) $(TARGET).obj |
$(REMOVE) $(TARGET).a90 |
$(REMOVE) $(TARGET).sym |
$(REMOVE) $(TARGET).lnk |
$(REMOVE) $(TARGET).lss |
$(REMOVE) $(OBJ) |
$(REMOVE) $(LST) |
$(REMOVE) $(SRC:.c=.s) |
$(REMOVE) $(SRC:.c=.d) |
# Automatically generate C source code dependencies. |
# (Code originally taken from the GNU make user manual and modified |
# (See README.txt Credits).) |
# |
# Note that this will work with sh (bash) and sed that is shipped with WinAVR |
# (see the SHELL variable defined above). |
# This may not work with other shells or other seds. |
# |
%.d: %.c |
set -e; $(CC) -MM $(ALL_CFLAGS) $< \ |
| sed 's,\(.*\)\.o[ :]*,\1.o \1.d : ,g' > $@; \ |
[ -s $@ ] || rm -f $@ |
# Remove the '-' if you want to see the dependency files generated. |
-include $(SRC:.c=.d) |
# Listing of phony targets. |
.PHONY : all begin finish end sizebefore sizeafter gccversion coff extcoff \ |
clean clean_list program |
/branches/V0.63_LED1_LED2/menu.c |
---|
0,0 → 1,118 |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Copyright (c) 04.2007 Holger Buss |
// + only for non-profit use |
// + www.MikroKopter.com |
// + see the File "License.txt" for further Informations |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
#include "main.h" |
unsigned int TestInt = 0; |
#define ARRAYGROESSE 10 |
unsigned char Array[ARRAYGROESSE] = {1,2,3,4,5,6,7,8,9,10}; |
char DisplayBuff[80] = "Hallo Welt"; |
unsigned char DispPtr = 0; |
unsigned char RemoteTasten = 0; |
#define KEY1 0x01 |
#define KEY2 0x02 |
#define KEY3 0x04 |
#define KEY4 0x08 |
#define KEY5 0x10 |
void LcdClear(void) |
{ |
unsigned char i; |
for(i=0;i<80;i++) DisplayBuff[i] = ' '; |
} |
void Menu(void) |
{ |
static unsigned char MaxMenue = 10,MenuePunkt=0; |
if(RemoteTasten & KEY1) { if(MenuePunkt) MenuePunkt--; else MenuePunkt = MaxMenue; LcdClear(); } |
if(RemoteTasten & KEY2) { MenuePunkt++; LcdClear(); } |
if((RemoteTasten & KEY1) && (RemoteTasten & KEY2)) MenuePunkt = 0; |
LCD_printfxy(17,0,"[%i]",MenuePunkt); |
switch(MenuePunkt) |
{ |
case 0: |
LCD_printfxy(0,0,"++ MikroKopter ++"); |
LCD_printfxy(0,1,"HW:V%d.%d SW:%d.%d",PlatinenVersion/10,PlatinenVersion%10,VERSION_HAUPTVERSION, VERSION_NEBENVERSION); |
LCD_printfxy(0,2,"Setting: %d ",GetActiveParamSetNumber()); |
LCD_printfxy(0,3,"(c) Holger Buss"); |
// if(RemoteTasten & KEY3) TestInt--; |
// if(RemoteTasten & KEY4) TestInt++; |
break; |
case 1: |
if(EE_Parameter.GlobalConfig & CFG_HOEHENREGELUNG) |
{ |
LCD_printfxy(0,0,"Hoehe: %5i",HoehenWert); |
LCD_printfxy(0,1,"SollHoehe: %5i",SollHoehe); |
LCD_printfxy(0,2,"Luftdruck: %5i",MessLuftdruck); |
LCD_printfxy(0,3,"Off : %5i",DruckOffsetSetting); |
} |
else |
{ |
LCD_printfxy(0,1,"Keine "); |
LCD_printfxy(0,2,"Höhenregelung"); |
} |
break; |
case 2: |
LCD_printfxy(0,0,"akt. Lage"); |
LCD_printfxy(0,1,"Nick: %5i",IntegralNick/1024); |
LCD_printfxy(0,2,"Roll: %5i",IntegralRoll/1024); |
LCD_printfxy(0,3,"Kompass: %5i",KompassValue); |
break; |
case 3: |
LCD_printfxy(0,0,"K1:%4i K2:%4i ",PPM_in[1],PPM_in[2]); |
LCD_printfxy(0,1,"K3:%4i K4:%4i ",PPM_in[3],PPM_in[4]); |
LCD_printfxy(0,2,"K5:%4i K6:%4i ",PPM_in[5],PPM_in[6]); |
LCD_printfxy(0,3,"K7:%4i K8:%4i ",PPM_in[7],PPM_in[8]); |
break; |
case 4: |
LCD_printfxy(0,0,"Ni:%4i Ro:%4i ",PPM_in[EE_Parameter.Kanalbelegung[K_NICK]],PPM_in[EE_Parameter.Kanalbelegung[K_ROLL]]); |
LCD_printfxy(0,1,"Gs:%4i Gi:%4i ",PPM_in[EE_Parameter.Kanalbelegung[K_GAS]],PPM_in[EE_Parameter.Kanalbelegung[K_GIER]]); |
LCD_printfxy(0,2,"P1:%4i P2:%4i ",PPM_in[EE_Parameter.Kanalbelegung[K_POTI1]],PPM_in[EE_Parameter.Kanalbelegung[K_POTI2]]); |
LCD_printfxy(0,3,"P3:%4i P4:%4i ",PPM_in[EE_Parameter.Kanalbelegung[K_POTI3]],PPM_in[EE_Parameter.Kanalbelegung[K_POTI4]]); |
break; |
case 5: |
LCD_printfxy(0,0,"Gyro - Sensor"); |
LCD_printfxy(0,1,"Nick %4i (%3i)",AccumulateNick / MessanzahlNick, AdNeutralNick); |
LCD_printfxy(0,2,"Roll %4i (%3i)",AccumulateRoll / MessanzahlRoll, AdNeutralRoll); |
LCD_printfxy(0,3,"Gier %4i (%3i)",AccumulateGier / MessanzahlGier, AdNeutralGier); |
break; |
case 6: |
LCD_printfxy(0,0,"ACC - Sensor"); |
LCD_printfxy(0,1,"Nick %4i (%3i)",accumulate_AccNick / messanzahl_AccNick,NeutralAccX); |
LCD_printfxy(0,2,"Roll %4i (%3i)",accumulate_AccRoll / messanzahl_AccRoll,NeutralAccY); |
LCD_printfxy(0,3,"Hoch %4i (%3i)",Aktuell_az/*accumulate_AccHoch / messanzahl_AccHoch*/,(int)NeutralAccZ); |
break; |
case 7: |
LCD_printfxy(0,1,"Spannung: %5i",UBat); |
LCD_printfxy(0,2,"Empf.Pegel:%5i",SenderOkay); |
break; |
case 8: |
LCD_printfxy(0,0,"Kompass "); |
LCD_printfxy(0,1,"Richtung: %5i",KompassRichtung); |
LCD_printfxy(0,2,"Messwert: %5i",KompassValue); |
LCD_printfxy(0,3,"Start: %5i",KompassStartwert); |
break; |
case 9: |
LCD_printfxy(0,0,"Poti1: %3i",Poti1); |
LCD_printfxy(0,1,"Poti2: %3i",Poti2); |
LCD_printfxy(0,2,"Poti3: %3i",Poti3); |
LCD_printfxy(0,3,"Poti4: %3i",Poti4); |
break; |
case 10: |
LCD_printfxy(0,0,"Servo " ); |
LCD_printfxy(0,1,"Setpoint %3i",Parameter_ServoNickControl); |
LCD_printfxy(0,2,"Stellung: %3i",ServoValue); |
LCD_printfxy(0,3,"Range:%3i-%3i",EE_Parameter.ServoNickMin,EE_Parameter.ServoNickMax); |
break; |
default: MaxMenue = MenuePunkt - 1; |
MenuePunkt = 0; |
break; |
} |
RemoteTasten = 0; |
} |
/branches/V0.63_LED1_LED2/menu.h |
---|
0,0 → 1,5 |
extern void Menu(void); |
extern char DisplayBuff[80]; |
extern unsigned char DispPtr; |
unsigned char RemoteTasten; |
/branches/V0.63_LED1_LED2/old_macros.h |
---|
0,0 → 1,47 |
/* |
For backwards compatibility only. |
Ingo Busker ingo@mikrocontroller.com |
*/ |
#ifndef cbi |
#define cbi(sfr, bit) (_SFR_BYTE(sfr) &= ~_BV(bit)) |
#endif |
#ifndef sbi |
#define sbi(sfr, bit) (_SFR_BYTE(sfr) |= _BV(bit)) |
#endif |
#ifndef inb |
#define inb(sfr) _SFR_BYTE(sfr) |
#endif |
#ifndef outb |
#define outb(sfr, val) (_SFR_BYTE(sfr) = (val)) |
#endif |
#ifndef inw |
#define inw(sfr) _SFR_WORD(sfr) |
#endif |
#ifndef outw |
#define outw(sfr, val) (_SFR_WORD(sfr) = (val)) |
#endif |
#ifndef outp |
#define outp(val, sfr) outb(sfr, val) |
#endif |
#ifndef inp |
#define inp(sfr) inb(sfr) |
#endif |
#ifndef BV |
#define BV(bit) _BV(bit) |
#endif |
#ifndef PRG_RDB |
#define PRG_RDB pgm_read_byte |
#endif |
/branches/V0.63_LED1_LED2/printf_P.c |
---|
0,0 → 1,480 |
// Die Funktion printf_P() unterliegt ihrer eigenen Lizenz und ist nicht von der Lizenz für den MikroKopter-Teil unterstellt |
/* |
Copyright (C) 1993 Free Software Foundation |
This file is part of the GNU IO Library. This library is free |
software; you can redistribute it and/or modify it under the |
terms of the GNU General Public License as published by the |
Free Software Foundation; either version 2, or (at your option) |
any later version. |
This library is distributed in the hope that it will be useful, |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
GNU General Public License for more details. |
You should have received a copy of the GNU General Public License |
along with this library; see the file COPYING. If not, write to the Free |
Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
As a special exception, if you link this library with files |
compiled with a GNU compiler to produce an executable, this does not cause |
the resulting executable to be covered by the GNU General Public License. |
This exception does not however invalidate any other reasons why |
the executable file might be covered by the GNU General Public License. */ |
/* |
* Copyright (c) 1990 Regents of the University of California. |
* All rights reserved. |
* |
* Redistribution and use in source and binary forms, with or without |
* modification, are permitted provided that the following conditions |
* are met: |
* 1. Redistributions of source code must retain the above copyright |
* notice, this list of conditions and the following disclaimer. |
* 2. Redistributions in binary form must reproduce the above copyright |
* notice, this list of conditions and the following disclaimer in the |
* documentation and/or other materials provided with the distribution. |
* 3. [rescinded 22 July 1999] |
* 4. Neither the name of the University nor the names of its contributors |
* may be used to endorse or promote products derived from this software |
* without specific prior written permission. |
* |
* THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND |
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE |
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE |
* ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE |
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL |
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS |
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) |
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT |
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY |
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF |
* SUCH DAMAGE. |
*/ |
/****************************************************************************** |
This file is a patched version of printf called _printf_P |
It is made to work with avr-gcc for Atmel AVR MCUs. |
There are some differences from standard printf: |
1. There is no floating point support (with fp the code is about 8K!) |
2. Return type is void |
3. Format string must be in program memory (by using macro printf this is |
done automaticaly) |
4. %n is not implemented (just remove the comment around it if you need it) |
5. If LIGHTPRINTF is defined, the code is about 550 bytes smaller and the |
folowing specifiers are disabled : |
space # * . - + p s o O |
6. A function void uart_sendchar(char c) is used for output. The UART must |
be initialized before using printf. |
Alexander Popov |
sasho@vip.orbitel.bg |
******************************************************************************/ |
/* |
* Actual printf innards. |
* |
* This code is large and complicated... |
*/ |
#include <string.h> |
#ifdef __STDC__ |
#include <stdarg.h> |
#else |
#include <varargs.h> |
#endif |
#include "main.h" |
//#define LIGHTPRINTF |
char PrintZiel; |
char Putchar(char zeichen) |
{ |
if(PrintZiel == OUT_LCD) { DisplayBuff[DispPtr++] = zeichen; return(1);} |
else return(uart_putchar(zeichen)); |
} |
void PRINT(const char * ptr, unsigned int len) |
{ |
for(;len;len--) Putchar(*ptr++); |
} |
void PRINTP(const char * ptr, unsigned int len) |
{ |
for(;len;len--) Putchar(pgm_read_byte(ptr++)); |
} |
void PAD_SP(signed char howmany) |
{ |
for(;howmany>0;howmany--) Putchar(' '); |
} |
void PAD_0(signed char howmany) |
{ |
for(;howmany>0;howmany--) Putchar('0'); |
} |
#define BUF 40 |
/* |
* Macros for converting digits to letters and vice versa |
*/ |
#define to_digit(c) ((c) - '0') |
#define is_digit(c) ((c)<='9' && (c)>='0') |
#define to_char(n) ((n) + '0') |
/* |
* Flags used during conversion. |
*/ |
#define LONGINT 0x01 /* long integer */ |
#define LONGDBL 0x02 /* long double; unimplemented */ |
#define SHORTINT 0x04 /* short integer */ |
#define ALT 0x08 /* alternate form */ |
#define LADJUST 0x10 /* left adjustment */ |
#define ZEROPAD 0x20 /* zero (as opposed to blank) pad */ |
#define HEXPREFIX 0x40 /* add 0x or 0X prefix */ |
void _printf_P (char ziel,char const *fmt0, ...) /* Works with string from FLASH */ |
{ |
va_list ap; |
register const char *fmt; /* format string */ |
register char ch; /* character from fmt */ |
register int n; /* handy integer (short term usage) */ |
register char *cp; /* handy char pointer (short term usage) */ |
const char *fmark; /* for remembering a place in fmt */ |
register unsigned char flags; /* flags as above */ |
signed char width; /* width from format (%8d), or 0 */ |
signed char prec; /* precision from format (%.3d), or -1 */ |
char sign; /* sign prefix (' ', '+', '-', or \0) */ |
unsigned long _ulong=0; /* integer arguments %[diouxX] */ |
#define OCT 8 |
#define DEC 10 |
#define HEX 16 |
unsigned char base; /* base for [diouxX] conversion */ |
signed char dprec; /* a copy of prec if [diouxX], 0 otherwise */ |
signed char dpad; /* extra 0 padding needed for integers */ |
signed char fieldsz; /* field size expanded by sign, dpad etc */ |
/* The initialization of 'size' is to suppress a warning that |
'size' might be used unitialized. It seems gcc can't |
quite grok this spaghetti code ... */ |
signed char size = 0; /* size of converted field or string */ |
char buf[BUF]; /* space for %c, %[diouxX], %[eEfgG] */ |
char ox[2]; /* space for 0x hex-prefix */ |
PrintZiel = ziel; // bestimmt, LCD oder UART |
va_start(ap, fmt0); |
fmt = fmt0; |
/* |
* Scan the format for conversions (`%' character). |
*/ |
for (;;) { |
for (fmark = fmt; (ch = pgm_read_byte(fmt)) != '\0' && ch != '%'; fmt++) |
/* void */; |
if ((n = fmt - fmark) != 0) { |
PRINTP(fmark, n); |
} |
if (ch == '\0') |
goto done; |
fmt++; /* skip over '%' */ |
flags = 0; |
dprec = 0; |
width = 0; |
prec = -1; |
sign = '\0'; |
rflag: ch = PRG_RDB(fmt++); |
reswitch: |
#ifdef LIGHTPRINTF |
if (ch=='o' || ch=='u' || (ch|0x20)=='x') { |
#else |
if (ch=='u' || (ch|0x20)=='x') { |
#endif |
if (flags&LONGINT) { |
_ulong=va_arg(ap, unsigned long); |
} else { |
register unsigned int _d; |
_d=va_arg(ap, unsigned int); |
_ulong = flags&SHORTINT ? (unsigned long)(unsigned short)_d : (unsigned long)_d; |
} |
} |
#ifndef LIGHTPRINTF |
if(ch==' ') { |
/* |
* ``If the space and + flags both appear, the space |
* flag will be ignored.'' |
* -- ANSI X3J11 |
*/ |
if (!sign) |
sign = ' '; |
goto rflag; |
} else if (ch=='#') { |
flags |= ALT; |
goto rflag; |
} else if (ch=='*'||ch=='-') { |
if (ch=='*') { |
/* |
* ``A negative field width argument is taken as a |
* - flag followed by a positive field width.'' |
* -- ANSI X3J11 |
* They don't exclude field widths read from args. |
*/ |
if ((width = va_arg(ap, int)) >= 0) |
goto rflag; |
width = -width; |
} |
flags |= LADJUST; |
flags &= ~ZEROPAD; /* '-' disables '0' */ |
goto rflag; |
} else if (ch=='+') { |
sign = '+'; |
goto rflag; |
} else if (ch=='.') { |
if ((ch = PRG_RDB(fmt++)) == '*') { |
n = va_arg(ap, int); |
prec = n < 0 ? -1 : n; |
goto rflag; |
} |
n = 0; |
while (is_digit(ch)) { |
n = n*10 + to_digit(ch); |
ch = PRG_RDB(fmt++); |
} |
prec = n < 0 ? -1 : n; |
goto reswitch; |
} else |
#endif /* LIGHTPRINTF */ |
if (ch=='0') { |
/* |
* ``Note that 0 is taken as a flag, not as the |
* beginning of a field width.'' |
* -- ANSI X3J11 |
*/ |
if (!(flags & LADJUST)) |
flags |= ZEROPAD; /* '-' disables '0' */ |
goto rflag; |
} else if (ch>='1' && ch<='9') { |
n = 0; |
do { |
n = 10 * n + to_digit(ch); |
ch = PRG_RDB(fmt++); |
} while (is_digit(ch)); |
width = n; |
goto reswitch; |
} else if (ch=='h') { |
flags |= SHORTINT; |
goto rflag; |
} else if (ch=='l') { |
flags |= LONGINT; |
goto rflag; |
} else if (ch=='c') { |
*(cp = buf) = va_arg(ap, int); |
size = 1; |
sign = '\0'; |
} else if (ch=='D'||ch=='d'||ch=='i') { |
if(ch=='D') |
flags |= LONGINT; |
if (flags&LONGINT) { |
_ulong=va_arg(ap, long); |
} else { |
register int _d; |
_d=va_arg(ap, int); |
_ulong = flags&SHORTINT ? (long)(short)_d : (long)_d; |
} |
if ((long)_ulong < 0) { |
_ulong = -_ulong; |
sign = '-'; |
} |
base = DEC; |
goto number; |
} else |
/* |
if (ch=='n') { |
if (flags & LONGINT) |
*va_arg(ap, long *) = ret; |
else if (flags & SHORTINT) |
*va_arg(ap, short *) = ret; |
else |
*va_arg(ap, int *) = ret; |
continue; // no output |
} else |
*/ |
#ifndef LIGHTPRINTF |
if (ch=='O'||ch=='o') { |
if (ch=='O') |
flags |= LONGINT; |
base = OCT; |
goto nosign; |
} else if (ch=='p') { |
/* |
* ``The argument shall be a pointer to void. The |
* value of the pointer is converted to a sequence |
* of printable characters, in an implementation- |
* defined manner.'' |
* -- ANSI X3J11 |
*/ |
/* NOSTRICT */ |
_ulong = (unsigned int)va_arg(ap, void *); |
base = HEX; |
flags |= HEXPREFIX; |
ch = 'x'; |
goto nosign; |
} else if (ch=='s') { // print a string from RAM |
if ((cp = va_arg(ap, char *)) == NULL) { |
cp=buf; |
cp[0] = '('; |
cp[1] = 'n'; |
cp[2] = 'u'; |
cp[4] = cp[3] = 'l'; |
cp[5] = ')'; |
cp[6] = '\0'; |
} |
if (prec >= 0) { |
/* |
* can't use strlen; can only look for the |
* NUL in the first `prec' characters, and |
* strlen() will go further. |
*/ |
char *p = (char*)memchr(cp, 0, prec); |
if (p != NULL) { |
size = p - cp; |
if (size > prec) |
size = prec; |
} else |
size = prec; |
} else |
size = strlen(cp); |
sign = '\0'; |
} else |
#endif /* LIGHTPRINTF */ |
if(ch=='U'||ch=='u') { |
if (ch=='U') |
flags |= LONGINT; |
base = DEC; |
goto nosign; |
} else if (ch=='X'||ch=='x') { |
base = HEX; |
/* leading 0x/X only if non-zero */ |
if (flags & ALT && _ulong != 0) |
flags |= HEXPREFIX; |
/* unsigned conversions */ |
nosign: sign = '\0'; |
/* |
* ``... diouXx conversions ... if a precision is |
* specified, the 0 flag will be ignored.'' |
* -- ANSI X3J11 |
*/ |
number: if ((dprec = prec) >= 0) |
flags &= ~ZEROPAD; |
/* |
* ``The result of converting a zero value with an |
* explicit precision of zero is no characters.'' |
* -- ANSI X3J11 |
*/ |
cp = buf + BUF; |
if (_ulong != 0 || prec != 0) { |
register unsigned char _d,notlastdigit; |
do { |
notlastdigit=(_ulong>=base); |
_d = _ulong % base; |
if (_d<10) { |
_d+='0'; |
} else { |
_d+='a'-10; |
if (ch=='X') _d&=~0x20; |
} |
*--cp=_d; |
_ulong /= base; |
} while (notlastdigit); |
#ifndef LIGHTPRINTF |
// handle octal leading 0 |
if (base==OCT && flags & ALT && *cp != '0') |
*--cp = '0'; |
#endif |
} |
size = buf + BUF - cp; |
} else { //default |
/* "%?" prints ?, unless ? is NUL */ |
if (ch == '\0') |
goto done; |
/* pretend it was %c with argument ch */ |
cp = buf; |
*cp = ch; |
size = 1; |
sign = '\0'; |
} |
/* |
* All reasonable formats wind up here. At this point, |
* `cp' points to a string which (if not flags&LADJUST) |
* should be padded out to `width' places. If |
* flags&ZEROPAD, it should first be prefixed by any |
* sign or other prefix; otherwise, it should be blank |
* padded before the prefix is emitted. After any |
* left-hand padding and prefixing, emit zeroes |
* required by a decimal [diouxX] precision, then print |
* the string proper, then emit zeroes required by any |
* leftover floating precision; finally, if LADJUST, |
* pad with blanks. |
*/ |
/* |
* compute actual size, so we know how much to pad. |
*/ |
fieldsz = size; |
dpad = dprec - size; |
if (dpad < 0) |
dpad = 0; |
if (sign) |
fieldsz++; |
else if (flags & HEXPREFIX) |
fieldsz += 2; |
fieldsz += dpad; |
/* right-adjusting blank padding */ |
if ((flags & (LADJUST|ZEROPAD)) == 0) |
PAD_SP(width - fieldsz); |
/* prefix */ |
if (sign) { |
PRINT(&sign, 1); |
} else if (flags & HEXPREFIX) { |
ox[0] = '0'; |
ox[1] = ch; |
PRINT(ox, 2); |
} |
/* right-adjusting zero padding */ |
if ((flags & (LADJUST|ZEROPAD)) == ZEROPAD) |
PAD_0(width - fieldsz); |
/* leading zeroes from decimal precision */ |
PAD_0(dpad); |
/* the string or number proper */ |
PRINT(cp, size); |
/* left-adjusting padding (always blank) */ |
if (flags & LADJUST) |
PAD_SP(width - fieldsz); |
} |
done: |
va_end(ap); |
} |
/branches/V0.63_LED1_LED2/printf_P.h |
---|
0,0 → 1,19 |
#ifndef _PRINTF_P_H_ |
#define _PRINTF_P_H_ |
#include <avr/pgmspace.h> |
#define OUT_V24 0 |
#define OUT_LCD 1 |
extern void _printf_P (char, char const *fmt0, ...); |
extern char PrintZiel; |
#define printf_P(format, args...) _printf_P(OUT_V24,format , ## args) |
#define printf(format, args...) _printf_P(OUT_V24,PSTR(format) , ## args) |
#define LCD_printfxy(x,y,format, args...) { DispPtr = y * 20 + x; _printf_P(OUT_LCD,PSTR(format) , ## args);} |
#define LCD_printf(format, args...) { _printf_P(OUT_LCD,PSTR(format) , ## args);} |
#endif |
/branches/V0.63_LED1_LED2/rc.c |
---|
0,0 → 1,85 |
/*####################################################################################### |
Decodieren eines RC Summen Signals |
#######################################################################################*/ |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Copyright (c) 04.2007 Holger Buss |
// + only for non-profit use |
// + www.MikroKopter.com |
// + see the File "License.txt" for further Informations |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
#include "rc.h" |
#include "main.h" |
volatile int PPM_in[11]; |
volatile int PPM_diff[11]; // das diffenzierte Stick-Signal |
volatile unsigned char NewPpmData = 1; |
//############################################################################ |
//zum decodieren des PPM-Signals wird Timer1 mit seiner Input |
//Capture Funktion benutzt: |
void rc_sum_init (void) |
//############################################################################ |
{ |
TCCR1B=(1<<CS11)|(1<<CS10)|(1<<ICES1)|(1<<ICNC1);//|(1 << WGM12); //timer1 prescale 64 |
// PWM |
//TCCR1A = (1 << COM1B1) | (1 << WGM11) | (1 << WGM10); |
//TCCR1B |= (1 << WGM12); |
//OCR1B = 55; |
TIMSK1 |= _BV(ICIE1); |
AdNeutralGier = 0; |
AdNeutralRoll = 0; |
AdNeutralNick = 0; |
return; |
} |
//############################################################################ |
//Diese Routine startet und inizialisiert den Timer für RC |
SIGNAL(SIG_INPUT_CAPTURE1) |
//############################################################################ |
{ |
static unsigned int AltICR=0; |
signed int signal = 0,tmp; |
static int index; |
signal = (unsigned int) ICR1 - AltICR; |
AltICR = ICR1; |
//Syncronisationspause? |
if ((signal > 1500) && (signal < 8000)) |
{ |
index = 1; |
NewPpmData = 0; // Null bedeutet: Neue Daten |
// OCR2A = Poti2/2 + 80; |
} |
else |
{ |
if(index < 10) |
{ |
if((signal > 250) && (signal < 687)) |
{ |
signal -= 466; |
// Stabiles Signal |
if(abs(signal - PPM_in[index]) < 6) { if(SenderOkay < 200) SenderOkay += 10;} |
tmp = (3 * (PPM_in[index]) + signal) / 4; |
if(tmp > signal+1) tmp--; else |
if(tmp < signal-1) tmp++; |
PPM_diff[index] = tmp - PPM_in[index]; |
PPM_in[index] = tmp; |
} |
index++; |
if(index == 5) PORTD |= 0x20; else PORTD &= ~0x20; // Servosignal an J3 anlegen |
if(index == 6) PORTD |= 0x10; else PORTD &= ~0x10; // Servosignal an J4 anlegen |
if(index == 7) PORTD |= 0x08; else PORTD &= ~0x08; // Servosignal an J5 anlegen |
} |
} |
} |
/branches/V0.63_LED1_LED2/rc.h |
---|
0,0 → 1,29 |
/*####################################################################################### |
Derkodieren eines RC Summen Signals |
#######################################################################################*/ |
#ifndef _RC_H |
#define _RC_H |
#if defined (__AVR_ATmega32__) |
#define TIMER_TEILER CK64 |
#define TIMER_RELOAD_VALUE 250 |
#endif |
#if defined (__AVR_ATmega644__) |
//#define TIMER_TEILER CK64 |
#define TIMER_RELOAD_VALUE 250 |
//#define TIMER_TEILER CK256 // bei 20MHz |
//#define TIMER_RELOAD_VALUE -78 // bei 20MHz |
#endif |
#define GAS PPM_in[2] |
extern void rc_sum_init (void); |
extern volatile int PPM_in[11]; |
extern volatile int PPM_diff[11]; // das diffenzierte Stick-Signal |
extern volatile unsigned char NewPpmData; |
#endif //_RC_H |
/branches/V0.63_LED1_LED2/timer0.c |
---|
0,0 → 1,158 |
#include "main.h" |
volatile unsigned int CountMilliseconds = 0; |
volatile static unsigned int tim_main; |
volatile unsigned char UpdateMotor = 0; |
volatile unsigned int cntKompass = 0; |
volatile unsigned int beeptime = 0; |
unsigned int BeepMuster = 0xffff; |
int ServoValue = 0; |
enum { |
STOP = 0, |
CK = 1, |
CK8 = 2, |
CK64 = 3, |
CK256 = 4, |
CK1024 = 5, |
T0_FALLING_EDGE = 6, |
T0_RISING_EDGE = 7 |
}; |
SIGNAL (SIG_OVERFLOW0) // 8kHz |
{ |
static unsigned char cnt_1ms = 1,cnt = 0; |
unsigned char pieper_ein = 0; |
// TCNT0 -= 250;//TIMER_RELOAD_VALUE; |
if(!cnt--) |
{ |
cnt = 9; |
cnt_1ms++; |
cnt_1ms %= 2; |
if(!cnt_1ms) UpdateMotor = 1; |
CountMilliseconds++; |
} |
if(beeptime > 1) |
{ |
beeptime--; |
if(beeptime & BeepMuster) |
{ |
pieper_ein = 1; |
} |
else pieper_ein = 0; |
} |
else |
{ |
pieper_ein = 0; |
BeepMuster = 0xffff; |
} |
if(pieper_ein) |
{ |
if(PlatinenVersion == 10) PORTD |= (1<<2); // Speaker an PORTD.2 |
else PORTC |= (1<<7); // Speaker an PORTC.7 |
} |
else |
{ |
if(PlatinenVersion == 10) PORTD &= ~(1<<2); |
else PORTC &= ~(1<<7); |
} |
if(EE_Parameter.GlobalConfig & CFG_KOMPASS_AKTIV) |
{ |
if(PINC & 0x10) |
{ |
cntKompass++; |
} |
else |
{ |
if((cntKompass) && (cntKompass < 4000)) |
{ |
KompassValue = cntKompass; |
} |
// if(cntKompass < 10) cntKompass = 10; |
// KompassValue = (unsigned long)((unsigned long)(cntKompass-10)*720L + 1L) / 703L; |
KompassRichtung = ((540 + KompassValue - KompassStartwert) % 360) - 180; |
cntKompass = 0; |
} |
} |
} |
void Timer_Init(void) |
{ |
tim_main = SetDelay(10); |
TCCR0B = CK8; |
TCCR0A = (1<<COM0A1)|(1<<COM0B1)|3;//fast PWM |
OCR0A = 0; |
OCR0B = 120; |
TCNT0 = -TIMER_RELOAD_VALUE; // reload |
//OCR1 = 0x00; |
TCCR2A=(1<<COM2A1)|(1<<COM2A0)|3; |
TCCR2B=(0<<CS20)|(1<<CS21)|(1<<CS22); |
// TIMSK2 |= _BV(TOIE2); |
TIMSK2 |= _BV(OCIE2A); |
TIMSK0 |= _BV(TOIE0); |
OCR2A = 10; |
TCNT2 = 0; |
} |
// ----------------------------------------------------------------------- |
unsigned int SetDelay (unsigned int t) |
{ |
// TIMSK0 &= ~_BV(TOIE0); |
return(CountMilliseconds + t + 1); |
// TIMSK0 |= _BV(TOIE0); |
} |
// ----------------------------------------------------------------------- |
char CheckDelay(unsigned int t) |
{ |
// TIMSK0 &= ~_BV(TOIE0); |
return(((t - CountMilliseconds) & 0x8000) >> 9); |
// TIMSK0 |= _BV(TOIE0); |
} |
// ----------------------------------------------------------------------- |
void Delay_ms(unsigned int w) |
{ |
unsigned int akt; |
akt = SetDelay(w); |
while (!CheckDelay(akt)); |
} |
// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// Servo ansteuern |
// +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
SIGNAL(SIG_OUTPUT_COMPARE2A) |
{ |
static unsigned char timer = 10; |
if(!timer--) |
{ |
TCCR2A=(1<<COM2A1)|(0<<COM2A0)|3; |
ServoValue = Parameter_ServoNickControl; |
if(EE_Parameter.ServoNickCompInvert & 0x01) ServoValue += ((long) EE_Parameter.ServoNickComp * (IntegralNick / 128)) / 512; |
else ServoValue -= ((long) EE_Parameter.ServoNickComp * (IntegralNick / 128)) / 512; |
if(ServoValue < EE_Parameter.ServoNickMin) ServoValue = EE_Parameter.ServoNickMin; |
else if(ServoValue > EE_Parameter.ServoNickMax) ServoValue = EE_Parameter.ServoNickMax; |
OCR2A = ServoValue;// + 75; |
timer = EE_Parameter.ServoNickRefresh; |
} |
else |
{ |
TCCR2A =3; |
PORTD&=~0x80; |
} |
} |
/branches/V0.63_LED1_LED2/timer0.h |
---|
0,0 → 1,15 |
#define TIMER_TEILER CK8 |
#define TIMER_RELOAD_VALUE 250 |
void Timer_Init(void); |
void Delay_ms(unsigned int); |
unsigned int SetDelay (unsigned int t); |
char CheckDelay (unsigned int t); |
extern volatile unsigned int CountMilliseconds; |
extern volatile unsigned char UpdateMotor; |
extern volatile unsigned int beeptime; |
extern volatile unsigned int cntKompass; |
extern int ServoValue; |
extern unsigned int BeepMuster; |
/branches/V0.63_LED1_LED2/twimaster.c |
---|
0,0 → 1,152 |
/*############################################################################ |
############################################################################*/ |
#include "main.h" |
unsigned char twi_state = 0; |
unsigned char motor = 0; |
unsigned char motorread = 0; |
unsigned char motor_rx[8]; |
//############################################################################ |
//Initzialisieren der I2C (TWI) Schnittstelle |
void i2c_init(void) |
//############################################################################ |
{ |
TWSR = 0; |
TWBR = ((SYSCLK/SCL_CLOCK)-16)/2; |
} |
//############################################################################ |
//Start I2C |
char i2c_start(void) |
//############################################################################ |
{ |
TWCR = (1<<TWSTA) | (1<<TWEN) | (1<<TWINT) | (1<<TWIE); |
return(0); |
} |
//############################################################################ |
//Start I2C |
void i2c_stop(void) |
//############################################################################ |
{ |
TWCR = (1<<TWEN) | (1<<TWSTO) | (1<<TWINT); |
} |
void i2c_reset(void) |
//############################################################################ |
{ |
i2c_stop(); |
twi_state = 0; |
motor = TWDR; |
motor = 0; |
TWCR = 0x80; |
TWAMR = 0; |
TWAR = 0; |
TWDR = 0; |
TWSR = 0; |
TWBR = 0; |
i2c_init(); |
i2c_start(); |
i2c_write_byte(0); |
} |
//############################################################################ |
//Start I2C |
char i2c_write_byte(char byte) |
//############################################################################ |
{ |
TWSR = 0x00; |
TWDR = byte; |
TWCR = (1<<TWINT) | (1<<TWEN) | (1<<TWIE); |
return(0); |
} |
//############################################################################ |
//Start I2C |
SIGNAL (TWI_vect) |
//############################################################################ |
{ |
switch (twi_state++) |
{ |
case 0: |
i2c_write_byte(0x52+(motor*2)); |
break; |
case 1: |
switch(motor++) |
{ |
case 0: |
i2c_write_byte(Motor_Vorne); |
break; |
case 1: |
i2c_write_byte(Motor_Hinten); |
break; |
case 2: |
i2c_write_byte(Motor_Rechts); |
break; |
case 3: |
i2c_write_byte(Motor_Links); |
break; |
} |
break; |
case 2: |
i2c_stop(); |
if (motor<4) twi_state = 0; |
else motor = 0; |
i2c_start(); |
break; |
//Liest Daten von Motor |
case 3: |
i2c_write_byte(0x53+(motorread*2)); |
break; |
case 4: |
switch(motorread) |
{ |
case 0: |
i2c_write_byte(Motor_Vorne); |
break; |
case 1: |
i2c_write_byte(Motor_Hinten); |
break; |
case 2: |
i2c_write_byte(Motor_Rechts); |
break; |
case 3: |
i2c_write_byte(Motor_Links); |
break; |
} |
break; |
case 5: //1 Byte vom Motor lesen |
motor_rx[motorread] = TWDR; |
case 6: |
switch(motorread) |
{ |
case 0: |
i2c_write_byte(Motor_Vorne); |
break; |
case 1: |
i2c_write_byte(Motor_Hinten); |
break; |
case 2: |
i2c_write_byte(Motor_Rechts); |
break; |
case 3: |
i2c_write_byte(Motor_Links); |
break; |
} |
break; |
case 7: //2 Byte vom Motor lesen |
motor_rx[motorread+4] = TWDR; |
motorread++; |
if (motorread>3) motorread=0; |
i2c_stop(); |
I2CTimeout = 10; |
twi_state = 0; |
} |
TWCR |= 0x80; |
} |
/branches/V0.63_LED1_LED2/twimaster.h |
---|
0,0 → 1,32 |
/*############################################################################ |
############################################################################*/ |
#ifndef _I2C_MASTER_H |
#define _I2C_MASTER_H |
//############################################################################ |
// I2C Konstanten |
#define SCL_CLOCK 200000L |
#define I2C_TIMEOUT 30000 |
#define I2C_START 0x08 |
#define I2C_REPEATED_START 0x10 |
#define I2C_TX_SLA_ACK 0x18 |
#define I2C_TX_DATA_ACK 0x28 |
#define I2C_RX_SLA_ACK 0x40 |
#define I2C_RX_DATA_ACK 0x50 |
//############################################################################ |
extern unsigned char twi_state; |
extern unsigned char motor; |
extern unsigned char motorread; |
extern unsigned char motor_rx[8]; |
void i2c_init (void); // I2C initialisieren |
char i2c_start (void); // Start I2C |
void i2c_stop (void); // Stop I2C |
char i2c_write_byte (char byte); // 1 Byte schreiben |
#endif |
/branches/V0.63_LED1_LED2/uart.c |
---|
0,0 → 1,332 |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
// + Copyright (c) 04.2007 Holger Buss |
// + only for non-profit use |
// + www.MikroKopter.com |
// + see the File "License.txt" for further Informations |
// ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
#include "main.h" |
#include "uart.h" |
unsigned char DebugGetAnforderung = 0,DebugDisplayAnforderung = 0,DebugDataAnforderung = 0,GetVersionAnforderung = 0; |
unsigned volatile char SioTmp = 0; |
unsigned volatile char SendeBuffer[MAX_SENDE_BUFF]; |
unsigned volatile char RxdBuffer[MAX_EMPFANGS_BUFF]; |
unsigned volatile char NMEABuffer[MAX_EMPFANGS_BUFF]; |
unsigned volatile char NeuerDatensatzEmpfangen = 0; |
unsigned volatile char NeueKoordinateEmpfangen = 0; |
unsigned volatile char UebertragungAbgeschlossen = 1; |
unsigned volatile char CntCrcError = 0; |
unsigned volatile char AnzahlEmpfangsBytes = 0; |
unsigned volatile char PC_DebugTimeout = 0; |
unsigned char PcZugriff = 100; |
unsigned char MotorTest[4] = {0,0,0,0}; |
unsigned char MeineSlaveAdresse; |
struct str_DebugOut DebugOut; |
struct str_Debug DebugIn; |
struct str_VersionInfo VersionInfo; |
int Debug_Timer; |
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
//++ Sende-Part der Datenübertragung |
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
SIGNAL(INT_VEC_TX) |
{ |
static unsigned int ptr = 0; |
unsigned char tmp_tx; |
if(!UebertragungAbgeschlossen) |
{ |
ptr++; // die [0] wurde schon gesendet |
tmp_tx = SendeBuffer[ptr]; |
if((tmp_tx == '\r') || (ptr == MAX_SENDE_BUFF)) |
{ |
ptr = 0; |
UebertragungAbgeschlossen = 1; |
} |
UDR = tmp_tx; |
} |
else ptr = 0; |
} |
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
//++ Empfangs-Part der Datenübertragung, incl. CRC-Auswertung |
//+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
SIGNAL(INT_VEC_RX) |
{ |
static unsigned int crc; |
static unsigned char crc1,crc2,buf_ptr; |
static unsigned char UartState = 0; |
unsigned char CrcOkay = 0; |
SioTmp = UDR; |
if(buf_ptr >= MAX_EMPFANGS_BUFF) UartState = 0; |
if(SioTmp == '\r' && UartState == 2) |
{ |
UartState = 0; |
crc -= RxdBuffer[buf_ptr-2]; |
crc -= RxdBuffer[buf_ptr-1]; |
crc %= 4096; |
crc1 = '=' + crc / 64; |
crc2 = '=' + crc % 64; |
CrcOkay = 0; |
if((crc1 == RxdBuffer[buf_ptr-2]) && (crc2 == RxdBuffer[buf_ptr-1])) CrcOkay = 1; else { CrcOkay = 0; CntCrcError++;}; |
if(!NeuerDatensatzEmpfangen && CrcOkay) // Datensatz schon verarbeitet |
{ |
NeuerDatensatzEmpfangen = 1; |
AnzahlEmpfangsBytes = buf_ptr; |
RxdBuffer[buf_ptr] = '\r'; |
if(RxdBuffer[2] == 'R') wdt_enable(WDTO_250MS); // Reset-Commando |
} |
} |
else |
switch(UartState) |
{ |
case 0: |
if(SioTmp == '#' && !NeuerDatensatzEmpfangen) UartState = 1; // Startzeichen und Daten schon verarbeitet |
buf_ptr = 0; |
RxdBuffer[buf_ptr++] = SioTmp; |
crc = SioTmp; |
break; |
case 1: // Adresse auswerten |
UartState++; |
RxdBuffer[buf_ptr++] = SioTmp; |
crc += SioTmp; |
break; |
case 2: // Eingangsdaten sammeln |
RxdBuffer[buf_ptr] = SioTmp; |
if(buf_ptr < MAX_EMPFANGS_BUFF) buf_ptr++; |
else UartState = 0; |
crc += SioTmp; |
break; |
default: |
UartState = 0; |
break; |
} |
} |
// -------------------------------------------------------------------------- |
void AddCRC(unsigned int wieviele) |
{ |
unsigned int tmpCRC = 0,i; |
for(i = 0; i < wieviele;i++) |
{ |
tmpCRC += SendeBuffer[i]; |
} |
tmpCRC %= 4096; |
SendeBuffer[i++] = '=' + tmpCRC / 64; |
SendeBuffer[i++] = '=' + tmpCRC % 64; |
SendeBuffer[i++] = '\r'; |
UebertragungAbgeschlossen = 0; |
UDR = SendeBuffer[0]; |
} |
// -------------------------------------------------------------------------- |
void SendOutData(unsigned char cmd,unsigned char modul, unsigned char *snd, unsigned char len) |
{ |
unsigned int pt = 0; |
unsigned char a,b,c; |
unsigned char ptr = 0; |
SendeBuffer[pt++] = '#'; // Startzeichen |
SendeBuffer[pt++] = modul; // Adresse (a=0; b=1,...) |
SendeBuffer[pt++] = cmd; // Commando |
while(len) |
{ |
if(len) { a = snd[ptr++]; len--;} else a = 0; |
if(len) { b = snd[ptr++]; len--;} else b = 0; |
if(len) { c = snd[ptr++]; len--;} else c = 0; |
SendeBuffer[pt++] = '=' + (a >> 2); |
SendeBuffer[pt++] = '=' + (((a & 0x03) << 4) | ((b & 0xf0) >> 4)); |
SendeBuffer[pt++] = '=' + (((b & 0x0f) << 2) | ((c & 0xc0) >> 6)); |
SendeBuffer[pt++] = '=' + ( c & 0x3f); |
} |
AddCRC(pt); |
} |
// -------------------------------------------------------------------------- |
void Decode64(unsigned char *ptrOut, unsigned char len, unsigned char ptrIn,unsigned char max) // Wohin mit den Daten; Wie lang; Wo im RxdBuffer |
{ |
unsigned char a,b,c,d; |
unsigned char ptr = 0; |
unsigned char x,y,z; |
while(len) |
{ |
a = RxdBuffer[ptrIn++] - '='; |
b = RxdBuffer[ptrIn++] - '='; |
c = RxdBuffer[ptrIn++] - '='; |
d = RxdBuffer[ptrIn++] - '='; |
if(ptrIn > max - 2) break; // nicht mehr Daten verarbeiten, als empfangen wurden |
x = (a << 2) | (b >> 4); |
y = ((b & 0x0f) << 4) | (c >> 2); |
z = ((c & 0x03) << 6) | d; |
if(len--) ptrOut[ptr++] = x; else break; |
if(len--) ptrOut[ptr++] = y; else break; |
if(len--) ptrOut[ptr++] = z; else break; |
} |
} |
// -------------------------------------------------------------------------- |
void BearbeiteRxDaten(void) |
{ |
if(!NeuerDatensatzEmpfangen) return; |
unsigned int tmp_int_arr1[1]; |
unsigned int tmp_int_arr2[2]; |
unsigned int tmp_int_arr3[3]; |
unsigned char tmp_char_arr2[2]; |
unsigned char tmp_char_arr3[3]; |
unsigned char tmp_char_arr4[4]; |
//if(!MotorenEin) |
PcZugriff = 255; |
switch(RxdBuffer[2]) |
{ |
case 'c':// Debugdaten incl. Externe IOs usw |
Decode64((unsigned char *) &DebugIn,sizeof(DebugIn),3,AnzahlEmpfangsBytes); |
/* for(unsigned char i=0; i<4;i++) |
{ |
EE_CheckAndWrite(&EE_Buffer[EE_DEBUGWERTE + i*2], DebugIn.Analog[i]); |
EE_CheckAndWrite(&EE_Buffer[EE_DEBUGWERTE + i*2 + 1], DebugIn.Analog[i] >> 8); |
}*/ |
//RemoteTasten |= DebugIn.RemoteTasten; |
DebugDataAnforderung = 1; |
break; |
case 'h':// x-1 Displayzeilen |
Decode64((unsigned char *) &tmp_char_arr2[0],sizeof(tmp_char_arr2),3,AnzahlEmpfangsBytes); |
RemoteTasten |= tmp_char_arr2[0]; |
DebugDisplayAnforderung = 1; |
break; |
case 't':// Motortest |
Decode64((unsigned char *) &MotorTest[0],sizeof(MotorTest),3,AnzahlEmpfangsBytes); |
break; |
case 'v': // Version-Anforderung und Ausbaustufe |
GetVersionAnforderung = 1; |
break; |
case 'g':// "Get"-Anforderung für Debug-Daten |
// Bei Get werden die vom PC einstellbaren Werte vom PC zurückgelesen |
DebugGetAnforderung = 1; |
break; |
case 'q':// "Get"-Anforderung für Settings |
// Bei Get werden die vom PC einstellbaren Werte vom PC zurückgelesen |
Decode64((unsigned char *) &tmp_char_arr2[0],sizeof(tmp_char_arr2),3,AnzahlEmpfangsBytes); |
if(tmp_char_arr2[0] != 0xff) |
{ |
if(tmp_char_arr2[0] > 5) tmp_char_arr2[0] = 5; |
ReadParameterSet(tmp_char_arr2[0], (unsigned char *) &EE_Parameter.Kanalbelegung[0], STRUCT_PARAM_LAENGE); |
SendOutData('L' + tmp_char_arr2[0] -1,MeineSlaveAdresse,(unsigned char *) &EE_Parameter.Kanalbelegung[0],STRUCT_PARAM_LAENGE); |
} |
else |
SendOutData('L' + GetActiveParamSetNumber()-1,MeineSlaveAdresse,(unsigned char *) &EE_Parameter.Kanalbelegung[0],STRUCT_PARAM_LAENGE); |
break; |
case 'l': |
case 'm': |
case 'n': |
case 'o': |
case 'p': // Parametersatz speichern |
Decode64((unsigned char *) &EE_Parameter.Kanalbelegung[0],STRUCT_PARAM_LAENGE,3,AnzahlEmpfangsBytes); |
WriteParameterSet(RxdBuffer[2] - 'l' + 1, (unsigned char *) &EE_Parameter.Kanalbelegung[0], STRUCT_PARAM_LAENGE); |
eeprom_write_byte(&EEPromArray[EEPROM_ADR_ACTIVE_SET], RxdBuffer[2] - 'l' + 1); // aktiven Datensatz merken |
Piep(GetActiveParamSetNumber()); |
break; |
} |
// DebugOut.AnzahlZyklen = Debug_Timer_Intervall; |
NeuerDatensatzEmpfangen = 0; |
} |
//############################################################################ |
//Routine für die Serielle Ausgabe |
int uart_putchar (char c) |
//############################################################################ |
{ |
if (c == '\n') |
uart_putchar('\r'); |
//Warten solange bis Zeichen gesendet wurde |
loop_until_bit_is_set(USR, UDRE); |
//Ausgabe des Zeichens |
UDR = c; |
return (0); |
} |
// -------------------------------------------------------------------------- |
void WriteProgramData(unsigned int pos, unsigned char wert) |
{ |
//if (ProgramLocation == IN_RAM) Buffer[pos] = wert; |
// else eeprom_write_byte(&EE_Buffer[pos], wert); |
// Buffer[pos] = wert; |
} |
//############################################################################ |
//INstallation der Seriellen Schnittstelle |
void UART_Init (void) |
//############################################################################ |
{ |
//Enable TXEN im Register UCR TX-Data Enable & RX Enable |
UCR=(1 << TXEN) | (1 << RXEN); |
// UART Double Speed (U2X) |
USR |= (1<<U2X); |
// RX-Interrupt Freigabe |
UCSRB |= (1<<RXCIE); |
// TX-Interrupt Freigabe |
UCSRB |= (1<<TXCIE); |
//Teiler wird gesetzt |
UBRR=(SYSCLK / (BAUD_RATE * 8L) - 1); |
//UBRR = 33; |
//öffnet einen Kanal für printf (STDOUT) |
//fdevopen (uart_putchar, 0); |
//sbi(PORTD,4); |
Debug_Timer = SetDelay(200); |
} |
//--------------------------------------------------------------------------------------------- |
void DatenUebertragung(void) |
{ |
static char dis_zeile = 0; |
if(!UebertragungAbgeschlossen) return; |
if(DebugGetAnforderung && UebertragungAbgeschlossen) // Bei Get werden die vom PC einstellbaren Werte vom PC zurückgelesen |
{ |
SendOutData('G',MeineSlaveAdresse,(unsigned char *) &DebugIn,sizeof(DebugIn)); |
DebugGetAnforderung = 0; |
} |
if((CheckDelay(Debug_Timer) || DebugDataAnforderung) && UebertragungAbgeschlossen) |
{ |
SendOutData('D',MeineSlaveAdresse,(unsigned char *) &DebugOut,sizeof(DebugOut)); |
DebugDataAnforderung = 0; |
Debug_Timer = SetDelay(MIN_DEBUG_INTERVALL); |
} |
if(DebugDisplayAnforderung && UebertragungAbgeschlossen) |
{ |
Menu(); |
DebugDisplayAnforderung = 0; |
if(++dis_zeile == 4) |
{ |
SendOutData('4',0,&PPM_in,sizeof(PPM_in)); // DisplayZeile übertragen |
dis_zeile = -1; |
} |
else SendOutData('0' + dis_zeile,0,&DisplayBuff[20 * dis_zeile],20); // DisplayZeile übertragen |
} |
if(GetVersionAnforderung && UebertragungAbgeschlossen) |
{ |
SendOutData('V',MeineSlaveAdresse,(unsigned char *) &VersionInfo,sizeof(VersionInfo)); |
GetVersionAnforderung = 0; |
} |
} |
/branches/V0.63_LED1_LED2/uart.h |
---|
0,0 → 1,90 |
#ifndef _UART_H |
#define _UART_H |
#define MAX_SENDE_BUFF 150 |
#define MAX_EMPFANGS_BUFF 150 |
extern unsigned char DebugGetAnforderung; |
extern unsigned volatile char SendeBuffer[MAX_SENDE_BUFF]; |
extern unsigned volatile char RxdBuffer[MAX_EMPFANGS_BUFF]; |
extern unsigned volatile char UebertragungAbgeschlossen; |
extern unsigned volatile char PC_DebugTimeout; |
extern unsigned volatile char NeueKoordinateEmpfangen; |
extern unsigned char MeineSlaveAdresse; |
extern unsigned char PcZugriff; |
extern int Debug_Timer; |
extern void UART_Init (void); |
extern int uart_putchar (char c); |
extern void boot_program_page (uint32_t page, uint8_t *buf); |
extern void DatenUebertragung(void); |
extern void DecodeNMEA(void); |
extern unsigned char MotorTest[4]; |
struct str_DebugOut |
{ |
unsigned char Digital[2]; |
unsigned int Analog[32]; // Debugwerte |
}; |
extern struct str_DebugOut DebugOut; |
struct str_Debug |
{ |
unsigned char Digital[2]; |
unsigned char RemoteTasten; |
unsigned int Analog[4]; |
}; |
extern struct str_Debug DebugIn; |
struct str_VersionInfo |
{ |
unsigned char Hauptversion; |
unsigned char Nebenversion; |
unsigned char PCKompatibel; |
unsigned char Rserved[7]; |
}; |
extern struct str_VersionInfo VersionInfo; |
//Die Baud_Rate der Seriellen Schnittstelle ist 9600 Baud |
//#define BAUD_RATE 9600 //Baud Rate für die Serielle Schnittstelle |
//#define BAUD_RATE 14400 //Baud Rate für die Serielle Schnittstelle |
//#define BAUD_RATE 28800 //Baud Rate für die Serielle Schnittstelle |
//#define BAUD_RATE 38400 //Baud Rate für die Serielle Schnittstelle |
#define BAUD_RATE 57600 //Baud Rate für die Serielle Schnittstelle |
//Anpassen der seriellen Schnittstellen Register wenn ein ATMega128 benutzt wird |
#if defined (__AVR_ATmega128__) |
# define USR UCSR0A |
# define UCR UCSR0B |
# define UDR UDR0 |
# define UBRR UBRR0L |
# define EICR EICRB |
#endif |
#if defined (__AVR_ATmega32__) |
# define USR UCSRA |
# define UCR UCSRB |
# define UBRR UBRRL |
# define EICR EICRB |
# define INT_VEC_RX SIG_UART_RECV |
# define INT_VEC_TX SIG_UART_TRANS |
#endif |
#if defined (__AVR_ATmega644__) |
# define USR UCSR0A |
# define UCR UCSR0B |
# define UDR UDR0 |
# define UBRR UBRR0L |
# define EICR EICR0B |
# define TXEN TXEN0 |
# define RXEN RXEN0 |
# define RXCIE RXCIE0 |
# define TXCIE TXCIE0 |
# define U2X U2X0 |
# define UCSRB UCSR0B |
# define UDRE UDRE0 |
# define INT_VEC_RX SIG_USART_RECV |
# define INT_VEC_TX SIG_USART_TRANS |
#endif |
#endif //_UART_H |
/branches/V0.63_LED1_LED2/version.txt |
---|
0,0 → 1,73 |
------- |
V0.53 27.04.2007 H.Buss |
- erste öffentliche Version |
V0.53b 29.04.2007 H.Buss |
- der FAKTOR_I war versehentlich auf Null, dann liegt der MikroKopter nicht so hart in der Luft |
V0.53c 29.04.2007 H.Buss |
- es gib ein Menü, in dem die Werte der Kanäle nach Nick, Roll, Gas,... sortiert sind. |
Die angezeigten Werte waren nicht die Werte der Funke |
V0.54 01.05.2007 H.Buss |
- die Paramtersätze können jetzt vor dem Start ausgewählt werden |
Dazu wird beim Kalibrieren der Messwerte (Gashebel oben links) der Nick-Rollhebel abgefragt: |
2 3 4 |
1 x 5 |
- - - |
Bedeutet: Nick-Rollhebel Links Mitte = Setting:1 Links Oben = Setting:2 usw. |
- der Faktor_I für den Hauptregler ist hinzugekommen. Im Heading-Hold-Modus sollte er vergössert werden, was Stabilität bringt |
V0.55 14.05.2007 H.Buss |
- es können nun Servos an J3,J4,J5 mit den Kanälen 5-7 gesteuert werden |
V0.56 14.05.2007 H.Buss |
- es gab Probleme mit Funken, die mehr als 8 Kanäle haben, wenn mehrere Kanäle dann auf Null waren |
- Funken, die nicht bis +-120 aussteuern können, sollten jetzt auch gehen |
V0.57 24.05.2007 H.Buss |
- Der Höhenregler kann nun auch mittels Schalter bedient werden |
- Bug im Gier-Algorithmus behoben; Schnelles Gieren fürhrte dazu, dass der MK zu weit gedreht hat |
- Kompass-Einfluss dämpfen bei Neigung |
- Man kann zwischen Kompass FIX (Richtung beim Kalibrieren) und Variabel (einstellbar per Gier) wählen |
- Der Motortest vom Kopter-Tool geht jetzt |
- Man kann den Parametersätzen einen Namen geben |
- Das Kamerasetting ist unter Setting 2 defaultmässig integriert |
V0.58 30.05.2007 H.Buss |
- Der Höhenregler-Algorithmus wird nun umgangen, wenn der Höhenreglerschalter aus ist |
V0.60 17.08.2007 H.Buss |
- "Schwindel-Bug" behoben |
- Die Poti-Werte werden jetzt auf Unterlauf (<0) überprüft |
- Poti4 zugefügt |
- Es werden jetzt 8 Kanäle ausgewertet |
- Kamera-Servo (an J7) |
- Die Settings müssen überschrieben werden |
V0.61 - V0.63 H.Buss 27.09.2007 |
- Poti 4 und Kanal 8 werden im Menü angezeigt |
- ein paar Kleinigkeiten bei den DefaultKonstanten2 bereinigt |
- Analog.c: Aktuell_ax korrigiert |
- auf 32 Debug-Kanäle erweitert |
- Loopings sind jetzt möglich und einzeln im KopterTool freischaltbar |
- leichte Anpassungen im Gier - Geschwindigkeit und Drift |
- die Hardwareversion V1.1 wird erkannt und das Programm stellt sich auf die geänderte Gyroverstärkung und die geänderten Portpins ein |
- die Software startet nach dem Einschalten schneller, weil der Luftdruckoffset schneller gefunden wird |
- die PPM-Ausgänge liegen wieder an den Pins an |
- Details an der Sensordatenverarbeitung -> es fliegt sich geringfügig anders |
- der MK ist bei wenig Gas nicht mehr so giftig -> soll das Landen vereinfachen |
- I2C-Bus läuft jetzt sicher nach einer Störung wieder an |
- Sticksignale werden präziser ausgewertet |
- Stick-Kanäle werden ans Kopter-Tool übertragen |
- Es muss die Version V1.47 des Kopter-Tool verwendet werden |
- Die Settings werden auf Default zurückgesetzt |
- am Piepen kann man die Fehlerart unterscheiden |
1. einzelnes Piepen beim Einschalten und Kalibrieren |
2. langsames Intervall mindestens 1 Sek -> Empfangsausfall |
3. schnelleres Intervall mindestens 1 Sek -> Akku |
4. sehr schnelles Intervall mindestens 1 Sek -> Kommunikation zu den Reglern gestört |