OSD Battery Monitoring for Helder's AIO Boards

Various user-contributed guides for hardware-related things
Post Reply
User avatar
HoolyHoo
Posts: 720
Joined: Sat Jul 09, 2016 9:34 pm
Has thanked: 200 times
Been thanked: 716 times

Re: OSD Battery Monitoring for Helder's AIO Boards

Post by HoolyHoo » Sun Aug 20, 2017 12:53 pm

144TECH wrote:
Sun Aug 20, 2017 12:27 pm
@ HoolyHoo,

I did install everything manually, that worked & everything got installed.
However, i guess i made a little mistake at the last rule wich has to be applied in rc.local , i could have entered that line incorrect.
But, i can do this one to get it right ( sudo sed -i '/\"exit 0\"/!s/exit 0/\/home\/pi\/gbzbatterymonitor\/HHMonitorStart.sh \&\nexit 0/g' /etc/rc.local ) so in this way it can't be wrong.
Now the only questions that last are, if that rule is typed or placed wrong, can this result in the battery icon appearing right before emulationstation runs, and dissapear when it enters retropie ?, because i see the icon coming up for 1 sec and then it dissapears.
And last question is, can it be turned off and on (offcourse when all is installed correct) by pressing select for a few seconds ?

And @Helder, if you read this, i have few aio's from you, including the Red colored aio 2.2(32u4), but for some reason i get trouble programming it into HoolyHoo's Hex, i get several errors in avrdudes for some reason it can't set the fuses, but when i reprogram it back to your Hex files, all goes perfect and no errors, only that Hex from HoolyHoo, and @ the white aio's there's no trouble flashing it into these Hex files.. (all connections are properly)

Thanks in advance, 144Tech
Type at the command line:

Code: Select all

cat /etc/rc.local
And show me the output.

User avatar
144TECH
Posts: 325
Joined: Fri Jan 06, 2017 7:30 am
Location: Amsterdam
Has thanked: 256 times
Been thanked: 71 times

Re: OSD Battery Monitoring for Helder's AIO Boards

Post by 144TECH » Sun Aug 20, 2017 1:25 pm

HoolyHoo wrote:
Sun Aug 20, 2017 12:53 pm
144TECH wrote:
Sun Aug 20, 2017 12:27 pm
Type at the command line:

Code: Select all

cat /etc/rc.local
And show me the output.
Okay, will post it here later, today's my birthday so not so much time, but i really like to know what causes the battery icon to lit up one time and dissapear, could it be in that last line ? because i swear i did make no mistakes installing, except that last line.
But when i sudo that one, like my post above it should be fine, haven't tested that yet.
I'll let you know.
Thank you very much :mrgreen:
* Very Rare * GBZ 640x480 v3 Stock Looks 6000MAH
http://www.sudomod.com/forum/viewtopic.php?f=43&t=4863

User avatar
HoolyHoo
Posts: 720
Joined: Sat Jul 09, 2016 9:34 pm
Has thanked: 200 times
Been thanked: 716 times

Re: OSD Battery Monitoring for Helder's AIO Boards

Post by HoolyHoo » Sun Aug 20, 2017 1:34 pm

144TECH wrote:
Sun Aug 20, 2017 1:25 pm
HoolyHoo wrote:
Sun Aug 20, 2017 12:53 pm
144TECH wrote:
Sun Aug 20, 2017 12:27 pm
Type at the command line:

Code: Select all

cat /etc/rc.local
And show me the output.
Okay, will post it here later, today's my birthday so not so much time, but i really like to know what causes the battery icon to lit up one time and dissapear, could it be in that last line ? because i swear i did make no mistakes installing, except that last line.
But when i sudo that one, like my post above it should be fine, haven't tested that yet.
I'll let you know.
Thank you very much :mrgreen:
Happy birthday!
My guess is that you may have more than version of the script running at startup so I need to see the contents of that file to eliminate that possibility.

User avatar
144TECH
Posts: 325
Joined: Fri Jan 06, 2017 7:30 am
Location: Amsterdam
Has thanked: 256 times
Been thanked: 71 times

