Notifications
Clear all

Raspberry Pi 5, DC-DC Buck down power supply from 36v, best method?

54 Posts
3 Users
12 Likes
4,779 Views
(@davee)
Member
Joined: 3 years ago
Posts: 1628
 

Hi Ron @zander & @whitneydesignlabs,

  Ron, I don't think we are significantly disagreeing, but there is one specific point that maybe worth discussing a little further, albeit I confess to finding the USB power standards rather complex and confusing, so apologies if I am making a mistake. For the purpose of constructing the first part of this note, I am using Wikipedia page:

https://en.wikipedia.org/wiki/USB_hardware#cite_ref-emarked-5A-cable_69-0

although I have also looked elsewhere as such in the past.

------------

The newer USB power standards for supplying more power obviously greatly exceed the 15W level implied by 5V at 3A.

These higher power standards only exceed 3A when supplied via Extended Power Range cables, which include modifications to both the wire size and connector mechanical design, as well as 'electronically' marking the cables, by incorporating electronic components that the power supply can detect, and hence determine as 'compatible' with the higher demands of carrying a higher current.

However, these higher power standards do not include any options for exceeding 3A at 5V. The only options for exceeding 3A are at 20V and higher.

Of course, the power supply will initially offer 5V, and only move to a higher voltage as the result of a 'conversation' involving 2-way serial data messages with the load, which establish the highest voltage the load can accept.

My understanding is that R-Pi 5 is only compatible with a 5V input, and hence would neither need nor want to request a higher voltage.

However, it would 'like' to be offered 5A at 5V, which is outside of the USB range of options.

----------------------------------

I am unclear as to the extent that the either the R-PI 'official' power supply or the R-Pi 5 has been modified to provide the 5V 5A specification.

Clearly, the supply unit itself will not limit any current demands up to 5A, and as it has a captive cable, I assume wire thicknesses, etc will have been chosen appropriately. 

It seems that the R-Pi 5 can determine the power supply capability, as it is able to decide whether to limit the amount of power available to USB loads plugged into it as either 'low current' (maybe 400 mA?? total from memory), if it 'thinks' it is connected to a 3A max supply, or 'higher current' (about 1.6A??? also from memory).

I haven't found much 'official' information on this, albeit their is some description at the Powering Raspberry Pi 5 Section of 

https://www.raspberrypi.com/documentation/computers/raspberry-pi-5.html#usb-boot-and-power-supplies

But two other forum threads may be helpful, albeit I can't check their veracity, so treat with caution.

https://community.element14.com/products/raspberry-pi/f/raspberry-pi-5-faq/53749/what-power-supply-do-i-need-for-the-raspberry-pi-5-can-i-use-a-previous-power-supply-and-does-it-support-usb-pd

which states:

The Raspberry Pi 5, to take full advantage of the processing capabilities and features, and to supply 1.6amps to the USB ports, requires a 5 volts, 5 amps USB-C power supply.

The Raspberry Pi 5 official AC adapter is 27 watts (27w) and is effectively a custom USB-PD (USB Power Delivery) power supply that can negotiate 5.1v 5a, 9.0v 3a, 12v 2.25a, 15v 1.8a.

The Raspberry Pi 5 can be powered from 5v 3a which is typically negotiated from a USB-PD power supply, if this happens the USB ports will be power limited to 600ma (milliamps) as opposed to the full 1.6 amps. This can be adequate for most applications.

Negotiating 5v 5a is not typical from USB-PD power supplies and it is supported by the 27w USB-C Power Supply from Raspberry Pi. It uses 17awg captive cabling.

The Raspberry Pi 5 will not negotiate higher voltages (such as 9v or 12v) even though the power supply can provide it to other devices.

To use the Raspberry Pi 5 at its fullest you will need a USB-PD power supply that can provide and negotiate 5A at 5V.

Previous Raspberry Pi power supplies do not supply this.

You will also be able to add a line to the config.txt of the Raspberry Pi to tell it to ignore the USB-PD auto-detection and assume that the power supply can provide 5v and 5A.

and https://forums.raspberrypi.com/viewtopic.php?t=358576 which has multiple replies, including:

Re: How does Pi5 determine Power Supply capacity  Sun Oct 29, 2023 1:44 am

To put things a little more simply, the Pi 5 just asks the USB-C port how much current it can give. Only USB-C chargers know how to talk the right language. You can tell the Pi that extra power is available with some boot options (this is a link).

