From 9a5c50d5864e9a18c856edb446ed2565037260e2 Mon Sep 17 00:00:00 2001 From: Zach Eveland Date: Mon, 24 Oct 2011 22:12:45 -0400 Subject: fixed logic bug in waiting for synch. stripped out all Serial stuff --- bootloaders/nuevo_diskloader/DiskLoader.elf.hex | 316 +++++++++++------------- bootloaders/nuevo_diskloader/DiskLoader.hex | 316 +++++++++++------------- bootloaders/nuevo_diskloader/src/CDC.cpp | 8 +- bootloaders/nuevo_diskloader/src/DiskLoader.cpp | 19 +- bootloaders/nuevo_diskloader/src/USBCore.cpp | 2 +- 5 files changed, 320 insertions(+), 341 deletions(-) (limited to 'bootloaders') diff --git a/bootloaders/nuevo_diskloader/DiskLoader.elf.hex b/bootloaders/nuevo_diskloader/DiskLoader.elf.hex index 565b0ae..7fa502a 100644 --- a/bootloaders/nuevo_diskloader/DiskLoader.elf.hex +++ b/bootloaders/nuevo_diskloader/DiskLoader.elf.hex @@ -1,15 +1,15 @@ -:10700000BEC00000E1C00000DFC00000DDC0000025 -:10701000DBC00000D9C00000D7C00000D5C0000010 -:10702000D3C00000D1C00000B2C3000024C40000DF -:10703000CBC00000C9C00000C7C00000C5C0000030 -:10704000C3C00000C1C00000BFC00000BDC0000040 -:10705000BBC00000B9C00000B7C00000B5C0000050 -:10706000B3C00000B1C00000AFC00000ADC0000060 -:10707000ABC00000A9C00000A7C00000A5C0000070 -:10708000A3C00000A1C000009FC000009DC0000080 -:107090009BC0000099C0000097C0000095C0000090 -:1070A00093C0000091C000008FC0000011241FBEDB -:1070B000CFEFDAE0DEBFCDBF56C1080B00020202FF +:10700000BDC00000E0C00000DEC00000DCC0000029 +:10701000DAC00000D8C00000D6C00000D4C0000014 +:10702000D2C00000D0C000004AC30000BCC30000B2 +:10703000CAC00000C8C00000C6C00000C4C0000034 +:10704000C2C00000C0C00000BEC00000BCC0000044 +:10705000BAC00000B8C00000B6C00000B4C0000054 +:10706000B2C00000B0C00000AEC00000ACC0000064 +:10707000AAC00000A8C00000A6C00000A4C0000074 +:10708000A2C00000A0C000009EC000009CC0000084 +:107090009AC0000098C0000096C0000094C0000094 +:1070A00092C0000090C000008EC0000011241FBEDE +:1070B000CFEFDAE0DEBFCDBFF7C0080B000202025F :1070C0000100090400000102020000052400100173 :1070D0000524010101042402060524060001070518 :1070E000810310004009040100020A0000000705A6 @@ -21,158 +21,144 @@ :107140006400750069006E006F0020004C004C0068 :1071500043001201000200000040412388000001AA :1071600001020001120100020200004041238800D8 -:1071700000010102000100C18081FE382B3C112476 -:107180001FBECFEFDAE0DEBFCDBF11E0A0E0B1E07F -:10719000E2EDFAE702C005900D92A831B107D9F7E8 -:1071A00011E0A8E1B1E001C01D92A73AB107E1F7F3 -:1071B00011E7CEE7D1E703C02297FE0184D4CA3796 -:1071C000D107D1F7D0D083C41BCFDC01809100015F -:1071D000909101018F5F9F4F61F4ED91FC911197A8 -:1071E0000480F581E02DCD010995909301018093F4 -:1071F0000001809100019091010108958EE091E0DD -:1072000090931901809318010895DF93CF930F9203 -:10721000CDB7DEB7698380910901882351F083E0FF -:10722000BE016F5F7F4F41E050E0CDD118161906C7 -:1072300014F080E090E00F90CF91DF91089583E00B -:107240009CC220910001309101018FEF2F3F380740 -:1072500039F08FEF9FEF909301018093000103C0FD -:1072600082E089D19C01C901089582E047D1282F8D -:1072700080910001909101018F5F9F4F09F02F5F76 -:10728000822F90E00895FC0180818E5F808380E8EA -:107290006AEB70E742E450E022C2FC0181819081F8 -:1072A000913A49F48132C1F480E062E071E047E054 -:1072B00050E015D20FC0913279F4803231F482E07F -:1072C00091E067E070E047D205C0823229F4828104 -:1072D0008093090181E0089580E00895FF920F9363 -:1072E0001F93CF93DF93982F8B01FF2480E76030AB -:1072F000780738F4FF24F39483E0FB018093570070 -:10730000E895C42FD0E0892F6AE171E0AE01FFD08B -:10731000FF2019F107B600FCFDCFD595C7954C2F7E -:10732000F801AAE1B1E020E031E009C08D919D9122 -:107330000C0130935700E895112432962F5F2417E3 -:10734000A8F385E0F80180935700E89507B600FCA4 -:10735000FDCF81E180935700E895DF91CF911F9198 -:107360000F91FF90089588E10FB6F8948093600024 -:10737000109260000FBE3F9A209A6E9A90E8909308 -:1073800061001092610081E885BF95BF01E005BFF3 -:1073900002E005BF769A289A479886EA91E045D29E -:1073A000789484E180939A0180E180939B01EE249C -:1073B000FF2488E191E059DF18161906D4F788E117 -:1073C00091E03FDFC82E8CEF90E7FC0124913196CD -:1073D000029644912C1511F02223B9F710929D01C9 -:1073E00010929C0150E082E06AE171E090D0F1E4FB -:1073F000CF1679F460911A016058633028F0683133 -:1074000011F064E001C063E0C62FD0E0C15FDE4848 -:1074100011C086E5C81691F480911A01803321F0DD -:107420008701DD24D3942BC080911C01C82FD0E0AC -:10743000C45FDE488701DD24D3942AC0E5E7CE1679 -:1074400031F4870123E0D22ECCE0D1E721C0F5E56D -:10745000CF1639F400911A0110911B01000F111F72 -:107460000DC084E6C81631F482E0B70140911B01DB -:1074700035DF03C0E4E7CE1629F08701DD24C3E140 -:10748000D1E706C0D0901B01E70187010D0D111D4A -:1074900088E191E0EADE18161906D4F488E191E05B -:1074A000D0DEEE24FF24809709F083CF11C04D2D4C -:1074B00050E083E8BE0187D083E46BE971E041E0EE -:1074C00050E081D0F1E5CF1609F471CF780171CF8A -:1074D00083E06AE971E041E050E075D0DD2061F3BE -:1074E000E6CFFC0104C08091F100819361506623D6 -:1074F000D1F7289884E680939F0108959FB7F89468 -:1075000087708093E9008091F2009FBF0895282F33 -:107510008091A0018823C1F057FF1AC015C0289898 -:1075200090939F018091F1008193E217F307B9F7DF -:107530004115510539F08091F200882319F48BE64A -:107540008093E800AFBF02C04FEF5FEFCA0108951C -:10755000AFB7F89427702093E9008091F200282FAC -:1075600030E0241735070CF4A901FB019B01240F1F -:10757000311D94E6DACFDF93CF930F92CDB7DEB70C -:10758000BE016F5F7F4F41E050E0C1DF019719F00E -:107590008FEF9FEF02C0898190E00F90CF91DF9134 -:1075A00008952FB7F89487708093E9008091E800E0 -:1075B00085FD02C090E004C08091F20090E4981B29 -:1075C0002FBF892F08955F926F927F928F929F9223 -:1075D000AF92BF92CF92DF92EF92FF920F931F93E1 -:1075E000CF93DF93F82E6A018091A001882319F4CC -:1075F0004FEF5FEF63C08B01EA0157E0E52EEF200C -:107600008F2D90E040E2842E912C882299223AE33B -:10761000532E20E4A22EB12CA822B92280EE682E8F -:107620008EE2782E43C08F2DBCDF282F882321F4D3 -:10763000C3010197F1F73AC090E0C817D9070CF4DD -:107640002C2FC21BD1094FB7F894E092E9008114A6 -:10765000910421F406C01092F10021502223D9F7A1 -:1076600019C0F7FC03C0F801922F10C0C801322FD7 -:1076700006C0FC010196E491E093F1003150332300 -:10768000C1F706C081918093F10091509923D1F701 -:10769000020F111D8091E80085FF05C0209729F495 -:1076A000A114B10411F05092E8004FBF209709F0E7 -:1076B000BACF769884E680939E01A601CA01DF9135 -:1076C000CF911F910F91FF90EF90DF90CF90BF90DF -:1076D000AF909F908F907F906F905F9008950F93E1 -:1076E0001F93182FFB01A091A301B091A401BA012F -:1076F0000EEF2AC017FF02C0949101C09081209123 -:10770000A1013091A2012A173B07ACF48091E80057 -:107710008570E1F38091E80082FF03C04FEF5FEFD7 -:1077200016C09093F100C90101968F739070892B58 -:1077300011F40093E8002F5F3F4F3093A201209394 -:10774000A1016150704031966115710599F6CA0129 -:107750001F910F910895CF93DF939C01EB018091CE -:10776000E80082FFFCCFC9016C2FBBDE8BEF80935A -:10777000E800CE01DF91CF9108958093E9008091D8 -:10778000F200882319F08AE38093E80008951F929D -:107790000F920FB60F9211242F933F938F938091E6 -:1077A000E1001092E100282F83FF0FC01092E90042 -:1077B00081E08093EB001092EC0082E38093ED0077 -:1077C0001092A00188E08093F00022FF26C083E0A1 -:1077D0008093E9008091F200882319F08AE3809376 -:1077E000E80080919E01882351F080919E01815094 -:1077F00080939E0180919E01882309F4769A80915E -:107800009F01882351F080919F01815080939F01B7 -:1078100080919F01882309F4289A8F913F912F919D -:107820000F900FBE0F901F9018951092A00181E04D -:107830008093D70080EA8093D80082E189BD09B4A3 -:1078400000FEFDCF80E98093D8008CE08093E200B9 -:107850001092E00008950895DF93CF930F92CDB773 -:10786000DEB71982CE0101960EDD898190E00F907E -:10787000CF91DF9108951F920F920FB60F921124AE -:10788000EF92FF921F932F933F934F935F936F93CA -:107890007F938F939F93AF93BF93EF93FF93DF9368 -:1078A000CF93CDB7DEB76197DEBFCDBF1092E900B1 -:1078B0008091E80083FFECC0CE01019668E011DE04 -:1078C00082EF8093E800998197FF05C08091E800DE -:1078D00080FFFCCF03C08EEF8093E800292F30E0BB -:1078E000C90180769070892B09F0B3C08A81882302 -:1078F00029F41092F1001092F100BFC0813009F418 -:10790000BCC0833009F4B9C0853049F48091E800E7 -:1079100080FFFCCF8B8180688093E300AEC086300F -:1079200009F06DC01C81EF80F8841230A9F5109227 -:10793000E9001092A2011092A1011092A4011092EC -:10794000A3018ADF99E0FE013996DF01292F1D92FC -:107950002A95E9F799871A8791E09E8790E8988B96 -:107960009AEF998B2091A1013091A201275F3F4F9F -:107970003C872B878D871092E9001092A20110920C -:10798000A101F092A401E092A30180E0BF0149E0CF -:1079900050E0A5DE61DF71C01092E9001092A201F3 -:1079A0001092A101F092A401E092A301113071F4B0 -:1079B00088E0E816F10411F41093A5018091A50167 -:1079C000882309F062C0E2E5F1E713C0133009F043 -:1079D00058C08B81882319F4E4E1F1E70AC08230B2 -:1079E00019F4E8E1F1E705C0813009F04AC0EAE3A3 -:1079F000F1E7449150E080E8BF0171DE3EC087307E -:107A000009F43FC0883021F481E08093F10035C053 -:107A1000893099F523703070232B99F5E7E7F1E76A -:107A200091E031E026E39093E9003093EB008491FC -:107A30008093EC002093ED009F5F3196943099F78E -:107A40008EE78093EA001092EA008B818093A00178 -:107A500014C08F8198851092E9001092A2011092B3 -:107A6000A1019093A4018093A3018D81882349F4FF -:107A7000CE01019612DC882321F08EEF8093E8007E -:107A800007C081E28093EB0003C0E4E6F1E7B1CFE9 -:107A90006196DEBFCDBFCF91DF91FF91EF91BF9196 -:107AA000AF919F918F917F916F915F914F913F9196 -:107AB0002F911F91FF90EF900F900FBE0F901F908E -:107AC0001895EE0FFF1F0590F491E02D0994F8949E -:027AD000FFCFE6 -:107AD200FFFF00E100000000000000000000353957 -:087AE200E53821391F3905398F +:1071700000010102000100C18081C33B11241FBE38 +:10718000CFEFDAE0DEBFCDBF11E0A0E0B1E0E2E09A +:10719000FAE702C005900D92A830B107D9F711E0C7 +:1071A000A8E0B1E001C01D92A539B107E1F711E7F0 +:1071B000CCE7D1E703C02297FE011DD4CA37D1071F +:1071C000D1F772D01CC41CCFFC0180818E5F8083FC +:1071D00080E86AEB70E742E450E023C2FC01818161 +:1071E0009081913A49F48132C1F480E060E071E02D +:1071F00047E050E016D20FC0913279F4803231F47A +:1072000080E091E067E070E048D205C0823229F466 +:1072100082818093070181E0089580E00895FF92C4 +:107220000F931F93CF93DF93982F8B01FF2480E759 +:107230006030780738F4FF24F39483E0FB018093F7 +:107240005700E895C42FD0E0892F68E071E0AE01C7 +:1072500000D1FF2019F107B600FCFDCFD595C795E9 +:107260004C2FF801A8E0B1E020E031E009C08D9199 +:107270009D910C0130935700E895112432962F5FB1 +:107280002417A8F385E0F80180935700E89507B626 +:1072900000FCFDCF81E180935700E895DF91CF910D +:1072A0001F910F91FF90089588E10FB6F894809395 +:1072B0006000109260000FBE3F9A209A6E9A90E88C +:1072C000909361001092610081E885BF95BF01E055 +:1072D00005BF02E005BF769A289A479884E991E0B5 +:1072E0003CD2789484E18093880180E18093890185 +:1072F00000E010E082E0A4D08823E1F382E0DDD05A +:10730000C82E8CEF90E7FC012491319602964491AF +:107310002C1511F02223B9F710928B0110928A01DB +:1073200050E082E068E071E094D0F1E4CF1679F4A7 +:10733000609108016058633028F0683111F064E012 +:1073400001C063E0C62FD0E0C15FDE4811C086E512 +:10735000C81691F480910801803321F07801DD2472 +:10736000D3942BC080910A01C82FD0E0C45FDE48BF +:107370007801DD24D3942AC0E5E7CE1631F47801F4 +:1073800023E0D22ECCE0D1E721C0F5E5CF1639F4C9 +:10739000E0900801F0900901EE0CFF1C0DC084E69E +:1073A000C81631F482E0B8014091090138DF03C00A +:1073B000E4E7CE1629F07801DD24C3E1D1E706C069 +:1073C000D0900901E8017801ED0CF11C08E813E107 +:1073D00082E036D08823F9F40A301105E1F001503B +:1073E0001040F6CF83E068E871E041E050E08DD0D6 +:1073F000DD2029F04D2D50E083E8BE0186D083E4E6 +:1074000069E871E041E050E080D0F1E5CF1609F481 +:107410006FCF87016FCF82E050D000E010E08097FF +:1074200009F068CFDFCFFC0104C08091F1008193A7 +:1074300061506623D1F7289884E680938D010895E2 +:107440009FB7F89487708093E9008091F2009FBF06 +:107450000895282F80918E018823C1F057FF1AC00C +:1074600015C0289890938D018091F1008193E217C7 +:10747000F307B9F74115510539F08091F2008823DF +:1074800019F48BE68093E800AFBF02C04FEF5FEFC7 +:10749000CA010895AFB7F89427702093E90080914E +:1074A000F200282F30E0241735070CF4A901FB0166 +:1074B0009B01240F311D94E6DACFDF93CF930F9217 +:1074C000CDB7DEB7BE016F5F7F4F41E050E0C1DF57 +:1074D000019719F08FEF9FEF02C0898190E00F9024 +:1074E000CF91DF9108952FB7F89487708093E900CA +:1074F0008091E80085FD02C090E004C08091F20018 +:1075000090E4981B2FBF892F08955F926F927F920E +:107510008F929F92AF92BF92CF92DF92EF92FF92A3 +:107520000F931F93CF93DF93F82E6A0180918E0102 +:10753000882319F44FEF5FEF63C08B01EA0157E036 +:10754000E52EEF208F2D90E040E2842E912C8822B2 +:1075500099223AE3532E20E4A22EB12CA822B9227C +:1075600080EA682E8FE0782E43C08F2DBCDF282F55 +:10757000882321F4C3010197F1F73AC090E0C817BE +:10758000D9070CF42C2FC21BD1094FB7F894E09205 +:10759000E9008114910421F406C01092F1002150F9 +:1075A0002223D9F719C0F7FC03C0F801922F10C0AD +:1075B000C801322F06C0FC010196E491E093F1006E +:1075C00031503323C1F706C081918093F10091506F +:1075D0009923D1F7020F111D8091E80085FF05C0A6 +:1075E000209729F4A114B10411F05092E8004FBF84 +:1075F000209709F0BACF769884E680938C01A60193 +:10760000CA01DF91CF911F910F91FF90EF90DF9012 +:10761000CF90BF90AF909F908F907F906F905F9032 +:1076200008950F931F93182FFB01A0919101B09122 +:107630009201BA010EEF2AC017FF02C0949101C057 +:10764000908120918F01309190012A173B07ACF473 +:107650008091E8008570E1F38091E80082FF03C02B +:107660004FEF5FEF16C09093F100C90101968F7341 +:107670009070892B11F40093E8002F5F3F4F3093F7 +:10768000900120938F016150704031966115710512 +:1076900099F6CA011F910F910895CF93DF939C0132 +:1076A000EB018091E80082FFFCCFC9016C2FBBDEAB +:1076B0008BEF8093E800CE01DF91CF9108951F9268 +:1076C0000F920FB60F9211242F933F938F938091B7 +:1076D000E1001092E100282F83FF0FC01092E90013 +:1076E00081E08093EB001092EC0082E38093ED0048 +:1076F00010928E0188E08093F00022FF26C083E084 +:107700008093E9008091F200882319F08AE3809346 +:10771000E80080918C01882351F080918C01815088 +:1077200080938C0180918C01882309F4769A809152 +:107730008D01882351F080918D01815080938D01BE +:1077400080918D01882309F4289A8F913F912F9180 +:107750000F900FBE0F901F90189510928E0181E030 +:107760008093D70080EA8093D80082E189BD09B474 +:1077700000FEFDCF80E98093D8008CE08093E2008A +:107780001092E00008950895DF93CF930F92CDB744 +:10779000DEB71982CE01019617DD898190E00F9046 +:1077A000CF91DF9108951F920F920FB60F9211247F +:1077B000EF92FF921F932F933F934F935F936F939B +:1077C0007F938F939F93AF93BF93EF93FF93DF9339 +:1077D000CF93CDB7DEB76197DEBFCDBF1092E90082 +:1077E0008091E80083FFECC0CE01019668E01BDECB +:1077F00082EF8093E800998197FF05C08091E800AF +:1078000080FFFCCF03C08EEF8093E800292F30E08B +:10781000C90180769070892B09F0B3C08A818823D2 +:1078200029F41092F1001092F100BFC0813009F4E8 +:10783000BCC0833009F4B9C0853049F48091E800B8 +:1078400080FFFCCF8B8180688093E300AEC08630E0 +:1078500009F06DC01C81EF80F8841230A9F51092F8 +:10786000E9001092900110928F01109292011092F3 +:1078700091018ADF99E0FE013996DF01292F1D92DF +:107880002A95E9F799871A8791E09E8790E8988B67 +:107890009AEF998B20918F0130919001275F3F4F94 +:1078A0003C872B878D871092E900109290011092EF +:1078B0008F01F0929201E092910180E0BF0149E0D6 +:1078C00050E0AFDE61DF71C01092E90010929001CC +:1078D00010928F01F0929201E0929101113071F4B7 +:1078E00088E0E816F10411F410939301809193015C +:1078F000882309F062C0E2E5F1E713C0133009F014 +:1079000058C08B81882319F4E4E1F1E70AC0823082 +:1079100019F4E8E1F1E705C0813009F04AC0EAE373 +:10792000F1E7449150E080E8BF017BDE3EC0873044 +:1079300009F43FC0883021F481E08093F10035C024 +:10794000893099F523703070232B99F5E7E7F1E73B +:1079500091E031E026E39093E9003093EB008491CD +:107960008093EC002093ED009F5F3196943099F75F +:107970008EE78093EA001092EA008B8180938E015B +:1079800014C08F8198851092E90010929001109296 +:107990008F0190939201809391018D81882349F406 +:1079A000CE0101961BDC882321F08EEF8093E80046 +:1079B00007C081E28093EB0003C0E4E6F1E7B1CFBA +:1079C0006196DEBFCDBFCF91DF91FF91EF91BF9167 +:1079D000AF919F918F917F916F915F914F913F9167 +:1079E0002F911F91FF90EF900F900FBE0F901F905F +:1079F0001895EE0FFF1F0590F491E02D0994F8946F +:027A0000FFCFB6 +:087A020000E10000000000009B :040000030000700089 :00000001FF diff --git a/bootloaders/nuevo_diskloader/DiskLoader.hex b/bootloaders/nuevo_diskloader/DiskLoader.hex index 565b0ae..7fa502a 100644 --- a/bootloaders/nuevo_diskloader/DiskLoader.hex +++ b/bootloaders/nuevo_diskloader/DiskLoader.hex @@ -1,15 +1,15 @@ -:10700000BEC00000E1C00000DFC00000DDC0000025 -:10701000DBC00000D9C00000D7C00000D5C0000010 -:10702000D3C00000D1C00000B2C3000024C40000DF -:10703000CBC00000C9C00000C7C00000C5C0000030 -:10704000C3C00000C1C00000BFC00000BDC0000040 -:10705000BBC00000B9C00000B7C00000B5C0000050 -:10706000B3C00000B1C00000AFC00000ADC0000060 -:10707000ABC00000A9C00000A7C00000A5C0000070 -:10708000A3C00000A1C000009FC000009DC0000080 -:107090009BC0000099C0000097C0000095C0000090 -:1070A00093C0000091C000008FC0000011241FBEDB -:1070B000CFEFDAE0DEBFCDBF56C1080B00020202FF +:10700000BDC00000E0C00000DEC00000DCC0000029 +:10701000DAC00000D8C00000D6C00000D4C0000014 +:10702000D2C00000D0C000004AC30000BCC30000B2 +:10703000CAC00000C8C00000C6C00000C4C0000034 +:10704000C2C00000C0C00000BEC00000BCC0000044 +:10705000BAC00000B8C00000B6C00000B4C0000054 +:10706000B2C00000B0C00000AEC00000ACC0000064 +:10707000AAC00000A8C00000A6C00000A4C0000074 +:10708000A2C00000A0C000009EC000009CC0000084 +:107090009AC0000098C0000096C0000094C0000094 +:1070A00092C0000090C000008EC0000011241FBEDE +:1070B000CFEFDAE0DEBFCDBFF7C0080B000202025F :1070C0000100090400000102020000052400100173 :1070D0000524010101042402060524060001070518 :1070E000810310004009040100020A0000000705A6 @@ -21,158 +21,144 @@ :107140006400750069006E006F0020004C004C0068 :1071500043001201000200000040412388000001AA :1071600001020001120100020200004041238800D8 -:1071700000010102000100C18081FE382B3C112476 -:107180001FBECFEFDAE0DEBFCDBF11E0A0E0B1E07F -:10719000E2EDFAE702C005900D92A831B107D9F7E8 -:1071A00011E0A8E1B1E001C01D92A73AB107E1F7F3 -:1071B00011E7CEE7D1E703C02297FE0184D4CA3796 -:1071C000D107D1F7D0D083C41BCFDC01809100015F -:1071D000909101018F5F9F4F61F4ED91FC911197A8 -:1071E0000480F581E02DCD010995909301018093F4 -:1071F0000001809100019091010108958EE091E0DD -:1072000090931901809318010895DF93CF930F9203 -:10721000CDB7DEB7698380910901882351F083E0FF -:10722000BE016F5F7F4F41E050E0CDD118161906C7 -:1072300014F080E090E00F90CF91DF91089583E00B -:107240009CC220910001309101018FEF2F3F380740 -:1072500039F08FEF9FEF909301018093000103C0FD -:1072600082E089D19C01C901089582E047D1282F8D -:1072700080910001909101018F5F9F4F09F02F5F76 -:10728000822F90E00895FC0180818E5F808380E8EA -:107290006AEB70E742E450E022C2FC0181819081F8 -:1072A000913A49F48132C1F480E062E071E047E054 -:1072B00050E015D20FC0913279F4803231F482E07F -:1072C00091E067E070E047D205C0823229F4828104 -:1072D0008093090181E0089580E00895FF920F9363 -:1072E0001F93CF93DF93982F8B01FF2480E76030AB -:1072F000780738F4FF24F39483E0FB018093570070 -:10730000E895C42FD0E0892F6AE171E0AE01FFD08B -:10731000FF2019F107B600FCFDCFD595C7954C2F7E -:10732000F801AAE1B1E020E031E009C08D919D9122 -:107330000C0130935700E895112432962F5F2417E3 -:10734000A8F385E0F80180935700E89507B600FCA4 -:10735000FDCF81E180935700E895DF91CF911F9198 -:107360000F91FF90089588E10FB6F8948093600024 -:10737000109260000FBE3F9A209A6E9A90E8909308 -:1073800061001092610081E885BF95BF01E005BFF3 -:1073900002E005BF769A289A479886EA91E045D29E -:1073A000789484E180939A0180E180939B01EE249C -:1073B000FF2488E191E059DF18161906D4F788E117 -:1073C00091E03FDFC82E8CEF90E7FC0124913196CD -:1073D000029644912C1511F02223B9F710929D01C9 -:1073E00010929C0150E082E06AE171E090D0F1E4FB -:1073F000CF1679F460911A016058633028F0683133 -:1074000011F064E001C063E0C62FD0E0C15FDE4848 -:1074100011C086E5C81691F480911A01803321F0DD -:107420008701DD24D3942BC080911C01C82FD0E0AC -:10743000C45FDE488701DD24D3942AC0E5E7CE1679 -:1074400031F4870123E0D22ECCE0D1E721C0F5E56D -:10745000CF1639F400911A0110911B01000F111F72 -:107460000DC084E6C81631F482E0B70140911B01DB -:1074700035DF03C0E4E7CE1629F08701DD24C3E140 -:10748000D1E706C0D0901B01E70187010D0D111D4A -:1074900088E191E0EADE18161906D4F488E191E05B -:1074A000D0DEEE24FF24809709F083CF11C04D2D4C -:1074B00050E083E8BE0187D083E46BE971E041E0EE -:1074C00050E081D0F1E5CF1609F471CF780171CF8A -:1074D00083E06AE971E041E050E075D0DD2061F3BE -:1074E000E6CFFC0104C08091F100819361506623D6 -:1074F000D1F7289884E680939F0108959FB7F89468 -:1075000087708093E9008091F2009FBF0895282F33 -:107510008091A0018823C1F057FF1AC015C0289898 -:1075200090939F018091F1008193E217F307B9F7DF -:107530004115510539F08091F200882319F48BE64A -:107540008093E800AFBF02C04FEF5FEFCA0108951C -:10755000AFB7F89427702093E9008091F200282FAC -:1075600030E0241735070CF4A901FB019B01240F1F -:10757000311D94E6DACFDF93CF930F92CDB7DEB70C -:10758000BE016F5F7F4F41E050E0C1DF019719F00E -:107590008FEF9FEF02C0898190E00F90CF91DF9134 -:1075A00008952FB7F89487708093E9008091E800E0 -:1075B00085FD02C090E004C08091F20090E4981B29 -:1075C0002FBF892F08955F926F927F928F929F9223 -:1075D000AF92BF92CF92DF92EF92FF920F931F93E1 -:1075E000CF93DF93F82E6A018091A001882319F4CC -:1075F0004FEF5FEF63C08B01EA0157E0E52EEF200C -:107600008F2D90E040E2842E912C882299223AE33B -:10761000532E20E4A22EB12CA822B92280EE682E8F -:107620008EE2782E43C08F2DBCDF282F882321F4D3 -:10763000C3010197F1F73AC090E0C817D9070CF4DD -:107640002C2FC21BD1094FB7F894E092E9008114A6 -:10765000910421F406C01092F10021502223D9F7A1 -:1076600019C0F7FC03C0F801922F10C0C801322FD7 -:1076700006C0FC010196E491E093F1003150332300 -:10768000C1F706C081918093F10091509923D1F701 -:10769000020F111D8091E80085FF05C0209729F495 -:1076A000A114B10411F05092E8004FBF209709F0E7 -:1076B000BACF769884E680939E01A601CA01DF9135 -:1076C000CF911F910F91FF90EF90DF90CF90BF90DF -:1076D000AF909F908F907F906F905F9008950F93E1 -:1076E0001F93182FFB01A091A301B091A401BA012F -:1076F0000EEF2AC017FF02C0949101C09081209123 -:10770000A1013091A2012A173B07ACF48091E80057 -:107710008570E1F38091E80082FF03C04FEF5FEFD7 -:1077200016C09093F100C90101968F739070892B58 -:1077300011F40093E8002F5F3F4F3093A201209394 -:10774000A1016150704031966115710599F6CA0129 -:107750001F910F910895CF93DF939C01EB018091CE -:10776000E80082FFFCCFC9016C2FBBDE8BEF80935A -:10777000E800CE01DF91CF9108958093E9008091D8 -:10778000F200882319F08AE38093E80008951F929D -:107790000F920FB60F9211242F933F938F938091E6 -:1077A000E1001092E100282F83FF0FC01092E90042 -:1077B00081E08093EB001092EC0082E38093ED0077 -:1077C0001092A00188E08093F00022FF26C083E0A1 -:1077D0008093E9008091F200882319F08AE3809376 -:1077E000E80080919E01882351F080919E01815094 -:1077F00080939E0180919E01882309F4769A80915E -:107800009F01882351F080919F01815080939F01B7 -:1078100080919F01882309F4289A8F913F912F919D -:107820000F900FBE0F901F9018951092A00181E04D -:107830008093D70080EA8093D80082E189BD09B4A3 -:1078400000FEFDCF80E98093D8008CE08093E200B9 -:107850001092E00008950895DF93CF930F92CDB773 -:10786000DEB71982CE0101960EDD898190E00F907E -:10787000CF91DF9108951F920F920FB60F921124AE -:10788000EF92FF921F932F933F934F935F936F93CA -:107890007F938F939F93AF93BF93EF93FF93DF9368 -:1078A000CF93CDB7DEB76197DEBFCDBF1092E900B1 -:1078B0008091E80083FFECC0CE01019668E011DE04 -:1078C00082EF8093E800998197FF05C08091E800DE -:1078D00080FFFCCF03C08EEF8093E800292F30E0BB -:1078E000C90180769070892B09F0B3C08A81882302 -:1078F00029F41092F1001092F100BFC0813009F418 -:10790000BCC0833009F4B9C0853049F48091E800E7 -:1079100080FFFCCF8B8180688093E300AEC086300F -:1079200009F06DC01C81EF80F8841230A9F5109227 -:10793000E9001092A2011092A1011092A4011092EC -:10794000A3018ADF99E0FE013996DF01292F1D92FC -:107950002A95E9F799871A8791E09E8790E8988B96 -:107960009AEF998B2091A1013091A201275F3F4F9F -:107970003C872B878D871092E9001092A20110920C -:10798000A101F092A401E092A30180E0BF0149E0CF -:1079900050E0A5DE61DF71C01092E9001092A201F3 -:1079A0001092A101F092A401E092A301113071F4B0 -:1079B00088E0E816F10411F41093A5018091A50167 -:1079C000882309F062C0E2E5F1E713C0133009F043 -:1079D00058C08B81882319F4E4E1F1E70AC08230B2 -:1079E00019F4E8E1F1E705C0813009F04AC0EAE3A3 -:1079F000F1E7449150E080E8BF0171DE3EC087307E -:107A000009F43FC0883021F481E08093F10035C053 -:107A1000893099F523703070232B99F5E7E7F1E76A -:107A200091E031E026E39093E9003093EB008491FC -:107A30008093EC002093ED009F5F3196943099F78E -:107A40008EE78093EA001092EA008B818093A00178 -:107A500014C08F8198851092E9001092A2011092B3 -:107A6000A1019093A4018093A3018D81882349F4FF -:107A7000CE01019612DC882321F08EEF8093E8007E -:107A800007C081E28093EB0003C0E4E6F1E7B1CFE9 -:107A90006196DEBFCDBFCF91DF91FF91EF91BF9196 -:107AA000AF919F918F917F916F915F914F913F9196 -:107AB0002F911F91FF90EF900F900FBE0F901F908E -:107AC0001895EE0FFF1F0590F491E02D0994F8949E -:027AD000FFCFE6 -:107AD200FFFF00E100000000000000000000353957 -:087AE200E53821391F3905398F +:1071700000010102000100C18081C33B11241FBE38 +:10718000CFEFDAE0DEBFCDBF11E0A0E0B1E0E2E09A +:10719000FAE702C005900D92A830B107D9F711E0C7 +:1071A000A8E0B1E001C01D92A539B107E1F711E7F0 +:1071B000CCE7D1E703C02297FE011DD4CA37D1071F +:1071C000D1F772D01CC41CCFFC0180818E5F8083FC +:1071D00080E86AEB70E742E450E023C2FC01818161 +:1071E0009081913A49F48132C1F480E060E071E02D +:1071F00047E050E016D20FC0913279F4803231F47A +:1072000080E091E067E070E048D205C0823229F466 +:1072100082818093070181E0089580E00895FF92C4 +:107220000F931F93CF93DF93982F8B01FF2480E759 +:107230006030780738F4FF24F39483E0FB018093F7 +:107240005700E895C42FD0E0892F68E071E0AE01C7 +:1072500000D1FF2019F107B600FCFDCFD595C795E9 +:107260004C2FF801A8E0B1E020E031E009C08D9199 +:107270009D910C0130935700E895112432962F5FB1 +:107280002417A8F385E0F80180935700E89507B626 +:1072900000FCFDCF81E180935700E895DF91CF910D +:1072A0001F910F91FF90089588E10FB6F894809395 +:1072B0006000109260000FBE3F9A209A6E9A90E88C +:1072C000909361001092610081E885BF95BF01E055 +:1072D00005BF02E005BF769A289A479884E991E0B5 +:1072E0003CD2789484E18093880180E18093890185 +:1072F00000E010E082E0A4D08823E1F382E0DDD05A +:10730000C82E8CEF90E7FC012491319602964491AF +:107310002C1511F02223B9F710928B0110928A01DB +:1073200050E082E068E071E094D0F1E4CF1679F4A7 +:10733000609108016058633028F0683111F064E012 +:1073400001C063E0C62FD0E0C15FDE4811C086E512 +:10735000C81691F480910801803321F07801DD2472 +:10736000D3942BC080910A01C82FD0E0C45FDE48BF +:107370007801DD24D3942AC0E5E7CE1631F47801F4 +:1073800023E0D22ECCE0D1E721C0F5E5CF1639F4C9 +:10739000E0900801F0900901EE0CFF1C0DC084E69E +:1073A000C81631F482E0B8014091090138DF03C00A +:1073B000E4E7CE1629F07801DD24C3E1D1E706C069 +:1073C000D0900901E8017801ED0CF11C08E813E107 +:1073D00082E036D08823F9F40A301105E1F001503B +:1073E0001040F6CF83E068E871E041E050E08DD0D6 +:1073F000DD2029F04D2D50E083E8BE0186D083E4E6 +:1074000069E871E041E050E080D0F1E5CF1609F481 +:107410006FCF87016FCF82E050D000E010E08097FF +:1074200009F068CFDFCFFC0104C08091F1008193A7 +:1074300061506623D1F7289884E680938D010895E2 +:107440009FB7F89487708093E9008091F2009FBF06 +:107450000895282F80918E018823C1F057FF1AC00C +:1074600015C0289890938D018091F1008193E217C7 +:10747000F307B9F74115510539F08091F2008823DF +:1074800019F48BE68093E800AFBF02C04FEF5FEFC7 +:10749000CA010895AFB7F89427702093E90080914E +:1074A000F200282F30E0241735070CF4A901FB0166 +:1074B0009B01240F311D94E6DACFDF93CF930F9217 +:1074C000CDB7DEB7BE016F5F7F4F41E050E0C1DF57 +:1074D000019719F08FEF9FEF02C0898190E00F9024 +:1074E000CF91DF9108952FB7F89487708093E900CA +:1074F0008091E80085FD02C090E004C08091F20018 +:1075000090E4981B2FBF892F08955F926F927F920E +:107510008F929F92AF92BF92CF92DF92EF92FF92A3 +:107520000F931F93CF93DF93F82E6A0180918E0102 +:10753000882319F44FEF5FEF63C08B01EA0157E036 +:10754000E52EEF208F2D90E040E2842E912C8822B2 +:1075500099223AE3532E20E4A22EB12CA822B9227C +:1075600080EA682E8FE0782E43C08F2DBCDF282F55 +:10757000882321F4C3010197F1F73AC090E0C817BE +:10758000D9070CF42C2FC21BD1094FB7F894E09205 +:10759000E9008114910421F406C01092F1002150F9 +:1075A0002223D9F719C0F7FC03C0F801922F10C0AD +:1075B000C801322F06C0FC010196E491E093F1006E +:1075C00031503323C1F706C081918093F10091506F +:1075D0009923D1F7020F111D8091E80085FF05C0A6 +:1075E000209729F4A114B10411F05092E8004FBF84 +:1075F000209709F0BACF769884E680938C01A60193 +:10760000CA01DF91CF911F910F91FF90EF90DF9012 +:10761000CF90BF90AF909F908F907F906F905F9032 +:1076200008950F931F93182FFB01A0919101B09122 +:107630009201BA010EEF2AC017FF02C0949101C057 +:10764000908120918F01309190012A173B07ACF473 +:107650008091E8008570E1F38091E80082FF03C02B +:107660004FEF5FEF16C09093F100C90101968F7341 +:107670009070892B11F40093E8002F5F3F4F3093F7 +:10768000900120938F016150704031966115710512 +:1076900099F6CA011F910F910895CF93DF939C0132 +:1076A000EB018091E80082FFFCCFC9016C2FBBDEAB +:1076B0008BEF8093E800CE01DF91CF9108951F9268 +:1076C0000F920FB60F9211242F933F938F938091B7 +:1076D000E1001092E100282F83FF0FC01092E90013 +:1076E00081E08093EB001092EC0082E38093ED0048 +:1076F00010928E0188E08093F00022FF26C083E084 +:107700008093E9008091F200882319F08AE3809346 +:10771000E80080918C01882351F080918C01815088 +:1077200080938C0180918C01882309F4769A809152 +:107730008D01882351F080918D01815080938D01BE +:1077400080918D01882309F4289A8F913F912F9180 +:107750000F900FBE0F901F90189510928E0181E030 +:107760008093D70080EA8093D80082E189BD09B474 +:1077700000FEFDCF80E98093D8008CE08093E2008A +:107780001092E00008950895DF93CF930F92CDB744 +:10779000DEB71982CE01019617DD898190E00F9046 +:1077A000CF91DF9108951F920F920FB60F9211247F +:1077B000EF92FF921F932F933F934F935F936F939B +:1077C0007F938F939F93AF93BF93EF93FF93DF9339 +:1077D000CF93CDB7DEB76197DEBFCDBF1092E90082 +:1077E0008091E80083FFECC0CE01019668E01BDECB +:1077F00082EF8093E800998197FF05C08091E800AF +:1078000080FFFCCF03C08EEF8093E800292F30E08B +:10781000C90180769070892B09F0B3C08A818823D2 +:1078200029F41092F1001092F100BFC0813009F4E8 +:10783000BCC0833009F4B9C0853049F48091E800B8 +:1078400080FFFCCF8B8180688093E300AEC08630E0 +:1078500009F06DC01C81EF80F8841230A9F51092F8 +:10786000E9001092900110928F01109292011092F3 +:1078700091018ADF99E0FE013996DF01292F1D92DF +:107880002A95E9F799871A8791E09E8790E8988B67 +:107890009AEF998B20918F0130919001275F3F4F94 +:1078A0003C872B878D871092E900109290011092EF +:1078B0008F01F0929201E092910180E0BF0149E0D6 +:1078C00050E0AFDE61DF71C01092E90010929001CC +:1078D00010928F01F0929201E0929101113071F4B7 +:1078E00088E0E816F10411F410939301809193015C +:1078F000882309F062C0E2E5F1E713C0133009F014 +:1079000058C08B81882319F4E4E1F1E70AC0823082 +:1079100019F4E8E1F1E705C0813009F04AC0EAE373 +:10792000F1E7449150E080E8BF017BDE3EC0873044 +:1079300009F43FC0883021F481E08093F10035C024 +:10794000893099F523703070232B99F5E7E7F1E73B +:1079500091E031E026E39093E9003093EB008491CD +:107960008093EC002093ED009F5F3196943099F75F +:107970008EE78093EA001092EA008B8180938E015B +:1079800014C08F8198851092E90010929001109296 +:107990008F0190939201809391018D81882349F406 +:1079A000CE0101961BDC882321F08EEF8093E80046 +:1079B00007C081E28093EB0003C0E4E6F1E7B1CFBA +:1079C0006196DEBFCDBFCF91DF91FF91EF91BF9167 +:1079D000AF919F918F917F916F915F914F913F9167 +:1079E0002F911F91FF90EF900F900FBE0F901F905F +:1079F0001895EE0FFF1F0590F491E02D0994F8946F +:027A0000FFCFB6 +:087A020000E10000000000009B :040000030000700089 :00000001FF diff --git a/bootloaders/nuevo_diskloader/src/CDC.cpp b/bootloaders/nuevo_diskloader/src/CDC.cpp index 8bc4b51..cc798b4 100644 --- a/bootloaders/nuevo_diskloader/src/CDC.cpp +++ b/bootloaders/nuevo_diskloader/src/CDC.cpp @@ -101,7 +101,7 @@ bool WEAK CDC_Setup(Setup& setup) return false; } - +/* int _serialPeek = -1; void Serial_::begin(uint16_t baud_count) { @@ -149,11 +149,6 @@ void Serial_::flush(void) size_t Serial_::write(uint8_t c) { - /* only try to send bytes if the high-level CDC connection itself - is open (not just the pipe) - the OS should set lineState when the port - is opened and clear lineState when the port is closed. - bytes sent before the user opens the connection or after - the connection is closed are lost - just like with a UART. */ // TODO - ZE - check behavior on different OSes and test what happens if an // open connection isn't broken cleanly (cable is yanked out, host dies @@ -172,6 +167,7 @@ size_t Serial_::write(uint8_t c) } Serial_ Serial; +*/ #endif #endif /* if defined(USBCON) */ \ No newline at end of file diff --git a/bootloaders/nuevo_diskloader/src/DiskLoader.cpp b/bootloaders/nuevo_diskloader/src/DiskLoader.cpp index 724a130..cbb709b 100644 --- a/bootloaders/nuevo_diskloader/src/DiskLoader.cpp +++ b/bootloaders/nuevo_diskloader/src/DiskLoader.cpp @@ -3,6 +3,7 @@ */ #include "Platform.h" +#include "USBCore.h" //extern "C" void entrypoint(void) __attribute__ ((naked)) __attribute__ ((section (".vectors"))); @@ -123,9 +124,12 @@ int main() u16 address = 0; for (;;) { - while (Serial.available() < 1) - ; - u8 cmd = Serial.read(); +// while (Serial.available() < 1) +// ; +// u8 cmd = Serial.read(); + while (!USB_Available(CDC_RX)) + ; + u8 cmd = USB_Recv(CDC_RX); // Read packet contents u8 len; @@ -180,8 +184,15 @@ int main() } // Check sync - if (Serial.available() > 0 && Serial.read() != ' ') +// if (Serial.available() > 0 && Serial.read() != ' ') +// break; +// if (USB_Available(CDC_RX) && USB_Recv(CDC_RX) != ' ') + u16 countdown = 5000; + while (!USB_Available(CDC_RX) && countdown-- > 10) + ; + if (USB_Recv(CDC_RX) != ' ') break; + USB_Send(CDC_TX, &_inSync, 1); if (send) diff --git a/bootloaders/nuevo_diskloader/src/USBCore.cpp b/bootloaders/nuevo_diskloader/src/USBCore.cpp index abb529a..cfcef73 100644 --- a/bootloaders/nuevo_diskloader/src/USBCore.cpp +++ b/bootloaders/nuevo_diskloader/src/USBCore.cpp @@ -273,7 +273,7 @@ int USB_Send(u8 ep, const void* d, int len) // if (!(--timeout)) // return -1; // delay(1); - _delay_ms(3); + _delay_ms(1); continue; } -- cgit v1.2.3-18-g5258