Re: OSD Battery Monitoring for Helder's AIO Boards

Post by 144TECH » Sun Aug 20, 2017 3:59 pm

HoolyHoo wrote:
Sun Aug 20, 2017 1:34 pm
144TECH wrote:
Sun Aug 20, 2017 1:25 pm
HoolyHoo wrote:
Sun Aug 20, 2017 12:53 pm


Type at the command line:

Code: Select all

cat /etc/rc.local
And show me the output.

Code: Select all

#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.

# Print the IP address
_IP=$(hostname -I) || true
if [ "$_IP" ]; then
  printf "My IP address is %s\n" "$_IP"
fi

/home/pi/gbzbatterymonitor/HHMonitorStart.sh &exit 0
* Very Rare * GBZ 640x480 v3 Stock Looks 6000MAH
http://www.sudomod.com/forum/viewtopic.php?f=43&t=4863

User avatar
HoolyHoo
Posts: 720
Joined: Sat Jul 09, 2016 9:34 pm
Has thanked: 200 times
Been thanked: 716 times

Re: OSD Battery Monitoring for Helder's AIO Boards

Post by HoolyHoo » Sun Aug 20, 2017 4:50 pm

144TECH wrote:
Sun Aug 20, 2017 3:59 pm
HoolyHoo wrote:
Sun Aug 20, 2017 1:34 pm
144TECH wrote:
Sun Aug 20, 2017 1:25 pm

Code: Select all

#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.

# Print the IP address
_IP=$(hostname -I) || true
if [ "$_IP" ]; then
  printf "My IP address is %s\n" "$_IP"
fi

/home/pi/gbzbatterymonitor/HHMonitorStart.sh &exit 0
The last line should read exit 0, it seems like it was placed adjacent to the script launch command. Try editing it to where it's on the next line and see if it works.

User avatar
Helder
Trailblazer
Trailblazer
Posts: 2740
Joined: Thu May 05, 2016 8:33 am
Location: Fall River, MA
Has thanked: 1399 times
Been thanked: 3066 times

Re: OSD Battery Monitoring for Helder's AIO Boards

Post by Helder » Sun Aug 20, 2017 5:02 pm

Write at a slower speed, it should be lightning fast with HollyHoo's hex as it's alot smaller
My Sale Threads:

Retro PSU, 3.5A output!


Chat with me and other members


Don't contact me about obtaining my board files (as you will not get them). Don't contact me about any of my boards if they are sold out, they will be restocked as soon as I can get them.


Don't support thieves like ckliang who copied my AIO to resell and is now cloning the mintyPi, support the original creators and not the thieves!

User avatar
144TECH
Posts: 325
Joined: Fri Jan 06, 2017 7:30 am
Location: Amsterdam
Has thanked: 256 times
Been thanked: 71 times

Re: OSD Battery Monitoring for Helder's AIO Boards

Post by 144TECH » Sun Aug 20, 2017 5:22 pm

HoolyHoo wrote:
Sun Aug 20, 2017 4:50 pm
144TECH wrote:
Sun Aug 20, 2017 3:59 pm
HoolyHoo wrote:
Sun Aug 20, 2017 1:34 pm
The last line should read exit 0, it seems like it was placed adjacent to the script launch command. Try editing it to where it's on the next line and see if it works.
Okay, done that (i actually did this before too on several ways)
But what i get is that when the retropie picture starts while loading and right before it goes over into emulationstation i see the battery icon for 1 or 2 seconds, and after that it dissapears.. no matter what i do, it comes, and goes right before it enters emu station.
I also tried another aio and another pi, but again i cant do wget, it keeps saying certificate not trusted blablabla. and my certificates are already updated to recent ones so for that reason i did it manually, but i can't get it to work.. the icon comes and goes.
IDK what the hell is going on, because i preferred to do it with wget offcourse...
@Helder, at what speed should i write the hex, any advice? since this stuff is not mentioned in the tutorial, but basically says follow helder's steps for programming the hex.. lol
As for now, i'm really freaking out here .. any help is welcome..

