ESPEasy assisted DIY Nextcloud server

Moderators: grovkillen, Stuntteam, TD-er

Message
Author
User avatar
chromo23
Normal user
Posts: 1070
Joined: 10 Sep 2020, 16:02
Location: germany

ESPEasy assisted DIY Nextcloud server

#1 Post by chromo23 » 28 Jul 2025, 18:03

Hi,

I want to introduce you to my new project today. It only partly has to do with ESPEasy, but it plays an important role.

My Nextcloud server with integrated UPS
(An utilisation of electronics that I had lying around here uselessly)

Features:
  • Modular design: You can also add another 2.5" hard drive instead of the UPS (9mm). So the maximum would be two SSDs with a dual PCIe M.2 Shield and two up to 9mm high 2.5" HDDs.
  • Easy accessibility: All components are easily accessible. Hard drives can be removed from the bottom. The enclosure-cylinder can be pulled upwards, with the display serving as a fixing button.
  • Cable management: The cables of the external hard drives can be stowed in the base through extra cut-outs. The cables leading to the outside are fixed by the snap-on foot.
  • Active ventilation: It hardly ever starts unless the server is under full load and it is very warm outside. Otherwise, natural convection is sufficient.
  • Display touch button and light sensor: In the normal state, the display shows a green bar that represents the fill level of the data partition. If you press the touch button, important information is displayed. The brightness of the display is regulated depending on the LDR.
  • UPS: As soon as a power failure occurs, the Raspberry Pi shuts down. The Esp32 serves as a watchdog and wakes the RPi up again if necessary.
  • ESPEasy: ESPEasy monitors the system. It regulates the UPS (the charge controller is activated or deactivated depending on the state of charge and temperature. There is no trickle charge). It takes care of the display and other sensors for touch, light, and temperature. It communicates with the RPi via a serial connection.
  • Low consumption: 5 watts idle
  • Daily backup via rsync from SDD to HDD (I don't need a RAID so it's much more energy efficient)
Difficulties during development:

1. Display:
I use a 1.77" display with a resolution of 160x128 and the ST7735 as controller. It took me several hours to get this display to work. At some point I found the crucial clue on the Internet:
The CS pin, although specified as optional on ESPEasy, must then be connected to ground!!!

2. UPS:
I chose the cheapest UPS on Aliexpress I could find. It’s called LX-2BUPS.
It uses two parallel 18650 batteries and a boost converter.
Unfortunately, boost converters are terribly inefficient. When my system consumed 10 watts, the input power was 20 watts.
But energy efficiency is very important to me!
So I kept all the components of the UPS except for the MOSFETs for switching from external supply to battery operation and a few capacitors. I modified the board so that the batteries are connected in series. Then I added a 2S protection board (which has an integrated balancer) and an extra charging board controlled by ESPEasy.
At the output of the UPS is a very efficient buck converter that can supply up to 5 Amps. An INA216 monitors the voltage and power.
The system now consumes around 5 watts idle and 10–12 watts under load.

3. M.2 SSD on the Raspberry:
It took me a few days to install Nextcloud, as I/O errors occurred, especially when booting.
It turns out that SSD via PCIe port on the Raspberry is not the same as Plug'n'Play.
With my SSD (2TB WD Black 7100) in particular, I had to add

Code: Select all

dtparam=pciex1_gen=3
to config.txt to enable PCIe Gen 3.0 instead of Gen 2.0 to get rid of this error (that was trial and error since I couldn’t find anything on the internet).
Fortunately, the server is now running without problems.

4. Audible Fan:
The fan I had lying around doesn’t have internal PWM control. In ESPEasy, I can use a specific frequency, but the fan still didn’t sound too happy about it, and the set frequency also got reset system-wide when using the backlight control of the display.
So, since it was already connected to Pin 25, I used the DAC plugin.
And it now works really well. You can barely hear the fan while it is running.

Existing problems:
- ESPEasy sometimes crashes. Or the individual cores. Sometimes the ESP is still connected via WLAN, but ESPEasy is no longer accessible. Or the ‘wifi’ core crashes and then only a manual reset helps. Not so good for a server that is not always within reach.
I think the serial server plugin is causing problems. I receive serial data from the Raspberry and then immediately send an acknowledge message to the Raspberry.
I have deactivated the Ack message and now it seems to work...

Here are some pictures (I didn’t put too much effort into cleaning up the 3D printed parts):
Main1.jpeg
Main2.jpeg
hdd_out.jpg
top.jpg
cable.jpeg
espboard.jpg
usv1.jpg
You do not have the required permissions to view the files attached to this post.
Last edited by chromo23 on 28 Jul 2025, 18:53, edited 4 times in total.

User avatar
chromo23
Normal user
Posts: 1070
Joined: 10 Sep 2020, 16:02
Location: germany

Re: ESPEasy assisted DIY Nextcloud server

#2 Post by chromo23 » 28 Jul 2025, 18:05

More pics:
i_front_r.jpeg
i_back_r.jpeg
i_back.jpeg
i_left.jpeg
i_front_l2.jpeg
i_front_l.jpeg
top_enc.jpg
You do not have the required permissions to view the files attached to this post.

User avatar
Ath
Normal user
Posts: 4547
Joined: 10 Jun 2018, 12:06
Location: NL

Re: ESPEasy assisted DIY Nextcloud server

#3 Post by Ath » 28 Jul 2025, 19:41

Looking great :D
/Ton (PayPal.me)

User avatar
Ath
Normal user
Posts: 4547
Joined: 10 Jun 2018, 12:06
Location: NL

Re: ESPEasy assisted DIY Nextcloud server

#4 Post by Ath » 28 Jul 2025, 20:02

chromo23 wrote: 28 Jul 2025, 18:03 1. Display:
I use a 1.77" display with a resolution of 160x128 and the ST7735 as controller. It took me several hours to get this display to work. At some point I found the crucial clue on the Internet:
The CS pin, although specified as optional on ESPEasy, must then be connected to ground!!!
This actually works 'the other way around': Some of these ST7735 displays do not have a CS pin available, that's why the GPIO setting is optional, if the display does have a CS pin, then it should be connected :shock: :roll:
/Ton (PayPal.me)

TD-er
Core team member
Posts: 10210
Joined: 01 Sep 2017, 22:13
Location: the Netherlands

Re: ESPEasy assisted DIY Nextcloud server

#5 Post by TD-er » 28 Jul 2025, 20:16

Well if the display is the only one on that SPI bus, then you don't really need a CS signal.
When addressing the device, the CS pin of that device is pulled down.

However if the CS signal is not in sync with the other SPI signals, then it can be too late at the start or pulled high too soon.
Especially with SPI, which typically uses higher frequencies, the signal integrity may start playing a role.

TD-er
Core team member
Posts: 10210
Joined: 01 Sep 2017, 22:13
Location: the Netherlands

Re: ESPEasy assisted DIY Nextcloud server

#6 Post by TD-er » 28 Jul 2025, 20:16

By the way, looking nice !

User avatar
chromo23
Normal user
Posts: 1070
Joined: 10 Sep 2020, 16:02
Location: germany

Re: ESPEasy assisted DIY Nextcloud server

#7 Post by chromo23 » 28 Jul 2025, 22:37

TD-er wrote: 28 Jul 2025, 20:16 By the way, looking nice !
Ath wrote: 28 Jul 2025, 19:41Looking great
Thanks :)

Forgot to show the nice Dashboard coming with the server ;)
NC_dash.png
You do not have the required permissions to view the files attached to this post.

Who is online

Users browsing this forum: Ahrefs [Bot], Anthropic Claude Bot [bot] and 2 guests