Toon as a domotica controller?

Everything about rooting Toons 1 and 2.

Moderators: marcelr, TheHogNL, Toonz

al_n
Member
Member
Posts: 52
Joined: Tue Jun 02, 2015 7:51 pm

Re: Toon as a domotica controller?

Post by al_n »

can someone please explain this:
Enter the u-boot menu by briefly shorting the proper control pins on
the NAND chip
Which chip is that? Can you please point it on a photo.
iMars
Starting Member
Starting Member
Posts: 17
Joined: Tue Nov 17, 2015 10:47 pm

Re: Toon as a domotica controller?

Post by iMars »

marcelr wrote:
Only reading values? Or is it possible to change the temperature and/or program (weg/slapen/thuis/comfort)?
The weekly program is stored in an xml-file:

/HCBv2/config/config_happ_thermstat.xml

and looks like this (small excerpt, it's quite a file):

Code: Select all

   
....

   <device>
     <schedule>
      <entry type="weekly_recurring">
       <type>weekly_recurring</type>
       <startMin>0</startMin>
       <startHour>8</startHour>
       <startDayOfWeek>0</startDayOfWeek>
       <targetState>1</targetState>
       <endMin>0</endMin>
       <endHour>17</endHour>
       <endDayOfWeek>0</endDayOfWeek></entry>
      <entry type="weekly_recurring">
       <type>weekly_recurring</type>
       <startMin>0</startMin>
       <startHour>17</startHour>
       <startDayOfWeek>0</startDayOfWeek>
       <targetState>0</targetState>
       <endMin>30</endMin>
       <endHour>21</endHour>
       <endDayOfWeek>0</endDayOfWeek></entry>
      <entry type="weekly_recurring">
       <type>weekly_recurring</type>
       <startMin>30</startMin>
       <startHour>21</startHour>
       <startDayOfWeek>0</startDayOfWeek>
       <targetState>2</targetState>
       <endMin>30</endMin>
       <endHour>6</endHour>
       <endDayOfWeek>1</endDayOfWeek></entry>
      <entry type="weekly_recurring">
       <type>weekly_recurring</type>
       <startMin>30</startMin>
       <startHour>6</startHour>
       <startDayOfWeek>1</startDayOfWeek>
       <targetState>1</targetState>
       <endMin>0</endMin>

...
  
By rewriting entries and restarting the thermostat application (happ_thermstat, not sure if it restarts by itself if you change the program, most applications on toon do autorestart) you should be able to remotely override the program settings. targetState in the example is one of the four preset temperatures, and these are set elsewhere in the same file.

Haven't tested this.
As long as I can set and read the temperature in Domoticz I'm happy :)
Or choose between the 4 default program's is enough ;)
I haven't open my Toon yet, as I'm waiting till everything is confirmed and ready.
What needs confirmation?
As I read the post afterwards, I had the feeling it wasn't 100% ready yet ;)
I've ordered this serial adapter for some ESP's, I'm assuming this is good enough for Toon (as long as the jumper is on 3.3V mode):
http://nl.aliexpress.com/item/Free-ship ... wVersion=2
FTDI chipset (or is it?). Should work. Good deal BTW.

And remember the 11th commandment: Thou shalt make back-ups!
(of your toon's flash memory, that is. dd is your friend).

grtz,

marcelr
Is it possible to switch/go back to the original Toon software? Back to default settings (fabrieksinstellingen)?

Did somebody alread integrate this into Domoticz? If so, are there photos or videos of that? I'm very curious how that looks ;)
marcelr
Global Moderator
Global Moderator
Posts: 1153
Joined: Thu May 10, 2012 10:58 pm
Location: Ehv

Re: Toon as a domotica controller?

Post by marcelr »

It's the samsung chip.
(there's only one of that brand on the pcb).

grtz,

marcelr
al_n
Member
Member
Posts: 52
Joined: Tue Jun 02, 2015 7:51 pm

Re: Toon as a domotica controller?

Post by al_n »

Thanks marcelr, I've got my serial port today, I'll give it a go tomorrow.
al_n
Member
Member
Posts: 52
Joined: Tue Jun 02, 2015 7:51 pm

Re: Toon as a domotica controller?

Post by al_n »

one more question, is this really one line:

Code: Select all

setenv addmisc setenv bootargs \$\{bootargs\} mem=\$\{mem\} lpj=999424 init=/bin/sh
?
marcelr
Global Moderator
Global Moderator
Posts: 1153
Joined: Thu May 10, 2012 10:58 pm
Location: Ehv

Re: Toon as a domotica controller?

Post by marcelr »

al_n wrote:one more question, is this really one line:

Code: Select all

setenv addmisc setenv bootargs \$\{bootargs\} mem=\$\{mem\} lpj=999424 init=/bin/sh
?
Yes.
It sets the environment variable addmisc to be bootargs + mem + lpj + init (and their respective values)
Check whether this line is _exactly_ the same as your original addmisc variable (apart from the init addition). If not, adapt accordingly.

grtz,

marcelr
Last edited by marcelr on Wed Dec 09, 2015 11:45 pm, edited 1 time in total.
al_n
Member
Member
Posts: 52
Joined: Tue Jun 02, 2015 7:51 pm

Re: Toon as a domotica controller?

Post by al_n »

ok, good info! I'll pay attention to that.

BTW, if anyone is looking for a cheap ttl serial port then I found this in the netherlands:

http://www.hobbyelectronica.nl/product/ ... converter/

(don't have to wait 3 weeks for a shipment from china)
marcelr
Global Moderator
Global Moderator
Posts: 1153
Joined: Thu May 10, 2012 10:58 pm
Location: Ehv

Re: Toon as a domotica controller?

Post by marcelr »

Is it possible to switch/go back to the original Toon software? Back to default settings (fabrieksinstellingen)?
You still have the original toon software, it's just that besides the back door that eneco uses, now also the front door is open, for you to use. As long as you don't throw away any of the software, or screw up the OpenVPN certificates, you can go back to the standard settings.
Did somebody alread integrate this into Domoticz?
Don't know, AFAIK Ierlandfan is playing around with that. (through the handlers, see his upload some 30-odd posts earlier).

grtz,

marcelr
hvxl
Senior Member
Senior Member
Posts: 1967
Joined: Sat Jun 05, 2010 11:59 am
Contact:

Re: Toon as a domotica controller?

Post by hvxl »

al_n wrote:Which chip is that? Can you please point it on a photo.
I put a small piece of an adhesive label next to it and marked which pins to short to make the job easier.
toon-nand.jpg
toon-nand.jpg (46.92 KiB) Viewed 15848 times
Schelte
al_n
Member
Member
Posts: 52
Joined: Tue Jun 02, 2015 7:51 pm

Re: Toon as a domotica controller?

Post by al_n »

wow, thanks @hvxl

These will be the 8th and 9th pins from top, right?
iMars
Starting Member
Starting Member
Posts: 17
Joined: Tue Nov 17, 2015 10:47 pm

Re: Toon as a domotica controller?

Post by iMars »

al_n wrote:wow, thanks @hvxl

These will be the 8th and 9th pins from top, right?
I see pins 7, 8 & 9...
marcelr
Global Moderator
Global Moderator
Posts: 1153
Joined: Thu May 10, 2012 10:58 pm
Location: Ehv

Re: Toon as a domotica controller?

Post by marcelr »

Yep, pin 1 is a the top left dot on the chip housing.

As long as you don't hit the pins in the middle (power supply), you should be OK.
good luck,

marcelr
al_n
Member
Member
Posts: 52
Joined: Tue Jun 02, 2015 7:51 pm

Re: Toon as a domotica controller?

Post by al_n »

I guess at my age (44) those tiny pins are not ment to be messed with. I had to use a magnifying glass and put a tape on the pins to the left and to the right so I could hit pins 8 and 9 fast enough. This after trying like 30 times and getting twice a kernel panic. I was happy to get the U-Boot prompt eventually.

I do have some remarks about the procedure that was posted here:
in /etc/inittab the original line was
ovpn:235:respawn:/usr/sbin/openvpn --config /etc/openvpn/vpn.conf --verb 0 >/dev/null 2>&1
and not
ovpn:2345:respawn:/usr/sbin/openvpn --config /etc/openvpn/vpn.conf --verb 0 >/dev/null 2>&1

my software version was 2.9.6 and I did have to change /etc/passwd

reboot didn't work, said something about timeout, power cycling did the trick.

I couldn't ssh from toon to my mac got an error:
ssh: connection to root@10.10.10.2:22 exited: no matching algo kex
has something to do with ssh protocol version I guess but it isn't so important as long as I can ssh into toon.

you can just safely use your router as a time server if you have support for time services, I do.

There is no need to symlink hcb_netcon, you can just copy it. for good measure I did chown so it will have the same ownership as the original file, 1129.513 in my case.


Thanks all who made this possible, it now hacking time :)
marcelr
Global Moderator
Global Moderator
Posts: 1153
Joined: Thu May 10, 2012 10:58 pm
Location: Ehv

Re: Toon as a domotica controller?

Post by marcelr »

I guess at my age (44) those tiny pins are not ment to be messed with.
Age has got nothing to do with it :-). They're not supposed to be messed with anyway. But if you have issues in seeing the pins (or if your arms become too short for reading), maybe it's time to see an opthalmologist :-).
in /etc/inittab the original line was
ovpn:235:respawn:/usr/sbin/openvpn --config /etc/openvpn/vpn.conf --verb 0 >/dev/null 2>&1
and not
ovpn:2345:respawn:/usr/sbin/openvpn --config /etc/openvpn/vpn.conf --verb 0 >/dev/null 2>&1
This probably depends on SW version, will check it out. Does not make a real difference, hardly any linux system runs runlevel 4.
I couldn't ssh from toon to my mac got an error:
ssh: connection to root@10.10.10.2:22 exited: no matching algo kex
Is probably a Mac problem, not toon's :-).
There is no need to symlink hcb_netcon, you can just copy it.
That's indeed a matter of taste, I like to keep original software around.

grtz,

marcelr
Last edited by marcelr on Thu Dec 10, 2015 3:20 pm, edited 1 time in total.
al_n
Member
Member
Posts: 52
Joined: Tue Jun 02, 2015 7:51 pm

Re: Toon as a domotica controller?

Post by al_n »

marcelr wrote:They're not supposed to be messed with anyway. But if you have issues in seeing the pins (or your if arms become too short for reading), maybe it's time to see an opthalmologist :-).
My optician did mention that my next pair of glasses will have to be multifocal :lol:
Post Reply

Return to “Toon Rooting”