Thanks guys
* Very Rare * GBZ 640x480 v3 Stock Looks 6000MAH
http://www.sudomod.com/forum/viewtopic.php?f=43&t=4863

User avatar
HoolyHoo
Posts: 720
Joined: Sat Jul 09, 2016 9:34 pm
Has thanked: 200 times
Been thanked: 716 times

Re: OSD Battery Monitoring for Helder's AIO Boards

Post by HoolyHoo » Sun Aug 20, 2017 5:32 pm

144TECH wrote:
Sun Aug 20, 2017 5:22 pm
HoolyHoo wrote:
Sun Aug 20, 2017 4:50 pm
144TECH wrote:
Sun Aug 20, 2017 3:59 pm


The last line should read exit 0, it seems like it was placed adjacent to the script launch command. Try editing it to where it's on the next line and see if it works.
Okay, done that (i actually did this before too on several ways)
But what i get is that when the retropie picture starts while loading and right before it goes over into emulationstation i see the battery icon for 1 or 2 seconds, and after that it dissapears.. no matter what i do, it comes, and goes right before it enters emu station.
I also tried another aio and another pi, but again i cant do wget, it keeps saying certificate not trusted blablabla. and my certificates are already updated to recent ones so for that reason i did it manually, but i can't get it to work.. the icon comes and goes.
IDK what the hell is going on, because i preferred to do it with wget offcourse...
@Helder, at what speed should i write the hex, any advice? since this stuff is not mentioned in the tutorial, but basically says follow helder's steps for programming the hex.. lol
As for now, i'm really freaking out here .. any help is welcome..

Thanks guys
I hear you but no need to freak out, haha. Are you running this script with a successful flash of the hex on helders board? I'm asking because that was part #2 of your problem. It won't work without it.

If that's not the issue, then check to see if script is running after ES starts. You can check through the command line and type:

Code: Select all

ps aux | grep python
Then we can go from there.

User avatar
144TECH
Posts: 325
Joined: Fri Jan 06, 2017 7:30 am
Location: Amsterdam
Has thanked: 256 times
Been thanked: 71 times

Re: OSD Battery Monitoring for Helder's AIO Boards

Post by 144TECH » Sun Aug 20, 2017 5:41 pm

HoolyHoo wrote:
Sun Aug 20, 2017 5:32 pm
144TECH wrote:
Sun Aug 20, 2017 5:22 pm
HoolyHoo wrote:
Sun Aug 20, 2017 4:50 pm
I hear you but no need to freak out, haha. Are you running this script with a successful flash of the hex on helders board? I'm asking because that was part #2 of your problem. It won't work without it.

If that's not the issue, then check to see if script is running after ES starts. You can check through the command line and type:

Code: Select all

ps aux | grep python
Then we can go from there.
The flashing went correct (on this aio board, no errors in avrdudes)

Then we got :

Code: Select all

root       645  0.2  2.6   9996  6520 ?        S    17:58   0:03 python /home/pi                                                                             /gbzbatterymonitor/HHBatteryMonitor.py
root       646  2.0  4.6  32796 11692 ?        Sl   17:58   0:27 python /home/pi                                                                             /gbzbatterymonitor/HHShutdown.py
pi         905  0.0  0.8   4272  2036 pts/0    S+   18:21   0:00 grep --color=au                                                                             to python
* Very Rare * GBZ 640x480 v3 Stock Looks 6000MAH
http://www.sudomod.com/forum/viewtopic.php?f=43&t=4863

User avatar
144TECH
Posts: 325
Joined: Fri Jan 06, 2017 7:30 am
Location: Amsterdam
Has thanked: 256 times
Been thanked: 71 times

Re: OSD Battery Monitoring for Helder's AIO Boards

Post by 144TECH » Sun Aug 20, 2017 6:01 pm

LoL, glad we made further conversation in pm, this thread would be hijacked otherwise.
Maybe ill open another topic if i cant solve it

Thank you HoolyHoo
* Very Rare * GBZ 640x480 v3 Stock Looks 6000MAH
http://www.sudomod.com/forum/viewtopic.php?f=43&t=4863

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest