Huawei B593 s-22 RS-232 pins
Thursday, March 19. 2015
As I told earlier, I bricked one. It was a loaned one, so I really got burned on that. There was not much to do, but pop the hood of the s-22 and hope to find something interesting there. An interesting thing would be serial console (RS-232) or JTAG.
There are 3 Phillips PH-2 screws holding the unit together. One screw always has a thin paper on top of it. It is a "Huawei-thing". If the paper is broken, it will void your warranty. Remove the 3 screws, and you can pry the box open:
Then the front cover is gone, you have the wrong side of the motherboard in front of you. You need to detach the MoBo from the back cover. There are 4 Phillips PH-2 screws holding it:
Now you're seeing the real thing:
Here is a layout of all the good stuff:
Mr. Asiantuntijakaveri gave me a hint to check couple pins near the CPU for serial signal. I attached an oscilloscope into couple of interesting pins and got following:
Definitely an RS-232 signal. Based on the timings, looks like 115200 bps. Just as in B593 u-12. The only thing was about the voltage. My scope said 1,792 volts peak-to-peak. That's way too low for my 3,3 volt TTL to RS-232 converter. I put in a purchase order for more capable (expensive) adapter and eventually UPS-guy brought it to me:
The one I have is Future Technology Devices International TTL-232RG, TTL-232RG-VREG1V8-WE to be specific. Their spec says: VREG1V8 = USB to UART cable with +5 to +1.8V TTL level UART signals and WE = wire end. A Linux sees it as a Bus 005 Device 004: ID 0403:6001 Future Technology Devices International, Ltd FT232 USB-Serial (UART) IC
. It is fully working after plugging in both on a Linux and Windows 7.
I put this into a PuTTY (115200 N81, no flow control):
And yes, there are results:
onchip NF_boot! UnSec_boo v?l?space?%s start addr:0x%x size:0x%x first step second step thred step DDR exam right !!!!!!!!!!!!!!!!!!!!!!! press space key to enter bootrom: Start from: vxWorks Kernel. >>loading: VxWorks ... success. >>loading: FastBoot ... success. hw main id:00000400, sub id:00000001activate_fastboot...0x3CD00000 Starting from entry: 0x30004000
That's it no more. Not very useful. Then Mr. Asiantuntijakaveri gave me another hint. Try the three-finger-salute, press WiFi, Reset and WPS buttons and then kick on the power. An u-12 will go to some sort of serial-console service mode. And yes, a s-22 does the same. All I have to do is have all three buttons pressed, kick the power on and immediately release all them. Now I have on serial:
first step second step thred step DDR exam right !!!!!!!!!!!!!!!!!!!!!!! press space key to enter bootrom: enter load backup IMAGE_BOOTROM load from:0x00340000>>loading: BootRom ... try inflate. image length: 000A412A ram_inflate_addr: 34F4382E inflating... return value: 00000000 inflate success! data check OK! hw main id:00000400, sub id:00000001Starting from entry: 0x300040Target Name: vxTarget Adding 5472 symbols for standalone. ]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]] ]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]] ]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]] ]]]]]]]]]]] ]]]] ]]]]]]]]]] ]] ]]]] (R) ] ]]]]]]]]] ]]]]]] ]]]]]]]] ]] ]]]] ]] ]]]]]]] ]]]]]]]] ]]]]]] ] ]] ]]]] ]]] ]]]]] ] ]]] ] ]]]] ]]] ]]]]]]]]] ]]]] ]] ]]]] ]] ]]]]] ]]]] ]]] ]] ] ]]] ]] ]]]]] ]]]]]] ]] ]]]]]]] ]]]] ]] ]]]] ]]]]] ] ]]]] ]]]]] ]]]]]]]] ]]]] ]] ]]]] ]]]]]]] ]]]] ]]]]]] ]]]]] ]]]]]] ] ]]]]] ]]]] ]] ]]]] ]]]]]]]] ]]]] ]]]]]]] ]]]]] ] ]]]]]] ] ]]] ]]]] ]] ]]]] ]]]] ]]]] ]]]] ]]]]]]]] ]]]]] ]]] ]]]]]]] ] ]]]]]]] ]]]] ]]]] ]]]] ]]]]] ]]]]]]]]]]]]]]]]]]]]]]]]]]]]]] ]]]]]]]]]]]]]]]]]]]]]]]]]]]]] Development System ]]]]]]]]]]]]]]]]]]]]]]]]]]]] ]]]]]]]]]]]]]]]]]]]]]]]]]]] VxWorks 6.8 ]]]]]]]]]]]]]]]]]]]]]]]]]] KERNEL: WIND version 2.13 ]]]]]]]]]]]]]]]]]]]]]]]]] Copyright Wind River Systems, Inc., 1984-2009 CPU: ARM RealView PBX-A9. Processor #0. Memory Size: 0x4efa000. BSP version 2.0/0. Created: Jun 03 2013, 13:52:34 ED&R Policy Mode: Deployed -> GU base addr: 0x3e200000 HIFI base addr: 0x3f800000 ===== beg mem usr function ===== Hisilicon NANDC_V4.00 initialize... NAND device: Manufacturer ID: 0xad, Chip ID: 0xbc (Hynix NAND 512MiB 1,8V 16-bit) ptable_yaffs_mount: /yaffs0 ...yaffs: Mounting /yaffs0 yaffs: yaffs_GutsInitialise() yaffs: yaffs_GutsInitialise() done. OK. ptable_yaffs_mount: /yaffs1 ...yaffs: Mounting /yaffs1 yaffs: yaffs_GutsInitialise() yaffs: yaffs_GutsInitialise() done. OK. ptable_yaffs_mount: /yaffs2 ...yaffs: Mounting /yaffs2 yaffs: yaffs_GutsInitialise() Collecting block 1136, in use 39, shrink 0, wholeBlock 0 Collecting block 1136, in use 34, shrink 0, wholeBlock 0 Collecting block 1136, in use 29, shrink 0, wholeBlock 0 Collecting block 1136, in use 24, shrink 0, wholeBlock 0 Collecting block 1136, in use 19, shrink 0, wholeBlock 0 Collecting block 1136, in use 14, shrink 0, wholeBlock 0 Collecting block 1136, in use 9, shrink 0, wholeBlock 0 Collecting block 1136, in use 4, shrink 0, wholeBlock 0 yaffs: yaffs_GutsInitialise() done. OK. ptable_yaffs_mount: /yaffs5 ...yaffs: Mounting /yaffs5 yaffs: yaffs_GutsInitialise() yaffs: yaffs_GutsInitialise() done. OK. Collecting block 301, in use 34, shrink 0, wholeBlock 0 Collecting block 301, in use 29, shrink 0, wholeBlock 1 0x34ef9d7c (tRootTask): PMU PWR IRQ1 : 0x0 0x34ef9d7c (tRootTask): PMU PWR IRQ2 : 0x20 0x34ef9d7c (tRootTask): PMU PWR IRQ3 : 0x0 0x34ef9d7c (tRootTask): PMU REG IRQ1 : 0x0 0x34ef9d7c (tRootTask): PMU REG IRQ2 : 0x20 0x34ef9d7c (tRootTask): PMU REG IRQ3 : 0x0 0x34ef9d7c (tRootTask): PMU REG H_N_STATUS(0x43) : 0x0 0x34ef9d7c (tRootTask): PMU REG H_N_STATUS(0x44) : 0x0 0x34ef9d7c (tRootTask): PMU FLAG REG 0x4 : 0x0 0x34ef9d7c (tRootTask): PMU FLAG REG 0x5 : 0x0 0x34ef9d7c (tRootTask): PMU FLAG REG 0x6 : 0x0 0x34ef9d7c (tRootTask): PMU FLAG REG 0x7 : 0x5 0x34ef9d7c (tRootTask): PMU FLAG REG 0x8 : 0x0 0x34ef9d7c (tRootTask): hw main id:0x400, sub id:0x1 0x34ef9d7c (tRootTask): PMU NVM_Read ERROR. 0x34ef9d7c (tRootTask): getFactoryMode:not in factory mode! 0x34ef9d7c (tRootTask): BootRom update_getWebUIUpdateFlag: 0x8B6A7024 0x34ef9d7c (tRootTask): dloadIsDoBackupUpdate: need to do the backup update! 0x34ef9d7c (tRootTask): getBackupBinState: open file failed! 0x34ef9d7c (): task deadexcutePreBackupUpdate: the backup bin is invalid! 0x34ef9d7c (): task deadclearBkupUpdateFlag: succeed to clear the backup update flag! 0x303c32f0 (tUSBTask): BSP_USB_GetDevDescIdx: MDM+PCUI+DIAG in Bootrom image 0x303c32f0 (tUSBTask): Starting USBware stack, Version 3.4.30.21
Oh yes! I was getting somewhere. On an enter I got a prompt and threw in some commands:
[M]->? C interp: syntax error. [M]->help help Print this list dbgHelp Print debugger help info edrHelp Print ED&R help info ioHelp Print I/O utilities help info nfsHelp Print nfs help info netHelp Print network help info rtpHelp Print process help info spyHelp Print task histogrammer help info timexHelp Print execution timer help info h [n] Print (or set) shell history i [task] Summary of tasks' TCBs ti task Complete info on TCB for task sp adr,args... Spawn a task, pri=100, opt=0x19, stk=20000 taskSpawn name,pri,opt,stk,adr,args... Spawn a task tip "dev=device1#tag=tagStr1", "dev=device2#tag=tagStr2", ... Connect to one or multiple serial lines td task Delete a task ts task Suspend a task tr task Resume a task Type to continue, Q or q to stop: tw task Print pending task detailed info w [task] Print pending task info d [adr[,nunits[,width]]] Display memory m adr[,width] Modify memory mRegs [reg[,task]] Modify a task's registers interactively pc [task] Return task's program counter iam "user"[,"passwd"] Set user name and passwd whoami Print user name devs List devices ld [syms[,noAbort][,"name"]] Load stdin, or file, into memory (syms = add symbols to table: -1 = none, 0 = globals, 1 = all) lkup ["substr"] List symbols in system symbol table lkAddr address List symbol table entries near address checkStack [task] List task stack sizes and usage printErrno value Print the name of a status value period secs,adr,args... Spawn task to call function periodically repeat n,adr,args... Spawn task to call function n times (0=forever) version Print VxWorks version info, and boot line shConfig ["config"] Display or set shell configuration variables Type to continue, Q or q to stop: strFree [address] Free strings allocated within the shell (-1=all) NOTE: Arguments specifying 'task' can be either task ID or name. value = 10 = 0xa [M]->
I don't yet know what to do with all that, but ... if I do, I'll tell about it. The part "press space key to enter bootrom
" sounds interesting. I don't know if I can un-brick this thing from VxWorks-side.
So, about the pins. First a ground is needed. Typically it's available almos everywhere. There are couple of easy points to get the ground from, especially in the PSU-area. Of all the easily available GND-pins I chose this one:
The choice was made by a simple logic, it was just an easy one to solder. Then the RS-232 DCE pins at the CPU-unit:
The metallic thing is simply a cover, the actual CPU is under that hood. I did check that one out, but I didn't find anything interesting under that one. Also understand about serial signals, that transmit and receive are from the point of the router (DCE), not from your computer (that would be DTE). You can think of it like this: when DCE transmits (TX), it will go to receive (RX) of a DTE.
If you do your own hacks, know that the power system on a s-22 is weird one. Input is 12 VDC, majority of the Vcc pins have 5 VDC, but I seriously doubt that the system would run on that voltage. If you need it, there is one easily accessible pin with 3,3 VDC:
At the time of writing, the box is still bricked. But this time I have something to work with.
Update 24th Mar 2015:
There is more information available about this subject in this article.
Sylpheed on :
Jari Turkia on :
In the bootup there is a "getFactoryMode:not in factory mode!", but I guess that is a different thing?
james on :
turn on power and only Power led is on...ok
press WLAN+WPS 30sec +/-, release the buttons and wait, if the signal bars turns on (4+ number 5 is blinking, ok, wait for the sistem to restore.
OR
press WLAN+WPS 30sec +/- release the buttons and turn off device and turn up again.
OR
turn on de device and press same time again WLAN+WPS, 30sec +/- and release, and wait if the sistem restore.
Tell me if it works, i dont remenber exactly what ive done, but its someting like that
Jari Turkia on :
Sebastian on :
Jari Turkia on :
OUSSAMA AMRI on :
I want to ask you can i use CP2102 USB instead of TTL-232RG !
Thank you
CP2102 USB
http://goo.gl/YhvsXz
OUSSAMA AMRI on :
http://goo.gl/YhvsXz
Jari Turkia on :
Fidel on :
Have you progress in this deal?
I have a B593s-22 only light the power LED, it has rong firmware update.
I can connect Wxworks and that is all!
When you connect ssh, then you use lan connection or jtag?
Jari Turkia on :
András on :
I am very sad!
You will still be dealing with it?
Is it dead project?
Jari Turkia on :
Earlier this year I moved to another country and pretty much all my electronics-projects are on deep freeze for the time being. I'll be working more on software and operating system -things as they don't require specialized hardware.
Jon on :
Ismael on :
Could you or someone help me to identify the values these two components to replace them?