marcraft2 / tesla-carplay

Carplay Raspberry Pi Wi-Fi Hotspot Web Server for Tesla.
Other
112 stars 19 forks source link

Font sizes of Album text #10

Closed psmith3 closed 2 years ago

psmith3 commented 2 years ago

Trying to get CarPlay to fill the full browser screen in the Tesla, I have set the canvas size to 1180x960 but now I am seeing the album and track name fonts being scaled too big. Do you have any idea what values set these items? I believe these values are set in jsmpeg.min.js. See my attached screenshot showing the oversized fonts.

On a separate issue, I am also trying to determine where the touch overlay map is that sets where the touch buttons are on the screen. Not all my touch locations line up and it seems to also be resolution related.

marcraft2 commented 2 years ago

You must have proportional values between width and height or equal here and here

I think the best is that it is equal between the two files, but be careful not to mount it too much on the server side because the raspberry has limits.

I will look to find the right parameter is to set it by default, in fact the tesla browser has changed the resolution quite a few times with the updates

psmith3 commented 2 years ago

Thanks I will make sure this is where I have set the resolution. The latest browser is now 1180x1020, I think. I am getting conflicting user agent details. Some say 1180x919. If you could confirm, that would be great. BTW, the latest Tesla browser updates finally make the browser much more responsive and usable for this CarPlay interface.

marcraft2 commented 2 years ago

The first time I set it I based myself on sites like this

marcraft2 commented 2 years ago

And I will try to test all that tomorrow.

marcraft2 commented 2 years ago

index.js:

const config = {
        dpi: 100,
        nightMode: 0,
        hand: 0,
        boxName: 'nodePlay',
        width: 900,
        height: 702,
        fps: 30,
}

index.html:

const carplayWidth = 900;
const carplayHeight = 702;

IMG_2511

Commit & Commit

psmith3 commented 2 years ago

Perfect! Thank you!

On Jun 5, 2022, at 5:01 PM, Marc Dubois @.***> wrote:



index.jshttps://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fmarcdubois71450%2Ftesla-carplay%2Fblob%2Fmaster%2Findex.js%23L82&data=05%7C01%7C%7Cf84c93dc786e48e8539b08da473ef6f9%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637900632999459221%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=YliXzQBDEdL3oX3G1%2FO15yhUL9ExPHg7mCAG2nfPiRU%3D&reserved=0:

const config = { dpi: 100, nightMode: 0, hand: 0, boxName: 'nodePlay', width: 900, height: 702, fps: 30, }

index.htmlhttps://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fmarcdubois71450%2Ftesla-carplay%2Fblob%2Fmaster%2Fstatic%2Findex.html%23L26&data=05%7C01%7C%7Cf84c93dc786e48e8539b08da473ef6f9%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637900632999459221%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=Tslqgx88egZU%2FO9FGQ7%2Bntc8RY3fnPGtUOs2AHo1Jns%3D&reserved=0:

const carplayWidth = 900; const carplayHeight = 702;

[IMG_2511]https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Fuser-images.githubusercontent.com%2F38250422%2F172072223-14cb3f52-bd33-431b-aa9c-b8439b72657c.jpg&data=05%7C01%7C%7Cf84c93dc786e48e8539b08da473ef6f9%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637900632999459221%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=gTg4zv1TaGr2qfPoytvYybm8ANrTAc3K%2F%2Bv%2B%2FKDmJFw%3D&reserved=0

Commithttps://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fmarcdubois71450%2Ftesla-carplay%2Fcommit%2F86514b880b7f778da727574de0966920194fac1d&data=05%7C01%7C%7Cf84c93dc786e48e8539b08da473ef6f9%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637900632999459221%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=j5tany4LDi8fo6j%2B6hwK79vb4tAoxk4HzppB6uE%2FDXk%3D&reserved=0 & Commithttps://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fmarcdubois71450%2Ftesla-carplay%2Fcommit%2F8d84d7264107ad9f302ff2f6d1c80aeca14f71ce&data=05%7C01%7C%7Cf84c93dc786e48e8539b08da473ef6f9%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637900632999459221%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=SRqLkz2wU5UTxxkZGUQ9yVMNwyZmbHClLvp1Jg1igys%3D&reserved=0

— Reply to this email directly, view it on GitHubhttps://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fmarcdubois71450%2Ftesla-carplay%2Fissues%2F10%23issuecomment-1146890634&data=05%7C01%7C%7Cf84c93dc786e48e8539b08da473ef6f9%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637900632999459221%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=dLCvBZhdq4QZsC%2F7ZziT7BdEn%2Fan2NtMpfkOFw2haF4%3D&reserved=0, or unsubscribehttps://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FADNVCK6RXAGN4TCKC37J7W3VNUPUDANCNFSM5W5QHZWQ&data=05%7C01%7C%7Cf84c93dc786e48e8539b08da473ef6f9%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637900632999459221%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=6S1Sh8OSX2KCMEVNUbhiETmfD81EAB8kv2zTqh3L964%3D&reserved=0. You are receiving this because you authored the thread.Message ID: @.***>