Re: SD Linux support for Allwinner A10s

6,688 views
Skip to first unread message

Aviv Greenberg

unread,
Jan 22, 2013, 1:33:10 AM1/22/13
to ver...@gmail.com, linux...@googlegroups.com
im sure it is possible - after all android is based on linux - I just dont know what to look for otherwise i would copy the bits from nand.
A10s are relatively new, i'm sure they will get support sometimes soon. i'll keep trying...


On Mon, Jan 21, 2013 at 8:59 PM, <ver...@gmail.com> wrote:
On Friday, January 18, 2013 12:18:51 PM UTC-7, rgviva wrote:
> I bought this A10s based mini pc from here:
> http://www.tinydeal.com/android-40-tv-box-with-wifi-hdmi-1gb-ddr3-4gb-nand-flash-p-78747.html
>
> And i am trying to create a Linux image to boot from SD. So far unsuccessfully. The board only boots into android from nand.
>
> I built a sun5i uboot + kernel, and a matching root fs. I tried the generic script.bin and also tried the script.bin from the android boot partition. Not booting when the SD is plugged in. The led doesnt even light.
>
> I tried a couple of A13 SPLs (not really sure i need one? no A10s specific ones available) and also that didnt work.
>
> Any ideas?

I'm having the same problem.  I'm starting to wonder if it's even possible!  I've tried the same things you've tried.  I don't know what else to try.  :-(



--
Thanks,
Aviv

Hans de Goede

unread,
Jan 22, 2013, 4:27:18 AM1/22/13
to linux...@googlegroups.com, rgviva
Hi,

On 01/18/2013 08:18 PM, rgviva wrote:
> I bought this A10s based mini pc from here:
> http://www.tinydeal.com/android-40-tv-box-with-wifi-hdmi-1gb-ddr3-4gb-nand-flash-p-78747.html
>
> And i am trying to create a Linux image to boot from SD. So far unsuccessfully. The board only boots into android from nand.
>
> I built a sun5i uboot + kernel, and a matching root fs. I tried the generic script.bin and also tried the script.bin from the android boot partition. Not booting when the SD is plugged in. The led doesnt even light.
>
> I tried a couple of A13 SPLs (not really sure i need one? no A10s specific ones available) and also that didnt work.
>
> Any ideas?

To all following this thread, I've been working the entire weekend and
last evening on getting something other then the stock android to run
on my A10s stick, but with very little luck sofar. I've soldered wires
to the test pad and I've a serial console on the device, through which
I can access the u-boot build into the nand, but I've very little
progress to report other then that.

Here is a quick status report:

u-boot:
Trying to put any u-boot on the sdcard has sofar
completely failed to work for me.

One thing did find out is that my A10s stick is using uart0
on port PB19 and PB20 rather then uart1 on PG3 and PG4, I've written
the following u-boot patch for this, but still no luck:

--- a/arch/arm/cpu/armv7/sunxi/board.c
+++ b/arch/arm/cpu/armv7/sunxi/board.c
@@ -99,6 +99,9 @@ int gpio_init(void) {
#elif CONFIG_CONS_INDEX == 1 && defined(CONFIG_SUN4I)
sunxi_gpio_set_cfgpin(SUNXI_GPB(22), SUN4I_GPB22_UART0_TX);
sunxi_gpio_set_cfgpin(SUNXI_GPB(23), SUN4I_GPB23_UART0_RX);
+#elif CONFIG_CONS_INDEX == 1 && defined(CONFIG_SUN5I)
+ sunxi_gpio_set_cfgpin(SUNXI_GPB(19), SUN4I_GPB22_UART0_TX);
+ sunxi_gpio_set_cfgpin(SUNXI_GPB(20), SUN4I_GPB23_UART0_RX);
#elif CONFIG_CONS_INDEX == 2 && defined(CONFIG_SUN5I)
sunxi_gpio_set_cfgpin(SUNXI_GPG(3), SUN5I_GPG3_UART0_TX);
sunxi_gpio_set_cfgpin(SUNXI_GPG(4), SUN5I_GPG4_UART0_RX);
--- a/include/configs/sun5i.h
+++ b/include/configs/sun5i.h
@@ -42,6 +42,8 @@
/* Define this to have serial channel 1 (UART0) redirected to SD port */
/* #define CONFIG_UART0_PORT_F */

+#define CONFIG_CONS_INDEX 1 /* UART0 */
+
#ifndef CONFIG_CONS_INDEX
#ifdef CONFIG_UART0_PORT_F

Note this patch is still in the "hack" phase and needs cleaning up ...


kernel:
Copying a sun5i kernel from the sdcard to the nand using android and
then booting that using the build-in nand u-boot fails too. This may
be due to the build-in nand u-boot not using atag, I'll try modifying
a sun5i kernel for that, and see how that goes later today.


But all in all it looks like we're still a long way from getting things
to run on the A10s, so don't get your hopes up.


Regards,

Hans

Mehmet Mersin

unread,
Jan 22, 2013, 5:18:03 AM1/22/13
to linux...@googlegroups.com
Hello,

Today I read a post from Olimex, and they were talking about A10s.
They used a lower cost PMU to decrease costs. Maybe your A10s stick
also uses a different PMU than AXP209

"1. the PMU was changed to AXP152 instead of AXP209 this is reduced
version with less voltage outputs but generally (with attempts and
errors we found on which address it responds and fortunately most of
the commands for AXP209 worked for AXP152 too, just on differnt
address and with one additional register)"

http://olimex.wordpress.com/2013/01/21/a10s-olinuxino-micro-first-prototypes-work-fine/

If it's the case, u-boot and kernel also needs to be updated to
support this new PMU.

Regards,
-mehmet mersin
> --
>
>

Hans de Goede

unread,
Jan 22, 2013, 5:39:54 AM1/22/13
to linux...@googlegroups.com, Mehmet Mersin
Hi,

On 01/22/2013 11:18 AM, Mehmet Mersin wrote:
> Hello,
>
> Today I read a post from Olimex, and they were talking about A10s.
> They used a lower cost PMU to decrease costs. Maybe your A10s stick
> also uses a different PMU than AXP209
>
> "1. the PMU was changed to AXP152 instead of AXP209 this is reduced
> version with less voltage outputs but generally (with attempts and
> errors we found on which address it responds and fortunately most of
> the commands for AXP209 worked for AXP152 too, just on differnt
> address and with one additional register)"
>

Yes I already know :) For now I've built a kernel without AXP compiled
in, since the boot0 / boot1 stuff will already setup the pmu. And the
u-boot axp code checks the chip id, so it should not touch it after that
...

> http://olimex.wordpress.com/2013/01/21/a10s-olinuxino-micro-first-prototypes-work-fine/

Oh, that is good news.

> If it's the case, u-boot and kernel also needs to be updated to
> support this new PMU.

Yes eventually they do...

Regards,

Hans

Andrew Tarabaras

unread,
Jan 22, 2013, 6:45:16 AM1/22/13
to linux...@googlegroups.com, avi...@gmail.com


On Saturday, 19 January 2013 06:18:51 UTC+11, rgviva wrote:
I bought this A10s based mini pc from here:
http://www.tinydeal.com/android-40-tv-box-with-wifi-hdmi-1gb-ddr3-4gb-nand-flash-p-78747.html

And i am trying to create a Linux image to boot from SD. So far unsuccessfully. The board only boots into android from nand.

I built a sun5i uboot + kernel, and a matching root fs. I tried the generic script.bin and also tried the script.bin from the android boot partition. Not booting when the SD is plugged in. The led doesnt even light.

I tried a couple of A13 SPLs (not really sure i need one? no A10s specific ones available) and also that didnt work.

Any ideas?


Im wondering why you are using A13 and sun5i stuff on an A10 sun4i ? Its also very hard to setup without a serial port. 

Jonas Smedegaard

unread,
Jan 22, 2013, 7:28:35 AM1/22/13
to linux...@googlegroups.com
Hi Andrew (and others),

Quoting Andrew Tarabaras (2013-01-22 12:45:16)
> On Saturday, 19 January 2013 06:18:51 UTC+11, rgviva wrote:
>
> I bought this A10s based mini pc from here:
> [1]http://www.tinydeal.com/android-40-tv-box-with-wifi-hdmi-1gb-ddr3-4gb-nand-flash-p-78747.html
>
> And i am trying to create a Linux image to boot from SD. So far
> unsuccessfully. The board only boots into android from nand.
>
> I built a sun5i uboot + kernel, and a matching root fs. I tried the
> generic script.bin and also tried the script.bin from the android boot
> partition. Not booting when the SD is plugged in. The led doesnt even
> light.
>
> I tried a couple of A13 SPLs (not really sure i need one? no A10s
> specific ones available) and also that didnt work.
>
> Any ideas?
>
> Im wondering why you are using A13 and sun5i stuff on an A10 sun4i ? Its
> also very hard to setup without a serial port. 

A10S != A10


- Jonas

--
* Jonas Smedegaard - idealist & Internet-arkitekt
* Tlf.: +45 40843136 Website: http://dr.jones.dk/

[x] quote me freely [ ] ask before reusing [ ] keep private
signature.asc

Aviv Greenberg

unread,
Jan 22, 2013, 11:55:53 AM1/22/13
to Andrew Tarabaras, linux...@googlegroups.com
See http://linux-sunxi.org/Main_Page - the A10s is a modified A13 with similar spec but with HDMI.


--
Thanks,
Aviv

Henrik Nordström

unread,
Jan 22, 2013, 1:05:51 PM1/22/13
to linux...@googlegroups.com
tis 2013-01-22 klockan 10:27 +0100 skrev Hans de Goede:

> To all following this thread, I've been working the entire weekend and
> last evening on getting something other then the stock android to run
> on my A10s stick, but with very little luck sofar. I've soldered wires
> to the test pad and I've a serial console on the device, through which
> I can access the u-boot build into the nand, but I've very little
> progress to report other then that.

I have not yet analyzed differences between A13 and A10S. It's a bit of
a uphill as not much information is available in th A10S SDK.

What we DO NOT have in the various sun5i SDKs availbla for A13 and A10s:
- linux/arch/arm/sun5i. There is some headers available, but very little
hardware details is available in those headers.
- memory controller information
- clock controller information

The A13 and A10S SDKs do not seem to share the same source tree even if
both are claimed to be sun5i.

What can be done:
- Dump the memory and clock controller register space and try to map out
how it shuld be set, both from nand u-boot and Android Linux. Quite
likely there is only small changes compared to A13.

But SPL from sunxi-current require very little to be able to print out
it's banner. Only basic clocking of CPU, bus & UART needs to be right
for that SPL to print the banner.

And please note that to boot u-boot without PMU support on a board with
PMU you better
1. Keep the clock fequency at the "safe boot" level.
2. Maybe also disable cpufreq support in the kernel.

Regards
Henrik

Andrew Tarabaras

unread,
Jan 23, 2013, 9:40:01 AM1/23/13
to linux...@googlegroups.com
Thanks for clearing that up. Didn't know there was a 10s and didn't notice the s in your post. Good to know, I thought I had read everything on linux-sunxi.org .

Hans de Goede

unread,
Jan 23, 2013, 12:06:52 PM1/23/13
to linux...@googlegroups.com, Henrik Nordström
Hi,

On 01/22/2013 07:05 PM, Henrik Nordstr�m wrote:
> tis 2013-01-22 klockan 10:27 +0100 skrev Hans de Goede:
>
>> To all following this thread, I've been working the entire weekend and
>> last evening on getting something other then the stock android to run
>> on my A10s stick, but with very little luck sofar. I've soldered wires
>> to the test pad and I've a serial console on the device, through which
>> I can access the u-boot build into the nand, but I've very little
>> progress to report other then that.
>
> I have not yet analyzed differences between A13 and A10S. It's a bit of
> a uphill as not much information is available in th A10S SDK.
>
> What we DO NOT have in the various sun5i SDKs availbla for A13 and A10s:
> - linux/arch/arm/sun5i. There is some headers available, but very little
> hardware details is available in those headers.
> - memory controller information
> - clock controller information
>
> The A13 and A10S SDKs do not seem to share the same source tree even if
> both are claimed to be sun5i.

I've done a diff between the A10s SDK 1.0 and the 1.5 A13 SDK sources
released recently by i-onek, and the changes are quite small, so they
seem to be the same tree to me ...

> What can be done:
> - Dump the memory and clock controller register space and try to map out
> how it shuld be set, both from nand u-boot and Android Linux. Quite
> likely there is only small changes compared to A13.

Thanks, that is a very useful hint. Can you provide such dumps for an
A13 board? I don't have an A13 board (yet, an olinuxio a13 micro is
on its way to me).