and there is a hint hidden in a rather long list of messages referenced in:

hal58 wrote:

Sun Oct 29, 2023 7:45 am

Thanks all for the insight. now to dig into the config.txt entries to see if there is in fact an override for this PD sensing since i have no way of configuring any PD handshake for my little power kludges. I'm not sure that this will be much of an improvement if the limit cannot be manually set.

This may short-circuit your search...viewtopic.php?p=2147932&hilit=usb_max_c ... e#p2147932

and

Re: How does Pi5 determine Power Supply capacity

Sun Oct 29, 2023 12:23 am

Screenshot_2023-10-28_21-20-40.png
Screenshot_2023-10-28_21-20-40.png (30.03 KiB) Viewed 3469 times

the usb-pd protocol has messages like this
so if you want to advertise that you can supply 5a, you send this packet with a 100 in the lower 7 bits

since its a 7bit int, the max is 127, which would be 6.35A

as the pi5 is booting, it will interrogate both the PD supply and the PoE hat, figure out where the power is coming from, and how much mA is available
and it has several defaults it will assume, if it doesnt get any reply

---------

Which at first glance, leads me to think:

  • R-Pi processor (itself) will work if it gets 5V at enough Amps, regardless of PD conversations, etc. ... presumably 4-ish+ Amps will do, if there are no significant additional USB loads plugged into sharing its supply. Overclocking, etc. may push the current demand higher.
  •  
  • PD compliant supplies, not specifically aimed at the R-Pi 5 market, are (IMHO) unlikely to be designed to supply more than 3 A at 5V, because this is the highest current level in the specification. I guess, some aimed at supplying more than 3 A at 20V may supply more, but may or may not reflect it in their PD conversation. Note, supplying more than 3A at any voltage implies higher current (and more expensive) components, so I would be surprised if a designer would provision for more 3A when designing a supply that does not also meet 5 A at 20V, etc., unless it is an 'R-Pi 5 special'.
  •  
  • Of course, there will soon be a significant number of R-Pi 5s in circulation, so this may well encourage R-Pi 5 compatible supply products to be designed and sold.
  •  
  • By default, the R-Pi processor will try to use PD conversation to determine whether it is connected to a 5V 5A supply ... if it gets a 'favourable' reply, then it will enable a higher current draw of up to 1.6A (total) from its USB ports. Apart from this response, I have not discovered any features that are affected by the PD conversations.
  •  
  • It is possible to modify the R-Pi 5 to ignore the PD checking, and enable the higher current USB load draw, by a simple procedure, probably changing a file on the R-Pi 5. This could be a useful workaround, if you are providing a 'simple' 5V 5(+)A supply and wish to connect peripherals to the USB ports.

-------------------

Best wishes, Dave


   
ReplyQuote
Ron
 Ron
(@zander)
Father of a miniature Wookie
Joined: 3 years ago
Posts: 6829
 

@davee Since the OP has 'solved' his problem, I am no longer interested in debating facts vs. opinions. The USB-C PD 3.0 standard most certainly supports 5.1V at 5A. That is why the official wall wart is 27Watts. See attached pic. Yes, I have one.

I think the confusion may be in the way that the documentation is written. I have not seen where it explicitly says 5.1V at 5A (except on the charger); instead, it says Max of 5A at voltages up to 20V (PD 3.0) and 5A at 48V (PD 3.1) Up to either 20V or 48V INCLUDES 5V so the statement could have been written as 5A at ALL voltages between 5V and 20V PD3.0 or 48VPD3.1.

EDIT: I just added a pic of the wire gauge marking on the cable.

IMG 8137
IMG 8138

I will reply to any reply other than agreed with a link to this post.

First computer 1959. Retired from my own computer company 2004.
Hardware - Expert in 1401, and 360, fairly knowledge in PC plus numerous MPU's and MCU's
Major Languages - Machine language, 360 Macro Assembler, Intel Assembler, PL/I and PL1, Pascal, Basic, C plus numerous job control and scripting languages.
Sure you can learn to be a programmer, it will take the same amount of time for me to learn to be a Doctor.


   
ReplyQuote
Ron
 Ron
(@zander)
Father of a miniature Wookie
Joined: 3 years ago
Posts: 6829
 

@davee @whitneydesignlabs,

