Jump to content
Ultimaker Community of 3D Printing Experts

Recommended Posts

Posted · Interesting choices

New user here. Questions:

- Why does a $3500 device feature a cheap UVC camera with resolution so low you can barely read the Ultimaker logo?

- Why not use some lightweight embedded Linux distribution (Alpine?) instead of bloated Debian with systemd that eats all free space and stresses mtd with constant writes.

- Where is a github repository for Ultimaker 3?

  • Link to post
    Share on other sites
    Posted (edited) · Interesting choices
    - Why does a $3500 device feature a cheap UVC camera with resolution so low you can barely read the Ultimaker logo?

    It was said that manufacturing a higher-end camera specifically for the UM3 was either cost-prohibitive or would have delayed the release.

    - Why not use some lightweight embedded Linux distribution (Alpine?) instead of bloated Debian with systemd that eats all free space and stresses mtd with constant writes.

    Good call, maybe they had some ideas behind that ?

    - Where is a github repository for Ultimaker 3?

    Nowhere.

    And we are approaching the usual 6 months wait time between release of the printer and the availability of source files.

    I still find that waiting 6 months before publishing source files while claiming to be open-source is not very fair play.

    Edited by Guest
    • Like 1
    Link to post
    Share on other sites
    Posted · Interesting choices
    - Why does a $3500 device feature a cheap UVC camera with resolution so low you can barely read the Ultimaker logo?

     

    Because it's cheap? The machine is already expensive enough as far as i can see. There is nothing wrong per se with UVC, but this is indeed a pretty rubbish camera.

     

    - Why not use some lightweight embedded Linux distribution (Alpine?)

    Because when we started (+- 3 years ago) Alpine wasn't really a thing yet. Switching distros is dangerous & expensive.

     

    systemd

    SystemD does perfectly what we need it to do. Especially if we ever want to open up the platform.

     

    - Where is a github repository for Ultimaker 3?

    It's not out yet. Most of the code is in python anyway and easy to view on the machine.

  • Link to post
    Share on other sites
    Posted · Interesting choices

     

    - Why not use some lightweight embedded Linux distribution (Alpine?)

     

    Because when we started (+- 3 years ago) Alpine wasn't really a thing yet. Switching distros is dangerous & expensive.

     

    Plus, it's bloody difficult to beat Debian for stability.

  • Link to post
    Share on other sites
    Posted · Interesting choices

    Plus, it's bloody difficult to beat Debian for stability.

     

    That was also a point of consideration. Together with more developers (both inside and outside of UM) being familiar with the distro. The last should not be a very strong reason to do it, but it's something one should take into account.

    • Like 1
    Link to post
    Share on other sites
    Posted (edited) · Interesting choices

     

    Plus, it's bloody difficult to beat Debian for stability.

     

    That was also a point of consideration. Together with more developers (both inside and outside of UM) being familiar with the distro. The last should not be a very strong reason to do it, but it's something one should take into account.

     

    Having a large knowledge base from an equally large number of users is always handy no matter what you're planning, that's for certain! Having to learn the particulars of something unrelated to the actual development can be a real pain in the butt when the project itself is already on the verge of making your hair fall out :)

    Edited by Guest
  • Link to post
    Share on other sites
    Posted (edited) · Interesting choices

     

    - Why does a $3500 device feature a cheap UVC camera with resolution so low you can barely read the Ultimaker logo?

     

    Because it's cheap? The machine is already expensive enough as far as i can see. There is nothing wrong per se with UVC, but this is indeed a pretty rubbish camera.

    Yes it is a cheap camera, but that was the whole point, we wanted to just monitor prints, not add to the price for a super high-end camera.

     

    That said, the camera defaults to 800x600 on purpose. It is 'good enough' for streaming purposes and is easy to work with, low bandwith etc. One use-case was to monitor a print remotly, via a mobile phone (or even a mobile connection). You don't want to do 1280x1024 there.

    Having said that, the camera is actually 1600x1200. We had choosen 800x600 as a default resolution exactly because it is a quarter resolution, and the controller chip on the camera can do some tricks to give you a little bit higher image quality while still giving the maximum field of view.

    Feel free to change the camera to a higher resolution, edit the file ' mjpg-streamer\@.service' on the printer and change the -r parameter from SVGA to whatever resolution the camera supports; e.g.

     

    resolutions[] = {   { "QQVGA", 160,  120  },   { "QCIF",  176,  144  },   { "CGA",   320,  200  },   { "QVGA",  320,  240  },   { "CIF",   352,  288  },   { "VGA",   640,  480  },   { "SVGA",  800,  600  },   { "XGA",   1024, 768  },   { "HD",    1280, 720  },   { "SXGA",  1280, 1024 },   { "UXGA",  1600, 1200 },   { "FHD",   1920, 1280 },};

     

    So for example:

     

    ExecStart=/usr/bin/mjpg-streamer -i "input_uvc.so -r SXGA -d /dev/video%i" -o "output_http.so -p 808%i"

     

    Note that using 1600x1200 will drop your framerate to 5fps, as the controller is underpowered to offer mjpg streaming at that resolution, and the USB bandwith is to low for a higher framerate.

    As to the UVC comment, UVC stands for Universal Video Class, e.g. a standard protocol to connect (web)camera's via USB. Most camera's (even the high-end ones) tend to speak UVC.

     

     

    - Why not use some lightweight embedded Linux distribution (Alpine?)

    Because when we started (+- 3 years ago) Alpine wasn't really a thing yet. Switching distros is dangerous & expensive.

    Not only that, it really makes little sense to use Alpine when you have a heavy python stack on top. Our debian is not that bloated, it is all the package dependencies we have that require a lot of space. Also, we had 4gb storage at the start of development, a pretty beefy linux system. Why not use a distro that's slim, yet featureful.

    Granted, Alpine is pretty sweet, but as nallath mentions, not a thing back then. But we did concider similar things, such as buildroot/openembedded to build our own minimal basis. But why? We are not making a device with only a few megs of storage. We have plenty and our software requirements requires so much more, it does not matter.

    As to mtd, we do not use mtd :)we use f2fs (Flash Friendly file system) ontop of an eMMC chip. The only thing I want to see improved, is the seperation (read only overlay) for the OS with a RW overlay for user generated data (config files etc).

     

     

    systemd

    SystemD does perfectly what we need it to do. Especially if we ever want to open up the platform.

    Not only that, systemd is pretty much very awesome. Note, I say this as someone who ran gentoo with -systemd on several systems! But I took the plunge when switching to debian (from ubuntu) on my dev machine to have an environment very closing the printers, and learned to appreciate it. Systemd (even journald) is very very cool. And no, it is not that bloated!

    Also, you know whats really cool? we can do systemd-nspawn on our rootfs and run printers that are not real!

     

     

    - Where is a github repository for Ultimaker 3?

    It's not out yet. Most of the code is in python anyway and easy to view on the machine.

     

    Almost all of _our_ code is python. The other code that we modified is open source so released. The only thing missing is the display code, and I hope it that and our other repository to be opened up after the 6 month deadline.

    Edited by Guest
  • Link to post
    Share on other sites
    Posted · Interesting choices

    As lead engineer on the firmware, and the "decision maker". I will just say:

    * Debian is proven stable.

    * Debian is easy to minimize, our compressed filesystem is 40mb, Python3 is actually a large chunk of that.

    * Debian is easy to play with. With our apt-get setup, you can install extra packages in minutes. Great for tinkering. Want to reset? Update the firmware and it will clean everything up. I have a printer that has a full gcc installation.

    * After working for years with sysv init and even smaller init systems. I say "systemd is the best thing that EVER happened to me". It's consistent, fast, configurable and extremely important, easy to diagnose problems.

    * The logging system is the only constant writer right now. And that was a choice (it actually defaulted to memory only logging, we had to change configuration to make this work proper) will last at least 5 years according to calculations. And we will most likely turn of "on disk" logging at some point when the firmware goes into full maintenance mode, to reduce wear and the bugs are no longer present.

    * We have 4GB of flash on the system. We don't need to stick it in 14MB (that's the space I had at my previous job) welcome to 2015.

    We haven't opened up all repos. But if you want a certain piece of code, you can ask (which is annoyingly valid with GPL) the python code is all readable on the printer itself. Marlin I will open up soon. The kernel we currently run isn't in an online repo, but I can also provide a copy. We try to mainline our patched on the kernel as much as possible, and we are in the process of switching to a better version, which actually is on github.

    • Like 1
    Link to post
    Share on other sites
    Posted · Interesting choices

    @slicerglitch

    I hope you are happy with the answers. Looks to me the choices that were made were pretty good and well thought through. You may want to read your initial post again and apologize for the tone.

  • Link to post
    Share on other sites
    Posted (edited) · Interesting choices

    The kernel we currently run isn't in an online repo, but I can also provide a copy. We try to mainline our patched on the kernel as much as possible, and we are in the process of switching to a better version, which actually is on github.

    Even the kernel is on github:

    https://github.com/Ultimaker/linux/tree/opinicus_v4.2.0-rc7

    with our config here: https://github.com/Ultimaker/linux/blob/archive/opinicus_v4.2.0-rc7_v2/arch/arm/configs/opinicus_defconfig

    It includes our patches (which where in WIP state at the time, they are on their way to upstream for ages)

    Our bootloader is also available in case you are wondering

    https://github.com/Ultimaker/u-boot/tree/archive/sunxi-ultimaker

    Afaik we are in full compliance with the GPL to these bits of code.

    Edited by Guest
  • Link to post
    Share on other sites
    Posted (edited) · Interesting choices

    You may want to read your initial post again and apologize for the tone.

    I don't feel there is much hate/rage/disrespect in his post:

    New user here. Questions:

    - Why does a $3500 device feature a cheap UVC camera with resolution so low you can barely read the Ultimaker logo?

    - Why not use some lightweight embedded Linux distribution (Alpine?) instead of bloated Debian with systemd that eats all free space and stresses mtd with constant writes.

    - Where is a github repository for Ultimaker 3?

    You shouldn't feel offended as his questions were pretty relevant and asked correctly. You guys made very thorough answers and I'm sure the community is grateful for that.

    We are supposedly all adults here and I think we can handle some spiced up discussion.

    Edited by Guest
    • Like 2
    Link to post
    Share on other sites
    Posted · Interesting choices
    On 4/12/2017 at 7:11 PM, Olliver said:

    Feel free to change the camera to a higher resolution, edit the file ' mjpg-streamer\@.service' on the printer

     

    Where is this file located on the Ultimaker 3?

  • Link to post
    Share on other sites
    Posted · Interesting choices
    4 hours ago, Yates said:

    Where is this file located on the Ultimaker 3?

     

    @Yates  /etc/systemd/system/mjpg-streamer@.service

  • Link to post
    Share on other sites
    Posted (edited) · Interesting choices

    @tinkergnome Hm, I can't seem to find it.

     

    image.thumb.png.14b5a7dc99d64caa8895588b3b94e6b7.png

     

    Edited by Yates
  • Link to post
    Share on other sites
    Posted · Interesting choices

    There's one in  /lib/systemd/system

    i'm not sure, but i guess one can copy it to /etc/systemd/system and modify it. But you do it on your own risk. I've definitely no clue...

     

    More info:

    https://unix.stackexchange.com/questions/206315/whats-the-difference-between-usr-lib-systemd-system-and-etc-systemd-system

    • Thanks 1
    Link to post
    Share on other sites
    Posted · Interesting choices

    @tinkergnome thank you. Copying and modifying the file worked perfectly!

  • Link to post
    Share on other sites

    Create an account or sign in to comment

    You need to be a member in order to leave a comment

    Create an account

    Sign up for a new account in our community. It's easy!

    Register a new account

    Sign in

    Already have an account? Sign in here.

    Sign In Now
    ×
    ×
    • Create New...