July 16, 2020, 11:56:13 am


Have you visited the Allwinner Chipset wiki? - http://linux-sunxi.org/

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Topics - tomg

Beginners / uart troubles on CB2 Fixed
March 07, 2014, 01:03:55 am
Can anyone help me to get uart5 and uart6 running ?

I have set up script.bin for PI10, PI11, PI12 and PI13
and the system now shows them in dmesg as ttyS1 and ttyS2

I have linked U14 pin 45 and 47 (tx to rx)
and linked U14 pin 46 and 48 (tx to rx)

When I run minicom I do not get any response on either ttyS1 or ttyS2

Running linux #1 SMP PREEMPT Sat Oct 26 18:10:18 CST 2013

Well I have answered my own question. Even though the two uarts which I am using
are 2 wire, the minicom application defaults to hardware flow control and as soon as I switched
that off hey presto data is delivered.

It makes no sense that a 2 wire interface should have hardware flow control
but there it is.
I have installed out of the box linaro on cb2 and when I play mp3 files they sound scratchy.
I am getting the sound through HDMI. I noticed when using android out of the box the sound quality was great. Does any one have any idea's on how to fix this ?
Please do not suggest installing another kernel. I can live without playing mp3's if I cannot fix.

If you use ftp to transfer binary files such as mp3 files remember to transfer in binary
mode else they will be corrupted.
Out of the box.
cubieboard2 booted up android and worked very well.
I installed linaro cb-a20-lubuntu-desktop-card-v105.img to mmc card 4GB and it failed.
Then installed that image to another card and it worked.
Always suspect mmc cards !

After lubuntu booted up it seemed very slow but then it was on an mmc card.
When I tried to bring up android from nand I got a half filled block in the middle of the screen
and thats where it stayed.
I installed CUBIER from the website android-cb2-20131230.img and that worked great.
boot from nand super !
Then booted lubuntu from the mmc card and that worked fine.
Tried to boot android from nand "Depressing half filled box in the middle of the screen".
Reinstalled android again thats fine. and can boot lubuntu from the card guess what ? android gone again.
Any one have any knowledge ?
An update.
I have just installed the linaro nand image using phoenixcard to the cubieboard2 and I have to say that
I shouldn't have bothered with the card image or android this image is much faster and the sceen resolution much finer.
I am ready to do some work now. Compile a program Woops ... No compiler !
Installed gcc make and dev files on cb2 and now compiling native.
Compiled c code to access PORT registers via mmap and tested with the status led on the cb2.
Started to build a library to access gpio ports.
I now have a library to access the configuration of all of the i/o ports on the allwinner SoC for the cubieboard.
This allows me to find out what each port is configured for and to modify the settings.
Subroutines include getCfg (), setCfg (), getPin (), setPin (), clrPin ().

An example which will flash the status led on and off a few times (Green led on the cb2)

#include <stdio.h>
#include "registers.h"

main ()
setPin (PORTH, 20);
sleep (1);
clrPin (PORTH, 20);
sleep (1);
setPin (PORTH, 20);
sleep (1);
clrPin (PORTH, 20);

Next step is to include PWM in the library.

Dual boot nand or mmc
I now have and image of v105 on mmc card as a backup and can boot either
from nand or mmc card.

Attached sata drive
Also I have attached a 500 GB sata disk which I am using to store software on.

Create additional tty ports.
Yesterday managed to modify a fex file to enable two extra ttl uarts
uart5 and uart6 are now enabled.