PitDroid: An Android app for your HeaterMeter


 
EDIT: I typed out the URL in the command line (instead of trying to find the file on the SD card) and it seemed to work on the second try. I would still like to know how to locate the file on the SD card though....

Crash course linux.

On linux the file system starts at / all directories, files, drives, removable media are somewhere under /
The following commands can be used:
- show the path of the current directory
pwd

- show list of directories and files in current directory, lines starting with a d are directories
ls -l

- show list of directories and files in /, lines starting with a d are directories
ls -l /

- change directory
cd /

- find all files and directories under / starting with luci
find / -name "luci*"

If you want to learn more have a look at http://www.tuxfiles.org/linuxhelp/cli.html
or http://linuxcommand.org/learning_the_shell.php

Please bear in mind the the HM is running a very small and basic version, this means that not commands and options are available. See http://www.busybox.net/about.html .
 
/usr/lib/lua/luci/dispatcher.lua:448: Failed to execute call dispatcher target for entry '/lm/light'.
The called action terminated with an exception:
/usr/lib/lua/luci/controller/linkmeter/lm.lua:13: module 'luci.json' not found:
no field package.preload['luci.json']
no file './luci/json.lua'
Oops forgot you also need to install this as well
Code:
opkg install http://home.capnbry.net:22674/rpi/packages/luci-lib-json_0.11.1-1_brcm2708.ipk

If you're using PuTTY to SSH in, you can just copy paste it by copying it here then right clicking in the terminal window.
 
Thank you Uipko for the crash coarse on linux, that was very helpful. Having worked with computers from DOS days I know all those commands by heart, it was very frustrating not knowing the commands in linux. I guess that's another good thing about this project, it is forcing me to learn...

Bryan,
Thanks for the follow up. I have downloaded and installed PuTTY (never used that before either). It connected easy enough but it took me a few minutes to figure out the user would be "root" with the password I set in the HeaterMeter to log in. Up until now I had been plugging the rPi into a monitor to work on it, it is so much easier to work from my PC via PuTTY.
I was able to paste in the URL above (via PuTTY) and do the upgrade, now the "light" page loads fine. I loaded it on my phone and all is good! The text does start out a little large but my phone can shrink it down to fit the screen easy enough, so that works out fine for me....
Thanks again for your help and all your work on this project....
 
Thank you Uipko for the crash coarse on linux, that was very helpful. Having worked with computers from DOS days I know all those commands by heart, it was very frustrating not knowing the commands in linux. I guess that's another good thing about this project, it is forcing me to learn...

OK if you're "used" to work on command line I can throw in some other commands ;)
In general the options -h or --help will give some info how to use the command
command line completion => tab (2 tabs for all options)
stop a command => q or ctrl + c
directories => . is current directory .. is directory below so cd ../../ will go back two directories

list directories,files, hidden files (starting with .) ls -al
read a file => less
copy => cp
search in file = grep "search term" filename

Be careful with this!
delete file => rm
delete directry => rm -r (or rmdir)

Advanced stuff
edit file => vim (first read basics about this editor, editor nano is easier but not installed by default)
combine commands => | (example: ls -l /bin | less)
search in certain files => find -name "*.txt" -print0| xargs -0 grep "search"

configuration is done in files in /etc

the permissions of a file work as follows:
rwxr-xr-x
r=read
w=write
x=execute
first rwx is for user
second rwx is for group
third rwx is for others

change permissions => chmod
 
I just fired up my smoker for the first time since I installed that beta release and I have problems...
The probe coeddicients are all messed up but when I choose a preset it doesnt put all the parameters in ABC, in fact it puts different data in different probes when I choose the same preset? It seems as though I cant save anything either, if I change the probe names it does not save. Bottom line the unit is AFU right now and wont work, but its time to cook!HELP!!!
HELP!!!

EDIT:
I ended up making a new build on another SD card, then had to re-flash the AVR before it would save settings again. Got it working for now, when I need it, I will have to revisit the update with the "light" web page at another time....
Sorry for taking this thread off topic a bit.

BTW, I tried IE, Chrome and Firefox and had the above problem with all. After I rebuilt the rPi it was reporting a checksum error in the config/info section before I re-flashed the AVR
 
Last edited:
I can't reproduce that under IE10 or Chrome so I'm not sure what is happening. If you want to discuss it further, I suggest making a new thread with more details, browser, steps to reproduce, etc. The PitDroid thread isn't for general help or anything not related to PitDroid actually.
 
I'm home sick today so I wrapped up some misc fixes into a new release. Thanks to Uipko now it won't crash if you view the graph before the server is up. Also, I added a new option so you can choose to not have the alarm go off if the server can't be contacted. This is for people with flaky wi-fi connections, so they won't get woken up at night for no reason. Of course, if your wi-fi goes down for real you might ruin some meat, so use at your own risk. There's also an option to put in your admin password, but I didn't get around to hooking up support for setting anything yet, so don't get too excited.
 
I was home sick again yesterday, so I did some more work and got admin support in. Now you can change the pit set temp. Also, I added an explicit exit button. If you've got alarms set it'll prompt you to make sure you really want to exit. It will hopefully eliminate the rare case where the app would get terminated by Android to free some memory and happily shut down the alarm timer too, so it would stop checking.
 
I want to use PitDroid on my phone when I am away from the LAN and on the Internet. For that I need to forward incoming TCP ports(s) from my router to the Heatermeter. What network ports does PitDroid use to query the Heatermeter?

-- Mache
 
It connects to the standard web services port, 80. The UI will take a port number though, so if you set up your firewall to forward another port like 8080 to the HeaterMeter's port 80 it works too.
 
I am having problems getting the dash and graph data to load on PitDroid. I am using the app on my Android ICS Thunderbolt logged into the local LAN. My HM4 is also logged into the local LAN and always gets the same IP address from DHCP. The web page is fully accessible to my laptop and I can even log into the rPI with SSH. The settings are all configured properly. Any suggestions on how to get PitDroid to load the data from the rPi and display it on my phone?

-- Mache
 
I checked the version and its 1.2 not 1.3. Play Store does not believe it needs to be upgraded. I tried to delete it and the deletion process just hangs. I will now try to root the phone so I can use the nuclear option t0 get rid of it.

-- Mache
 
I managed to delete it and reinstall. All is working properly now. Must have had a corrupted initial install.

-- Mache
 
I'm having some issues with PitDroid. At the moment, it seems to be hung and not updating. It has data from ~3 hours ago. Maybe it's due to having too much data? I'm at ~24 hours of running time on the HM. (trying different fan settings, etc.)

I've tried force stopping it, and it takes forever (30+ mins) to get data again. Sometimes current, sometimes not.

Also, I've had more than a few force closes. I sent the crashlogs off, not sure how useful that is.

I have 1.2 installed, and that's the most recent version I can find on the store.

I'm happy to debug, etc. I get good data going via the browser, so it's not a connectivity issue.

Galaxy s4m fwiw.

job
 
Job,

I'm having the same issue. I have found opening and closing a few times quickly (not the exit button)and it will start working for a little while.

Very cool app. Feature request- Date time of the last data packet on the the main screen.
 
This is cool,

However I'm getting authentication failed even though I've triple checked my password?

Update: it works fine with my Android tablet, but not with my Android phone :o
 
Last edited:
I'm having the same issues running v1.2 on 4.3 jellybean on Nexus 4. The app runs ok but it's like the network connection is intermittent. I usually get dashes and if I try to run the app enough times eventually it will connect and run for a while, then stop updating.
 

 

Back
Top