Gentlemen, I am going to change my mind. I have looked everywhere and found no concrete proof that at 5.1V, the USB-C PD3.0 standard allows for more than 3A. The official wall wart is 5.1V at 5A, but is that an out-of-spec device?

The wording of everything I read is very weaselly, it can be read as only 3A at 5V or 5A at any voltage. Those specs were obviously written by lawyers.

Since I am seeing literally dozens, if not more, websites saying the same thing, or rather showing the same or similar graphs, I am forced to change my finding to maybe or not more than 3A at 5V.

What really threw me was the offering of 5A UPS modules for the Pi4. I don't know why they would go above the official supply unless, for UPS operations, they assume a large auxiliary load.

I think I learned a few things so this wasn't a total waste of my time, I hope everyone else feels the same. 

 

First computer 1959. Retired from my own computer company 2004.
Hardware - Expert in 1401, and 360, fairly knowledge in PC plus numerous MPU's and MCU's
Major Languages - Machine language, 360 Macro Assembler, Intel Assembler, PL/I and PL1, Pascal, Basic, C plus numerous job control and scripting languages.
Sure you can learn to be a programmer, it will take the same amount of time for me to learn to be a Doctor.


   
DaveE and Inst-Tech reacted
ReplyQuote
WhitneyDesignLabs
(@whitneydesignlabs)
Member
Joined: 3 years ago
Posts: 99
Topic starter  

@zander @davee, I am still following this thread with interest. But I don't have any new data points to offer or any insights into USB standards and protocols. As mentioned, my issue is "solved", in quote marks, because it works, but obviously is less than ideal.  I am sure as Pi5s become more commonly in use, other power options will start presenting themselves.

In the meantime I am exploring:

A1) small form factor PC to run Linux, in place of a pi5. (actively, testing with Dell Optiplex 7050, found at scrapyard for $5)

A2) alternative SBC, with native DC power input, in place of pi5 (no budget for this at the moment)

B1) more efficient inverter/wall-wart combo to run pi5 (this option is running currently as my dev rig)

B2) and on going, the topic of the original post, a way to run pi5 natively from a DC power source (on hold, until a new idea presents itself)

Scott

Imagine by thought, create, don't wait, Scott.


   
DaveE reacted
ReplyQuote
(@davee)
Member
Joined: 3 years ago
Posts: 1628
 

Hi Ron @zander,

Thanks for your latest update.

 Your finding that 3A is the maximum current for 5V in the PD spec matches my own findings, including the Universal Serial Bus Power Delivery Specification on the USB.org website, which appears to be the source of the tables and graphs widely reproduced on other websites.

The relevant USB specification numbering system is a masterpiece of confusion, as it does not directly refer to PD 3.0 or PD 3.1 ... the only hints of these come from memos of meetings which formally ratify specs with a different numbering system.

Also, the R-Pi website page describing the 'official' R-Pi 5 power supply has to be read very carefully.

------------------

The website https://manhattanproducts.eu/pages/usb-c-pd-charging-everything-you-need-to-know, although it is not a primary information source (i.e. USB.org), seems to have summarised the confusing story, which is more difficult to follow on the USB.org site.

Essentially, PD 3.1 was an addition to PD 3.0, not a replacement, with 3.1 introducing new power levels for 20V and above, leaving 5V, 9V and 15V unchanged.

I presume, the USB organisation assumed that generally the best way of increasing power availability was to increase the voltage, and although it now includes 5A options, it did not want to push this onto the lower voltage options. Clearly R-Pi wanted to keep to 5V, and I have previously suggested a possible reason that I thought of.

Hence, 5V is only specified to 15W, which is obviously 3A.

--------------------

I think R-Pi's 'official' power supply, offering 5V at 5A, as well as 9V and 12V, is a pragmatic solution to their limitations of trying to provide capabilities of an increased processor power demand, the ability to plug in peripherals like USB disc drives that derive all of their power through a single data+power USB, and not having any voltages on the board in excess of 5V.

------------------

As to your question "The official wall wart is 5.1V at 5A, but is that an out-of-spec device?"

The strict answer appears to be "ambiguous".

I am pretty certain it EXCEEDS the specification expected of a USB PD 1 to PD 3.1 supply devices.

But I haven't seen a clear point in a spec for 'fixed' voltage supplies offering choices 5v, 9V, 12V, 20V etc. saying that offering more than the limits listed in the tables is necessarily 'out-of-spec'.

