Newbie Questions / Documentation

strahlermann
 
Posts: 11
Joined: Sun Dec 11, 2016 9:34 am

Newbie Questions / Documentation

Sun Dec 11, 2016 10:40 am

Hi, I received my vocore2 yesterday (almost forgot about backing this) and I really like the little thing.
I'm almost completely new to these things though I did some easy raspi projects before.

However, I stumbled upon the wpa2 issue mentioned in another post and thought maybe an update would fix this and I could get wpa enabled, so I picked the wrong file and tried to update via Webinterface.

Result is vocore2 is bricked.

Now I tried to get it working again using the docs at http://vocore.io/v2u.html, which turned out to be not that easy.

I really hope I only need to follow "Fix Bricked VoCore2 (uboot alive)" but there are some questions:

"VoCore2 GD32 USB2TTL is driver free, but have to wait 6~8 seconds until it is ready"
What will be the device I have to connect to assuming I am using an Ubuntu Linux?
Or even better could someone provide an example kermit config for connection to vocore2 with ultimate dock

How do I find out if uboot is dead or alive? Is the device name different in /dev/* ?

Hope someone can help me with this. Tomorrow I'll have time to have a deeper look and I hope I can give the answers myself then.

thank you in advance and greetings from Germany

Vonger
 
Posts: 896
Joined: Sun Oct 19, 2014 6:00 am

Re: Newbie Questions / Documentation

Sun Dec 11, 2016 1:01 pm

Hi, it is /dev/tty.usbmodem_____1, speed 115200, 8n1
thank you for the information, i will update the tutorial.

strahlermann
 
Posts: 11
Joined: Sun Dec 11, 2016 9:34 am

Re: Newbie Questions / Documentation

Sun Dec 11, 2016 1:30 pm

Hi I already found time to look further into this, on my system (some ubuntu) it's "/dev/ttyACM0" or "/dev/ttyACM1" if you replug it into another USB port.
This is what I did
I did a chmod 777 /dev/ttyACM0
then:
(/home/uli/) C-Kermit>set speed 115200
/dev/ttyACM0, 115200 bps
(/home/uli/) C-Kermit>set carrier-watch off
(/home/uli/) C-Kermit>set prefixing all
(/home/uli/) C-Kermit>set parity none
(/home/uli/) C-Kermit>set stop-bits 1
(/home/uli/) C-Kermit>set modem none
(/home/uli/) C-Kermit>set file type bin
(/home/uli/) C-Kermit>set file name lit
(/home/uli/) C-Kermit>set flow-control none
(/home/uli/) C-Kermit
(/home/uli/) C-Kermit>c


============================================
Ralink UBoot Version: 4.3.0.0
--------------------------------------------
ASIC 7628_MP (Port5<->None)
DRAM component: 1024 Mbits DDR, width 16
DRAM bus: 16 bit
Total memory: 128 MBytes
Flash component: SPI Flash
Date:Jun 25 2016 Time:22:54:33
============================================
icache: sets:512, ways:4, linesz:32 ,total:65536
dcache: sets:256, ways:4, linesz:32 ,total:32768
RESET MT7628 PHY!!!!!!
Please choose the operation:
0: Load system code then write to Flash via SERIAL.
1: Load system code to SDRAM via TFTP.
2: Load system code then write to Flash via TFTP.
3: Boot system code via Flash (default).
4: Entr boot command line interface.
5: Load system code then write to Flash via USB Storage.
7: Load Boot Loader code then write to Flash via Serial.
8: Start Web Server to load system code.
9: Load Boot Loader code then write to Flash via TFTP.
gpio trigger enabled
GPIO 46 used to trigger webpage
Hold button for between 3 seconds and 6 seconds
then release to trigger webpage to load image
Hold button for between 6 seconds and 9 seconds
then release to trigger loading image from USBSTORAGE
GPIO 46 is low
8
You chose 7

## Ready for binary (kermit) download to 0x80100000 at 115200 bps...

(Back at uli-System-Product-Name)
----------------------------------------------------
(/home/uli/) C-Kermit>send /home/uli/Downloads/ultimate.20161114.bin
(/home/uli/) C-Kermit>


## Booting image at bc050000 ...
Image Name: MIPS OpenWrt Linux-3.18.20
Image Type: MIPS Linux Kernel Image (lzma compressed)
Data Size: 1051119 Bytes = 1 MB
Load Address: 80000000
Entry Point: 80000000
Verifying Checksum ... OK
Uncompressing Kernel Image ... OK
No initrd
## Transferring control to Linux (at address 80000000) ...
## Giving linux memsize in MB, 128

Starting kernel ...

I also tried openwrt-ramips-mt7628-vocore2-128M-sd-squashfs-sysupgrade.bin from viewtopic.php?f=16&t=3422

Now it unfortunately hangs with Starting kernel ...

noblepepper
 
Posts: 240
Joined: Sat Nov 29, 2014 3:22 pm

Re: Newbie Questions / Documentation

Sun Dec 11, 2016 8:00 pm

EDIT- Just reread your post, you need to use uboot and if you are connect to the VoCore with an ethernet cable you can use option 8 in uboot. You need to use a static IP with your computer set to 10.10.10.1 and the web page recovery will be on 10.10.10.123. You can also use a USB stick See below to use the serial connection on Linux

For anyone else that lost the wifi connection this applies-

You probably just hosed the wifi configuration and need to reset it. It is fairly hard to delete uboot, and it isn't easy to even mess up the base image on the VoCore2.

If you are on linux the VoCore2 will be /dev/ttyUSBx. The last digit is assigned automatically by linux, it will probably be ttyUSB0 but if you have other serial devices plugged in it could be different.

Here is a plan:
1. Install picocom on your Ubuntu box:
Code: Select all
$ sudo apt-get install picocom

2. Connect to the VoCore2:
Code: Select all
$ picocom -b 115200 /dev/ttyUSB0


Press enter and you should get a banner and command prompt.

3. Reboot the Vocore2:
Code: Select all
root@vocore2:/# reboot


4. Get into failsafe mode:
Watch the boot process, when you see
Press the [f] key and hit [enter] to enter failsafe mode
Press f and Enter (duh) and you should get a banner and then a prompt:

Code: Select all
================= FAILSAFE MODE active ================
special commands:
* firstboot        reset settings to factory defaults
* mount_root    mount root-partition with config files

after mount_root:
* passwd          change root's password
* /etc/config          directory with config files

for more help see:
http://wiki.openwrt.org/doc/howto/generic.failsafe
=======================================================

root@(none):/#


5. Reset the VoCore2 to how it was when you got it:
Code: Select all
root@(none):/# firstboot
[  145.282364] jffs2reset: This will erase all settings and remove any installed packages. Are you sure? [N/y]
y
[  147.772465] jffs2reset: /dev/mtdblock6 is not mounted
[  147.773878] jffs2reset: /dev/mtdblock6 will be erased on next mount
root@(none):/# reboot


When the VoCore2 boots back up it should be like it was when you got it. Actually it will be like the last time an image was flashed but I seriously doubt you have flashed one.

strahlermann
 
Posts: 11
Joined: Sun Dec 11, 2016 9:34 am

Re: Newbie Questions / Documentation

Sun Dec 11, 2016 9:02 pm

Hm, unfortunately I'm pretty sure I did like described in my last post which wasn't approved yet.

strahlermann
 
Posts: 11
Joined: Sun Dec 11, 2016 9:34 am

Re: Newbie Questions / Documentation

Tue Dec 13, 2016 8:58 am

Problem was I tried to flash the wrong image with "sdcard" in filename.

Got it working again using option 8 and flashing your image many thanks!

noblepepper
 
Posts: 240
Joined: Sat Nov 29, 2014 3:22 pm

Re: Newbie Questions / Documentation

Tue Dec 13, 2016 1:35 pm

Glad you got it going. Since you used the web page I assume you have an ultimate with the ethernet connector, correct?

The /dev/ttyACM0 instead of /dev/ttyUSB0 is probably the uart/usb converter chip on the ultimate but could be Ubuntu instead of Debian which I use. When my release boards arrive I'll confirm, I'm still running on a beta unit.

It is great to see the uboot is working well, it took quite a bit of time to get it working but it probably would have taken a lot less if I actually knew what I was doing ;-)

From your post (copy/paste is great I wish everyone would do it) I think you took the wrong option from the uboot menu. To load a new image over the serial you want option 0.

It looks like you took option 7, this is to replace uboot. Thank goodness it didn't work it is quite complicated to revive a board if uboot gets hosed. I believe this didn't actually write to the flash since the system image won't fit in the uboot partition. I thought very seriously about removing this option because it can be dangerous.

So for everyone else:
USE OPTION 0 on the uboot menu to load a new image
DON'T USE OPTION 7 UNLESS YOU CAN WRITE TO THE FLASH CHIP DIRECTLY in case of problems!!!

Since you are familiar with the uboot web interface it should be pretty easy to try system images, if you are on an ultimate would you try the sd card image again? I think you actually changed two things at once (using the web load and which image). With the image you have loaded the sdcard won't work and if the sdcard image doesn't work I need to take it down until I get it fixed!

Thanks!

strahlermann
 
Posts: 11
Joined: Sun Dec 11, 2016 9:34 am

Re: Newbie Questions / Documentation

Tue Dec 13, 2016 2:08 pm

that's why I chose option 7
from vocore2 Ultimate Wiki:
Fix Bricked VoCore2 (uboot alive)

1. connect your VoCore to computer through microUSB, keep your VoCore in reset mode.

note:: to keep VoCore in reset mode, you need to connect RST and GND by wire, use this step to wait until USB2TTL ready.

2. open tty tools(must have kermit protocol), such as kermit, ckermit.

note:: VoCore2 GD32 USB2TTL is driver free, but have to wait 6~8 seconds until it is ready, once it is ready, we can disconnect RST and GND, then it is able to boot normally.

3. power up your VoCore, once you find: "7: Entr boot command line interface.", press '7'.

note: VoCore will show "## Ready for binary (kermit) download to 0x80100000 at 115200 bps..."

note: kermit: press Ctrl and '\' same time then press 'c', you will switch to kermit command console.

5. send upgrade firmware to VoCore, after that, back to VoCore uboot console.

note: kermit: call "send path/to/your/upgrade/file/on/pc.bin" to send firmware, around 10 minutes, once it finished, call 'c' back to console.

6. wait around 20~30 seconds, firmware uploaded, your VoCore will reboot.

strahlermann
 
Posts: 11
Joined: Sun Dec 11, 2016 9:34 am

Re: Newbie Questions / Documentation

Tue Dec 13, 2016 3:31 pm

if you are on an ultimate would you try the sd card image again?


Just did, Image is working fine.

But then I tried to put in an sd card, sd card got hotter and hotter seems to be broken now. Did anybody manage to get this working?
I don't have many micro sd cards to burn.

noblepepper
 
Posts: 240
Joined: Sat Nov 29, 2014 3:22 pm

Re: Newbie Questions / Documentation

Tue Dec 13, 2016 4:35 pm

Hopefully Vonger will get that fixed quickly, The correct options are in the uboot menu (like you posted earlier). 4 is for the uboot command line, 0 is for serial upload so "7: Entr boot command line interface" is no where near correct.

0: Load system code then write to Flash via SERIAL.
1: Load system code to SDRAM via TFTP.
2: Load system code then write to Flash via TFTP.
3: Boot system code via Flash (default).
4: Entr boot command line interface.
5: Load system code then write to Flash via USB Storage.
7: Load Boot Loader code then write to Flash via Serial.
8: Start Web Server to load system code.
9: Load Boot Loader code then write to Flash via TFTP.

I don't have a board with a sd slot yet so I can't test, Vonger has tried this image but I only know he tested wifi I can't say if he tested the sd card.

Maybe it is a compatiblity issue, what model & manufacturer was the sdcard? There isn't much that can be set wrong on OpenWrt unless there is a problem in the mtk sd driver.

Next
Return to VoCore2/Lite/Ultimate

Who is online

Users browsing this forum: No registered users and 59 guests