![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
2011
Diff: main.cpp
- Revision:
- 201:efc3a92cc6be
- Parent:
- 200:ebc69d6ee6f1
- Child:
- 202:6fe9886cdb6e
diff -r ebc69d6ee6f1 -r efc3a92cc6be main.cpp --- a/main.cpp Wed Dec 23 00:39:47 2020 +0000 +++ b/main.cpp Wed Dec 23 04:36:24 2020 +0000 @@ -1,4 +1,4 @@ -//201223_1 +//201223_2 #include "mbed.h" #include "FastPWM.h" #include "INIT_HW.h" @@ -199,72 +199,72 @@ float input_NN[num_input] = { 0.0f }; const float h1[num_input][16] = { - {-1.6000940799713135f,0.4413917660713196f,0.12903714179992676f,-0.07903441786766052f,-1.8977726697921753f,1.8713637590408325f,-0.17472904920578003f,0.4568611681461334f,-0.43561747670173645f,-0.04615814611315727f,-0.23684236407279968f,-1.5037455558776855f,-0.2676747143268585f,-0.6216555237770081f,-0.2571594715118408f,-0.4336307942867279f}, -{-0.8367072343826294f,0.09323202818632126f,-0.3927857577800751f,-0.2727188766002655f,-1.0405902862548828f,0.8998438119888306f,-0.4054011106491089f,0.44874632358551025f,-0.29669591784477234f,0.21184058487415314f,-0.2736198306083679f,-0.8792054653167725f,0.23191256821155548f,-0.8017642498016357f,-0.20967772603034973f,-0.9694083333015442f}, -{-0.8188105821609497f,0.49548420310020447f,0.36391180753707886f,-0.5226353406906128f,-0.6585426330566406f,0.8799821138381958f,0.2872133255004883f,0.012798400595784187f,-0.41921380162239075f,0.2234516143798828f,-0.3474748432636261f,-0.5087661147117615f,-0.00637056166306138f,-0.18617482483386993f,0.05590221285820007f,-0.8025757670402527f}, -{-0.6304765939712524f,0.6922854781150818f,0.39742106199264526f,0.24299956858158112f,-0.42302995920181274f,0.14712309837341309f,-0.11584559082984924f,-0.5310759544372559f,-0.27385860681533813f,0.3663768470287323f,0.09638378769159317f,0.29256293177604675f,-0.16855108737945557f,-0.18148168921470642f,-0.2961459457874298f,0.8457931876182556f}, -{0.7473434209823608f,0.48988762497901917f,-0.0051451027393341064f,0.3333152234554291f,0.5788547396659851f,-0.6460171937942505f,0.1294034719467163f,-0.9815593957901001f,-0.3184085786342621f,0.19254086911678314f,0.34836387634277344f,0.49276548624038696f,-0.07216952741146088f,0.27343443036079407f,-0.3865056037902832f,1.4092313051223755f}, -{3.2342982292175293f,-2.2555158138275146f,0.21773302555084229f,0.5652960538864136f,3.146817207336426f,-3.1406891345977783f,0.16514194011688232f,0.6139293909072876f,-0.4235992729663849f,0.21656234562397003f,-0.24712057411670685f,1.274764895439148f,-0.2688344120979309f,1.1950470209121704f,-0.4132833778858185f,-0.059984441846609116f}, -{-0.6526948809623718f,0.7561483383178711f,-0.2501986622810364f,-0.7059148550033569f,-0.7783506512641907f,0.33273711800575256f,0.06014183163642883f,-4.296197891235352f,0.15086668729782104f,-0.12566223740577698f,0.1482049971818924f,0.7200766205787659f,-0.17589396238327026f,-0.14634668827056885f,-0.15618428587913513f,4.646012783050537f}, -{-0.7106614112854004f,-0.292780339717865f,-0.26619744300842285f,0.1277981847524643f,-0.9086422920227051f,0.2727634906768799f,-0.17925891280174255f,-2.5595145225524902f,-0.2821522653102875f,-0.020468801259994507f,0.1025993749499321f,0.01748223975300789f,0.36828503012657166f,0.025631556287407875f,0.04303058981895447f,1.733962059020996f}, -{0.9920234084129333f,-1.627883791923523f,0.10248100757598877f,-0.08735460788011551f,0.6591731309890747f,-0.48275211453437805f,-0.07246989011764526f,0.49826139211654663f,-0.6757456660270691f,0.2720978260040283f,-0.29995009303092957f,0.6254252791404724f,0.22595258057117462f,1.0093032121658325f,-0.30555272102355957f,-3.7689568996429443f}, -{0.14623138308525085f,-1.3082497119903564f,0.18462657928466797f,0.06593218445777893f,0.38641560077667236f,0.006398537661880255f,-0.2990540862083435f,0.5669264197349548f,-0.25464093685150146f,-0.5164272785186768f,-0.010852855630218983f,-0.6049553751945496f,0.36904722452163696f,0.27233806252479553f,0.3484981060028076f,-2.143152952194214f}, -{0.26631736755371094f,-0.37726837396621704f,0.37182438373565674f,0.2574600577354431f,-0.09127864241600037f,-0.01836557500064373f,-0.20339298248291016f,0.23786002397537231f,-0.49957215785980225f,-0.008945263922214508f,0.3458111584186554f,-0.824551522731781f,-0.06989830732345581f,0.1074192151427269f,0.26688337326049805f,-0.8953605890274048f}, -{-0.23877182602882385f,-0.7098087072372437f,-0.40320003032684326f,-0.1078604906797409f,0.28780120611190796f,-0.42413681745529175f,0.1533789038658142f,0.40164631605148315f,-0.1681622713804245f,0.16031795740127563f,-0.4167521595954895f,-0.43077829480171204f,0.1412402093410492f,0.07915178686380386f,0.10493969917297363f,-0.07492798566818237f}, -{-0.03229803964495659f,-0.42042604088783264f,0.19847965240478516f,-0.0030563066247850657f,0.36559855937957764f,-0.1463041454553604f,-0.2404318004846573f,0.20067740976810455f,-0.1734953671693802f,-0.2558341920375824f,-0.1115814819931984f,-0.7943522334098816f,0.08852691203355789f,0.1106438934803009f,-0.22268100082874298f,-0.1786385029554367f}, -{-0.11297377943992615f,-0.43093106150627136f,0.4127817749977112f,-0.24888765811920166f,-0.21446679532527924f,-0.5084688663482666f,-0.32001304626464844f,0.04496301710605621f,-0.12302793562412262f,-0.3023318648338318f,-0.19743306934833527f,-0.7400186061859131f,-0.3162824809551239f,0.03880959749221802f,0.0479682981967926f,-0.08672763407230377f}, -{-0.02818325348198414f,-0.06082405894994736f,0.20282304286956787f,-0.12476225942373276f,0.10320129990577698f,-0.1304563730955124f,0.04202890396118164f,0.21194368600845337f,0.32223421335220337f,-0.0071917143650352955f,-0.28180214762687683f,-1.0684038400650024f,0.09998573362827301f,-0.12126590311527252f,0.0668090283870697f,-0.012993170879781246f}, -{-0.005457713268697262f,-0.446575790643692f,-0.40439701080322266f,-0.2776923179626465f,-0.21002432703971863f,-0.2032385915517807f,-0.15568238496780396f,-0.06614420562982559f,0.19860975444316864f,-0.10510893166065216f,-0.4762294590473175f,-0.7791360020637512f,-0.27474963665008545f,-0.020535530522465706f,-0.08245879411697388f,0.022347593680024147f}, -{-0.11706838756799698f,-0.6494715213775635f,0.16706281900405884f,-0.1073165163397789f,-0.16269126534461975f,-0.41736364364624023f,-0.041414469480514526f,0.182882621884346f,-0.049576375633478165f,-0.01950126886367798f,-0.355907678604126f,-0.59775710105896f,0.10836437344551086f,0.30783337354660034f,0.29427415132522583f,0.02123108133673668f}, + {-1.3218942880630493f,-0.36400434374809265f,0.12903714179992676f,0.429623544216156f,-1.6577956676483154f,1.7033133506774902f,-0.17472904920578003f,-0.2851046621799469f,-0.49116143584251404f,0.06607223302125931f,0.3375219702720642f,-2.2524662017822266f,-0.27079522609710693f,-0.762893795967102f,-0.2571594715118408f,1.4109240770339966f}, +{-0.37324637174606323f,-0.15218985080718994f,-0.3927857577800751f,0.007113985251635313f,-0.3063763976097107f,0.9829694032669067f,-0.4054011106491089f,-0.31343314051628113f,-0.219583198428154f,0.2695960998535156f,-0.5558209419250488f,-1.282995581626892f,0.2314668595790863f,-1.249930739402771f,-0.20967772603034973f,0.5141465663909912f}, +{-0.6641733050346375f,0.017473289743065834f,0.36391180753707886f,-0.4323294460773468f,-0.08410172164440155f,1.215465784072876f,0.2872133255004883f,-0.043526541441679f,-0.243999183177948f,0.22554270923137665f,-0.44232791662216187f,-1.150320053100586f,-0.0057098641991615295f,-0.04272075369954109f,0.05590221285820007f,0.32508206367492676f}, +{-1.0940684080123901f,-0.04530835524201393f,0.39742106199264526f,0.1436801254749298f,-0.6349416375160217f,0.4820998013019562f,-0.11584559082984924f,0.30921149253845215f,-0.000982354860752821f,0.3077179789543152f,0.878911018371582f,-0.22050485014915466f,-0.16739247739315033f,0.9827160835266113f,-0.2961459457874298f,0.920122504234314f}, +{-0.06578315794467926f,0.3108767569065094f,-0.0051451027393341064f,-0.02737285941839218f,-0.3175713121891022f,-0.6044548153877258f,0.1294034719467163f,0.07160712033510208f,0.0824594646692276f,0.0623602457344532f,1.4683424234390259f,0.9879506230354309f,-0.07084126025438309f,1.5485845804214478f,-0.3865056037902832f,-0.10284630954265594f}, +{3.439326763153076f,-0.08953062444925308f,0.21773302555084229f,-0.20206354558467865f,3.1267402172088623f,-3.7185111045837402f,0.16514194011688232f,-0.02496114745736122f,0.19640423357486725f,-0.0020644422620534897f,-1.5591723918914795f,3.902881622314453f,-0.2675211429595947f,-0.4959312081336975f,-0.4132833778858185f,-3.3079867362976074f}, +{-1.1197727918624878f,-0.5500129461288452f,-0.2501986622810364f,-0.2799862027168274f,-2.3328442573547363f,-0.132772758603096f,0.06014183163642883f,-1.004108190536499f,0.15053577721118927f,0.2857603430747986f,2.9658493995666504f,1.8222824335098267f,-0.1866893470287323f,5.238436698913574f,-0.15618428587913513f,0.5511018633842468f}, +{-0.9798851609230042f,-0.703582227230072f,-0.26619744300842285f,-0.0006682495004497468f,-1.6165897846221924f,0.380368709564209f,-0.17925891280174255f,-0.7800179719924927f,-0.15784938633441925f,0.15170113742351532f,0.36156779527664185f,-0.5079174637794495f,0.3572063446044922f,2.8821215629577637f,0.04303058981895447f,0.9579430818557739f}, +{1.7867474555969238f,-0.0848393663764f,0.10248100757598877f,-0.764881432056427f,1.6779911518096924f,0.12515445053577423f,-0.07246989011764526f,-0.5425961017608643f,-0.43091732263565063f,0.23076780140399933f,-3.556222915649414f,-0.45602038502693176f,0.2150629162788391f,-0.22613663971424103f,-0.30555272102355957f,-1.1970525979995728f}, +{0.49247217178344727f,-0.6100321412086487f,0.18462657928466797f,-0.44132569432258606f,0.5540245771408081f,0.11097308248281479f,-0.2990540862083435f,-0.12513786554336548f,-0.21949408948421478f,-0.6120793223381042f,-1.7016773223876953f,-1.0618832111358643f,0.3581237494945526f,-0.3369358777999878f,0.3484981060028076f,-0.646379828453064f}, +{0.4998452067375183f,-0.23967741429805756f,0.37182438373565674f,0.11048014461994171f,-0.176174134016037f,-0.18318013846874237f,-0.20339298248291016f,-0.03489489480853081f,-0.6619229912757874f,-0.06554030627012253f,-0.3575388193130493f,-0.5891056656837463f,-0.08014930039644241f,-0.16254858672618866f,0.26688337326049805f,-0.549512505531311f}, +{-0.16863179206848145f,-0.63383549451828f,-0.40320003032684326f,-0.06436152756214142f,0.10193628072738647f,-0.42881327867507935f,0.1533789038658142f,0.3290553092956543f,-0.33869749307632446f,0.16060978174209595f,-0.6078652143478394f,0.07535827159881592f,0.13159756362438202f,-0.25955528020858765f,0.10493969917297363f,-0.3826476037502289f}, +{-0.02708348259329796f,-0.2554214298725128f,0.19847965240478516f,0.11599287390708923f,0.21222886443138123f,-0.11548527330160141f,-0.2404318004846573f,0.09940898418426514f,-0.2991648018360138f,-0.22267135977745056f,-0.10326461493968964f,-0.27013441920280457f,0.07888800650835037f,-0.220597505569458f,-0.22268100082874298f,-0.5450948476791382f}, +{-0.08554086834192276f,-0.0048485384322702885f,0.4127817749977112f,-0.10780080407857895f,-0.15764707326889038f,-0.468060702085495f,-0.32001304626464844f,-0.35388854146003723f,-0.2101491242647171f,-0.26073700189590454f,-0.2794083058834076f,0.0009492248645983636f,-0.32617586851119995f,-0.23431988060474396f,0.0479682981967926f,-0.13342662155628204f}, +{-0.010516862384974957f,0.16337159276008606f,0.20282304286956787f,0.10361315310001373f,0.23695318400859833f,-0.28938424587249756f,0.04202890396118164f,0.18139049410820007f,0.21247349679470062f,0.04262121394276619f,-0.15076512098312378f,-0.23182213306427002f,0.09068387746810913f,-0.10250203311443329f,0.0668090283870697f,0.147233784198761f}, +{-0.024800969287753105f,-0.18882757425308228f,-0.40439701080322266f,-0.0288613922894001f,0.08520511537790298f,-0.33271586894989014f,-0.15568238496780396f,-0.1499001532793045f,0.09826154261827469f,-0.050523608922958374f,-0.705298662185669f,0.015389705076813698f,-0.2764745354652405f,-0.10522280633449554f,-0.08245879411697388f,0.11431360244750977f}, +{-0.20605795085430145f,-0.06449012458324432f,0.16706281900405884f,0.21528883278369904f,0.2196291834115982f,-0.678229808807373f,-0.041414469480514526f,-0.17858709394931793f,-0.20013731718063354f,0.05195881053805351f,-1.3081425428390503f,-0.11665066331624985f,0.10795028507709503f,-0.07690823823213577f,0.29427415132522583f,0.2846755087375641f}, }; const float h2[16][16] = { - {-3.323141574859619f,2.0404324531555176f,-0.06966331601142883f,1.7146148681640625f,-0.21907491981983185f,0.3013889193534851f,-0.20208165049552917f,0.0904630720615387f,-0.43008196353912354f,-0.1415480375289917f,1.703560709953308f,-1.0790513753890991f,0.12968102097511292f,-4.26299524307251f,-0.03616251423954964f,1.0661470890045166f}, -{0.12045703083276749f,0.15307354927062988f,0.057057321071624756f,3.0073626041412354f,-0.35503754019737244f,-1.694530725479126f,-0.34237051010131836f,-0.2990124225616455f,-0.33757925033569336f,0.2895788848400116f,-1.596266746520996f,-0.9465551376342773f,0.33698758482933044f,1.5713340044021606f,0.2106013149023056f,0.14802111685276031f}, + {1.086565613746643f,2.574704647064209f,-0.06966331601142883f,1.6805508136749268f,-0.21907491981983185f,2.837353229522705f,0.04810171574354172f,0.030697785317897797f,-0.43008196353912354f,-0.1415480375289917f,0.5063120126724243f,-1.9408607482910156f,0.022154537960886955f,-3.385542154312134f,2.279616594314575f,-0.044693201780319214f}, +{-0.37410521507263184f,-0.46174633502960205f,0.057057321071624756f,0.049985624849796295f,-0.35503754019737244f,-0.4283068776130676f,-0.36380279064178467f,-0.35795170068740845f,-0.33757925033569336f,0.2895788848400116f,-1.1613237857818604f,-0.08905521780252457f,0.1978856921195984f,0.06828687340021133f,-0.024457667022943497f,-0.5562209486961365f}, {-0.22745239734649658f,0.003037691116333008f,-0.061119019985198975f,0.35696902871131897f,0.05568113923072815f,0.011741191148757935f,-0.20225946605205536f,-0.08465918898582458f,0.3489862382411957f,0.0687277615070343f,0.31964078545570374f,0.3004753887653351f,0.36063823103904724f,-0.42892736196517944f,0.08652284741401672f,0.027493387460708618f}, -{-0.0038494274485856295f,-0.27630358934402466f,-0.2894435524940491f,0.4252559542655945f,0.08946844935417175f,0.27233457565307617f,-0.3439287841320038f,0.4122363030910492f,0.26211628317832947f,0.2953031361103058f,0.2075938880443573f,0.2481931746006012f,-0.404754102230072f,-0.39094415307044983f,0.12583167850971222f,0.12181642651557922f}, -{-0.8256309032440186f,1.8575127124786377f,-0.25313520431518555f,0.03169454261660576f,0.036378175020217896f,0.14327585697174072f,-0.7250795960426331f,-0.08570799231529236f,-0.024399548768997192f,-0.39465832710266113f,-0.36996984481811523f,-1.1260812282562256f,0.10077962279319763f,-1.170457363128662f,-0.640777051448822f,0.3631480038166046f}, -{1.3197550773620605f,-1.6532154083251953f,-0.3519742488861084f,-0.4759509563446045f,-0.3015052080154419f,-0.37989047169685364f,-1.0408955812454224f,-0.019414573907852173f,-0.23047015070915222f,0.3579089343547821f,-0.4645023047924042f,-0.7267597317695618f,-0.20959392189979553f,-0.8655065298080444f,-0.023840362206101418f,-0.2557324171066284f}, +{0.01423916220664978f,-0.38853248953819275f,-0.2894435524940491f,0.3727268874645233f,0.08946844935417175f,0.10421331971883774f,-0.23805072903633118f,0.3510231077671051f,0.26211628317832947f,0.2953031361103058f,-0.5028022527694702f,0.19459620118141174f,-0.5438413023948669f,-0.16673438251018524f,0.3145257532596588f,0.01681516319513321f}, +{2.0800623893737793f,1.432834267616272f,-0.25313520431518555f,-0.016256675124168396f,0.036378175020217896f,0.8040815591812134f,-0.5962198376655579f,-0.14559465646743774f,-0.024399548768997192f,-0.39465832710266113f,2.0540409088134766f,-2.2457785606384277f,-0.03767414391040802f,-1.5023373365402222f,-4.233590602874756f,-1.2050756216049194f}, +{0.6775730848312378f,2.3938848972320557f,-0.3519742488861084f,-1.6996997594833374f,-0.3015052080154419f,-0.7195495367050171f,-0.45002612471580505f,-0.07942326366901398f,-0.23047015070915222f,0.3579089343547821f,2.074578046798706f,1.2932076454162598f,-0.34661057591438293f,-0.16136223077774048f,-0.6242503523826599f,-2.459754228591919f}, {-0.1828227937221527f,-0.02554568648338318f,-0.3260969817638397f,0.08422836661338806f,-0.38453540205955505f,-0.25432005524635315f,0.285016268491745f,0.12387624382972717f,-0.0982072651386261f,0.13111665844917297f,-0.03692615032196045f,-0.32796353101730347f,-0.21546880900859833f,0.049302369356155396f,-0.27088475227355957f,-0.4124959409236908f}, -{-0.07586349546909332f,-0.36089158058166504f,0.33083590865135193f,-0.2909453213214874f,-0.14358049631118774f,1.0950231552124023f,-0.025492865592241287f,-0.3003333508968353f,0.2600560486316681f,-0.37898191809654236f,0.6435545086860657f,-0.5071706771850586f,-0.31673234701156616f,0.11079536378383636f,-11.455972671508789f,0.5229361057281494f}, -{0.004702992737293243f,-0.1820937544107437f,-0.11379697918891907f,0.14139454066753387f,0.041274964809417725f,-0.14186520874500275f,-0.10284432768821716f,0.0019084513187408447f,0.06103590130805969f,-0.38046833872795105f,0.3429935574531555f,-0.34765779972076416f,-0.37024784088134766f,0.1993687003850937f,-0.2297692447900772f,-0.23237699270248413f}, -{-0.34216949343681335f,0.23496045172214508f,-0.13502129912376404f,0.08847349882125854f,0.12987366318702698f,0.14208538830280304f,0.2711336314678192f,-0.3632148504257202f,-0.13619378209114075f,0.16938945651054382f,0.2009814977645874f,0.44322916865348816f,0.3811538517475128f,-0.24470730125904083f,0.04349624365568161f,-0.24874821305274963f}, -{-0.28599539399147034f,0.0020868044812232256f,0.0457797646522522f,-0.3547317385673523f,-0.03321319818496704f,-0.42137426137924194f,0.17873415350914001f,-0.20421427488327026f,-0.050184011459350586f,0.12480869889259338f,-0.2116698920726776f,0.3545852601528168f,-0.3647043704986572f,0.40816983580589294f,-0.4018280804157257f,-0.27432969212532043f}, -{0.1522299200296402f,-0.45329317450523376f,0.3954955041408539f,-0.48470574617385864f,0.0033026933670043945f,0.572025716304779f,-0.31212282180786133f,-0.11795541644096375f,0.3487861454486847f,-0.32520344853401184f,-3.3134469985961914f,-0.530846357345581f,0.0820283591747284f,-2.0381298065185547f,1.0461171865463257f,0.4835590124130249f}, -{-0.2670588493347168f,-0.21156641840934753f,-0.15798500180244446f,0.38131895661354065f,-0.37393757700920105f,0.3658103048801422f,0.11292675137519836f,-0.2947862446308136f,-0.3764709532260895f,0.2424570620059967f,-0.10874747484922409f,-0.2837170362472534f,0.41839322447776794f,-0.016431119292974472f,-0.1284826099872589f,0.10878776758909225f}, -{-0.08318141847848892f,0.9871321320533752f,-0.2018718123435974f,-1.6108821630477905f,0.07545611262321472f,0.18611471354961395f,-0.43937158584594727f,-0.21416273713111877f,-0.24509364366531372f,0.19522181153297424f,-0.010126939043402672f,-0.5335819721221924f,-0.16718891263008118f,-1.5700724124908447f,0.43778514862060547f,-0.32085344195365906f}, +{0.5051438808441162f,0.4051232635974884f,0.33083590865135193f,-0.27685779333114624f,-0.14358049631118774f,-0.4349077343940735f,-0.09043094515800476f,-0.32793861627578735f,0.2600560486316681f,-0.37898191809654236f,-1.0842820405960083f,-0.38802140951156616f,-0.31673234701156616f,0.0956958457827568f,0.14717528223991394f,0.30060118436813354f}, +{-0.42268261313438416f,0.06737900525331497f,-0.11379697918891907f,0.04332885146141052f,0.041274964809417725f,-0.6803827881813049f,-0.10284432768821716f,-0.05322534218430519f,0.06103590130805969f,-0.38046833872795105f,-0.4098280668258667f,0.1557205766439438f,-0.37024784088134766f,-0.12674230337142944f,-0.12822191417217255f,-0.49499791860580444f}, +{-0.08738718181848526f,0.28344640135765076f,-0.13502129912376404f,0.1009710505604744f,0.12987366318702698f,0.11979040503501892f,0.2711336314678192f,-0.3837684988975525f,-0.13619378209114075f,0.16938945651054382f,0.25600337982177734f,0.20644976198673248f,0.2439122498035431f,-0.33253055810928345f,-0.02116083726286888f,-0.19732771813869476f}, +{0.15024028718471527f,-0.3313325047492981f,0.0457797646522522f,-0.013095580972731113f,-0.03321319818496704f,-0.3155671954154968f,0.17873415350914001f,-0.20421427488327026f,-0.050184011459350586f,0.12480869889259338f,-0.8987048268318176f,-0.39230379462242126f,-0.46108195185661316f,-0.22425983846187592f,-0.17279477417469025f,-0.08967062085866928f}, +{1.181969404220581f,-2.0675883293151855f,0.3954955041408539f,3.6613519191741943f,0.0033026933670043945f,1.4220753908157349f,-0.42960718274116516f,-0.17812912166118622f,0.3487861454486847f,-0.32520344853401184f,-2.81772518157959f,1.658347487449646f,-0.059010960161685944f,-0.055940140038728714f,1.9505656957626343f,-1.9203261137008667f}, +{-0.2699771523475647f,-0.22843177616596222f,-0.15798500180244446f,0.35002923011779785f,-0.37393757700920105f,0.35887888073921204f,0.11292675137519836f,-0.2947862446308136f,-0.3764709532260895f,0.2424570620059967f,-0.12342590093612671f,-0.2837170362472534f,0.41839322447776794f,0.0017942850245162845f,-0.11156019568443298f,0.08838236331939697f}, +{-3.942028522491455f,-3.311384439468384f,-0.2018718123435974f,0.14251072704792023f,0.07545611262321472f,-0.46971479058265686f,-0.27744850516319275f,-0.2663668394088745f,-0.24509364366531372f,0.19522181153297424f,-10.485258102416992f,0.45670536160469055f,-0.3057396411895752f,-0.43390122056007385f,-1.0128750801086426f,-0.2547776699066162f}, {0.4138670265674591f,0.1604653298854828f,0.056746453046798706f,0.036025404930114746f,0.3228367865085602f,-0.07083973288536072f,0.018455177545547485f,0.0059362053871154785f,0.40515169501304626f,0.014240056276321411f,-0.07738298177719116f,0.1407785713672638f,-0.13024571537971497f,-0.29546058177948f,-0.11976784467697144f,-0.35825538635253906f}, -{-0.7150428295135498f,1.2618980407714844f,0.12081471085548401f,0.5926679968833923f,0.29976895451545715f,-1.5232646465301514f,-0.25536221265792847f,0.31089308857917786f,-0.3893685042858124f,-0.02222958207130432f,-1.6488481760025024f,-0.8796235918998718f,-0.19991017878055573f,1.0744037628173828f,0.49341896176338196f,-2.339517593383789f}, +{0.7931989431381226f,0.7419624924659729f,0.12081471085548401f,-0.7267265319824219f,0.29976895451545715f,-1.240850567817688f,-0.2380465716123581f,0.250751256942749f,-0.3893685042858124f,-0.02222958207130432f,-0.8707955479621887f,0.12276076525449753f,-0.3236342966556549f,0.46684637665748596f,0.5395627617835999f,-0.8622570633888245f}, }; const float h3[16][16] = { - {-0.36079341173171997f,-4.516791343688965f,0.9862267971038818f,-0.4074249267578125f,-1.7838587760925293f,1.4453092813491821f,0.3332441747188568f,0.36921602487564087f,-0.3300304710865021f,-0.19002185761928558f,-0.40770405530929565f,0.4001283347606659f,2.8152735233306885f,-1.6125714778900146f,4.618896961212158f,0.12741845846176147f}, -{0.047732532024383545f,-0.34105879068374634f,0.20525789260864258f,-0.2253294587135315f,0.3607877194881439f,0.141396164894104f,-0.3198729455471039f,-0.08264346420764923f,0.07495583593845367f,-0.02900463528931141f,0.32022908329963684f,-0.5149437785148621f,-1.6438157558441162f,-1.3210893869400024f,-2.072963237762451f,-0.2941063344478607f}, + {-0.36079341173171997f,-0.9896907210350037f,2.566742181777954f,1.1174317598342896f,-2.1639771461486816f,-0.3735062777996063f,0.24656157195568085f,0.16717645525932312f,-4.844010353088379f,-0.17538253962993622f,-0.38347333669662476f,0.06564424932003021f,-0.528713583946228f,1.4847720861434937f,-0.17825211584568024f,-0.48647341132164f}, +{0.047732532024383545f,1.835311770439148f,-3.989875078201294f,-1.0266798734664917f,-0.17154192924499512f,-0.2671833038330078f,-0.4181799292564392f,-0.08267560601234436f,0.8685728311538696f,-0.46098625659942627f,0.12363140285015106f,-0.7202304601669312f,0.4795161485671997f,-0.36958348751068115f,-0.33969876170158386f,0.38744300603866577f}, {0.07903262972831726f,0.2790505588054657f,-0.07798504829406738f,0.04248586297035217f,-0.1963958442211151f,-0.19260792434215546f,-0.4038352966308594f,0.015906542539596558f,0.15353140234947205f,0.030178606510162354f,0.2488909661769867f,0.13805970549583435f,-0.0816211998462677f,-0.20733052492141724f,-0.3036302626132965f,0.054825395345687866f}, -{-0.30922991037368774f,-0.0848562940955162f,-0.2771536707878113f,-0.39299437403678894f,-0.501600980758667f,-0.07938367873430252f,0.20021501183509827f,-0.019295204430818558f,-0.5755168795585632f,-0.46145495772361755f,0.06848174333572388f,0.11526546627283096f,-0.9005468487739563f,-0.6515923142433167f,-0.5762438774108887f,-0.04038632661104202f}, +{-0.30922991037368774f,0.3438586890697479f,-1.3785123825073242f,-0.32740458846092224f,2.1433217525482178f,0.8283578753471375f,0.120731420814991f,-0.05569665879011154f,-4.613624095916748f,-0.648725152015686f,0.0031571832951158285f,0.020493555814027786f,-1.1740103960037231f,-1.3394651412963867f,0.34946492314338684f,-3.218242645263672f}, {-0.39607733488082886f,-0.05481579899787903f,0.1976260244846344f,0.022423356771469116f,0.16892847418785095f,-0.27518749237060547f,0.16012099385261536f,0.3626593053340912f,-0.08640444278717041f,-0.11053556203842163f,-0.10529157519340515f,-0.31317979097366333f,-0.1530032455921173f,-0.1336749792098999f,0.22959044575691223f,0.19986507296562195f}, -{-0.37449589371681213f,-0.9064159989356995f,-0.6610195636749268f,0.0874672383069992f,-0.5877532362937927f,0.3902459144592285f,-0.18732719123363495f,0.19508449733257294f,-0.6848570704460144f,-0.31486886739730835f,-0.0473649837076664f,-0.07467646896839142f,-0.5057598948478699f,1.9025719165802002f,0.09490102529525757f,-0.36226871609687805f}, -{0.4110594093799591f,0.2790789306163788f,-0.31044068932533264f,0.37246426939964294f,0.21461978554725647f,-0.05120496079325676f,-0.08670487999916077f,-0.25336313247680664f,-0.030661463737487793f,-0.06259563565254211f,-0.1344406008720398f,0.35313835740089417f,0.19873254001140594f,0.11977154016494751f,0.3239758014678955f,-0.3391006588935852f}, -{-0.40892091393470764f,0.043769627809524536f,-0.3867315948009491f,0.25968697667121887f,0.3424709737300873f,-0.051169753074645996f,-0.23312048614025116f,-0.390264093875885f,0.28059282898902893f,-0.1559126079082489f,-0.14134526252746582f,-0.0003446042537689209f,-0.2742875814437866f,-0.36560842394828796f,0.07994696497917175f,0.005298197269439697f}, +{-0.37449589371681213f,0.6101797819137573f,-1.2181596755981445f,-0.5827922224998474f,-0.8879736661911011f,0.07010719180107117f,-0.18732719123363495f,0.08816012740135193f,-0.006525547243654728f,-0.3420955538749695f,-0.22282767295837402f,0.0009094775305129588f,0.841801106929779f,1.4600549936294556f,0.5438138842582703f,-1.1902813911437988f}, +{0.4110594093799591f,0.1984775811433792f,-0.2031489461660385f,0.47899430990219116f,0.22170546650886536f,-0.15623991191387177f,-0.08670487999916077f,-0.25336313247680664f,-0.030661463737487793f,-0.06259563565254211f,-0.1344406008720398f,0.35313835740089417f,0.26677072048187256f,0.03510013595223427f,0.3126353323459625f,-0.25811511278152466f}, +{-0.40892091393470764f,0.05906093493103981f,-0.40232452750205994f,0.22033147513866425f,0.3268229365348816f,-0.03595959022641182f,-0.23312048614025116f,-0.390264093875885f,0.28059282898902893f,-0.1559126079082489f,-0.14134526252746582f,-0.0003446042537689209f,-0.2899816036224365f,-0.34944114089012146f,0.09555623680353165f,0.005298197269439697f}, {0.10697010159492493f,-0.12228584289550781f,-0.37870171666145325f,0.21184906363487244f,-0.37222859263420105f,-0.17138728499412537f,-0.1382003128528595f,0.3493293821811676f,-0.360889196395874f,-0.3875247836112976f,0.42142823338508606f,-0.3482915461063385f,-0.3289247751235962f,-0.2186824083328247f,0.09620395302772522f,-0.06898030638694763f}, {0.2847062647342682f,0.018552124500274658f,0.11435768008232117f,0.36562982201576233f,-0.047046810388565063f,0.30447837710380554f,0.2430230677127838f,0.2909286320209503f,-0.2802048921585083f,0.18043199181556702f,0.41849127411842346f,-0.287167489528656f,0.24394884705543518f,-0.14084559679031372f,-0.10168051719665527f,0.010465055704116821f}, -{0.15459725260734558f,0.2614503502845764f,-0.8414085507392883f,-0.252727746963501f,-0.6894345283508301f,1.0636138916015625f,-0.08742031455039978f,0.06376123428344727f,-0.1714128702878952f,-0.47240930795669556f,0.1268840730190277f,-0.44391879439353943f,0.12466016411781311f,-0.9005870819091797f,-0.9095998406410217f,0.30346015095710754f}, -{-0.408692330121994f,-0.10330183058977127f,-0.03088713251054287f,-0.04910988733172417f,-0.14289908111095428f,-0.08836136758327484f,0.03285527229309082f,0.38763079047203064f,-0.20705322921276093f,-0.26367273926734924f,0.12809070944786072f,0.03996849060058594f,-0.6194682121276855f,-0.3420376479625702f,-0.15302342176437378f,0.334671288728714f}, -{-0.2991822361946106f,0.3794580399990082f,-0.07897943258285522f,-0.05932474136352539f,0.08582660555839539f,0.24227938055992126f,-0.11253207921981812f,0.34576353430747986f,0.04814547300338745f,-0.35770976543426514f,-0.044228196144104004f,-0.36229726672172546f,0.015840977430343628f,-0.13475483655929565f,0.36124154925346375f,-0.16869547963142395f}, -{-0.2675279378890991f,-0.2572242021560669f,-0.008989264257252216f,-0.14364181458950043f,2.3832051753997803f,0.2777503728866577f,-0.32875844836235046f,-0.2555496394634247f,-0.6392947435379028f,-0.7831358909606934f,-0.5172973275184631f,-0.6818525195121765f,0.8480085134506226f,-0.1394871473312378f,-1.3122553825378418f,0.1775851845741272f}, -{-0.015470266342163086f,0.5476723909378052f,0.4976131021976471f,0.19412125647068024f,-1.3260929584503174f,-1.7757221460342407f,0.05196094512939453f,0.09510938823223114f,-0.42801159620285034f,-0.7967047095298767f,0.13606210052967072f,-0.11511552333831787f,-0.7240217924118042f,-0.9549937844276428f,-0.9997981190681458f,-0.45693734288215637f}, -{0.1863725483417511f,0.9262488484382629f,-0.6855837106704712f,-0.577112078666687f,-0.642444372177124f,-0.24064891040325165f,0.04860696196556091f,0.14380735158920288f,-0.2648492157459259f,-0.029172860085964203f,-0.3929237127304077f,-0.10258594900369644f,1.1357184648513794f,0.016820937395095825f,1.862500786781311f,-0.1434863805770874f}, +{0.15459725260734558f,0.15348730981349945f,-4.331019878387451f,-0.12700089812278748f,-0.43322819471359253f,0.6307356953620911f,-0.08742031455039978f,-0.07590076327323914f,-1.1967891454696655f,-0.34674903750419617f,-0.14378179609775543f,-0.6840097904205322f,-0.24892647564411163f,-1.46860671043396f,0.4001198410987854f,-0.34875261783599854f}, +{-0.408692330121994f,-2.4127047061920166f,0.6133113503456116f,0.6079068183898926f,-1.315674901008606f,-1.007749319076538f,-0.03212685510516167f,0.38763079047203064f,-0.1677095741033554f,-0.36886489391326904f,-0.021568385884165764f,-0.33266445994377136f,1.6963165998458862f,0.9977030754089355f,-0.7752869129180908f,-1.1602344512939453f}, +{-0.2991822361946106f,0.362497478723526f,-0.06535498052835464f,-0.05932474136352539f,0.0975942388176918f,0.2226579189300537f,-0.11253207921981812f,0.34576353430747986f,0.04814547300338745f,-0.35770976543426514f,-0.044228196144104004f,-0.36229726672172546f,0.026891062036156654f,-0.1484510898590088f,0.3464936316013336f,-0.15040993690490723f}, +{-0.2675279378890991f,0.6284428834915161f,-2.0627334117889404f,1.5773100852966309f,1.4359925985336304f,-0.389126718044281f,-0.32875844836235046f,-0.31893211603164673f,0.16554830968379974f,-0.7438210248947144f,-0.48459216952323914f,-0.9164623618125916f,0.01574878580868244f,-0.8491065502166748f,0.36173921823501587f,1.086820363998413f}, +{-0.015470266342163086f,0.27051296830177307f,0.5455320477485657f,0.17461276054382324f,0.1404210478067398f,-0.7530509829521179f,-0.02548167109489441f,-0.008358269929885864f,-1.811440110206604f,-0.7032980918884277f,-0.0036238140892237425f,-0.3215062916278839f,-0.8373879790306091f,-0.4874410629272461f,-0.16436916589736938f,-0.6490094661712646f}, +{0.1863725483417511f,0.6204939484596252f,-0.29299893975257874f,0.23702117800712585f,-0.49486076831817627f,1.1787160634994507f,0.04860696196556091f,0.17769548296928406f,-3.209083318710327f,-0.2113076001405716f,-0.3929237127304077f,0.018219824880361557f,1.9527950286865234f,0.24260221421718597f,-0.011532197706401348f,-0.2762066423892975f}, }; -const float hout[16] = { 0.45773375034332275f,0.22148412466049194f,-0.22813020646572113f,-0.08917035162448883f,-0.21528248488903046f,0.29861685633659363f,0.0030125975608825684f,0.1412937343120575f,0.04779195412993431f,0.05501026287674904f,0.13024552166461945f,-0.04984400048851967f,-0.304860919713974f,-0.14634203910827637f,0.23745152354240417f,-0.16097530722618103f }; - -const float b1[16] = { 0.3074471652507782f,2.836015224456787f,-1.7145336866378784f,0.2683033347129822f,0.6529231071472168f,0.9833991527557373f,-0.058932315558195114f,2.29449462890625f,0.9298062920570374f,-0.9408509135246277f,0.5694966912269592f,1.5112576484680176f,-0.3744742274284363f,-1.0548338890075684f,-1.087764859199524f,0.6528083682060242f }; - -const float b2[16] = { 0.6096800565719604f,-0.6226189136505127f,-1.4564176797866821f,-0.5512577891349792f,-0.6939148902893066f,0.9173181653022766f,-0.0477285161614418f,-0.30969977378845215f,-1.200630784034729f,-1.912178635597229f,0.6023832559585571f,-0.04530715569853783f,-0.07918518036603928f,0.8115787506103516f,0.43986114859580994f,1.1172503232955933f }; - -const float b3[16] = { -1.963319182395935f,0.43098294734954834f,1.14909827709198f,-0.260453462600708f,-0.3398900330066681f,0.9021360874176025f,-0.45353031158447266f,-0.7342051267623901f,0.2843529284000397f,0.16309885680675507f,-0.24944843351840973f,-0.24138091504573822f,-0.16837841272354126f,-0.15490709245204926f,-0.771912157535553f,-0.42885565757751465f }; - -const float bout[1] = { -0.08879395574331284f }; +const float hout[16] = { 0.45773375034332275f,0.21716231107711792f,-0.10662519931793213f,-0.15387772023677826f,-0.2196422517299652f,0.2064427137374878f,-0.10921455174684525f,0.1304573118686676f,-0.12518544495105743f,0.0890493243932724f,0.06451720744371414f,-0.059981025755405426f,-0.24339118599891663f,0.21811717748641968f,0.4603889584541321f,-0.21442806720733643f }; + +const float b1[16] = { 0.19295264780521393f,1.094767451286316f,-1.7145336866378784f,0.35016536712646484f,0.8905879259109497f,1.1228079795837402f,-0.058932315558195114f,0.8859702944755554f,0.40630224347114563f,-0.8278393745422363f,2.5525219440460205f,0.8436682224273682f,-0.38463300466537476f,-3.1473605632781982f,-1.087764859199524f,1.0978176593780518f }; + +const float b2[16] = { -1.2509182691574097f,-0.646367609500885f,-1.4564176797866821f,-0.507847011089325f,-0.6939148902893066f,-0.4377679228782654f,0.0604497455060482f,-0.3696805536746979f,-1.200630784034729f,-1.912178635597229f,-0.12731675803661346f,0.8075035810470581f,-0.21940016746520996f,1.736842393875122f,0.5691323280334473f,1.4795602560043335f }; + +const float b3[16] = { -1.963319182395935f,-0.8063167929649353f,1.322169303894043f,-0.5002508759498596f,-0.39175909757614136f,0.863596498966217f,-0.5429335236549377f,-0.7943687438964844f,0.3544142544269562f,-0.010377739556133747f,-0.44223567843437195f,-0.39951252937316895f,-0.7216567397117615f,0.4033844470977783f,-1.1502139568328857f,0.6962782144546509f }; + +const float bout[1] = { -0.15546835958957672f }; /////////////////////////////////////////////////////////////////////////////////////////////RL float input_RL[num_input_RL] = { 0.0f }; @@ -2493,9 +2493,7 @@ float Va = (1256.6f + Amm * pos.sen/(float)(ENC_PULSE_PER_POSITION)) * 0.000000001f; // 4mm pipe * 100mm + (25mm Cylinder 18mm Rod) * x, unit : m^3 float Vb = (1256.6f + Amm * (79.0f - pos.sen/(float)(ENC_PULSE_PER_POSITION))) * 0.000000001f; // 4mm pipe * 100mm + (25mm Cylinder 18mm Rod) * (79.0mm-x), unit : m^3 - -// float Va = (1256.6f + Amm * 39.5f) * 0.000000001f; // 4mm pipe * 100mm + (25mm Cylinder 18mm Rod) * x, unit : m^3 -// float Vb = (1256.6f + Amm * 39.5f) * 0.000000001f; // 4mm pipe * 100mm + (25mm Cylinder 18mm Rod) * (79.0mm-x), unit : m^3 + V_adapt = 1.0f / (1.0f/Va + 1.0f/Vb); //initial 0.0000053f