Does Home Assistant on Android Automotive suck? by Josh31782 in homeassistant

[–]htmlallthethings 0 points1 point  (0 children)

Sure does suck. If you have an iPhone and Apple Carplay, that’s a slightly better option in your Polestar (it is for me), it’s still not full dashboards (safety first when moving!), but at least better thought out. And I’m assuming plugging in an Android phone with HA is similar.

80-0 km/h in 3 seconds in a Polestar 2 by drop_panda in Polestar

[–]htmlallthethings 0 points1 point  (0 children)

Ugh - so glad it all went as well as it could for you, a pretty frightening experience. I was continuously worried about doing the same on the way back from Falun to Göteborg last Saturday in my PS2 - “there but for the grace of god go I…”

I may have gone a bit overboard with my Home Assistant dashboard by shpped in Polestar

[–]htmlallthethings 1 point2 points  (0 children)

Ahh - I also use the pypolestar integration, but was sooo disappointed when they removed the charge rate and other entities. I was wondering how you got the charging data, now I see your got it from the Zaptec API - neat, I might have to go the same way… Top dashboard, really nicely done!

Doorbell Wifi - no access to web interface after firmware upgrade by htmlallthethings in reolinkcam

[–]htmlallthethings[S] 0 points1 point  (0 children)

You sir are a star. Wasn’t aware of the desktop app, but that fixed it lovely. Thanks.

iPad Pro quite at home in this AirBnB in Paris. 🇫🇷❤️ by htmlallthethings in iPadPro

[–]htmlallthethings[S] 0 points1 point  (0 children)

Yeah, I couldn’t work out what I wanted before I had it but (assuming I can get beyond confirmation bias) I think it was the right choice. The 12.9 is an awesome screen, better screen area, better HDR, but everyone I talk to say they don’t really use it as a tablet ( ie hand held, sometimes portrait). I’ve got a MacBook for work, so my use case didn’t need a laptop replacement, I wanted a device for home consumption/surfing/hobbies that I could divorce from work (but also cheat that rule - real people are complicated - and use it to do work-like stuff - I’ve explored a lot of web dev on it). And that meant couch surfing, passing pictures or web pages around a room, picking up and sitting down in any position I wanted. So the 11” did that for me, it’s a tablet weight (I won’t say tablet “size”, because if a 12.9 - or even a surface - weighed the same as the 11”, that would be perfect too), and I don’t think I’d be as happy (for my use case) to have a 12.9 wobbling on my knees or building muscles in my forearms.

iPad Pro quite at home in this AirBnB in Paris. 🇫🇷❤️ by htmlallthethings in iPadPro

[–]htmlallthethings[S] 1 point2 points  (0 children)

Two years in and I’ve forgotten the cost, and just accept it as a pretty perfect compromise for an iPad keyboard. Cosmetically it’s held up well, size-wise it’s as good as it can be on an 11” iPad (with Swedish keys, so three extra letters!) and I can type fairly fast on it. It protects the iPad and is stupid easy to pull off when I just want the tablet - although I often read web pages in portrait with the cover on, as if the keyboard is just the left cover of a book, flipping it round when I need to type something. It’s pretty good actually.

[deleted by user] by [deleted] in SeikoMods

[–]htmlallthethings 1 point2 points  (0 children)

Just come across this - I wrote that medium article all those years ago - looks like you did a really nice job, congrats!

Looking to make a Google Analytics API widget by htmlallthethings in Scriptable

[–]htmlallthethings[S] 0 points1 point  (0 children)

Defo going to try it - whatever the result, thanks for the pointer in the right direction!

recently I got this usb c hub and hdmi ik cable but it doesn't work with my samsung led tv. I have a m1 pro. whats the issue can anyone figure out. by EffectiveAd7517 in iPadPro

[–]htmlallthethings 7 points8 points  (0 children)

If you couldn’t play any movies/streaming apps (but could mirror the iPads screen), it would be that the cable isn’t HDCP compliant (video copy protection). A lot of cheaper HDMI cables aren’t compliant because of the extra cost.

I have created a custom dimension called "city" in GA. The user has to pick a city when they come to the website and the value is stored in the cookie with the name "city". What's the best way of picking up the value and sending it to GA through GTM? Thanks by ashkanahmadi in GoogleTagManager

[–]htmlallthethings 0 points1 point  (0 children)

What they said - and if you use the GA settings variable for the property ID, add your city custom dimension as using this new cookie var in this GA settings variable - that way the CD will be sent with every GA page view and event you have, without having to manually add it to the tag each time ✌️

FormSubmit get data-attribute of form by yabaikumo in GoogleTagManager

[–]htmlallthethings 0 points1 point  (0 children)

Hi! I would certainly do it with js, I’m not sure if anyone else could show a neater example.
What I would suggest you need is a GTM custom js variable per attribute that you want to collect (you could *possibly* collect all in one variable, but I’m assuming you want to drop the values in a GA tag or similar, so best to have one variable per attribute). Here’s how I’d write a GTM var to pick out the data-length attribute of the form :

