16
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-07-22 19:49:19 +02:00

Add wiper animation

This commit is contained in:
2025-03-06 22:51:24 +01:00
parent 13e6dc0f87
commit f8d6bf5d0c
10 changed files with 330 additions and 6 deletions

View File

@@ -609,6 +609,17 @@ struct TDEScheme
double Umax = 0.0; /*napiecie maksymalne*/
double Imax = 0.0; /*prad maksymalny*/
};
struct TWiperScheme
{
uint8_t byteSum = 0; // suma bitowa pracujacych wycieraczek
double WiperSpeed = 0.0; // predkosc wycieraczki
double interval = 0.0; // interwal pracy wycieraczki
double outBackDelay = 0.0; // czas po jakim wycieraczka zacznie wracac z konca do poczatku
};
typedef TWiperScheme TWiperSchemeTable[16];
typedef TDEScheme TDESchemeTable[33]; /*tablica rezystorow rozr.*/
struct TShuntScheme
{
@@ -1134,6 +1145,9 @@ class TMoverParameters
bool LocHandleTimeTraxx = false; /*hamulec dodatkowy typu traxx*/
double MBPM = 1.0; /*masa najwiekszego cisnienia*/
int wiperSwitchPos = 0; // pozycja przelacznika wycieraczek
double WiperAngle = {45.0}; // kat pracy wycieraczek
std::shared_ptr<TBrake> Hamulec;
std::shared_ptr<TDriverHandle> Handle;
std::shared_ptr<TDriverHandle> LocHandle;
@@ -1359,6 +1373,9 @@ class TMoverParameters
bool Flat = false;
double Vhyp = 1.0;
TDESchemeTable DElist;
TWiperSchemeTable WiperList;
int WiperListSize;
double Vadd = 1.0;
TMPTRelayTable MPTRelay;
int RelayType = 0;
@@ -2046,6 +2063,7 @@ private:
void LoadFIZ_UCList(std::string const &Input);
void LoadFIZ_DList( std::string const &Input );
void LoadFIZ_FFList( std::string const &Input );
void LoadFIZ_WiperList(std::string const &Input);
void LoadFIZ_LightsList( std::string const &Input );
void LoadFIZ_CompressorList(std::string const &Input);
void LoadFIZ_PowerParamsDecode( TPowerParameters &Powerparameters, std::string const Prefix, std::string const &Input );
@@ -2067,6 +2085,7 @@ private:
bool readPmaxList(std::string const &line);
bool readFFList( std::string const &line );
bool readWWList( std::string const &line );
bool readWiperList( std::string const &line );
bool readLightsList( std::string const &Input );
bool readCompressorList(std::string const &Input);
void BrakeValveDecode( std::string const &s ); //Q 20160719