element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
RIoTboard
  • Products
  • Dev Tools
  • Single-Board Computers
  • RIoTboard
  • More
  • Cancel
RIoTboard
Forum Hard Float on RIoTboard
  • Blog
  • Forum
  • Documents
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join RIoTboard to participate - click to join for free!
Actions
  • Share
  • More
  • Cancel
Forum Thread Details
  • Replies 8 replies
  • Subscribers 23 subscribers
  • Views 694 views
  • Users 0 members are here
  • riotboard
  • hardfloat
  • linux
Related

Hard Float on RIoTboard

Former Member
Former Member over 11 years ago

It appears that freescale do not have a hard float linux released. This limits the platform significantly. Can anyone at Element14 please put pressure  on freescale, or better yet compile their own version of linux with the enabled? Without this the usefulness of the board as an embedded platform is limited as many libraries and frameworks are only building against hard float.

Thanks.

  • Sign in to reply
  • Cancel
  • Former Member
    Former Member over 11 years ago

    What of the Linux download from http://riotboard.org/index.php/download is it soft float ?

     

    Personally, I ran through http://www.linuxfromscratch.org/ to build my own system with the settings I wanted.

     

    Which libraries and frameworks ?  Examples ?   If you have source to these libraries I think it's very likely you can build them for whatever you like.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • radiatortwo
    radiatortwo over 11 years ago

    All you need is an RootFS partition with debian with hardfloat.

     

    You can create one with debootstrap and qemu inside a virtual machine for example. Then pack the files into a tgz and flash it to the Riotboard.

     

    No need to compile the whole System from scratch.

     

    If you need directions for this just ask.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • Former Member
    Former Member over 11 years ago in reply to radiatortwo

    Hello, may I ask you for a little help with creating rootfs using debootstrap? I managed to download ubuntu rootfs using debootstrap, but I was not able to run qemu with compiled kernel 3.0.35 for RiotBoard. I tried kernel from ubuntu sites Index of /ubuntu-ports/dists/precise/main/installer-armel/current/images/linaro-vexpress/netboot which works in qemu, but when I finished debootstrap --second-stage, tarball rootfs and flash it to RiotBoard, during boot it hangs with message Freeing init memory: 212K

     

    So if you are able to write some steps how to go through this. It would be nice.

     

    Thank you

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • radiatortwo
    radiatortwo over 11 years ago in reply to Former Member

    I didn´t test it with the Ubuntu rootfs system by now. I did it with Debian.

    Also I used the precompiled Kernel you get with the Ubuntu Linux Image.

     

    Here are the steps I did to create the rootfs. (I have a Windows System with a Debian VMWare Virtual Machine to create and then flash it)

     

    1. Get the needed packages in the host system

     

    apt-get install qemu-user-static debootstrap binfmt-support

     

    2. Set the evironment variables then create the directory and download the basic Debian system

    targetdir=rootfs

    distro=wheezy

     

    mkdir rootfs

    debootstrap --arch=armhf --foreign $distro $targetdir

     

    3. Copy the qemu-arm-static-binary into the created system and the resolv.conf from the host

     

    cp /usr/bin/qemu-arm-static $targetdir/usr/bin/

    cp /etc/resolv.conf $targetdir/etc

     

    4. Change into the new rootfs system

     

    chroot $targetdir

     

    5. In the new rootfs system we need to set the variables again

     

    distro=wheezy

    export LANG=C

     

    6. Execute second stage

     

    /debootstrap/debootstrap --second-stage

     

    7. We need a sources.list and some settings.

    Change the locale in the URLs in the following script to your locale:

     

    cat <<EOT > /etc/apt/sources.list

    deb http://ftp.de.debian.org/debian $distro main contrib non-free

    deb-src http://ftp.de.debian.org/debian $distro main contrib non-free

    deb http://ftp.de.debian.org/debian $distro-updates main contrib non-free

    deb-src http://ftp.de.debian.org/debian $distro-updates main contrib non-free

    deb http://security.debian.org/debian-security $distro/updates main contrib non-free

    deb-src http://security.debian.org/debian-security $distro/updates main contrib non-free

    EOT

     

    cat <<EOT > /etc/apt/apt.conf.d/71-no-recommends

    APT::Install-Recommends "0";

    APT::Install-Suggests "0";

    EOT

     

    8. Update the lists

    (You´ll get some ignored lines because we didn´t set up the locales by now.)

     

    apt-get update

     

    9. Setup the missing locales and update again

    (The ignored lines should be pulled now)

     

    apt-get install locales dialog

    dpkg-reconfigure locales

    apt-get update

     

    10. Now we have basically installed all we need, but I like to install some useful stuff.

     

    apt-get install openssh-server ntpdate

     

    11. Set the root password

     

    passwd

     

    12. We need at least an DHCP connection on eth0 (configure as you like)

     

    echo <<EOT >> /etc/network/interfaces

    allow-hotplug eth0

    iface eth0 inet dhcp

    EOT

     

    13. We need a hostname (Change as you like)

     

    echo debian-armhf > /etc/hostname

     

    14. We can quit the chroot shell now

     

    exit

     

    15. We need to remove the files we copied into the system

     

    rm $targetdir/usr/bin/qemu-arm-static

    rm $targetdir/etc/resolv.conf

     

    16. We now have a fully functional rootfs system and can put it into a tgz file

    Notice the parameter p in the tar command. This means the permissions stay like they are inside the rootfs. This is very important!

     

    cd rootfs

    tar cvzpf oneiric.tgz *

     

    Now you can flash the file by replacing it inside the files folder in the standard linux image with MFGTools.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • Former Member
    Former Member over 11 years ago in reply to radiatortwo

    Thank you very much for your guide. I followed your solution which lead me to bootable rootfs, but unfortunately when system starts booting on my RiotBoard it hangs after loading openssh and die on that place. Have you experienced this kind of state?

     

    Freeing init memory: 208K
    INIT: version 2.88 booting
    [info] Using makefile-style concurrent boot in runlevel S.
    [ ok ] Starting the hotplug events dispatcher: udevd.
    [ ok ] Synthesizing the initial hotplug events...done.
    [....] Waiting for /dev to be fully populated...ERROR: v4l2 capture: slave not found!
    ----mx6_csi0_cam_powerdown 0
    --------Setting mclk to 24 MHz
    ov2656_read_reg:write reg error:reg=300a
    ----mx6_csi0_cam_powerdown 1
    done.
    [ ok ] Activating swap...done.
    [warn] Creating compatibility symlink from /etc/mtab to /proc/mounts. ... (warning).
    [ ok ] Cleaning up temporary files... /tmp.
    [ ok ] Activating lvm and md swap...done.
    [....] Checking file systems...fsck from util-linux 2.20.1
    done.
    [ ok ] Mounting local filesystems...done.
    [ ok ] Activating swapfile swap...done.
    [ ok ] Cleaning up temporary files....
    [ ok ] Setting kernel variables ...done.
    [ ok ] Configuring network interfaces...done.
    [ ok ] Cleaning up temporary files....
    INIT: Entering runlevel: 2
    [info] Using makefile-style concurrent boot in runlevel 2.
    [ ok ] Starting enhanced syslogd: rsyslogd.
    [ ok ] Starting periodic command scheduler: cron.
    [ ok ] Starting OpenBSD Secure Shell server: sshd.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • radiatortwo
    radiatortwo over 11 years ago in reply to Former Member

    If you get to that point the system should be up and running. It says ok at Starting OpenBSD Secure Shell server: sshd. Which means the shell is started.

     

    You can now connect over ssh into the system.

    If you don´t know the ip (because you´re using DHCP) you can look into your DHCP Server or Router for the ip.

    If you can´t find it there do an IP-Scan with Advanced IP-Scanner or similar.

    Alternatively connect it over HDMI to your monitor then login with root and your password and type in "ifconfig" to get the IP. You maybe have to reset the board to get a picture at this point.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • Former Member
    Former Member over 11 years ago in reply to radiatortwo

    Thank you for the hint. I was trying to access debian via ssh before, but it was not working. I thought that system died during the boot. Thanks to your hint I finally found the problem. In network configuration you used allow-hotplug eth0 I changed that to auto eth0 and than my network interface load successfully and I'm now able to login via ssh. Actually I don't know what difference is between those two configurations, but for me allow-hotplug was not working. Maybe it will help someone.

     

    Thank you for your help one more time

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • radiatortwo
    radiatortwo over 11 years ago in reply to Former Member

    Strange. On my board hotplug is working.

     

    But you´re right. I used hotplug because it uses the Kernel Hotplug Event. It then won´t activate when restarting the interfaces with "/etc/intit.d/networking restart".

    It should be used for non static interfaces, like Wireless USB Sticks.

     

    For static interfaces the auto option is better. Maybe you didn´t get the hotplug event from the Kernel when the board started.

     

    Glad I could help and it´s working now.

     

    Edit:

    Just read that allow-hotplug is deprecated. Shouldn´t use it in the future...

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube