• 0 Posts
  • 33 Comments
Joined 3 years ago
cake
Cake day: June 12th, 2023

help-circle

  • I am typing this on a 5 year old Android phone. It has 128GB of memory and 8GB of RAM, very decent cameras, a beautiful OLED screen and a processor that is more than fast enough for everything I do with it. And even now the battery still lasts two days with normal use. It cost me about €300 at the time.

    Unfortunately the Android version is getting so far behind that some apps are starting to get a few issues, so I have been checking out some black Friday deals for new phones, but they look very disappointing.

    In the current market it seems like I’d have to pay about €500 to effectively just get a side-grade. All €300 offerings look like just a straight up downgrade in any way apart from the more recent android version.

    So I think I’ll hold on to this one a while longer. Hardware-wise it’s still in perfect condition, and if software support really becomes an issue then perhaps I’ll try out a custom ROM.


  • The main reason is tech debt and proprietary software. Most companies have decades of software infrastructure all built on Microsoft based systems. Transitioning all that stuff to Linux is a massive investment, especially taking into account the downtime it’ll cause combined with the temporary decrease in productivity when everyone has to get trained and build up experience with the new platform.

    And then you have to deal with proprietary software. A lot of niche corporate or industrial hardware only supports Windows. And you probably have to regularly interact with customers who use Windows and share files with you that can only be opened in Windows only proprietary software.

    Linux also frequently struggles with a lot of weird driver issues and other weird quirks, causing an increased burden on the IT department.

    Basically you’re looking at a massive investment in the short term, for significantly reduced productivity in the long run. And all that mostly to save a bit of hardware costs, which are only a fraction of the operating costs for most companies. Just sticking with Windows ends up being the more economical choice for most companies.



  • In this case it’s somewhat different.

    We have seen almost these exact formations on earth, where they are created by microbiological lifeforms which could survive in the condition of how we expect ancient Mars was like when this sediment was formed.

    We have been able to reproduce similar patterns in the lab, but only in conditions with much higher temperatures or with much higher acidity than what we’d expect Mars to have been like back then.

    So the possible options are:

    1. Ancient Mars was how we expect it to have been, and these patterns were formed by ancient microbiological, Martian lifeforms.

    2. These patterns were formed by a known chemical process, and ancient Mars was much hotter or more acidic (or both) than we expected based on all other research.

    3. These patterns were formed by a currently unknown chemical process that does not require the high temperature of acidity that the known processes require.

    So in this case it’s not just wishful thinking. The hypothesis of this being formed by microbiological life is the hypothesis that best fits with what we currently know about the conditions in which the sediment was formed (which doesn’t fully prove that it’s true, but does give it credibility). And even if options 2 or 3 will end up being the right explanation, then we’ll still at least learn something interesting from this.


  • I just searched, and the Wikipedia page on USB contains some basic information. If the connector is facing towards you and the clips to secure the cable are facing down, then the pins are numbered 1-5 from left to right. Pin 4 is the “ID” pin which is used to detect if the A or B type connector is inserted, and pin 5 is the ground. In an A type connector those two pins are bridged, so you’d want to short those two pins together if you want the device you plug it in to see your type B cable as if it has a type A connector (the connector is a slightly different shape, but that doesn’t matter, it’ll still fit and the ID pin is the only method used to detect the connector type).

    If you short the pins together by inserting something conductive inside the connector then you’ll likely also short them to the case, but that shouldn’t matter as the case is internally almost always connected to the ground too.

    If you take the route of soldering two cables together, I looked into it a bit more and it’s apparently a bigger mess than I anticipated. Hardware manufacturers have always treated the USB specs as more of a suggestion than as fixed standards, and apparently this is by far the worst when it comes to micro USB. Most phones and tablets with micro USB which support OTG use the type B receptacle instead of the AB receptacle, even though according to the standards only the AB receptacle is allowed for a device that can act as the host. The majority of micro USB OTG cables are then designed for such devices and use a type B connector for the host side. So if you use an OTG cable to harvest the micro-A connector from, make sure you get a standards-compliant cable. You can see the difference by the shape: for the proper micro-A connector the metal casing on the outside is rectangular in shape, while for the much more common micro-B connector it is roughly trapezoidal. According to the standards the plastic inside the connector should also be white for a type A connector (and black for type B), but those colours are probably the most often violated part of the standards.


  • I know that you can make a USB mini B connection appear as an USB mini A, because I have seen someone do that. He just made a small ball of aluminium foil and shoved it into the connector. The pins that need to be shorted are next to eachother and at the side (but I don’t remember if it was the left or right side), so it was still doable to get it in the right place. Micro USB is internally very similar, so it should be possible there too, but the inside is quite a bit smaller so it’ll be a lot harder.

    In your case it might be easier to solder 2 cables together. It is a bit annoying to solder USB cables together because the cables are shielded, but there are only 4 internal wires and the data rates are low enough that it doesn’t really matter if the shielding is imperfect. USB OTG cables should have an A type connector, and they are generally relatively cheap and easy to obtain. To get the USB-C connector, use a cable that has a USB 2 type of connector on the other side (regular, mini or micro), to make sure that the cable only has the USB 2 wires (USB 3 cables have extra wires in them, which aren’t really feasible to extend).


  • A micro USB-AB port has an extra electrical contact which is shorted together with another pin (probably with ground, but I don’t remember) when a USB-A connector is inserted, but left unconnected when a USB-A connector is inserted. Some USB driver chips require this extra pin to be shorted to enter host/master mode.

    This is done because to have USB communication one device needs to be the master, and the other the slave. Micro and mini USB cables handle this by having an A type connector on one side and a B type on the other side, and whichever device sees the A side will act as the master.

    In OP’s case the firmware is probably expecting the device to act as the master, but with a B type connector inserted it’s unable to do so.








  • x86 has bit manipulation instructions for any bit. If you have a book stored in bit 5 it doesn’t need to do anything masking, it can just directly check the state of bit 5. If you do masking in a low-level programming language to access individual bits then the compiler optimization will almost always change them to the corresponding bit manipulation instructions.

    So there’s not even a performance impact if you’re cycle limited. If you have to operate on a large number of bools then packing 8 of them in bytes can sometimes actually improve performance, as then you can more efficiently use the cache. Though unless you’re working with thousands of bools in a fast running loop you’re likely not going to really notice the difference.

    But most bool implementations still end up wasting 7 out of 8 bits (or sometimes even 15 out of 16 or 31 out of 32 to align to the word size of the device) simply because that generally produces the most readable code. Programming languages are not only designed for computers, but also for humans to work on and maintain, and waisting bits in a bool happens to be more optimal for keeping code readable and maintainable.



  • A wooden toothpick is probably a bit too thick. You’d want something thin enough that it can be inserted without touching the electrical contacts. If you do have something plastic then that’s probably better, but if you do the cleaning when the device is off the USB port should be unpowered and there shouldn’t be a risk of causing a short, and modern USB ports are quite well protected again shorts anyway so it’s very unlikely to cause damage just by being conductive. You mainly want something that is long and thin enough to get all the way to the bottom of the port without having to apply any force. If the only things you have that are long and thin enough to reach the bottom of the port without having to be forced in are made of metal, then that’s still a safer option than jamming something too thick into the port that can deform the center contacts.


  • Grab a thin needle or piece of wire, thin enough to easily insert into the USB-C port, and scratch all of the dirt and lint out of it. Always point the needle towards the outer surface so you don’t scratch the electrical contacts in the middle.

    There is often a surprising amount of junk inside even if you can’t see it from the outside, and that can greatly affect the connection quality.

    My phone recently had a similar issue where it would only charge if the cable was inserted in a specific way, and any movement would cause it to stop charging. The cable also wasn’t really held well even though it looked like it was fully inserted. I cleaned out the port even though I couldn’t see anything inside, and managed to pull out a bit of dust anyway. And now my phone no longer has charging issues and holds on to the cable much better.

    USB-C unfortunately just seems to have a design that makes it very easy for dust to get stuck in it, while also having a relatively low tolerance for foreign material buildup before the connection quality gets affected, making this a quite common issue.



  • Depends on viewing conditions. As of yet there isn’t an objectively superior display technology.

    OLEDs have the best contrast in a dark room as black pixels can be fully turned off, but they are generally less bright and use more power than comparable LCD TVs or monitors (especially when you compare models of a similar price range).

    LCD based monitors and TVs can get brighter and can actually achieve a higher contrast in a well lit room as the black pixels on an LCD are less reflective than black pixels on an OLED, and when viewing in daylight the ambient light is more than enough to drown out the backlight bleed.

    There are also other smaller pros and cons. OLED for example has a better pixel response time, while IPS LCDs are more colour accurate. Text rendering and other fine graphics also generally look slightly sharper on an LCD than on an OLED display (when comparing displays of equal resolution / pixel density) due to the subpixel layout.