Re: Debian on WD MyCloud EX 4100 November 30, 2017 05:26PM |
Admin Registered: 13 years ago Posts: 19,094 |
cd /boot
cd /boot/dts mv armada-388-wd-ex4100.dtb armada-388-wd-ex4100.dtb.orig mv ../armada-388-wd-ex4100.dtb .
Re: Debian on WD MyCloud EX 4100 November 30, 2017 05:49PM |
Registered: 7 years ago Posts: 11 |
root@debian:~# dmesg | grep tty [ 0.000000] Kernel command line: console=ttyS0,115200 root=LABEL=rootfs rootdelay=10 earlyprintk=serial mtdparts=armada-nand:5m@0(u-boot),5m@5m(kernel),5m@10m(uRamdisk),441m@15m(image.cfs),15m@456m(rescue_fw),20m@471m(config),10m@491m(reserve1),10m@501m(reserve2) [ 1.152223] console [ttyS0] disabled [ 1.176119] f1012000.serial: ttyS0 at MMIO 0xf1012000 (irq = 22, base_baud = 12500000) is a 16550A [ 1.185213] console [ttyS0] enabled
root@debian:~# mcm-daemon -fd mcm-daemon[3413]: Bind name to ls. mcm-daemon[3413]: Listen on ls for connections. mcm-daemon[3413]: Server startup success on port 57367 mcm-daemon[3413]: Got no stop magic, but read 1 bytes! mcm-daemon[3413]: Buf 0: 0 mcm-daemon[3413]: Try number: 1 mcm-daemon[3413]: Got no stop magic, but read 1 bytes! mcm-daemon[3413]: Buf 0: 152 mcm-daemon[3413]: Try number: 2 mcm-daemon[3413]: Got no stop magic, but read 1 bytes! mcm-daemon[3413]: Buf 0: 152 mcm-daemon[3413]: Try number: 3 mcm-daemon[3413]: Got no stop magic, but read 1 bytes! mcm-daemon[3413]: Buf 0: 152 mcm-daemon[3413]: Try number: 4 mcm-daemon[3413]: Error sending DeviceReady command, exit!
Re: Debian on WD MyCloud EX 4100 December 01, 2017 12:00AM |
Registered: 7 years ago Posts: 119 |
[ 1.152223] console [ttyS0] disabled [ 1.176119] f1012000.serial: ttyS0 at MMIO 0xf1012000 (irq = 22, base_baud = 12500000) is a 16550A [ 1.185213] console [ttyS0] enabled
[ 1.325450] console [ttyS0] disabled [ 1.349214] f1012000.serial: ttyS0 at MMIO 0xf1012000 (irq = 23, base_baud = 12500000) is a 16550A [ 1.358241] console [ttyS0] enabled [ 1.394748] f1012100.serial: ttyS1 at MMIO 0xf1012100 (irq = 24, base_baud = 12500000) is a 16550A
+ serial@12100 { + status = "okay"; + };
Re: Debian on WD MyCloud EX 4100 December 01, 2017 01:02AM |
Admin Registered: 13 years ago Posts: 19,094 |
Quote
@bodhi?
Can you boot the WD firmware and run dmesg | grep ttyS so we can confirm the second serial is supposed to be at 12100 for the EX4100?
Quote
internal-regs {
i2c@11000 {
status = "okay";
clock-frequency = <100000>;
};
i2c@11100 {
status = "okay";
clock-frequency = <100000>;
};
serial@12000 {
status = "okay";
};
serial@12100 {
status = "okay";
};
ethernet@30000 {
status = "okay";
phy = <&phy1>;
phy-mode = "rgmii-id";
buffer-manager = <&bm>;
bm,pool-long = <2>;
bm,pool-short = <3>;
};
Re: Debian on WD MyCloud EX 4100 December 01, 2017 08:03AM |
Registered: 7 years ago Posts: 119 |
Quote
bodhi
No, I cannot :) I don't have this box, you forgot that I do not have the hardware :) I only worked on it virtually based on saschadd information. Either saschadd or esion has to do it.
Re: Debian on WD MyCloud EX 4100 December 01, 2017 09:43AM |
Registered: 7 years ago Posts: 11 |
Re: Debian on WD MyCloud EX 4100 December 01, 2017 12:29PM |
Registered: 7 years ago Posts: 119 |
Re: Debian on WD MyCloud EX 4100 December 01, 2017 01:31PM |
Registered: 7 years ago Posts: 11 |
root@debian:~# dmesg | grep tty [ 0.000000] Kernel command line: console=ttyS0,115200 root=LABEL=rootfs rootdelay=10 earlyprintk=serial mtdparts=armada-nand:5m@0(u-boot),5m@5m(kernel),5m@10m(uRamdisk),441m@15m(image.cfs),15m@456m(rescue_fw),20m@471m(config),10m@491m(reserve1),10m@501m(reserve2) [ 1.152483] console [ttyS0] disabled [ 1.176464] f1012000.serial: ttyS0 at MMIO 0xf1012000 (irq = 22, base_baud = 12500000) is a 16550A [ 1.185520] console [ttyS0] enabled
Re: Debian on WD MyCloud EX 4100 December 01, 2017 01:56PM |
Registered: 7 years ago Posts: 119 |
Re: Debian on WD MyCloud EX 4100 December 01, 2017 02:02PM |
Registered: 7 years ago Posts: 11 |
Re: Debian on WD MyCloud EX 4100 December 01, 2017 02:49PM |
Registered: 7 years ago Posts: 119 |
fdtfile=armada-38x-modular.dtb
Re: Debian on WD MyCloud EX 4100 December 01, 2017 03:16PM |
Registered: 7 years ago Posts: 11 |
[ 0.000000] Kernel command line: console=ttyS0,115200 root=LABEL=rootfs rootdelay=10 earlyprintk=serial mtdparts=armada-nand:5m@0(u-boot),5m@5m(kernel),5m@10m(uRamdisk),441m@15m(image.cfs),15m@456m(rescue_fw),20m@471m(config),10m@491m(reserve1),10m@501m(reserve2) [ 1.037730] console [ttyS0] disabled [ 1.061720] f1012000.serial: ttyS0 at MMIO 0xf1012000 (irq = 23, base_baud = 12500000) is a 16550A [ 1.070796] console [ttyS0] enabled [ 1.107157] f1012100.serial: ttyS1 at MMIO 0xf1012100 (irq = 24, base_baud = 12500000) is a 16550A
root@debian:~# mcm-daemon -df mcm-daemon[3443]: Bind name to ls. mcm-daemon[3443]: Listen on ls for connections. mcm-daemon[3443]: Server startup success on port 57367 mcm-daemon[3443]: Try number: 1 mcm-daemon[3443]: mcm-daemon startup complete, going to FanControl mode mcm-daemon[3443]: found 4 ata ports mcm-daemon[3443]: setFanSpeed 50 mcm-daemon[3443]: Try number: 1 mcm-daemon[3443]: Returning 1 read bytes mcm-daemon[3443]: Try number: 1 mcm-daemon[3443]: Read system temperature: 29 °C mcm-daemon[3443]: Returning 1 read bytes mcm-daemon[3443]: Try number: 1 mcm-daemon[3443]: Read fan rpm: 1241 mcm-daemon[3443]: system temp: 29 fan rpm: 1241 mcm-daemon[3443]: query disk 1 temperature mcm-daemon[3443]: query disk 2 temperature mcm-daemon[3443]: query disk 3 temperature mcm-daemon[3443]: query disk 4 temperature mcm-daemon[3443]: system tempOld: 29, temp: 29, fanSpeed: 50, fanRpm: 1241 mcm-daemon[3443]: setFanSpeed 50 mcm-daemon[3443]: Try number: 1
Re: Debian on WD MyCloud EX 4100 December 01, 2017 03:39PM |
Admin Registered: 13 years ago Posts: 19,094 |
Re: Debian on WD MyCloud EX 4100 December 01, 2017 03:52PM |
Registered: 7 years ago Posts: 11 |
Re: Debian on WD MyCloud EX 4100 December 01, 2017 03:56PM |
Registered: 7 years ago Posts: 119 |
char PLedOffCmd[] = {0xfa, 0x26, 0x00, 0x01, 0x00, 0x01, 0xfb}; char PLedBlueOnCmd[] = {0xfa, 0x26, 0x00, 0x11, 0x00, 0x01, 0xfb}; char PLedBlueBlinkCmd[] = {0xfa, 0x26, 0x00, 0x21, 0x00, 0x01, 0xfb}; char PLedBlueFadeCmd[] = {0xfa, 0x26, 0x00, 0x41, 0x00, 0x01, 0xfb}; char PLedRedOnCmd[] = {0xfa, 0x26, 0x00, 0x14, 0x00, 0x01, 0xfb}; char PLedRedBlinkCmd[] = {0xfa, 0x26, 0x00, 0x24, 0x00, 0x01, 0xfb}; char PLedOrangeOnCmd[] = {0xfa, 0x26, 0x00, 0x12, 0x00, 0x01, 0xfb}; char PLedOrangeBlinkCmd[] = {0xfa, 0x26, 0x00, 0x22, 0x00, 0x01, 0xfb};
Re: Debian on WD MyCloud EX 4100 December 01, 2017 03:58PM |
Admin Registered: 13 years ago Posts: 19,094 |
Re: Debian on WD MyCloud EX 4100 December 01, 2017 04:12PM |
Registered: 7 years ago Posts: 119 |
Quote
bodhi
How far did saschadd and I got regarding Power Off
import serial from time import sleep port = serial.Serial("/dev/ttyS1", 115200, 8, "N", 1, 0.1) def WritePktToSerial(port, data): assert len(data) == 7 port.write(data) port.flush() def ReadPktFromSerial(port, timeout=5): data = port.read(7) if data and len(data) == 7 and data[0] == "\xfa" and data[6] == "\xfb": return data WritePktToSerial(port,"\xfa\x03\x03\x01\x01\x01\xfb") resp = ReadPktFromSerial(port) import binascii print binascii.hexlify(resp)
Check_SYSTEM_Command=03 nick pwr off 1 phy data=01 phy dir=01 nick pwr on Check_SYSTEM_Command=11 PwrOnCause=08
Check_SYSTEM_Command=03 Yosemite Uart test nick 2222 nick pwr on Check_SYSTEM_Command=11 PwrOnCause=02
Re: Debian on WD MyCloud EX 4100 December 01, 2017 04:29PM |
Registered: 7 years ago Posts: 11 |
root@debian:# telnet localhost 57367 Trying ::1... Trying 127.0.0.1... Connected to localhost. Escape character is '^]'. help DeviceReady Tells the MCU, tht the device booted fully SetFanMode set fan control to mode "auto" or "manual" GetFanRpm Reads the fan speed from the MCU SetFanSpeed set the fan pwm value to 0 | min ... max GetSysTemp Reads the system temperatur from the MCU GetHddTemp print harddisk temperatures PwrLedOff switches the all power leds off PwrLedBlue switches the power led to blue PwrLedBlueBlink blinks the power led blue PwrLedBlueFade fades power led blue PwrLedRed switches the power led to red PwrLedRedBlink blinks the power led red PwrLedOrange switches the power led to orange PwrLedOrangeBlink blinks the power led orange ShutdownDaemon stops the mcm-daemon help shows this message quit closes connection to daemonSetFanMode, GetFanRpm, SetFanSpeed, GetSysTemp seem to work, all other commands do not work.
Re: Debian on WD MyCloud EX 4100 December 01, 2017 04:31PM |
Admin Registered: 13 years ago Posts: 19,094 |
Re: Debian on WD MyCloud EX 4100 December 01, 2017 04:35PM |
Admin Registered: 13 years ago Posts: 19,094 |
Quote
I just tested the "Power Off" command from the kernel patch on my EX2100. It doesn't stay powered off, just shutting off for about 1 second and then starting again immediately.
Re: Debian on WD MyCloud EX 4100 December 01, 2017 04:37PM |
Registered: 7 years ago Posts: 11 |
Re: Debian on WD MyCloud EX 4100 December 02, 2017 12:40AM |
Registered: 7 years ago Posts: 119 |
Quote
bodhi
Perhaps you can try to pigyyback the mcmdaemon Power Off in /etc/init.d/halt?
Quote
esion
Just a wild guess: Maybe you have to tell the MCU to stay off? Standard behaviour is to boot if there is power.
Quote
esion
For strace I would have to boot to stock, right?
Re: Debian on WD MyCloud EX 4100 December 02, 2017 03:55AM |
Admin Registered: 13 years ago Posts: 19,094 |
Re: Debian on WD MyCloud EX 4100 December 02, 2017 11:44AM |
Registered: 7 years ago Posts: 119 |
Quote
bodhi
We don't do power off during normal operation. There are quite a few things that need to happen before power off is issued, as the final step.
Re: Debian on WD MyCloud EX 4100 December 02, 2017 04:19PM |
Admin Registered: 13 years ago Posts: 19,094 |
johnei
Re: Debian on WD MyCloud EX 4100 June 18, 2019 09:19AM |
johnei
Re: Debian on WD MyCloud EX 4100 June 18, 2019 09:20AM |