Announcement

Collapse
No announcement yet.

Announcement

Collapse
No announcement yet.

Linux for RK3188 based TV boxes

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Haha, turns out I was using the wrong initramfs.
    Switched to the right one with my mk908 kernel source and I'm up and running with it on NAND.
    But my wifi stopped working... so now I have to figure that out.

    The fun never stops!

    Edit: My kernel and the other kernel were looking for wifi firmware in different spots. I'm all set now!
    Last edited by tyeo098; 15 January 2014, 16:25.
    Buy me a beer with
    DogeCoin: D6EeoEKcZJL234UhVFRV8Uy6HnfNurBS2y
    or
    BitCoin 17iQsUv7RoWVmDynfBS9qF88NxT4ETvhUn

    Comment


      TimingPower RK3188 Working!

      Thanks for all of the hard work!


      Following instructions on first page of this thread I was able to get Ubuntu running first time I tried it in NAND. WiFi is not working so I am using a USB-Ethernet dongle but I am still troubleshooting. I have also emailed the TimingPower developer and asked for the chipset info and driver if he has one.

      Comment


        TimingPower 3188 WiFi Update

        Just heard from the developer, the WiFi chipset is the RK903. From the quick research I have done, it looks like it is equivalent to the Broadcom 40183 chipset. Now off to complete my troubleshooting.

        Comment


          @mmm123 Thank you so much for creating this . I wish I had found it sooner. I've
          been struggling to get Debian running on my new K-R42. This runs, however, the wire
          ethernet doesn't work. I think it may be hardware, which will suck, because I can't imagine
          getting fair treatment trying to return it to china. The wire ethernet acts like it is doing the
          right thing, but no packets actually reach the network. I was sniffing my LAN, while it was
          making requests, and I never saw frames from my device when it was seeking an IP address
          from the DHCP server. I saw that it was broadcasting from the ip address it was saying it
          was requesting on, but I never saw anything hit the network with wireshark.

          Is there any chance you have an idea of what the issue might be, or how to debug this.
          Running dhclient with the -d option did not provide me very much to go on, except to see
          that it was broadcasting to reach the DHCP server. I have never seen this behavior before.
          All my other devices just connect to the DHCP server, and get assigned an ip address.

          Grateful but Confused ,


          Originally posted by mmm123 View Post
          [Edit: This is working on K-R42/CS918/MK888/DX05 devices, if you try it on another device, please report your results ]

          Version 1.1.1 some updates in kernel and load process.
          If you have it running with previous version, there is no need to update.

          RK Flash tools:


          Full installation in internal nand flash
          Debian: http://data.a41z.net/X9fG54/dx05_nand_debian_1.1.1.7z
          Ubuntu: http://data.a41z.net/X9fG54/dx05_nand_ubuntu_1.1.1.7z

          Install instruction:
          WARNING ALL DATA ON DEVICE WILL BE LOST - I MEAN ALL OF IT!!!

          -extract archive
          -start RKBatchTool
          -connect device to a USB port
          -power on
          -press reset button
          -if this is first time connecting to this PC, install drivers from drivers dir)
          -in RKBatchTool, the little grey box with [1] in it should become green.
          -choose image file
          LAST WARNING - ALL EXISTING DATA ON DEVICE WILL BE LOST IN NEXT STEP!
          -click restore. Install tool will format flash and reboot into linux.

          now as it is first time you running your new linux, I strongly recommend doing these steps:
          1. login as root (there is no password)
          2. type "passwd" to set root password
          3. type "adduser" to add new non-root user
          4. make sure, that device is connected to network via LAN
          run: apt-get update
          run: tasksel - choose whatever you want (for example Desktop environment)
          Alternatively - use apt-get to install dselect or aptitude and install whatever packages you want.

          To restore Android - download any of custom roms and follow installation procedure.

          NOTE about UBUNTU. After loading kernel, at some point some error messages are displayed and it looks like system is frozen. It is not, wait 2-3 minutes and it will continue and work normally. I am not a ubuntu expert, so if someone has idea how to fix this, please post some solution and i will fix it in next release.



          Running linux from SD card or USB device


          This is for advanced users - kernel and initrd will be installed into internal flash,
          but linux will run from external device

          Step 1 - prepare linux
          Get a SD card or USB flash drive, install partition table,
          format one partition with ext4, label it "linuxroot"
          install any debian, ubuntu, picuntu or something else compiled for armhf

          Step 2 prepare rk3188 device
          WARNING ALL DATA ON DEVICE WILL BE LOST

          -extract archive
          -start RKBatchTool
          -connect device to a USB port
          -power on
          -press reset button
          -if this is first time connecting to this PC, install drivers from drivers dir)
          -in RKBatchTool, the little grey box with [1] in it should become green.
          -choose image file
          LAST WARNING - ALL EXISTING DATA ON DEVICE WILL BE LOST IN NEXT STEP!
          -click restore. Install tool will format flash and reboot into linux.

          kernel contains all necessary drivers to start linux, but additional drivers are available in modules.tgz
          To restore Android - download any of custom ROMs and follow installation procedure.


          Recovery image:

          Just install it to recovery partition and reboot into recovery mode, it will boot from SD/USB with label linuxroot
          Tool suitable for this is RkFlashKit for linux.

          Comment


            Originally posted by atenhotep View Post
            @mmm123 Thank you so much for creating this . I wish I had found it sooner. I've
            been struggling to get Debian running on my new K-R42. This runs, however, the wire
            ethernet doesn't work. I think it may be hardware, which will suck, because I can't imagine
            getting fair treatment trying to return it to china. The wire ethernet acts like it is doing the
            right thing, but no packets actually reach the network. I was sniffing my LAN, while it was
            making requests, and I never saw frames from my device when it was seeking an IP address
            from the DHCP server. I saw that it was broadcasting from the ip address it was saying it
            was requesting on, but I never saw anything hit the network with wireshark.

            Is there any chance you have an idea of what the issue might be, or how to debug this.
            Running dhclient with the -d option did not provide me very much to go on, except to see
            that it was broadcasting to reach the DHCP server. I have never seen this behavior before.
            All my other devices just connect to the DHCP server, and get assigned an ip address.

            Grateful but Confused ,
            Check if your card has a MAC address or better just set one
            ifconfig eth0 hw ether 00:00:00:12:12:12

            You can add this to /etc/network/interfaces
            ---
            auto eth0
            iface eth0 inet dhcp
            pre-up ifconfig eth0 hw ether 00:00:00:12:12:12
            ---

            Comment


              Originally posted by mmm123 View Post
              Check if your card has a MAC address or better just set one
              ifconfig eth0 hw ether 00:00:00:12:12:12

              You can add this to /etc/network/interfaces
              ---
              auto eth0
              iface eth0 inet dhcp
              pre-up ifconfig eth0 hw ether 00:00:00:12:12:12
              ---

              Thanks for the quick response. I appreciate it.

              My eth0 interface does have a MAC address. From my k-r42:

              $ sudo ifconfig
              eth0 Link encap:Ethernet HWaddr 7a:75:5d:57:15:9c

              and when I run the dhclient:


              sudo dhclient -d eth0
              Internet Systems Consortium DHCP Client 4.2.2
              Copyright 2004-2011 Internet Systems Consortium.
              All rights reserved.
              For info, please visit https://www.isc.org/software/dhcp/

              Listening on LPF/eth0/7a:75:5d:57:15:9c
              Sending on LPF/eth0/7a:75:5d:57:15:9c
              Sending on Socket/fallback
              DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 4
              DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 11
              DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 16
              DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 14
              DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 15
              DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 1
              No DHCPOFFERS received.
              No working leases in persistent database - sleeping.

              I'm willing to experiment with your suggestion,though.

              In doing so I got results, just like above except, of course,
              the MAC address was the address assigned to the device.

              Thanks again for such a quick reply,

              Comment


                Wifi Driver Issue

                Ok, I know this is not a new issue but I am stuck. I am unable to find the Ubuntu Broadcom 4330 driver to install.

                I do see the following out of dmesg:
                [ 0.196764] gpio_request: gpio-14848 (wifi_power) status -22
                [ 0.196786] rk29sdk_wifi_bt_gpio_control_init: request wifi power gpio failed
                [ 0.874658] Rockchip WiFi SYS interface (V1.00) ...

                any suggestions as to where to go from here?

                Comment


                  Originally posted by atenhotep View Post
                  My eth0 interface does have a MAC address. From my k-r42:
                  I'v got the same messages and eth0 does not receive address.
                  I have T-R42 mini-pc with internal bluetooth module. It also known as mk888b.
                  I think it had some different hardware NIC or it is not proper configured by kernel.

                  I also tried picuntu 4.5. I can't use WLAN or LAN with it.
                  ....
                  I've opened the box and checked the board. It is V2.0
                  WLAN+BT: RTL8723AS and LAN: RTL8201F
                  Last edited by tigra; 17 January 2014, 00:26.

                  Comment


                    Originally posted by tigra View Post
                    I'v got the same messages and eth0 does not receive address.
                    I have T-R42 mini-pc with internal bluetooth module. It also known as mk888b.
                    I think it had some different hardware NIC or it is not proper configured by kernel.

                    I also tried picuntu 4.5. I can't use WLAN or LAN with it.
                    ....
                    I've opened the box and checked the board. It is V2.0
                    WLAN+BT: RTL8723AS and LAN: RTL8201F
                    I haven't opened mine up yet, but my WIFI does work. So does plugging in a USB
                    to ethernet adapter. However, I bought the K-R42, because I would not need to
                    plug in an ethernet adapter to get it on the wire internet. I'd have bought an
                    MK802iv, or a CX-919 if I wasn't wanting the built in RJ-45 connector. So it goes ...

                    Comment


                      Wi Fi goes sleeping?

                      I've installed web server on mk908 with picuntu, work's ok.
                      But if i not connecting to web server for some time (several minutes) mk908 not responding on connections ('no route to host' or 'host unreachable'). If i try to connect several times, web server (or mk908 wifi?) wakes up and responding ok.

                      When i continiuosly pinging mk908 from pc i've got no problems with connecting to web server.

                      Any ideas?

                      Comment


                        Originally posted by atenhotep View Post
                        My eth0 interface does have a MAC address. From my k-r42:
                        Would you please check dmesg for lines like these and post result:

                        Jan 1 02:00:28 rk3188 kernel: [ 12.241585] enter func vmac_open...
                        Jan 1 02:00:28 rk3188 kernel: [ 12.247097] power on phy
                        Jan 1 02:00:28 rk3188 kernel: [ 13.320597] vmac_mii_bus: probed
                        Jan 1 02:00:28 rk3188 kernel: [ 13.328359] rk29 vmac rk29 vmac.0: PHY driver [Generic PHY] (mii_bushy_addr=0:00, irq=-1)
                        Jan 1 02:00:28 rk3188 kernel: [ 13.338490] ADDRCONF(NETDEV_UP): eth0: link is not ready
                        Jan 1 02:00:28 rk3188 kernel: [ 15.324216] PHY: 0:00 - Link is Down
                        Jan 1 02:00:28 rk3188 kernel: [ 17.324264] PHY: 0:00 - Link is Up - 100/Full
                        Jan 1 02:00:28 rk3188 kernel: [ 17.334035] ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready

                        In general these devices don't have eeprom to store mac address so each time when you restart it it get some random mac (for android mac is stored into flash and there is a script which sets it duryng boot). Sometimes these random macs are invalid. Even if they are valid, changing mac evry time confuses DHCP server.

                        Comment


                          Originally posted by subver View Post
                          I've installed web server on mk908 with picuntu, work's ok.
                          But if i not connecting to web server for some time (several minutes) mk908 not responding on connections ('no route to host' or 'host unreachable'). If i try to connect several times, web server (or mk908 wifi?) wakes up and responding ok.

                          When i continiuosly pinging mk908 from pc i've got no problems with connecting to web server.

                          Any ideas?
                          Just a wild guess, but try to change CPU governor to "performance"
                          check power settings with powertop and disable wlan power savings if they exist

                          Comment


                            Originally posted by 6stringplayer View Post
                            Ok, I know this is not a new issue but I am stuck. I am unable to find the Ubuntu Broadcom 4330 driver to install.

                            I do see the following out of dmesg:
                            [ 0.196764] gpio_request: gpio-14848 (wifi_power) status -22
                            [ 0.196786] rk29sdk_wifi_bt_gpio_control_init: request wifi power gpio failed
                            [ 0.874658] Rockchip WiFi SYS interface (V1.00) ...

                            any suggestions as to where to go from here?
                            Wifi/BT power is controlled by GPIO pins from CPU. CPU has several of these GPIOs, and each board manufacturer decides which one to use. In your case, manufacturer decided to use something different from what others do, and because of that, driver can't control power state of your WiFi Card.
                            Solution is to re-compile wifi driver with proper GPIO settings, but guessing which ones are correct is dangerous process, as experiments might damage your device.
                            Try to see dmesg from android kernel and see if it by any chence mentions which GPIOs are used.
                            There is also some program which debugs GPIO ussage, it might help if you run it in android and play with WiFi.

                            Comment


                              Originally posted by mmm123 View Post
                              Would you please check dmesg for lines like these and post result:

                              Jan 1 02:00:28 rk3188 kernel: [ 12.241585] enter func vmac_open...
                              Jan 1 02:00:28 rk3188 kernel: [ 12.247097] power on phy
                              Jan 1 02:00:28 rk3188 kernel: [ 13.320597] vmac_mii_bus: probed
                              Jan 1 02:00:28 rk3188 kernel: [ 13.328359] rk29 vmac rk29 vmac.0: PHY driver [Generic PHY] (mii_bushy_addr=0:00, irq=-1)
                              Jan 1 02:00:28 rk3188 kernel: [ 13.338490] ADDRCONF(NETDEV_UP): eth0: link is not ready
                              Jan 1 02:00:28 rk3188 kernel: [ 15.324216] PHY: 0:00 - Link is Down
                              Jan 1 02:00:28 rk3188 kernel: [ 17.324264] PHY: 0:00 - Link is Up - 100/Full
                              Jan 1 02:00:28 rk3188 kernel: [ 17.334035] ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready

                              In general these devices don't have eeprom to store mac address so each time when you restart it it get some random mac (for android mac is stored into flash and there is a script which sets it duryng boot). Sometimes these random macs are invalid. Even if they are valid, changing mac evry time confuses DHCP server.
                              Yes. I got this lines in dmesg and I've checked eth0 MAC is randomly generated after reboot.
                              Does your kernel support rtl8201f and rtl8723as?

                              Comment


                                Originally posted by mmm123 View Post
                                Would you please check dmesg for lines like these and post result:

                                Jan 1 02:00:28 rk3188 kernel: [ 12.241585] enter func vmac_open...
                                Jan 1 02:00:28 rk3188 kernel: [ 12.247097] power on phy
                                Jan 1 02:00:28 rk3188 kernel: [ 13.320597] vmac_mii_bus: probed
                                Jan 1 02:00:28 rk3188 kernel: [ 13.328359] rk29 vmac rk29 vmac.0: PHY driver [Generic PHY] (mii_bushy_addr=0:00, irq=-1)
                                Jan 1 02:00:28 rk3188 kernel: [ 13.338490] ADDRCONF(NETDEV_UP): eth0: link is not ready
                                Jan 1 02:00:28 rk3188 kernel: [ 15.324216] PHY: 0:00 - Link is Down
                                Jan 1 02:00:28 rk3188 kernel: [ 17.324264] PHY: 0:00 - Link is Up - 100/Full
                                Jan 1 02:00:28 rk3188 kernel: [ 17.334035] ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready

                                In general these devices don't have eeprom to store mac address so each time when you restart it it get some random mac (for android mac is stored into flash and there is a script which sets it duryng boot). Sometimes these random macs are invalid. Even if they are valid, changing mac evry time confuses DHCP server.
                                Thanks again for such a quick response. I am sorry it's taken me a while to get back to you.

                                I see a block of log messages that are similar. It does seem that eth0 physical interface does not have a MAC address signed initially. However, by the time I can run ifconfig, or manually run dhclient, it does.

                                Here's that portion of my syslog:
                                [ 11.247811] enter func vmac_open...
                                [ 11.247861] power on phy
                                [ 12.308493] vmac_mii_bus: probed
                                [ 12.311318] rk29 vmac rk29 vmac.0: PHY driver [Generic PHY] (mii_bus: phy_addr=0:00, irq=-1)
                                [ 12.314594] ADDRCONF(NETDEV_UP): eth0: link is not ready
                                [ 14.303032] PHY: 0:00 - Link is Down
                                [ 16.303038] PHY: 0:00 - Link is Up - 100/Full
                                [ 16.312992] ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
                                [ 26.642634] eth0: no IPv6 routers present
                                Why does it still fail later after a MAC address is assigned though, and what can I do about it?

                                Curiously,

                                Comment

                                Working...
                                X