Topic: Get your Chumby working offline (native)

I was bothered by my C1, because it is a brick without an internet connection.
I couldn't believe that i can't use the build in FM tuner or the internal storage to play sounds and i can't see the actual time without any interaction. If the Chumby starts up and can't get an internet connection it is annoying you to establish a connection.
The common suggested hacks wasn't smart enough for me, because i don't wanted to have an USB-Stick connected all the time and the Chumby shouldn't change his behaviour if he has a connection.

I tried to figure out what is responsible for that cumbrous behaviour.
It's not the controlpanel itself. The problem is in the start_control_panel script in /usr/chumby/scripts/
And you have to change only one byte to get the chumby working in a smart way.

The script forces the controlpanel to ask for an internet connection by parameter:

controlpanel.swf -dbuiltin=1 -Q

With it, the controlpanel asks for a connection and downloads the actual controlpanel from chumby.com and close itself so the script can start the downloaded CP.
Maybe this was a good solution for Chumby classic, because it has no offline functionality, but on C1 it su**s.

The solution is quite easy. You have to prevent the script from adding this parameter, if no network is available, by changing "BUILTIN=1" to "BUILTIN=0" in the following lines:

...
    if [ ! -z "$NETWORK_ERROR" ]; then
        # network is not functioning
        CP=$CP_PATH
        BUILTIN=0
    else
...

Please consider that you can change this script only if you have write access to "/" and you do it by your own risk.

After this patch the C1 will load the controlpanel from "/usr/widgets/" if it couldn't establish a connection. You can connect to a network manually, without restarting the Chumby, under "Settings->Network".
If you start your Chumby offline the CP may not be the actual one, but you can copy the actual CP from "/tmp/" to  "/usr/widgets/" (you need write access to "/" to do that) if you have started your Chumby with a connection to the internet.

Re: Get your Chumby working offline (native)

Andiii wrote:

I
If you start your Chumby offline the CP may not be the actual one, but you can copy the actual CP from "/tmp/" to  "/usr/widgets/" (you need write access to "/" to do that) if you have started your Chumby with a connection to the internet.


great work.

do you think it could be possible to copy all widgets (or applications) to the local  internal sd-card?
perhaps as a script that works if an internet-connection ist active to copy all to a local space and that works with this local data if no internet-connection ist availlable

Re: Get your Chumby working offline (native)

At the moment you can use some patches where you mount the profile.xml and the widgets from storage to your webserver or you use an USB dongle.
But i'm looking forward to controlpanel 2.8.75 which should be able to load the profile.xml from tmp or storage.
http://forum.chumby.com/viewtopic.php?pid=33251#p33251

Re: Get your Chumby working offline (native)

Andiii wrote:

At the moment you can use some patches where you mount the profile.xml and the widgets from storage to your webserver or you use an USB dongle.
But i'm looking forward to controlpanel 2.8.75 which should be able to load the profile.xml from tmp or storage.
http://forum.chumby.com/viewtopic.php?pid=33251#p33251

I wonder how much longer we'll need to wait. The last update on that thread was 6 months ago.