> But SPL from sunxi-current require very little to be able to print out
> it's banner. Only basic clocking of CPU, bus & UART needs to be right
> for that SPL to print the banner.

Ok.

>
> And please note that to boot u-boot without PMU support on a board with
> PMU you better
> 1. Keep the clock fequency at the "safe boot" level.
> 2. Maybe also disable cpufreq support in the kernel.

Right.

Thanks for your input!

Regards,

Hans


p.s.

I seem to be able to boot a sunxi5 kernel from sdcard fine when I
first boot into android and then reboot into the sdcard... So it
seems we're indeed missing some extra clock init most likely.

Hans de Goede

unread,
Jan 23, 2013, 12:31:18 PM1/23/13
to linux...@googlegroups.com
Hi,

On 01/23/2013 06:06 PM, Hans de Goede wrote:

> p.s.
>
> I seem to be able to boot a sunxi5 kernel from sdcard fine when I
> first boot into android and then reboot into the sdcard... So it
> seems we're indeed missing some extra clock init most likely.

For people trying to reproduce this, I have done slightly more
then just a sun5i built, I needed to make some script.bin fixes
too, to fix a null ptr deref in the display code, as well as
fix an issue with uart0. I hope to post patches for the linux
parts soon, but first I need to verify things as sofar I'm
able to boot successfully this way *sometimes*.

IOW major WIP, be patient please.

Regards,

Hans

Alejandro Mery

unread,
Feb 8, 2013, 5:30:48 AM2/8/13
to linux...@googlegroups.com, bia...@gmail.com, m...@petercairns.co.uk
On 08/02/13 09:19, bia...@gmail.com wrote:
> W dniu wtorek, 5 lutego 2013 20:30:35 UTC+1 u�ytkownik
> bia...@gmail.com napisaďż˝:
>> I made this fex file from my device mk802+ cs102
>> http://pastebin.com/AzYsm39k maybe someone can use this to build
>> linux for it.
>
> Is there anybody who run debian Wheezy armhf on mk802+ with a10s ??
> There is no information about this in the net. I build the kernel
> using stage/sunxi-3.4 with axp15 patch , i used fex file from
> oryginal mk802+ , the latest u-boot and spl and still no boot :(
> almost two weeks and no efect :(((
>

you need a device specific u-boot and a device specific fex. so first
grab your script.bin from android's nanda, and then run (in android)
a10meminfo.

Alejandro Mery

unread,
Feb 8, 2013, 6:42:37 AM2/8/13
to linux...@googlegroups.com, m...@petercairns.co.uk



On 8 February 2013 12:02, <bia...@gmail.com> wrote:

Ok and how to use information from a10meminfo ???

use it to complete/fix the [dram_para] section of the fex 

Alejandro Mery

unread,
Feb 8, 2013, 7:17:20 AM2/8/13
to linux...@googlegroups.com, bia...@gmail.com, m...@petercairns.co.uk
On 08/02/13 13:12, bia...@gmail.com wrote:
> Ok then i have to bin2fex the script.bin from device then use
> a10meminfo to build new fex file a then use fextobin to build
> script.bin to ma linux SD card?
>

and then use fexc to general u-boot's dram.c to add support for your
board to u-boot-sunxi. and submit the changes to u-boot-sunxi and
sunxi-boards ;-)

Hans de Goede

unread,
Feb 8, 2013, 7:58:52 AM2/8/13
to linux...@googlegroups.com, Alejandro Mery, bia...@gmail.com, m...@petercairns.co.uk
Hi,
Erm, bialasa has an A10s, so simply doing the usual steps for adding
support for a new board don't work. The A10s needs some special magic,
which I've yet to figure out ...

What does work is first booting android, then inserting an sdcard
and then rebooting. At least that will give you the sdcard uboot]
and allow you to load a sun5i kernel, which will then hang within
10 - 30 seconds when build with defconfig due to a timer bug I
still need to find the time to properly fix.

This timer bug is not A10s specific though, the core timer code is
busted in general. But since the core timer has a prio of 100, and
the HIGH_RES timer of 300 on sun4i, we get the non broken HIGH_RES
on sun4i, but on sun5i both claim a prio of 300 and we get the
broken core timer.

I've a patch in my queue which merges the core.c code between
sun4i and sun5i, lowering the core timer prio for sun5i to 100
too, thus working around the brokeness there too. As said writing
a real fix is on my todo

Note the problem with the core timer is mainly in oneshot mode,
so disabling NO_HZ is a workaround too.

Regards,

Hans

Hans de Goede

unread,
Feb 8, 2013, 8:51:21 AM2/8/13
to linux...@googlegroups.com, m...@petercairns.co.uk, Alejandro Mery, bia...@gmail.com
Hi,

On 02/08/2013 02:10 PM, m...@petercairns.co.uk wrote:
> Hi,
>
> How are you guys getting a serial interface out of your boards? I'm using a A10S MK802 clone (CS102S) which doesn't seem to have a serial header on the board. :-/

By soldering wires to the testpoints on the pcb.

Regards,

Hans

Hans de Goede

unread,
Feb 8, 2013, 8:58:45 AM2/8/13
to linux...@googlegroups.com, m...@petercairns.co.uk, Alejandro Mery, bia...@gmail.com
Hi,

On 02/08/2013 02:50 PM, m...@petercairns.co.uk wrote:
> Hi,
> Yup, but where are they? I know on the A10 MK802 boards they are below the SOC...can't locate 'em on this A10S board.

I cannot help you there as I'm doing my testing with an R7 A10s hdmi stick, which has a different pcb

I think they might be "under" the SOC, that is on the other side of the pcb under the SOC :)

Regards,

Hans

Henrik Nordström

unread,
Feb 11, 2013, 2:46:36 AM2/11/13
to linux...@googlegroups.com
fre 2013-02-08 klockan 05:50 -0800 skrev m...@petercairns.co.uk:
> Hi,
> Yup, but where are they? I know on the A10 MK802 boards they are below the SOC...can't locate 'em on this A10S board.

Can you provide hires pictures of the PCB? Easier to help when there is
something to look at.

Regards
Henrik

Andrew Armenia

unread,
Feb 12, 2013, 12:10:05 AM2/12/13
to ver...@gmail.com, linux...@googlegroups.com
Didn't solder mine either, but I tried my scope and a multimeter
looking for the high level on the idle Tx line, and I got nothing.
Going on the assumption that these points are indeed PB19 and PB20, I
tried hacking up gpio_init() in u-boot to see if I could get them to
do anything. I couldn't - this could be because the test points are
wired to some other pins, or just because I don't know my way around
the u-boot source all that well.

I also poked around the AXP152 PMIC a bit, first booting from the NAND
with the factory firmware, then from the SD card with u-boot. Probing
a capacitor connected to pin 9 gave 3V on the factory firmware and
only 2.8V when using the SD card. This makes some sense since pin 9 is
the output of a programmable linear regulator, according to the
datasheet. All other voltages I could find seemed to be equal
regardless of what medium I booted from.

-Andrew


On Mon, Feb 11, 2013 at 11:32 PM, <ver...@gmail.com> wrote:
> On Monday, February 11, 2013 1:48:44 PM UTC-7, and...@asquaredlabs.com wrote:
> ...snip...
>>
>> Not sure if this helps, but here's a similar A10s-based MK802 clone I'm currently trying to boot Linux on: http://imgur.com/YSugUgo. I suspect the two test-points below the left corner of the A10s connect to UART0 Tx and Rx, but there seems to be no activity on these pins when the NAND bootloader starts.
>>
>
> That's exactly what my board looks like too. I also was unable to get anything from those test points. Although I tried only by holding wires to the pads, didn't solder them.

Hans de Goede

unread,
Feb 12, 2013, 4:10:31 AM2/12/13
to linux...@googlegroups.com, and...@asquaredlabs.com
Hi,

On 02/11/2013 09:48 PM, and...@asquaredlabs.com wrote:
> Not sure if this helps, but here's a similar A10s-based MK802 clone I'm currently trying to boot Linux on: http://imgur.com/YSugUgo. I suspect the two test-points below the left corner of the A10s connect to UART0 Tx and Rx, but there seems to be no activity on these pins when the NAND bootloader starts.

As I already said in a previous mail, you need to look at *the other side of the pcb*,
if you look closely those 2 testpoints you are trying to use are likely part of the
ground plane, and thus connected to just ground otoh, on the other side of the pcb,
"under" the A10s soc there are a couple of testpoints which look promising.

Regards,

Hans

Henrik Nordström

unread,
Feb 12, 2013, 5:19:14 PM2/12/13
to linux...@googlegroups.com
mån 2013-02-11 klockan 12:48 -0800 skrev and...@asquaredlabs.com:

> Not sure if this helps, but here's a similar A10s-based MK802 clone
> I'm currently trying to boot Linux on: http://imgur.com/YSugUgo. I
> suspect the two test-points below the left corner of the A10s connect
> to UART0 Tx and Rx, but there seems to be no activity on these pins
> when the NAND bootloader starts.

Yes those two looks like they could be UART0 TX/RX. But it's not 100%
fit. UART8 is G3(PB19),G4(PB20), or row 7 of 20 below the label couted
from the white dot. That looks more like row 5 or 6. But it's pad 3,4
from the edge so might be shifted a bit under the BGA or maybe I am not
measuring distance correct.

Should be easy to probe if those are the right pins by using our
fel-gpio tool from sunxi-tools.

It is possible the device is firmware is simply configured to use
another UART as console. If you have a firmware upgrade file try
unpacking it and check the pin assignments in script.bin and also boot0
header.

Regards
Henrik

Henrik Nordström

unread,
Feb 12, 2013, 5:20:50 PM2/12/13
to linux...@googlegroups.com
tis 2013-02-12 klockan 23:19 +0100 skrev Henrik Nordström:

> It is possible the device is firmware is simply configured to use
> another UART as console. If you have a firmware upgrade file try
> unpacking it and check the pin assignments in script.bin and also boot0
> header.

forgot to mention, script.bin should also be accessible from the device
using adb which might be the easiest path getting that file.

Regards
Henrik

Iso9660

unread,
Feb 14, 2013, 3:31:21 PM2/14/13
to linux...@googlegroups.com, and...@asquaredlabs.com, ver...@gmail.com, m...@petercairns.co.uk
I see [uart_para0] has the used flag to 1, I think that uart0 shares some pins with the sdcard port as can be read from Olimex A13 Micro... In fact in the micro we use uart 1, since we boot with the sdcard port.

El miércoles, 13 de febrero de 2013 21:45:13 UTC+1, m...@petercairns.co.uk escribió:
Here's my script.fex, if it's some use to anybody...
http://pastebin.com/YxeNkqGw

Looks like TX is on PB19 and RX on PB20

On Wednesday, February 13, 2013 9:36:38 PM UTC+1, m...@petercairns.co.uk wrote:
> Yep, I have the same board. Those two pads not on the groundplane have some voltages present, but I couldn't get any serial output from them. Will check out the script.bin to see what the pin assignments might be... ;)


>
> On Tuesday, February 12, 2013 5:32:56 AM UTC+1, ver...@gmail.com wrote:
> > On Monday, February 11, 2013 1:48:44 PM UTC-7, and...@asquaredlabs.com wrote:
> > ...snip...
> > >

> > > Not sure if this helps, but here's a similar A10s-based MK802 clone I'm currently trying to boot Linux on: http://imgur.com/YSugUgo. I suspect the two test-points below the left corner of the A10s connect to UART0 Tx and Rx, but there seems to be no activity on these pins when the NAND bootloader starts.
> > >
> >

Rodrigo Pinheiro

unread,
Mar 9, 2013, 3:01:46 PM3/9/13
to linux...@googlegroups.com, avi...@gmail.com
Hi All,

Have We any progress on build a working Linux SD Card for our A10s ?
I have some aknowleges in Linux, maybe I may help.

Oliver Schinagl

unread,
Apr 7, 2013, 11:58:07 AM4/7/13
to linux...@googlegroups.com
On 07-04-13 23:40, sebastie...@gmail.com wrote:
> +1 for support on the A10s.
>
> Not having a working linux on this processor made me stop buying any A10 related Android Sticks to build custom headerless multimedia devices, as vendors often either lie about the processor in their package, advertising them as A10, or don't have a clue about the difference between A10s and A10.
>
> I am considering switching to the more powerful RK3066 as an alternative, onto which I got "picuntu" running, but it's a shame that we still can't get linux running on the A10s given its low price point and ample power to run audio related applications.
>
> Dear sunxi community, please make this happen!
>
Feel free to send a patch or an A10s to test things. I only have an A10
so no way to even possibly test this.

alex allss

unread,
Apr 9, 2013, 1:46:13 AM4/9/13
to linux...@googlegroups.com
Devs lack such hardware at all, please feel free send patches to ML


2013/4/7 Oliver Schinagl <olive...@schinagl.nl>


--
You received this message because you are subscribed to the Google Groups "linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.



theRat

unread,
Apr 9, 2013, 4:36:50 AM4/9/13
to linux...@googlegroups.com
I today got a mini-x box that claimed to be A10, but in fact it contained a A10S instead.  Something for people to be wary of I guess.  I will be refusing to pay for this device.


2013/4/7 Oliver Schinagl <olive...@schinagl.nl>
To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi...@googlegroups.com.

Oliver Schinagl

unread,
Apr 8, 2013, 5:53:04 PM4/8/13
to linux...@googlegroups.com
On 09-04-13 13:46, sebastie...@gmail.com wrote:
> On Tuesday, April 9, 2013 1:46:13 AM UTC-4, wingrime wrote:
>> Devs lack such hardware at all, please feel free send patches to ML
> I see that Hans submitted some sys_config patches some time ago, and I am willing to make a contribution to the best of my abilities and available time... if that's even possible? I am not familiar with embedded development, but I have a strong background in C.
>
> Is there anything I can do to get started on this?
Clone the 'sunxi-bsp' git tree and build something that is as similar as
possible and go from there I guess :)
>
>
>
>
>