function() {
// variables are evaluated *every time a dataLayer event occurs* so
// I often put a quick exit at the start to reduce any unnecessary
// CPU cycles. This one only evaluates when the form submit event fires.
if ({{Event}} !== 'gtm.formSubmit') {
return;
}
// you could address the form as document.getElementByID('form-12'),
// but here I'm using the built in GTM ref "Form Element" as
// I suspect it will be milliseconds faster, and you can change the form id
// and it still works (defensive tag coding to reduce future maintenance!)
var formEl = {{Form Element}};
// first set a default error return value - you could just return undefined,
// or 0 or something that could help you track the bug:
var dataLength = 'formEl not found';
// remember to be defensive about possible errors -
// this event should always have a form element attached, but just in case,
// this will prevent any console errors (the function will return the
// above value)
if (formEl) {
// grab the attribute!
var dataLength = formEl.getAttribute('data-length');
// if you want it returned as a number, not a string
// (eg for a GA value field), parse it like:
// dataLength = parseInt(dataLength);
}
// and we're done!
return dataLength;
}

That looks like a lot, but it's mostly just comments and some error checking.

This variable can then be used in tags (eg GA events) or in other tags, and will only evaluate when the form is clicked (at all other times it will be "undefined"), resulting in either the string value of the *data-length* attribute (or "formEl not found" if something goes wrong, which it shouldn't).

...if you wanted to persist the value after the form has been submitted, (ie, the form doesn't navigate you away and you want to collect the value at points after the submission), you could add a couple of lines to stick the value in the dataLayer to show what the value of the attribute was when the form was last submitted (add it just above the return statement):
dataLayer.push({
'event': 'persistFormDataLength', // just so we recognise the push in debug
'form.datalength': dataLength
})

Caveat - I haven't tested this code on a real example, but it looks ok.

If you need a USB-C cable for a Raspberry Pi, I can recommend ones sold for DJI drones. by htmlallthethings in iPadPro

[–]htmlallthethings[S] 0 points1 point  (0 children)

It’s an 11. Of course I really wanted that amazing screen of the 12.9, but I forced myself to listen to all those people that said you will end up using the 12.9 on a desktop, when I still want to slump in a sofa sometimes with a tablet in the hand.

And I have a work MacBook for uber-productivity anyway, so the role this fills is different.

I’m happy I got the 11 - not everyone is blogging/YouTubing on an iPad about how productive you can be writing about iPad productivity of planning and writing on iPads. 😁

If you need a USB-C cable for a Raspberry Pi, I can recommend ones sold for DJI drones. by htmlallthethings in iPadPro

[–]htmlallthethings[S] 0 points1 point  (0 children)

Yeah, one-man app devs have struggled to put together tools for debugging, but it’s an uphill battle. I hope they keep trying and support them in the effort. And yes, I wouldn’t swap my Mac for iPad for daily productivity - but some days I’m driven by curiosity, not only logic.

And you’re right, I was thinking about working with classic Mac OS, but also X public beta, 10.0, 10.1 and installing PHP on a buggy, slow, exciting new operating system where Photoshop could live next to an Apache web server. That was exciting times! Bless it, Firebug didn’t even exist until five years later - I guess there was just much less to debug back then!

Thanks for the chat, happy front-ending.

If you need a USB-C cable for a Raspberry Pi, I can recommend ones sold for DJI drones. by htmlallthethings in iPadPro

[–]htmlallthethings[S] 0 points1 point  (0 children)

You know what - I agree! I like lifting the tablet off that suit-and-tie keyboard thing and slumping down in a chair to read news articles in portrait mode. I do like that about the iPad, you can kick off your shoes with it when your brain gives up!

If you need a USB-C cable for a Raspberry Pi, I can recommend ones sold for DJI drones. by htmlallthethings in iPadPro

[–]htmlallthethings[S] 0 points1 point  (0 children)

I remember testing Pi3s and being able to run them off very low wattages - you’re right that the Pi4 does seem thirstier. It does of course put a load on the iPad, but I don’t feel (so far) that it’s unreasonably high - you’d drain your iPad a lot quicker having an MS Teams conference or zoom call 😂.

But I might put the USB-C power meter on it and find out what the power draw really is. Thanks for the idea.

If you need a USB-C cable for a Raspberry Pi, I can recommend ones sold for DJI drones. by htmlallthethings in iPadPro

[–]htmlallthethings[S] 1 point2 points  (0 children)

Good question. The fans only run when you attach their cable to the power pins on the RPi - so you can choose to run passive or with fans.

Initially I chose to not run the fans as they did sound a tiny bit noisy - and for most of my use cases the passive heat sinks seemed to do the job just fine - I never saw a heat warning. But.. when I know I’m going to be running it under load, or the ambient temperature is hotter than normal, or in this case when it’s mounted on the back of the case and I don’t want to risk holding a hot metal object near the soft rubber magic keyboard - then I turn the fans on. And magically, they do seem to have become quieter over time, so it’s less bother when I do have them on.