In general, it potentially raises questions about the suitability of the cables and connectors to handle the increased current. As R-Pi are supplying the cables and connectors in this specific case, they may feel they have sufficient control to answer these questions.

------------------------

Personally, I hope that our joint research will be a help to someone in what seems to have become a small minefield. I am presuming R-Pi 5 will sell in large numbers, but not all purchasers will want to use the 'official' wall wart supply, and hence may require a power source that exceeds the PD 3.1 spec.

Best wishes and take care to all, Dave


   
Inst-Tech reacted
ReplyQuote
Ron
 Ron
(@zander)
Father of a miniature Wookie
Joined: 3 years ago
Posts: 6829
 

@davee @whitneydesignlabs I find it not just frustrating that official written specs are incorrect (at least given my understanding of the written word) but downright unprofessional.

Also, somebody needs to ask the Pi folks how they are pushing 5A into a device rated at 3A.

Oh well, on to the next mystery.

First computer 1959. Retired from my own computer company 2004.
Hardware - Expert in 1401, and 360, fairly knowledge in PC plus numerous MPU's and MCU's
Major Languages - Machine language, 360 Macro Assembler, Intel Assembler, PL/I and PL1, Pascal, Basic, C plus numerous job control and scripting languages.
Sure you can learn to be a programmer, it will take the same amount of time for me to learn to be a Doctor.


   
Inst-Tech reacted
ReplyQuote
WhitneyDesignLabs
(@whitneydesignlabs)
Member
Joined: 3 years ago
Posts: 99
Topic starter  

I have no new info to offer on my Pi5 running on DC. Still using the inverter method for the time being.

I wanted to post a video from Andreas Spiess (the guy with the Swiss accent) :). He goes into very fine detail about USB C and misleading info about various devices and cables:

Cheers,

Scott

Imagine by thought, create, don't wait, Scott.


   
Inst-Tech and Ron reacted
ReplyQuote
Ron
 Ron
(@zander)
Father of a miniature Wookie
Joined: 3 years ago
Posts: 6829
 

@whitneydesignlabs WOW, that video is eye-opening. Basically, it's a zoo; without the test instruments he was using (I have ordered), it's impossible to know what is going on. Even worse, cables labelled as 10, 20 or more GBS are often/generally fake and similarly with power.

Once I get the testers, I will label all my cables, but the big problem is in many/most cases, I need USB-C on one end and something else on the other, and that is where everything breaks down (does NOT work)

As he points out, old and slow-charging devices like phones and laptops are better, so fancy new cables are unnecessary. For data transfer, it comes down to how often you need it, what speed, and how much you are willing to pay.

I have a 'special' drive and high-speed cable to clone my Mac system drive. It is extremely fast. I don't remember the speed, but I think it is 20GB/s, and the clone app reports the speed, so I can verify it. That cable costs $100 MORE than the usual cables. If you can live with overnight backups, you can get away with USB 2.0 speed and save a lot of money.

Somewhere down the road, maybe in 5 years or even 10 years, USB4 and TB4 will be relevant, important, easily available and cheaper, but for now, it's not something most of us need unless you are specifically testing that piece of hardware for some reason.

 

First computer 1959. Retired from my own computer company 2004.
Hardware - Expert in 1401, and 360, fairly knowledge in PC plus numerous MPU's and MCU's
Major Languages - Machine language, 360 Macro Assembler, Intel Assembler, PL/I and PL1, Pascal, Basic, C plus numerous job control and scripting languages.
Sure you can learn to be a programmer, it will take the same amount of time for me to learn to be a Doctor.


   
Inst-Tech reacted
ReplyQuote
WhitneyDesignLabs
(@whitneydesignlabs)
Member
Joined: 3 years ago
Posts: 99
Topic starter  

I have lately been working with some PoE stuff for surveillance cameras. In this process, I have discovered an entire world of PoE devices now available: injectors, USB-C ports, solar regulators, battery charging, and of course 1Gb network switches and more.  Jeff Geerling just released this video and it got me thinking about a whole new approach to powering the Pi5 at full tilt from a DC source. The answer may be PoE... I will report here if I do any testing on this approach.:

Imagine by thought, create, don't wait, Scott.


   
Ron reacted
ReplyQuote
Page 4 / 4