Hans de Goede

unread,
Apr 10, 2013, 4:43:16 AM4/10/13
to linux...@googlegroups.com, m...@petercairns.co.uk, olive...@schinagl.nl, sebastie...@gmail.com
Hi,

On 04/10/2013 10:10 AM, m...@petercairns.co.uk wrote:
> What board do you have? If it's an MK802 clone with A10S inside (see the pics further up this thread) then I think we have everything from NAND that is needed. If not, then please submit the board as per the guidelines here: http://linux-sunxi.org/Submitting_Boards
>
> I'm going to have a crack at building a linux image this weekend I think. Also, I'm happy to donate an A10S device for development.

AFAIK the biggest problem is we don't have a working stand-alone (so not
using the boot0 / boot1 blobs) u-boot for the A10s.

Regards,

Hans

Oliver Schinagl

unread,
Apr 9, 2013, 5:32:23 PM4/9/13
to sebastie...@gmail.com, linux...@googlegroups.com
On 09-04-13 22:12, sebastie...@gmail.com wrote:
> On Monday, April 8, 2013 5:53:04 PM UTC-4, Oliver Schinagl wrote:
>>> Is there anything I can do to get started on this?
>> Clone the 'sunxi-bsp' git tree and build something that is as similar as
>>
>> possible and go from there I guess :)
>>
> I love sarcasm :)
I was quite serious :)

We do have _some_ support, but since there's no hardware, nobody has
been able to test or run anything. Maybe it even 'just works' (tm).

I would suggest to Download hansg's fedora 18 image and install it to an
SD card, use a13-mid if no a10s is listed as that is probably the
closest. I assume that won't boot, but with the sunxi-bsp you should be
able to build a a10s target. Actually, you can define your own target.
Boot android and run 'a10-meminfo-static' (instructions on the
'submitting boards' on the wiki) to get your memory timings. You must be
running stock software for that to be accurate. Safe those. Then from
nanda you can extract your script.bin. In the bsp there's tools to
decompile that to script.fex (text file). Check out sunxi-boards for the
other boards's fex file. See if there is a very similar a10s board (or
fex file, if fex files match, then they are identical). Note that
dram_para will be wrong! But you extracted that ith a10-meminfo-static.

If you have to create a new board.fex in the sunxi-boards, you will also
have to add that to u-boot (check the log how that is done, modify 2
files, create a dir).

