Re: Hyper car hybrid
Posted: Sat Mar 12, 2022 9:13 am
Dale, you've changed the behaviour of the debug mth printout in your tidy-up.
The "|\t" print should not be inside the if(j=0) bracket.Thank you, and oops.Dale, you've changed the behaviour of the debug mth printout in your tidy-up.
Code: Select all
void diag_mth()
{
///mask just hides any MTH data byte which is represented here with a 0. Useful for debug/discovering.
bool mth_mask[100] = {
0,0,0,0,0,0,0,0,1,1,
1,1,0,0,1,1,1,1,1,1,
1,1,1,1,1,1,1,1,1,1,
1,0,0,1,1,1,1,0,0,1,
1,1,0,0,1,1,1,1,1,1,
1,1,1,1,1,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,
1,1,0,0,1,1,0,0,1,1,
1,1,1,1,1,1,1,1,0,0,};
SerialDEBUG.print("\n");
SerialDEBUG.println("\t0\t1\t2\t3\t4\t5\t6\t7\t8\t9");
SerialDEBUG.println(" ------------------------------------------------------------------------------");
for (int j=0;j<10;j++)
{
SerialDEBUG.print(j*10);if(j==0)SerialDEBUG.print("0");SerialDEBUG.print(" |\t");
for (int k=0;k<10;k++)
{
if(mth_mask[j*10+k])SerialDEBUG.print(mth_data[j*10+k]);else SerialDEBUG.print (" ");
SerialDEBUG.print("\t");
}
SerialDEBUG.print("\n");
}
SerialDEBUG.print("\n");
SerialDEBUG.print("MTH Valid: ");if(mth_good)SerialDEBUG.print("Yes"); else SerialDEBUG.print("No");SerialDEBUG.print("\tChecksum: ");SerialDEBUG.print(mth_checksum);
SerialDEBUG.print("\n");
SerialDEBUG.print("DC Bus: ");if(dc_bus_voltage>=0)SerialDEBUG.print(dc_bus_voltage);else SerialDEBUG.print("----");
SerialDEBUG.print("v\n");
SerialDEBUG.print("MG1 - Speed: ");SerialDEBUG.print(mg1_speed);
SerialDEBUG.print("rpm\tPosition: ");SerialDEBUG.print(mth_data[12]|mth_data[13]<<8);
SerialDEBUG.print("\n");
SerialDEBUG.print("MG2 - Speed: ");SerialDEBUG.print(mg2_speed);
SerialDEBUG.print("rpm\tPosition: ");SerialDEBUG.print(mth_data[37]|mth_data[38]<<8);
SerialDEBUG.print("\n");
SerialDEBUG.print("Water Temp:\t");SerialDEBUG.print(temp_inv_water);
SerialDEBUG.print("c\nInductor Temp:\t" );SerialDEBUG.print(temp_inv_inductor);
SerialDEBUG.print("c\nAnother Temp:\t");SerialDEBUG.print(mth_data[88]|mth_data[89]<<8);
SerialDEBUG.print("c\nAnother Temp:\t");SerialDEBUG.print(mth_data[41]|mth_data[40]<<8);
SerialDEBUG.print("c\n");
SerialDEBUG.print("\n");
SerialDEBUG.print("\n");
SerialDEBUG.print("\n");
SerialDEBUG.print("\n");
SerialDEBUG.print("\n");
SerialDEBUG.print("\n");
SerialDEBUG.print("\n");
SerialDEBUG.print("\n");
SerialDEBUG.print("\n");
SerialDEBUG.print("\n");
}
Code: Select all
// Serial Port Debug Print String
void diag_mth()
{
///mask just hides any MTH data byte which is represented here with a 0. Useful for debug/discovering.
bool mth_mask[100] = {
0,0,0,0,0,0,0,0,1,1,
1,1,0,0,1,1,1,1,1,1,
1,1,1,1,1,1,1,1,1,1,
1,0,0,1,1,1,1,0,0,1,
1,1,0,0,1,1,1,1,1,1,
1,1,1,1,1,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,
1,1,0,0,1,1,0,0,1,1,
1,1,1,1,1,1,1,1,0,0,};
SerialDEBUG.print("\n");
SerialDEBUG.println("\t0\t1\t2\t3\t4\t5\t6\t7\t8\t9");
SerialDEBUG.println(" ------------------------------------------------------------------------------");
for (int j=0;j<10;j++)
{
SerialDEBUG.print(j*10);
if(j==0)
{
SerialDEBUG.print("0");
SerialDEBUG.print(" |\t");
}
for (int k=0;k<10;k++)
{
if(mth_mask[j*10+k])
{
SerialDEBUG.print(mth_data[j*10+k]);
}
else SerialDEBUG.print (" ");
{
SerialDEBUG.print("\t");
}
}
SerialDEBUG.print("\n");
}
SerialDEBUG.print("\n");
SerialDEBUG.print("MTH Valid: ");
if(mth_good)
{
SerialDEBUG.print("Yes");
}
else
{
SerialDEBUG.print("No");SerialDEBUG.print("\tChecksum: ");
}
SerialDEBUG.print(mth_checksum);
SerialDEBUG.print("\n");
SerialDEBUG.print("DC Bus: ");
if(dc_bus_voltage>=0)
{
SerialDEBUG.print(dc_bus_voltage);
}
else
{
SerialDEBUG.print("----");
}
SerialDEBUG.print("v\n");
SerialDEBUG.print("MG1 - Speed: ");
SerialDEBUG.print(mg1_speed);
SerialDEBUG.print("rpm\tPosition: ");
SerialDEBUG.print(mth_data[12]|mth_data[13]<<8);
SerialDEBUG.print("\n");
SerialDEBUG.print("MG2 - Speed: ");
SerialDEBUG.print(mg2_speed);
SerialDEBUG.print("rpm\tPosition: ");
SerialDEBUG.print(mth_data[37]|mth_data[38]<<8);
SerialDEBUG.print("\n");
SerialDEBUG.print("Water Temp:\t");
SerialDEBUG.print(temp_inv_water);
SerialDEBUG.print("c\nInductor Temp:\t" );
SerialDEBUG.print(temp_inv_inductor);
SerialDEBUG.print("c\nAnother Temp:\t");
SerialDEBUG.print(mth_data[88]|mth_data[89]<<8);
SerialDEBUG.print("c\nAnother Temp:\t");
SerialDEBUG.print(mth_data[41]|mth_data[40]<<8);
SerialDEBUG.print("c\n");
SerialDEBUG.print("\n");
SerialDEBUG.print("\n");
SerialDEBUG.print("\n");
SerialDEBUG.print("\n");
SerialDEBUG.print("\n");
SerialDEBUG.print("\n");
SerialDEBUG.print("\n");
SerialDEBUG.print("\n");
SerialDEBUG.print("\n");
SerialDEBUG.print("\n");
}
Change was in the spreading out of the last quoted line of v3:daleread wrote: ↑Sat Mar 12, 2022 1:25 pm
Thank you, and oops.
But I cant see that in the code I have?
I have this in version 3 user, "gs450h_v3_user.ino"Or this in version 7, "gs450h_v7.D.R.ino"Code: Select all
SerialDEBUG.println("\t0\t1\t2\t3\t4\t5\t6\t7\t8\t9"); SerialDEBUG.println(" ------------------------------------------------------------------------------"); for (int j=0;j<10;j++) { SerialDEBUG.print(j*10);if(j==0)SerialDEBUG.print("0");SerialDEBUG.print(" |\t");
gs450h_v7a_D.R.ino
Code: Select all
SerialDEBUG.println("\t0\t1\t2\t3\t4\t5\t6\t7\t8\t9"); SerialDEBUG.println(" ------------------------------------------------------------------------------"); for (int j=0;j<10;j++) { SerialDEBUG.print(j*10); if(j==0) { SerialDEBUG.print("0"); SerialDEBUG.print(" |\t"); }
Code: Select all
SerialDEBUG.println("\t0\t1\t2\t3\t4\t5\t6\t7\t8\t9");
SerialDEBUG.println(" ------------------------------------------------------------------------------");
for (int j=0;j<12;j++)
{
if(j<10)SerialDEBUG.print(" ");
if(j==0)SerialDEBUG.print(" ");
SerialDEBUG.print(j*10);
SerialDEBUG.print(" |\t");
The part of the Q211 over the axel center is abour 250mm high, so maybe sufficient clearance, all depends on the thickness of cross member , and I guess important to keep level, for the splash internal lubrication drip points.
arber333 wrote: ↑Sun Mar 06, 2022 11:04 amWell, regen operates in reverse of the propulsion torque. It is native to PMSM motors. You need a mass with velocity to stop and you apply certain settings in your inverter so it provides negative torque to the wheels. This then is converted to current to the batteries.
In OEM cars the motors are connected with the engine by elaborate gearing or belts or CVT connections.
In your case you will allways have the connection between motor and engine. Ground will provide traction and torque translation. In example if you drive your engine and select regen front motor will fight the rear motor + mass. Also you can have front axle add its torque for starting from standstill or you can just frewheel the engine clutch and drive on electric only...
My logic would be a bit different though... I would install a smaller engine on Lexus gs450h transmission which would operate simillary to OEM and maybe search for another motor like MGR or larger to put in front to have a true sport 4wd.
Sorry didnt notice this car was mid engine...
EDIT: Observe that you can connect motor to smaller battery and it will still provide regen current but it will not be able to accelerate your car to higher speed. This is why MGR is limited in power.
The idea is that for 95% of the time the car will be driven only through the rear wheels. Therefore the front wheels will be available for regen.of course the frequency of utilizing the potential energy into work will be greater than the regenerative recovery, if so , the system have to make sure the battery never fully charge?
30V is enough on the HV to turn things. 12V, about 1.5A on the Prius block I have been testing with. Woodfie has the experience with the gs450h_vcu. You'll need a throttle pedal probably!
The out3.csv data is looking really good, do you plan to tabulate it as live data and maybe highlight in red/yellow/green as the data bytes change?My first attempt to extract the data is here:
https://github.com/evbuilder/SnifferParser
If you don't give the disconnected motor a torque request it might go quiet.disconnect of one of the resolver plugs, recall a higher pitch whine