lilzz
Posts: 411
Joined: Sat Nov 30, 2013 5:27 pm

what's the simplest OS a Pi can have to make Http call?

Wed Apr 13, 2016 8:31 pm

I need the simplest OS on a Pi that can allow an user to make a HTTP call.
Raspbian is full linux image that take up too much space. I can't have that.

Is FreeRTOS the simplest OS I can have to make a http call base on user input?

User avatar
davidcoton
Posts: 4212
Joined: Mon Sep 01, 2014 2:37 pm
Location: Cambridge, UK

Re: what's the simplest OS a Pi can have to make Http call?

Wed Apr 13, 2016 8:44 pm

lilzz wrote: Raspbian is full linux image that take up too much space. I can't have that.
Why not? SD card space is cheap.
Signature retired

lilzz
Posts: 411
Joined: Sat Nov 30, 2013 5:27 pm

Re: what's the simplest OS a Pi can have to make Http call?

Wed Apr 13, 2016 9:21 pm

davidcoton wrote:
lilzz wrote: Raspbian is full linux image that take up too much space. I can't have that.
Why not? SD card space is cheap.

Let's just say for argument sake, I want to save that SD card money.
Just have onboard flash memory.

I need tiny footprint on OS. FreeRTOS is the smallest foot print I could find.

Heater
Posts: 13704
Joined: Tue Jul 17, 2012 3:02 pm

Re: what's the simplest OS a Pi can have to make Http call?

Wed Apr 13, 2016 9:33 pm

lilzz,

There is no onboard FLASH memory on the Pi. You need the SD card.

Use Raspbian Lite. It will fit on the smallest SD cards you can buy now a days.

Install wget and/or curl to make the HTTP request.
Memory in C++ is a leaky abstraction .

stderr
Posts: 2178
Joined: Sat Dec 01, 2012 11:29 pm

Re: what's the simplest OS a Pi can have to make Http call?

Wed Apr 13, 2016 10:08 pm

lilzz wrote:I need tiny footprint on OS. FreeRTOS is the smallest foot print I could find.
Did you look at tiny core? It is straight up real linux with an X GUI if you want, but you can chroot into raspbian and do a lot of command line stuff with apt-get available in the chroot. So you can boot to tiny core and do whatever and then if you need your full command line stuff, you can chroot to that on a flash drive or something and then just go back to the bare tiny core when you need it. I haven't looked carefully enough, but I think that the stock download includes code for both the pi and the pi2 meaning that if it were optimized, it would be even smaller. See, http://tinycorelinux.net/7.x/armv6/releases/RPi/ .

I think that FreeRTOS is more intended for when you are in situations where you might normally expect microcontrollers to be used. According to the current wikipedia, "There are none of the more advanced features typically found in operating systems like Linux or Microsoft Windows, such as device drivers, advanced memory management, user accounts, and networking. The emphasis is on compactness and speed of execution. FreeRTOS can be thought of as a 'thread library' rather than an 'operating system', although command line interface and POSIX-like I/O abstraction add-ons are available.", https://en.wikipedia.org/wiki/FreeRTOS .

User avatar
solar3000
Posts: 1051
Joined: Sat May 18, 2013 12:14 am

Re: what's the simplest OS a Pi can have to make Http call?

Thu Apr 14, 2016 1:55 am

I just got a 32GB micro SD card for $9USD.

A 16GB card is only $5USD
http://www.microcenter.com/product/3046 ... emory_Card
Antikythera

mutley
Posts: 61
Joined: Sat Jan 02, 2016 8:06 pm

Re: what's the simplest OS a Pi can have to make Http call?

Thu Apr 14, 2016 2:04 pm

Ignoring other factors and just answering the question you asked.

uIP and IwIP are the smallest OS's that I know of that will give you a TCPIP stack. TCPIP is the minimum OS requirements you'll need to make a HTTP call. But if either will run / compile for a PI is a different story.

Personally, I'd start with raspbian lite on the PI and simply strip off everything I didn't want. DietPi may be an option if you are not familiar / happy with removing stuff from a distribution.

User avatar
DougieLawson
Posts: 36340
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
Contact: Website Twitter

Re: what's the simplest OS a Pi can have to make Http call?

Fri Apr 15, 2016 1:01 pm

lilzz wrote:I need the simplest OS on a Pi that can allow an user to make a HTTP call.
Raspbian is full linux image that take up too much space. I can't have that.

Is FreeRTOS the simplest OS I can have to make a http call base on user input?
I'll echo what Mr. Mutley has said.

Raspbian Lite is a 1.3GB OS that is going to be easier for you to use than FreeRTOS. Raspbian Lite doesn't have any helper tools to add missing pieces, you do that with apt-get and you have to work out what's needed.

DietPi may be a better choice (again it is Raspbian with lots of stuff removed) but it includes a menu system to install things you need on top of the basic stripped down Linux system.
Note: Having anything humorous in your signature is completely banned on this forum. Wear a tin-foil hat and you'll get a ban.

Any DMs sent on Twitter will be answered next month.

This is a doctor free zone.

hippy
Posts: 6108
Joined: Fri Sep 09, 2011 10:34 pm
Location: UK

Re: what's the simplest OS a Pi can have to make Http call?

Fri Apr 15, 2016 2:08 pm

It might be worth taking a look at Ultibo -

viewtopic.php?f=56&t=134956

Pithagoros
Posts: 580
Joined: Wed Nov 12, 2014 8:16 pm

Re: what's the simplest OS a Pi can have to make Http call?

Fri Apr 15, 2016 2:15 pm

Heater wrote:
There is no onboard FLASH memory on the Pi. You need the SD card.
I've got one with 4GB of eMMC flash...... ;)

Heater
Posts: 13704
Joined: Tue Jul 17, 2012 3:02 pm

Re: what's the simplest OS a Pi can have to make Http call?

Fri Apr 15, 2016 4:37 pm

Ah, OK, caught us out there. Sounds like you have a compute module. Well, as far as I can tell the 4GB of FLASH on the CM is is equivalent to an SD card. And it's HUGE!

I was running Linux on a 1GB disk back in the day and I thought that was gigantically spacious.

So what about putting raspbian lite on there?

If that is too much I would go for OpenWRT, which is a Linux that fits on routers with very limited RAM and FLASH space. And is available for the Pi.
Memory in C++ is a leaky abstraction .

FM81
Posts: 518
Joined: Wed Apr 17, 2013 4:33 pm

Re: what's the simplest OS a Pi can have to make Http call?

Mon Apr 18, 2016 5:37 am

Or try a busybox-system, HTTPD is included:

Code: Select all

BusyBox v1.20.2 (Debian 1:1.20.0-7) built-in shell (ash)
Enter 'help' for a list of built-in commands.

~ $ ps -ef | grep httpd
   77 pi       /usr/sbin/httpd -u 1000:100 -h /var/tmp/www/
Around 10 Megabyte and you're done.
Size depends on, what other programs you want to include ...

Greetings, FM_81
A: What does the command 'cat /dev/urandom', can you tell me please?
B: Yeah, that's very simple: It feeds your cat with radioactive material!

Return to “General discussion”