Now building should give you a working u-boot and possibly a working
kernel. Put those on the SD card (check the installation script for how
to write the bootloader to the sd card, a simple dd task). checkout
output/*.hwpack (or build/*hwpack) for files that could/should be
specific for your board :)

P.S. I or someone should put this (more clear) on the wiki :)
>
> Now... Since the board runs Android, is there anything I can extract something from the nand to get started? I've seen other pictures of boards with similar layouts as mine, so I am guessing this would help others too.

Oliver Schinagl

unread,
Apr 9, 2013, 6:03:17 PM4/9/13
to m...@petercairns.co.uk, linux...@googlegroups.com, sebastie...@gmail.com
On 10-04-13 16:22, m...@petercairns.co.uk wrote:
> Is there a way to boot linux without a fully working uboot? Hans, I remember you mentioning further up the thread that it worked ok when rebooting from the Android nand image, but not from a 'cold' boot.
I personally have not gotten a 3.0 kernel to boot on my A10 from nand.
Only stock kernel builds (no debug so can't see why)

But yes, you can replace the kernel in the boot.img

Roman Mamedov

unread,
Apr 10, 2013, 10:44:04 AM4/10/13
to linux...@googlegroups.com, m...@petercairns.co.uk, olive...@schinagl.nl, sebastie...@gmail.com
On Wed, 10 Apr 2013 07:22:23 -0700 (PDT)
m...@petercairns.co.uk wrote:

> Is there a way to boot linux without a fully working uboot? Hans, I remember you mentioning further up the thread that it worked ok when rebooting from the Android nand image, but not from a 'cold' boot.

You can replace a kernel that is in /dev/nanda with your own. It can't be
uImage, it must be in a different format (bImage), created by

objcopy -R .note.gnu.build-id -S -O binary vmlinux bImage

I did that on my MK802 where SD uBoot fails to work, put a kernel there that
had a hardcoded command line of "root=/dev/mmcblk0p2" and it booted
successfully.

--
With respect,
Roman
signature.asc

Hans de Goede

unread,
Apr 10, 2013, 10:55:25 AM4/10/13
to linux...@googlegroups.com, m...@petercairns.co.uk, olive...@schinagl.nl, sebastie...@gmail.com
Hi,

On 04/10/2013 04:22 PM, m...@petercairns.co.uk wrote:
> Is there a way to boot linux without a fully working uboot? Hans, I remember you mentioning further up the thread that it worked ok when rebooting from the Android nand image, but not from a 'cold' boot.

Yes A13 targeted images (with the right RAM timings) will work when
hot-booted from android, mini howto:
-create an A13 targetted sd-card
-boot into android on the A10s (without the sdcard being inserted at this point)
-now insert the sdcard
-shutdown android and in the shutdown menu, chose reboot instead

This worked for me, but is less then ideal.

Regards,

Hans

theRat

unread,
Apr 11, 2013, 7:03:57 AM4/11/13
to linux...@googlegroups.com, m...@petercairns.co.uk, olive...@schinagl.nl, sebastie...@gmail.com
Today I go a A10S device (new mini-x box) to boot linaro from an SD device.  I had to hack axp209.c and others to get the voltages correct from the axp152 that is used on the board.

The biggest pain is that the A10S is a cross between the A10 and A13 so neither defconfig is suitable.  I used the a13-mid as a starting point, but then had to stuff around to enable hdmi and get the serial console on uart0.

On Thursday, 11 April 2013 01:07:37 UTC+10, m...@petercairns.co.uk wrote:
Thanks Hans, will give that a try.

Hans de Goede

unread,
Apr 11, 2013, 7:08:41 AM4/11/13
to linux...@googlegroups.com, theRat, m...@petercairns.co.uk, olive...@schinagl.nl, sebastie...@gmail.com
Hi,

On 04/11/2013 01:03 PM, theRat wrote:
> Today I go a A10S device (new mini-x box) to boot linaro from an SD device. I had to hack axp209.c and others to get the voltages correct from the axp152 that is used on the board.

Very cool, looking forward to you sharing your uboot changes for this :)

Regards,

Hans

theRat

unread,
Apr 11, 2013, 7:43:59 AM4/11/13
to linux...@googlegroups.com, theRat, m...@petercairns.co.uk, olive...@schinagl.nl, sebastie...@gmail.com
Hans,

I am not sure how to go about sharing the changes.  I have just done them as a nasty hack to get to grips with the AXP152.  It seems that there almost needs to be another architecture as A10S/AXP152 really isn't the same as sun4i or sun5i.

Happy to share the hack so someone with more knowledge than me can integrate it as appropriate.

The 3 main files I changed were u-boot-sunxi/drivers/power/axp209.c, u-boot-sunxi/include/axp209.h and u-boot-sunxi/board/allwinner/common/board.c
All the references in the to axp209 should change to axp152.

These are the changed files:

Cheers
Simon

Roman Mamedov

unread,
Apr 11, 2013, 7:55:07 AM4/11/13
to linux...@googlegroups.com, si...@proatomic.com.au, m...@petercairns.co.uk, olive...@schinagl.nl, sebastie...@gmail.com
signature.asc

theRat

unread,
Apr 11, 2013, 7:58:47 AM4/11/13
to linux...@googlegroups.com, si...@proatomic.com.au, m...@petercairns.co.uk, olive...@schinagl.nl, sebastie...@gmail.com
Roman,

I know how to make patches now, but with this one I don't know how to go about structuring things.  The a10s really needs its own defconfig I think, but I am clueless on how to do this.

Cheers
Simon

Hans de Goede

unread,
Apr 11, 2013, 8:30:40 AM4/11/13
to linux...@googlegroups.com, theRat, m...@petercairns.co.uk, olive...@schinagl.nl, sebastie...@gmail.com
Hi,

On 04/11/2013 01:43 PM, theRat wrote:
> Hans,
>
> I am not sure how to go about sharing the changes. I have just done them as a nasty hack to get to grips with the AXP152. It seems that there almost needs to be another architecture as A10S/AXP152 really isn't the same as sun4i or sun5i.

Thanks for the files. I'm not sure an entire other arch is needed.
I'll take a look at your work as time permits (I likely won't have
time till this weekend) and I'll try to turn it into a proper patch.

I do have some questions:
1) Which git repo and branch did you use as a base for building your
uboot?
2) Which target did you build it for ?
3) Did you do anything special during the build, other then modifying
the files you've put on dropbox?

Thanks & Regards,

Hans

theRat

unread,
Apr 11, 2013, 8:47:15 AM4/11/13
to linux...@googlegroups.com, theRat, m...@petercairns.co.uk, olive...@schinagl.nl, sebastie...@gmail.com
Hans,

I also don't have much time in the next few days.  Thanks for your interest :)

My starting point was sunxi-bsp stage-3.0 downloaded about a week ago.
The target I chose was a13_mid.

The other things I did:
1. Apply your hack earlier in this thread to change to uart0
2. changed CONFIG_SW_DEBUG_UART=1 to =0 and enabled early printk
3. enabledf hdmi (both display and audio)
4. change selection of module AXP20 to AXP15

This is the .config I used.

Cheers
Simon

Hans de Goede

unread,
Apr 11, 2013, 10:49:29 AM4/11/13
to linux...@googlegroups.com
Hi,

On 04/11/2013 02:47 PM, theRat wrote:
> Hans,
>
> I also don't have much time in the next few days. Thanks for your interest :)
>
> My starting point was sunxi-bsp stage-3.0 downloaded about a week ago.

I meant which uboot sources + branch you used, not the kernel.

Regards,

Hans

theRat

unread,
Apr 11, 2013, 6:48:15 PM4/11/13
to linux...@googlegroups.com
Oops, sorry.

It would be the u-boot source that is linked to in the sunxi-bsp repository.  I am not sure which that is but I would guess that it is just the sunxi branch.  Is there a better way to tell?

Cheers
Simon

alex allss

unread,
Apr 14, 2013, 7:40:19 AM4/14/13
to linux...@googlegroups.com
a10s more close to a13 than a10 you must build uImage, modules,spl,uboot


2013/4/14 <franck...@gmail.com>
Hi every one,

Just because I'm new on this subject, I also have a MK802 with a A10s chip.

I have a debian armhf image for MK802-A10 (http://romanrm.ru/en/a10/debian), and I would like to know if getting a sunxi-spl.bin and a u-boot.bin on the sdcard should be enough, or should I have also to change the uImage ?

Thx in advance for any advice.

theRat

unread,
Apr 14, 2013, 7:57:33 AM4/14/13
to linux...@googlegroups.com
The issue of getting the a10s to work is not really related the the a10s, but the different pmu that is used with devices that use it.  The axp152 is quite different to the axp209 that is used in a10 and a13 devices.  This device is responsible for providing the various voltages be the different subsystems correct.

In time Hans and I will hopefully come up with a proper solution to support these devices.  Be patient grasshoppers ;)

Unfortunately I have paid work that I can't put off so I will have little time for the next week.  This is the first time I have looked in since my last post and now it is time for sleep.

In summary for those that are impatient.  You need to add support for the axp152 pmu if you want to have any chance.  On top of that you need to choose a a13 type board to build (I used the a13-mid) and you must do the usual things to get a new board to work (ie. memory settings) and have a valid script.bin for the device.  Remember the a13 did not have hdmi so any script.bin that was provided for one of those will not give you a display without modifications.   Bottom line, if you can't connect the uart up to get diagnostics you are going to find it difficult if not impossible to get working.

Cheers
Simon

theRat

unread,
Apr 17, 2013, 6:18:59 PM4/17/13
to linux...@googlegroups.com, sande...@gmail.com
San,

If you have your uart connected correctly you should get output when you boot the android image in the NAND.

If that gives you output then you have missed something.  The most likely thing is that you haven't changed from UART1 to UART0.  There is a hack that Hans posted towards the top, in fact his first post in this thread to change to use UART0.

Cheers
Simon

On Thursday, 18 April 2013 08:09:14 UTC+10, sande...@gmail.com wrote:
Hi all,

an update from my part on the A10s support.

Since the last time I've acquired an UART cable and am able to track data and send commands to the board. In addition extracted the script.bin from NandA and ran the a10-meminfo-static to log information. According to this wiki page (http://linux-sunxi.org/Submitting_Boards) this data is also interesting to other members of the community.

a10-memdump: https://www.dropbox.com/s/9ics6qxa7jzc4bz/a10-memdump.txt
script.bin : https://www.dropbox.com/s/badifse51k7ydhc/script.bin
script.fex : https://www.dropbox.com/s/161cyquj9h5yy5x/script.fex

The suggestion provided by PeterC. on updating the dram.c settings did not improve booting from sdcard. If the device is turned on with the sdcard inserted no information is send over UART. This might indicate either that it does not boot, no information is send over UART (same issue as mentioned earlier in this threat?), or both. Rebooting the android device from stock rom (using a terminal application) with the sdcard inserted locks the device in a similar way.

I'm in no direct hurry to get this working, I can focus on other challenges, so I'll wait for Simon and Hans to figure out the final details. But if I can provide any additional information or anything in general to help get this board officially supported just let me know. So far this has been an interesting exercise / learning process and I'm eager to learn more.


Kind Regards,
San

Hans de Goede

unread,
Apr 19, 2013, 4:25:21 AM4/19/13
to linux...@googlegroups.com, theRat, sande...@gmail.com
Hi,

On 04/18/2013 12:18 AM, theRat wrote:
> San,
>
> If you have your uart connected correctly you should get output when you boot the android image in the NAND.
>
> If that gives you output then you have missed something. The most likely thing is that you haven't changed from UART1 to UART0. There is a hack that Hans posted towards the top, in fact his first post in this thread to change to use UART0.

I'm afraid it is not that simple, even with your patches / changed files
I still cannot cold-boot my A10s boards (both of them, 2 different models)
either. So it seems you're lucky somehow.

One "interesting" thing I've learned is the following:
1) boot into nand android
2) reboot into flash bootload-loader interrupt boot, so it stays
there.
3) manually trigger a reset by writing to the watchdog ctrl register
from u-boot (the built-in reset command seems to be broken).
4a) if no sd-card is inserted it reboots fine into nand android
4b) if an sd-card is inserted it just hangs, not output to the
serial port, no nothing

But if I do:
1) boot into nand android
2) reboot with sd-card inserted
3) sdcard u-boot works fine, and my F-18 kernel boots happily.

Then my sd-card u-boot does work. So the nand u-boot is undoing a change
done by the android kernel (and a change which survives cpu-reset at that),
causing the sd-card u-boot to not work.

Likewise if I do:
1) boot into nand android
2) reboot with sd-card inserted
3) interrupt sd-card u-boot
4) reset by manual writing to watchdog ctrl reg
Then:
4a) If the sd-card is still inserted it hangs
4b) If I've removed the sd-card after u-boot has started, it
happily reboots into the nand android

So either u-boot does something to the A10s (*) soc, which causes sd-card
boot to no longer work.

I've tried commenting out various parts of the u-boot init code to see
what causes the problem, but I've not gotten very far. I'll likely have
time to look deeper into this this Sunday.

So Simon seems to be the only person who has a cold-booting A10s
system, the question is why though. I hope figuring out why even after
a hot-reboot from android booting works only once will shed some light
on this.

Regards,

Hans


*) I believe it is not the axp152 settings, as I've commented out all
axp152 calls in the sd-card u-boot, and even then it will only boot
from the sd-card once...


>
> Cheers
> Simon
>
> On Thursday, 18 April 2013 08:09:14 UTC+10, sande...@gmail.com wrote:
>
> Hi all,
>
> an update from my part on the A10s support.
>
> Since the last time I've acquired an UART cable and am able to track data and send commands to the board. In addition extracted the script.bin from NandA and ran the a10-meminfo-static to log information. According to this wiki page (http://linux-sunxi.org/Submitting_Boards <http://linux-sunxi.org/Submitting_Boards>) this data is also interesting to other members of the community.
>
> a10-memdump: https://www.dropbox.com/s/9ics6qxa7jzc4bz/a10-memdump.txt <https://www.dropbox.com/s/9ics6qxa7jzc4bz/a10-memdump.txt>
> script.bin : https://www.dropbox.com/s/badifse51k7ydhc/script.bin <https://www.dropbox.com/s/badifse51k7ydhc/script.bin>
> script.fex : https://www.dropbox.com/s/161cyquj9h5yy5x/script.fex <https://www.dropbox.com/s/161cyquj9h5yy5x/script.fex>
>
> The suggestion provided by PeterC. on updating the dram.c settings did not improve booting from sdcard. If the device is turned on with the sdcard inserted no information is send over UART. This might indicate either that it does not boot, no information is send over UART (same issue as mentioned earlier in this threat?), or both. Rebooting the android device from stock rom (using a terminal application) with the sdcard inserted locks the device in a similar way.
>
> I'm in no direct hurry to get this working, I can focus on other challenges, so I'll wait for Simon and Hans to figure out the final details. But if I can provide any additional information or anything in general to help get this board officially supported just let me know. So far this has been an interesting exercise / learning process and I'm eager to learn more.
>
>
> Kind Regards,
> San
>
>
>
>
> On Sunday, April 14, 2013 1:57:33 PM UTC+2, theRat wrote:
> > The issue of getting the a10s to work is not really related the the a10s, but the different pmu that is used with devices that use it. The axp152 is quite different to the axp209 that is used in a10 and a13 devices. This device is responsible for providing the various voltages be the different subsystems correct.
> >
> >
> > In time Hans and I will hopefully come up with a proper solution to support these devices. Be patient grasshoppers ;)
> >
> >
> > Unfortunately I have paid work that I can't put off so I will have little time for the next week. This is the first time I have looked in since my last post and now it is time for sleep.
> >
> >
> > In summary for those that are impatient. You need to add support for the axp152 pmu if you want to have any chance. On top of that you need to choose a a13 type board to build (I used the a13-mid) and you must do the usual things to get a new board to work (ie. memory settings) and have a valid script.bin for the device. Remember the a13 did not have hdmi so any script.bin that was provided for one of those will not give you a display without modifications. Bottom line, if you can't connect the uart up to get diagnostics you are going to find it difficult if not impossible to get
> working.
> >
> >
> > Cheers
> > Simon
> >
> >
> >
> > On Sunday, 14 April 2013 21:40:19 UTC+10, wingrime wrote:
> > a10s more close to a13 than a10 you must build uImage, modules,spl,uboot
> >
> >
> >
> >
> > 2013/4/14 <franck...@gmail.com>
> >
> > Hi every one,
> >
> >
> >
> > Just because I'm new on this subject, I also have a MK802 with a A10s chip.
> >
> >
> >
> > I have a debian armhf image for MK802-A10 (http://romanrm.ru/en/a10/debian <http://romanrm.ru/en/a10/debian>), and I would like to know if getting a sunxi-spl.bin and a u-boot.bin on the sdcard should be enough, or should I have also to change the uImage ?
> >
> >
> >
> >
> > Thx in advance for any advice.
> >
> >
> >
> >
> >
> > --
> >
> > You received this message because you are subscribed to the Google Groups "linux-sunxi" group.
> >
> > To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi...@googlegroups.com.
> >
> > For more options, visit https://groups.google.com/groups/opt_out <https://groups.google.com/groups/opt_out>.

theRat

unread,
Apr 19, 2013, 9:35:31 PM4/19/13
to linux...@googlegroups.com, theRat, sande...@gmail.com, m...@petercairns.co.uk
Hans and Peter,

I suspect what Peter suggested may be correct, for example your devices might use different RAM that requires a different voltage.
Are you able to post a .fex for one of your boards?  Although I am not sure that android is actually using those values as on my device one of them was wrong.  I resorted to using i2cdump to get the values programmed into the axp152.  Can you post the output of the following command and I will check the voltages etc

i2cdump -f -y 0 0x30

An android version of i2cdump can be found here https://www.dropbox.com/s/7iy0tnfkzna42or/i2cdump

I also found an interesting problem after removing the serial link.  Upon reboot it would get enough noise on the rx line to uart rx pin to be detected as a key press, resulting in the device sitting at the boot prompt forever.  This seems to have stopped after putting it back in its case and moving it away from the noisy environment it was in.

Simon.

On Friday, 19 April 2013 23:07:06 UTC+10, m...@petercairns.co.uk wrote:
Could it be that the AXP152 settings which Simon created patches for differ from one board design to another, such as voltages?

theRat

unread,
Apr 20, 2013, 4:12:40 AM4/20/13
to linux...@googlegroups.com, theRat, sande...@gmail.com, m...@petercairns.co.uk
Peter,

It appears there is a difference between out devices.  On mine DCDC2 is 1.2v while yours is 1.4v.  I think DCDC2 must be used to power the RAM as that appears to be the voltages they will need.  If you want to give it a go change the DCDC2 voltage setting in board.c (down the bottom) from

power_failed |= axp209_set_dcdc2(1200);

to
power_failed |= axp209_set_dcdc2(1400);

and give that a try.

Simon



On Saturday, 20 April 2013 17:57:56 UTC+10, m...@petercairns.co.uk wrote:
Hi Simon,

Thanks for the i2cdump.bin. I've got a MK802 clone - here are the various files:

script.fex: http://pastebin.com/QLF5R1XE
output from i2cdump: http://pastebin.com/aWdEkyPJ

Hope that helps,
-Pete

theRat

unread,
Apr 20, 2013, 4:33:15 AM4/20/13
to linux...@googlegroups.com, theRat, sande...@gmail.com, m...@petercairns.co.uk
Hope it works!

There was one other change I made that I forgot about, but it wouldn't affect the booting, but may explain some of Hans' inconsistencies.

In the kernel config I changed

   Device Drivers --> Power supply class support --> AXP Power drivers --> AXP PMU type --> AXP15 driver

This was set to AXP20 driver.  I haven't looked at what the code in that driver is used for.

Simon


On Saturday, 20 April 2013 18:19:21 UTC+10, m...@petercairns.co.uk wrote:
Cool, thanks Simon - I'll give that a go!

theRat

unread,
Apr 20, 2013, 5:47:46 AM4/20/13
to linux...@googlegroups.com, theRat, sande...@gmail.com, m...@petercairns.co.uk
I tend to agree.  I would never have gotten it to work without the uart connected.

Are you sure the dram settings are correct?  They are different to mine.  The dram section in my script.fex are:

[dram_para]
dram_baseaddr = 0x40000000
dram_clk = 432
dram_type = 3
dram_rank_num = 1
dram_chip_density = 4096
dram_io_width = 16
dram_bus_width = 32
dram_cas = 9
dram_zq = 0x7b
dram_odt_en = 0
dram_size = 512
dram_tpr0 = 0x42d899b7
dram_tpr1 = 0xa090
dram_tpr2 = 0x22a00
dram_tpr3 = 0x0
dram_tpr4 = 0x0
dram_tpr5 = 0x0
dram_emr1 = 0x0
dram_emr2 = 0x10
dram_emr3 = 0x0

And they need to match what's in the dram.c file.

Simon

On Saturday, 20 April 2013 19:33:18 UTC+10, m...@petercairns.co.uk wrote:
Okay I had another go - did a fresh git update and compiled from scratch with the patches etc. No dice.

It doesn't work when warm-booting from Android either (unlike Hans I've never had this working). I also tried lowering the mem frequency to 360 in case that was causing some kind of lockup. It's definitely not reaching kernel boot as there is no USB OTG power and no kernel logs are left.

So I think the next thing is to figure out how to get UART connected to this board for some more info as to what the devil is going on there... :)

theRat

unread,
Apr 20, 2013, 5:56:51 AM4/20/13
to linux...@googlegroups.com, theRat, sande...@gmail.com, m...@petercairns.co.uk
Did you check the dram settings using a10-meminfo-static under android?
The script.bin that was on supplied with the device I am using was wrong.  I suspect that android doesn't actually use the stuff from the script.bin for the memory settings and has them hardcoded.

On Saturday, 20 April 2013 19:50:07 UTC+10, m...@petercairns.co.uk wrote:
Yup, I updated dram.c with the settings from my FEX file before compiling.

Hans de Goede

unread,
Apr 21, 2013, 4:02:40 PM4/21/13
to linux...@googlegroups.com, theRat, sande...@gmail.com, m...@petercairns.co.uk
Hi,

So I've spend some hours on this today, and I've got good news!

I now have both my a10s "hdmi-sticks" cold-booting from the sd-card.

Attached are 4 patches which when applied on top of the sunxi branch
of: https://github.com/linux-sunxi/u-boot-sunxi

The last one contains the magic needed to make the A10s cold boot
reliable for me. This likely is just a workaround for the u-boot
uart code not knowing how to deal with the special designware
uart the A10 / A13 / A10s has, and tripping over the non standard
LCR busy interrupt. I will try to write a proper fix for this later.

This does not mean that we're there yet, there still is work to do
to clean up the u-boot code, and then get axp152 support into the
linux-sunxi kernel + support for the spi wifi.

Talking about the spi-wifi. Simon, you've that working, right?

Could you post your code somewhere?

Regards,

Hans
0001-a10s-r7-tv-dongle-Add-support-for-the-a10s-R7-TV-don.patch
0002-A10s-hack-change-console-to-uart0.patch
0003-A10s-hack-Modify-axp209-code-to-work-with-the-axp152.patch
0004-A10s-hack-init-uart0-hard-and-early.patch

theRat

unread,
Apr 21, 2013, 6:00:24 PM4/21/13
to linux...@googlegroups.com, theRat, sande...@gmail.com, m...@petercairns.co.uk
Hans,

Well done.

If you are talking about sdio/mmc wifi (ie rtl8189es) I have just posted more details here for you to look at.

I am unaware of any spi-wifi?

Cheers
Simon

Angus Gratton

unread,
Apr 22, 2013, 2:46:56 AM4/22/13
to linux...@googlegroups.com
On Sun, Apr 21, 2013 at 10:02:40PM +0200, Hans de Goede wrote:
> So I've spend some hours on this today, and I've got good news!
>
> I now have both my a10s "hdmi-sticks" cold-booting from the sd-card.
>
> *snip*

Hi Hans,

Wow, excellent work! Great news.

You don't have any photos of your hdmi stick boards, do you? If it's
possible I'd like to compare them to the board I have, be sure I was
right when I diagnosed it as not having a broken out UART.

Apologies if you've already posted them and I missed the post.

- Angus

theRat

unread,
Apr 22, 2013, 3:02:09 AM4/22/13
to linux...@googlegroups.com, theRat, sande...@gmail.com, m...@petercairns.co.uk
Hans,

My thoughts on the AXP stuff that needs to be added is that in the boards.cfg that maybe the NO_AXP tag should be ditched and replaced with AXP152, AXP209 etc.  Boards with no axp would simply have no AXPxxx tag.  I think this would be better going forward as it would allow for new PMU's to be added more easily.

Simon.


On Monday, 22 April 2013 06:02:40 UTC+10, Hans de Goede wrote:

Hans de Goede

unread,
Apr 22, 2013, 3:37:15 AM4/22/13
to linux...@googlegroups.com, Angus Gratton
Hi,

On 04/22/2013 08:46 AM, Angus Gratton wrote:
> On Sun, Apr 21, 2013 at 10:02:40PM +0200, Hans de Goede wrote:
>> So I've spend some hours on this today, and I've got good news!
>>
>> I now have both my a10s "hdmi-sticks" cold-booting from the sd-card.
>>
>> *snip*
>
> Hi Hans,
>
> Wow, excellent work! Great news.
>
> You don't have any photos of your hdmi stick boards, do you? If it's
> possible I'd like to compare them to the board I have, be sure I was
> right when I diagnosed it as not having a broken out UART.

The one I've which does not have any reachable / working uart pins is:
http://i868.photobucket.com/albums/ab244/electronic0305/MK802A10s.jpg

So basically the classic mk802 but then with an A10s inside.

I don't have any pictures of the pcb, but if yours looks the same on
the outside and has an A10s it very likely is using the same pcb.

Regards,

Hans

Angus Gratton

unread,
Apr 22, 2013, 3:45:38 AM4/22/13
to linux...@googlegroups.com
On Mon, Apr 22, 2013 at 09:37:15AM +0200, Hans de Goede wrote:
> The one I've which does not have any reachable / working uart pins is:
> http://i868.photobucket.com/albums/ab244/electronic0305/MK802A10s.jpg
>
> So basically the classic mk802 but then with an A10s inside.

Thanks Hans. Yeah, that's what mine looks like (was sold as an A10
MK802.) Mine has this board (marked 2012/10/23 ST-G2 S-VER:1.0)

http://www.projectgus.com/files/a10s/Front%20MK802+.jpg

:(.

When I get some time I was going to see if the other half of the JTAG
port (PB12,PB13) is routed somewhere.

- Angus

Hans de Goede

unread,
Apr 22, 2013, 3:52:03 AM4/22/13
to linux...@googlegroups.com, Angus Gratton
Hi,

On 04/22/2013 09:45 AM, Angus Gratton wrote:
> On Mon, Apr 22, 2013 at 09:37:15AM +0200, Hans de Goede wrote:
>> The one I've which does not have any reachable / working uart pins is:
>> http://i868.photobucket.com/albums/ab244/electronic0305/MK802A10s.jpg
>>
>> So basically the classic mk802 but then with an A10s inside.
>
> Thanks Hans. Yeah, that's what mine looks like (was sold as an A10
> MK802.) Mine has this board (marked 2012/10/23 ST-G2 S-VER:1.0)
>
> http://www.projectgus.com/files/a10s/Front%20MK802+.jpg

Yep, same pcb as mine.

Note that once we've a working u-boot and images for this, not having
the uart should not be a big loss. Luckily I also have another
a10s based model which does have test-points for the uart.

Regards,

Hans

theRat

unread,
Apr 22, 2013, 3:57:25 AM4/22/13
to linux...@googlegroups.com
Angus,

Are you sure those pins are PB11 and PB14?  Although my A10s board is different to yours I have two test points in exactly the same spot that are the uart and looking at the data sheet the functions on those pins don't make much sense to bring out.  My board is a ST-G1-A10S VER0.2. and has a very similar layout in parts.

Simon

Hans de Goede

unread,
Apr 22, 2013, 4:01:09 AM4/22/13
to linux...@googlegroups.com
Hi,

On 04/22/2013 12:00 AM, theRat wrote:
> Hans,
>
> Well done.
>
> If you are talking about sdio/mmc wifi (ie rtl8189es) I have just posted more details here for you to look at.
> https://groups.google.com/d/msg/linux-sunxi/vKfoCQc0qxk/PCWm3Qo_q7sJ
>
> I am unaware of any spi-wifi?

Yes, my bad I thought it was spi based, but it is not.

Regards,

Hans

Angus Gratton

unread,
Apr 22, 2013, 4:05:24 AM4/22/13
to linux...@googlegroups.com
On Mon, Apr 22, 2013 at 12:57:25AM -0700, theRat wrote:
> Are you sure those pins are PB11 and PB14? Although my A10s board is
> different to yours I have two test points in exactly the same spot that are
> the uart and looking at the data sheet the functions on those pins don't
> make much sense to bring out. My board is a ST-G1-A10S VER0.2. and has a
> very similar layout in parts.
>
> Simon

Hi Simon,

Weird. And yeah, I definitely thought it was odd too.

On this one I had zero console output when booting Android.

So I used the fel-gpio tool to probe them. I just assumed the GPIO
address space was mapped the same on A10 and A10s, though. Maybe what
fel-gpio had as PB11/PB14 was actually something else?

Is there a date on your PCB? Despite mine being "G2" and "VER1.0", is
it possible yours is the newer & corrected version with the right UART
pins?

- Angus

theRat

unread,
Apr 22, 2013, 4:10:46 AM4/22/13
to linux...@googlegroups.com
Angus,

Mine is the A10s version of the mini-x aka MK805.  I reckon it came from the same people as yours.  The date on the back is 2013/01/10.

I am just setting up camera and lights so I can get some decent pics of it to put up.

I think I will shortly add a new A10S HTPC category on the linux-sunxi wiki.

Simon

Angus Gratton

unread,
Apr 22, 2013, 4:18:10 AM4/22/13
to linux...@googlegroups.com
On Mon, Apr 22, 2013 at 01:10:46AM -0700, theRat wrote:
> Angus,
>
> Mine is the A10s version of the mini-x aka MK805. I reckon it came from
> the same people as yours. The date on the back is 2013/01/10.

I agree. I think they stuffed up the UART routing on the older
revision I have and then fixed it with the revision you have.

> > I just assumed the GPIO
> > address space was mapped the same on A10 and A10s, though. Maybe what
> > fel-gpio had as PB11/PB14 was actually something else?

I just checked the A10 and A13 user manuals, and all the GPIO register
addresses are the same. From what I understand the A10s is closely
related to the A13, so I'm guessing they're the same.

Am I right that there is no comprehensive A10s manual available yet?

> I think I will shortly add a new A10S HTPC category on the linux-sunxi wiki.

Happy to upload or link my pictures if it's helpful.


- Angus

theRat

unread,
Apr 22, 2013, 4:58:39 AM4/22/13
to linux...@googlegroups.com
But how do you know that those test points are physically connected to PB11 and PB14?

This is my board:

On the board front the 3 test points at the bottom right of the A10s are ground, rx and tx.

Simon

theRat

unread,
Apr 22, 2013, 5:00:35 AM4/22/13
to linux...@googlegroups.com
The only datasheet I have seen is here:



On Monday, 22 April 2013 18:18:10 UTC+10, Angus Gratton wrote:

theRat

unread,
Apr 22, 2013, 5:39:33 AM4/22/13
to linux...@googlegroups.com
Cool,

At least we don't have anything else to deal with :)

That other post I made in the other thread should have everything needed for sdio/mmc cards.

Angus Gratton

unread,
Apr 22, 2013, 6:51:10 AM4/22/13
to linux...@googlegroups.com
Hi Simon,

Thanks for the help working through my understanding of this.

On Mon, Apr 22, 2013 at 01:58:39AM -0700, theRat wrote:
> But how do you know that those test points are physically connected to PB11
> and PB14?

I booted into 'fel' mode and used the fel-gpio tool from
linux-sunxi/sunxi-tools that reads/writes the GPIO registers over
USB.[1]

I measured voltages when driving PB11 & PB14 low & high using the
fel-gpio tool, but not when driving any of the documented UART pins
(as per the available A10s datasheet.)
Wow, that is similar! The routing is nearly identical, the DDR traces
on the bottom right side are 100% the same including the length
matching patterns.

Looking at it up close the traces near the test points look different
to me, though. I think they may be coming from different nearby balls:

http://www.projectgus.com/files/a10s/Comparison%20with%20mk805.png

(Sorry my pic is a bit blurry, took it in bad light with my phone!)

PB11/PB14 are at E3/F4, UART0 is at G3/G4.

Do you think much point in me doing any more probing or tests?

- Angus

[1] the pio tool actually needed a patch before fel-gpio mode worked,
I opened a Pull Request in github.

theRat

unread,
Apr 22, 2013, 7:25:03 AM4/22/13
to linux...@googlegroups.com
Angus,

To be honest I don't think getting your uart is going to really help, as Hans said once you have the thing booting the uart output is of no interest.  I think between Hans and I we have probably figured out the details needed to make the suckers work.  I think the biggest task now is figuring out how best to package up the required changes.  I think Hans might be taking the lead on that as I am far less experienced in doing linux style patches.

Have you tried the 4 patches that Hans posted (up ^^^ somewhere) to see if it gets your board working?

Simon.

Angus Gratton

unread,
Apr 22, 2013, 7:39:36 AM4/22/13
to linux...@googlegroups.com
On Mon, Apr 22, 2013 at 04:25:03AM -0700, theRat wrote:
> Angus,
>
> To be honest I don't think getting your uart is going to really help, as
> Hans said once you have the thing booting the uart output is of no
> interest.

You're both totally right that it'll be possible to use these with
Linux without a UART, and they'll be quite useful.

In my case I bought the module to run it headless, and using a
new/unique setup, so I was counting on having a UART. But I've
actually already bought another board for that project after I
recognised this one was UART-less.

Now I'm just curious about it. :)


> Have you tried the 4 patches that Hans posted (up ^^^ somewhere) to see if
> it gets your board working?

When I read that post I assumed that would make uboot run, but not a
kernel (or anything that I can see outside a serial port.) However
now I remember people mentioned warm booting Linux images, so maybe
I'll give it a shot.

Debugging blind is extremely frustrating though, so I might just wait
for you folks to work on it a bit more. :)

- Angus

Hans de Goede

unread,
May 4, 2013, 9:18:06 AM5/4/13
to linux...@googlegroups.com, franck...@gmail.com, avi...@gmail.com
Hi,

On 05/04/2013 12:29 PM, franck...@gmail.com wrote:
>
> Hi,
>
> I did a fresh git clone git://github.com/linux-sunxi/sunxi-bsp.git, then I try
> ./configure mk802+-a10s but I get the answer "a10s: unsupport SoC", whereas I feel that you're commiting for this chip.
>
> What have I done wrong?

Nothing the mk802+-a10s is not supported yet, u-boot support is available in
my personal u-boot tree:
https://github.com/jwrdegoede/u-boot-sunxi

And the kernel support is still being worked on.

Regards,

Hans

Henrik Nordström

unread,
May 5, 2013, 6:57:48 AM5/5/13
to linux...@googlegroups.com
sön 2013-05-05 klockan 03:00 -0700 skrev franck...@gmail.com:
> Thks for your answer.
>
> And so, with it, I'm guessing that only changing the µBoot to use a kernel for MK802 is not enough? (like this one: http://romanrm.ru/en/a10/debian)

Correct. A10 and A10s is different CPUs. A10s is a sister to A13, not
A10.

Regards
Henrik

theRat

unread,
May 6, 2013, 8:29:22 AM5/6/13
to linux...@googlegroups.com, kevin1...@gmail.com
I suggest you read back about 3 posts.  A10s is a work in progress and not supported yet.

On Monday, 6 May 2013 22:20:59 UTC+10, kevin1...@gmail.com wrote:

today i build the boot from https://github.com/jwrdegoede/u-boot-sunxi use mk802_a10s,

and build the kernel with sun5i_defconfig,

but i failed!

i don't have serial console to connect the device to see whether the boot or the kernel is wrong...

mk802 with a10s chip is so terrible!

can anyone fix it?

theRat

unread,
May 14, 2013, 5:44:27 PM5/14/13
to linux...@googlegroups.com, ver...@gmail.com
You also need a valid kernel.

Hans is working on the support for the A10s, it isn't a small task.  But I believe it is coming.  He just posted a bunch of patches for the wifi modules used in these devices.

I would suggest being just a little patient.

Cheers
Simon.

On Wednesday, 15 May 2013 07:32:49 UTC+10, ver...@gmail.com wrote:
On Tuesday, May 14, 2013 2:45:46 PM UTC-6, ver...@gmail.com wrote:
>
> I found and used a10s-r7-tv-dongle_config and was able to do a make.  It built tools/mkimage (among other things).  Am I missing something?  I don't see any new u-boot.bin file.

I wouldn't doubt it if everyone ignored my thoughtless ramblings.  Anyhow I was able to make a u-boot.bin using the a10s-r7-tv-dongle_config.  

Just didn't have any luck with it booting.  :(

Kevin Tang

unread,
May 26, 2013, 9:36:46 AM5/26/13
to linux...@googlegroups.com, avi...@gmail.com
uboot is OK in my last post!!!!!!!!!

boot file is script.bin and uImage  i'll post it later

the kernel start and who and tell me which serial port dose it use? 

i bought a tty usb serial and make the tx rx pin to debug, i can see the debug message, but after the kernel runs it close the serial port

I WANNA OPEN IT

Henrik Nordström

unread,
May 31, 2013, 9:33:03 AM5/31/13
to linux...@googlegroups.com
fre 2013-05-31 klockan 05:15 -0700 skrev biz...@gmail.com:

> - Run each linux from SD, using different known u-boot and SPL.

You need an SPL that is for your board. Or to be specific your memory
configuration and UART port (if you have one).

> - When press reset button & connect to PC - MK802 doesn't switch to other mode, it just reset firmware.

Odd..

> - Tried to use even CWM recovery - no success. Just blank screen.

Do you have a CWM recovery built for A10s?

It's very different from A10. Using something built for A13 might work
however as A10s is the big brother of A13, but not quite up to the
feature richness of A10.

Regards
Henrik

Henrik Nordström

unread,
May 31, 2013, 10:11:30 AM5/31/13
to linux...@googlegroups.com, avi...@gmail.com
fre 2013-05-31 klockan 06:43 -0700 skrev biz...@gmail.com:
> Unfortunately, there are no builds for A10s, and boots of A13 aren't working too.
> Looks like A10s is closer to A13 than A10, but anyway this is not A13.

sun5i u-boot and even SPL do work fine on A10s as such. But there is
still no support for AXP152 power management chip so SPL booting is not
very useful on most A10s boards as you can't clock the CPU to anything
reasonable (wrong core voltage).

Regards
Henrik

Henrik Nordström

unread,
May 31, 2013, 10:25:46 AM5/31/13
to linux...@googlegroups.com
fre 2013-05-31 klockan 07:24 -0700 skrev biz...@gmail.com:
> May be.
> I haven't so deep knowledges regarding that.
>
> So, is there a working solution ?
>

The solution is to implement AXP152 support and add an SPL definition
for your board.

There is AXP152 patches pending in the queue.

And see the sunxi u-boot wiki page for instructions on how to add a new
board.

Regards
Henrik

John S

unread,
May 31, 2013, 5:06:35 PM5/31/13
to linux...@googlegroups.com
"biz...@gmail.com" <biz...@gmail.com> wrote:

>Could anyone step-by-step assist me to make u-boot and SPL for MK802+ a10s ?
>
>I cloned git of sunxi-tools, I made copy of my android boot, I converted script.bin into plain text file (also, I unable convert other bins eg example u-boot.bin), but then I do not understand what I need.
>
>Please assist, or point to exact wiki url.

I don't think it exists yet.  The A10s is recent.  It is very like the A13 so look for info on that.

This is the fun of being on the bleeding edge with a semi-documented chip...

John

Henrik Nordström

unread,
May 31, 2013, 6:02:50 PM5/31/13
to linux...@googlegroups.com
fre 2013-05-31 klockan 13:39 -0700 skrev biz...@gmail.com:
> Seems I'm stupid, or a newbie, but I unable to understand, what same I should do.
>
> Could anyone step-by-step assist me to make u-boot and SPL for MK802+ a10s ?

There is no SPL support for A10s MK802+ yet.

But there are just fresh A10s support in u-boot sunxi-current branch.
Haven't yet tried actually booting Linux, but looks good so far (even
Ethernet works).

There is a proposed board definiton for your board (see archives from
24/4 "mk802_a10s: Add support for mk802 with a10s board") but needs to
be updated a bit to match the sunxi-current u-boot branch.

Regards
Henrik

Kevin Tang

unread,
Jun 3, 2013, 8:42:26 AM6/3/13
to linux...@googlegroups.com, avi...@gmail.com
a10s succeed running archlinux!!!!!!!!!!

& rootfs ARCHLINUX-SUN5I

uboot build from my previous post
kernel use sun4i_crane_defconfig and change arch to sun5i

and there is still some bugs to fix 

you can test it , but i don't responsible for what you're doing!

Kevin Tang

unread,
Jun 3, 2013, 8:50:27 AM6/3/13
to linux...@googlegroups.com, avi...@gmail.com
it's a pitty only serial console no hdmi 

在 2013年6月3日星期一UTC+8下午8时42分26秒,Kevin Tang写道:

Roman Mamedov

unread,
Jun 3, 2013, 10:09:52 AM6/3/13
to linux...@googlegroups.com, biz...@gmail.com, avi...@gmail.com
On Mon, 3 Jun 2013 07:02:04 -0700 (PDT)
Vitaliy Blats <biz...@gmail.com> wrote:

> Damn :(
> My strange device hasn't serial console.
>
> Also, yesterday I was killed my MK802+, while experimented with android
> kernel.
>
> There was nand partition (seems nanda) , which I mounted, and renamed
> "u-boot.bin" to "u-boot1.bin" in folder "/linux".
> Now device is dead, and recovery doesn't helps (process of recovery is
> executing, but after is no success).

I don't know which process you mean, but you can always flash an A10 device
with LiveSuit, it overwrites the NAND completely. So there is no way to brick
it, really.

--
With respect,
Roman
signature.asc

Vitaliy Blats

unread,
Jun 3, 2013, 10:22:01 AM6/3/13
to linux...@googlegroups.com, biz...@gmail.com, avi...@gmail.com
MK802+ devices may not work with LiveSuit.
My device has only one button. 
When we press on this button, and turn ON power, device just starts recovery itself from internal source.
It doesn't detects by PC via USB.
Sad story.

- - -
What I did:
1) SSHed to MK802.
2) Mounted nanda using mount /dev/block/nanda /mnt/temp
3) In this folder were few folders, one of them named "linux". In this folder, were few files like script.bin, scrip0.bin, magic.bin, u-boot.bin etc
4) I renamed u-boot.bin: mv u-boot.bin u-boot1.bin
5) After restart, device was not starts.

Also, may be device started, but I haven't any picture on HDMI out.


thanks for assistance



понедельник, 3 июня 2013 г., 10:09:52 UTC-4 пользователь Roman Mamedov написал:

Hans de Goede

unread,
Jun 3, 2013, 10:24:42 AM6/3/13
to linux...@googlegroups.com, Vitaliy Blats, avi...@gmail.com
Hi,

On 06/03/2013 04:02 PM, Vitaliy Blats wrote:
> Damn :(
> My strange device hasn't serial console.
>
> Also, yesterday I was killed my MK802+, while experimented with android kernel.
>
> There was nand partition (seems nanda) , which I mounted, and renamed "u-boot.bin" to "u-boot1.bin" in folder "/linux".
> Now device is dead, and recovery doesn't helps (process of recovery is executing, but after is no success).
> I have a local copy of this folder, but unable to enter in MK802.
>
> So..Is there a way to connect HDMI in your builds ?
> Sorry for my stupidness, I use this device only first week :)

I've a10s working with hdmi out, and I now also have finished writing a kernel
driver for the axp152 pmic on these devices, so now we can do voltage scaling
for the cpu, and actually turn the thing off when shutting down ...

This is all working now. I still need to add support for a bunch of boards
to the sunxi-current u-boot branch, and investigate some emac issues with
the A10s, and they I'll do a new release of the sunxi Fedora 18 images with
A10s support.

So patience my young padawan, patience. Hopefully by the end of the week I'll
have some brand new images for you. Which you can write to an sdcard and since
the nand is not involved in sdcard booting they should even work on a "bricked"
device.

Regards,

Hans

John S

unread,
Jun 3, 2013, 10:34:07 AM6/3/13
to linux...@googlegroups.com
The chip is likely to be able to talk over USB.
Have you tried the fel stuff?  Have you tried LiveSuit?
What happens in each case?

John


From: Vitaliy Blats <biz...@gmail.com>
To: linux...@googlegroups.com
Cc: biz...@gmail.com; avi...@gmail.com
Sent: Monday, 3 June 2013, 15:22
Subject: Re: [linux-sunxi] Re: SD Linux support for Allwinner A10s

Vitaliy Blats

unread,
Jun 3, 2013, 10:47:15 AM6/3/13
to linux...@googlegroups.com, John S
When FEL, i tried different FEL images, but device is not responsible (as I understand, it doesn't loading) until SD is plugged.
Also, when I tried to connect device to LiveSuit using press button and plug in USB - device just starts recovery process. USB is silent.
The same situation is under linux: no new devices found looking to lsusb.

MB I tried wrong FEL images ?

thanks. 

понедельник, 3 июня 2013 г., 10:34:07 UTC-4 пользователь John S написал:

Henrik Nordström

unread,
Jun 3, 2013, 3:27:07 PM6/3/13
to linux...@googlegroups.com, avi...@gmail.com
mån 2013-06-03 klockan 07:02 -0700 skrev Vitaliy Blats:

> There was nand partition (seems nanda) , which I mounted, and renamed
> "u-boot.bin" to "u-boot1.bin" in folder "/linux".
> Now device is dead, and recovery doesn't helps (process of recovery is
> executing, but after is no success).
> I have a local copy of this folder, but unable to enter in MK802.

It is not dead, but stuck in the boot1 bootloader.

You should be able to livesuit the device. Is there an UBOOT/RECOVERY
hard button? If not then try with the FEL SD image on an sdcard to force
FEL mode that way so livesuit can reflash the device.

Note: If you have a serial console then all you need to do is to press 2
during bootup to expose nanda as a USB device allowing you to fix
u-boot.bin that way.

Regards
Henirk


Vitaliy Blats

unread,
Jun 3, 2013, 4:12:01 PM6/3/13
to linux...@googlegroups.com, avi...@gmail.com
Yeah, I understand, but:

- I haven't serial console.
- Recovery button start to recovery (led is blinking), but no success (looks like original u-boot.bin is needed). Device still silent after process.
- To connect with LiveSuit i must switch device in needed mode. But I cannot do it, because one button recovery start recovery and there's no other buttons on device.
- As for FEL, I cannot find proper FEL which start on my MK802+ device. May be you can point me to proper FEL? ...
- FELs which I found (for example, from there: http://www.rikomagic.co.uk/forum/viewtopic.php?f=6&t=449&start=120) doesn't work. Device doesn't start, only one (of two) led is turn ON.

Thank you very much !



понедельник, 3 июня 2013 г., 22:27:07 UTC+3 пользователь Henrik Nordström написал:

Henrik Nordström

unread,
Jun 3, 2013, 4:29:13 PM6/3/13
to linux...@googlegroups.com, avi...@gmail.com
mån 2013-06-03 klockan 13:12 -0700 skrev Vitaliy Blats:

> - As for FEL, I cannot find proper FEL which start on my MK802+
> device. May be you can point me to proper FEL? ...

FEL is part of the boot rom. Not someting you add.

See http://linux-sunxi.org/FEL for instructions on how to enter FEL
mode.

And keep in mind that all the FEL boot image does is to put the device
into FEL mode. There will be no leds flashing or anything visible, only
visible effect is that it enters FEL USB device mode so that livesuit
can find it. (1f3a:efe8)

Regards
Henrik


Vitaliy Blats

unread,
Jun 3, 2013, 4:53:02 PM6/3/13
to linux...@googlegroups.com, avi...@gmail.com
Unfortunately, the same.
Under Windows - it doesn't detect any new hardware.
Under Linux, I can copypaste my terminal:

COPY FEL:
root@ntfs-workstation:/home/ntfs/MK802/sunxi-tools/bin# dd if=fel-sdboot.sunxi of=/dev/sdc bs=1024 seek=8
0+1 записей получено
0+1 записей отправлено
скопировано 512 байт (512 B), 0,00012384 c, 4,1 MB/c
root@ntfs-workstation:/home/ntfs/MK802/sunxi-tools/bin# sync
UNPLUG SD, PLUG IN MK802+:

root@ntfs-workstation:/home/ntfs/MK802/sunxi-tools/bin# lsusb 
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub - motherboard device
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub - motherboard device
Bus 002 Device 002: ID 040b:2000 Weltrend Semiconductor  - keyboard
Bus 002 Device 003: ID 09da:000a A4 Tech Co., Ltd Optical Mouse Opto 510D - mouse

No other devices found on USB.

Also, this is not A10 or A13 device.
I'ts A10s CPU.

Thank you....


понедельник, 3 июня 2013 г., 23:29:13 UTC+3 пользователь Henrik Nordström написал:

Vitaliy Blats

unread,
Jun 3, 2013, 6:08:12 PM6/3/13
to linux...@googlegroups.com, avi...@gmail.com
Looks like I did something wrong...
Usage: ./usb-boot board u-boot.bin [boot.scr|-] [kernel script.bin [initramfs]]

I tried this, but unable to understand, what same values I should to put here (not found on wiki).
board - what same board (or where I can find list of boards) ? - a10, a13, a10s ? Or sun4i, sun5i ?
u-boot.bin - where I need to get it ? It should be u-boot.bin from my nand ? Or something else ?

- - -

Thanks.


понедельник, 3 июня 2013 г., 23:29:13 UTC+3 пользователь Henrik Nordström написал:

Henrik Nordström

unread,
Jun 3, 2013, 6:21:18 PM6/3/13
to linux...@googlegroups.com, avi...@gmail.com
mån 2013-06-03 klockan 15:08 -0700 skrev Vitaliy Blats:
> Looks like I did something wrong...
> Usage: ./usb-boot board u-boot.bin [boot.scr|-] [kernel script.bin [initramfs]]

usb-boot requires you to first have the device in FEL mode.

> I tried this, but unable to understand, what same values I should to
> put here (not found on wiki).

http://linux-sunxi.org/FEL/USBBoot

> board - what same board (or where I can find list of boards) ? - a10,
> a13, a10s ? Or sun4i, sun5i ?

no, see wiki link above.

> u-boot.bin - where I need to get it ? It should be u-boot.bin from my
> nand ? Or something else ?

the u-boot.bin (or other stand-alone program) you want to run. Can be
the one from your nand or one build from source for your board or one
you found somewhere else.

But first of all you need to make the device enter FEL mode.

Regards
Henrik


Vitaliy Blats

unread,
Jun 3, 2013, 6:38:10 PM6/3/13
to linux...@googlegroups.com, avi...@gmail.com
Yeah, that's main issue.
This device cannot switch into FEL mode, using hardware methods.
You can look it on image.

And when tried standart FEL switch (using recovery button + USB on) - device just start recovery process, and doesn't switch into FEL.

Or may be I did something incorrectly...

thank you...




вторник, 4 июня 2013 г., 1:21:18 UTC+3 пользователь Henrik Nordström написал:

John S

unread,
Jun 4, 2013, 2:03:22 AM6/4/13
to linux...@googlegroups.com
As I understand it, there's an internal ROM in the A10s (as with A13, A10, etc) which decides whether to enter FEL mode.  Your board will have that ROM code.  It is not part of the NAND.  You "just" have to find how to make it enter FEL mode.  It is the same (I think) as any other A10s (or A13 or A10 or ...).

I believe that ROM code looks for specific pins in specific states or sequences of states, such as power button pressed 5 times or whatever.  We know some sequences for commoner chips like A10 and A13.  It is possible the A10s is different although it probably isn't.

So you can try all the things people found work on the other chips.

Or give up and buy another device - sorry but it may be this was a learning experience not to rename things!
I'm not saying you should give up - I wouldn't want to.

You can very possibly find a way to connect a serial console and/or JTAG, to help yourself.

John

From: Vitaliy Blats <biz...@gmail.com>

Henrik Nordström

unread,
Jun 4, 2013, 3:45:22 AM6/4/13
to linux...@googlegroups.com, avi...@gmail.com
mån 2013-06-03 klockan 15:38 -0700 skrev Vitaliy Blats:

> And when tried standart FEL switch (using recovery button + USB on) -

I do not think that button i a FEL/USBBOOT button but instead a soft
button most likely connected to the LRADC, same as is used for
next/prev/menu etc in devices with the normal Android buttons.

Regards
Henrik


Henrik Nordström

unread,
Jun 4, 2013, 3:54:21 AM6/4/13
to linux...@googlegroups.com
tis 2013-06-04 klockan 07:03 +0100 skrev John S:

> I believe that ROM code looks for specific pins in specific states or
> sequences of states, such as power button pressed 5 times or whatever.
> We know some sequences for commoner chips like A10 and A13. It is
> possible the A10s is different although it probably isn't.

Yes it looks for one specific pin "UBOOT". If this is active (pulled to
GND) then the CPU enters FEL mode immediately on power on without even
touching NAND or SD. This button is not used for any other purpose (at
least not yet).

To the best of my knowledge the A10s have the same boot sequence as A10
when the UBOOT pin is not active.
1. MMC0
2. NAND
3. other

So if the SD slot is connected to MMC0 then using the FEL boot image
hould have the device enter FEL mode immediately at boot as well,
similar to as if one hold the UBOOT pin active.

The 5 press thing is different and is done in the bootloader loaded from
NAND.

If the FEL boot image is not working then I can only thingk of three
possible reasons

a) If the image is ignored then it's not MMC0 that is routed to the SD
slot. The CPU can support several MMC slots.

b) If the image is loaded and executed then the USB port is perhaps not
the USB0 OTG port.

But it's very odd if it's 'b'.. devices are normally tested and
programmed at the factory using a factory version of livesuit.

Regards
Henrik


Vitaliy Blats

unread,
Jun 4, 2013, 6:07:52 AM6/4/13
to linux...@googlegroups.com, avi...@gmail.com
I found 3 pins on a board. It's marked as Rx, Tx, Gnd. 
What is it ?

No other marked pins, and any combinations of recovery button (press 5 times, press up to 10 sec) - didn't help.

- - -

thanks


вторник, 4 июня 2013 г., 3:45:22 UTC-4 пользователь Henrik Nordström написал:

Julian Calaby

unread,
Jun 4, 2013, 6:09:59 AM6/4/13
to linux...@googlegroups.com, avi...@gmail.com
Hi Vitaliy,

On Tue, Jun 4, 2013 at 8:07 PM, Vitaliy Blats <biz...@gmail.com> wrote:
> I found 3 pins on a board. It's marked as Rx, Tx, Gnd.
> What is it ?

Serial port.

Thanks,

--
Julian Calaby

Email: julian...@gmail.com
Profile: http://www.google.com/profiles/julian.calaby/
.Plan: http://sites.google.com/site/juliancalaby/

Vitaliy Blats

unread,
Jun 4, 2013, 6:30:47 AM6/4/13
to linux...@googlegroups.com, avi...@gmail.com
So, I can connect it directly to COM1\COM2 on my PC, and see output messages during OS loading ?
I mean, such like "screen /dev/tty0 86400" ?



вторник, 4 июня 2013 г., 6:09:59 UTC-4 пользователь Julian Calaby написал:

Julian Calaby

unread,
Jun 4, 2013, 6:34:41 AM6/4/13
to linux...@googlegroups.com, avi...@gmail.com
Hi Vitaliy,

On Tue, Jun 4, 2013 at 8:30 PM, Vitaliy Blats <biz...@gmail.com> wrote:
> So, I can connect it directly to COM1\COM2 on my PC, and see output messages
> during OS loading ?
> I mean, such like "screen /dev/tty0 86400" ?

Not without some form of voltage level shifter - hooking it directly
to a COM port on your PC will most likely blow up your A10s board.
It is loading more messages.
0 new messages