Forum des Objets Communicants et Solutions pour les Libérer...


 
AccueilAccueil  GalerieGalerie  FAQFAQ  RechercherRechercher  S'enregistrerS'enregistrer  Connexion  

Partagez | 
 

 free mother

Aller en bas 
AuteurMessage
carlo64
Bronze Nabz
Bronze Nabz


Localisation : italia
Nbr de messages : 151
Carottes : 1470

MessageSujet: free mother   Mar 27 Mar 2018 - 19:14

Hi,
since I can not connect my mother to the site sen.se and the media does not respond to my emails ..

we will create our own server or at least we will try ..

is very little about this argument, so any information is welcome!

necessary



a linux pc (a raspberry with raspbian is fine)
we assume the name of the ethernet card is eth0

install the dnsmasq package (for dhcp and dns)
apt-get install dnasmasq

we configure /etc/dnsmasq.conf

# global options
domain-needed
bogus-priv
no-resolv
filterwin2k
expand-hosts
domain = mydomain.net
local = /mydomain.net/
listen-address = 127.0.0.1
listen-address = 192.168.0.1

# DHCP range
dhcp-range = eth0,192.168.0.10,192.168.0.50,12h



we assign the ip to the network card (eth0) where we connected Mother
ifconfig eth0 192.168.0.1 netmask 255.255.255.0



add these lines to the /etc/hosts file
192.168.0.1 in.sen.se
192.168.0.1 pool.ntp.org


we modify /etc/ntp.conf to read the time from the pc clock

we add

server 127.127.1.0
fudge 127.127.1.0 stratum 10

and comment on the lines of 'pool'



----
for the server part I used https://github.com/Pithikos/python-websocket-server (thanks Pithikos!)

follow the installation instructions (python setup.py install)

copy the modified server program freemother.py

https://github.com/ccarlo64/freemother


please edit the file and set mac address variable (check it in you router)
compose with "MO" + MACADDRESS without ":"
like this
mac='MO0004A3F90001' ###change here

same in the clienttest.html


run...
python freemother.py


connect Mother and after a few seconds she will smile

To see the effects, in the same pc loaded in firefox the clienttest.html


COOKIE:
the name of 4 cookies (node) are hex digit, plese analyze the log on server and change the file
this are mine

cookieNode=['6FEC200D','AA81082C','206B121A','65EB0E1C']

help me, please test!!!

Carlo
Revenir en haut Aller en bas
carlo64
Bronze Nabz
Bronze Nabz


Localisation : italia
Nbr de messages : 151
Carottes : 1470

MessageSujet: Re: free mother   Jeu 5 Avr 2018 - 22:48

ver 1

Added a sqlite db to store sensor data and created a page to display data

Revenir en haut Aller en bas
carlo64
Bronze Nabz
Bronze Nabz


Localisation : italia
Nbr de messages : 151
Carottes : 1470

MessageSujet: Re: free mother   Ven 13 Avr 2018 - 18:58

added the management of the reset sounds and animations
(tap tap between the eyes when starting M.)

to work you need a web server
installed in the same pc for example

apt-get install webfs
create the / var / www / html folder and copy it into the two folders

00102
is
00103

containing the files

default webfs is activated on localhost: 8000
that should be 192.168.0.1 following my example

the sounds are mono wav files sampled at 16k I do not know the limits of M.
the animations are described in the json text files you have to go a little imagination and do tests

Carlo
Revenir en haut Aller en bas
luismo
Lapin nain
Lapin nain
avatar

Age : 48
Localisation : Geneve
Nabaztag : Karotz
Nbr de messages : 31
Carottes : 906

MessageSujet: Re: free mother   Mar 5 Juin 2018 - 13:14

Thank you very much for your work !
I will try it as soon as possible nabzcheers

edit 16.06.18:
trying to install python-websocket-server-master:
I need to add this command before running 'python setup.py install': sudo apt-get install python-setuptools

edit 17.06.18:
I connected my mother and she smile, but not for long time. After a few minutes I have that: sorry for the poor quality:


And the cookies does not appears like in your example
Revenir en haut Aller en bas
Contenu sponsorisé




MessageSujet: Re: free mother   

Revenir en haut Aller en bas
 
free mother
Revenir en haut 
Page 1 sur 1
 Sujets similaires
-
» Jeux Free (Alien Assault)
» Free Box => installation AIDE
» Free Online Draft [SoM] dispo
» [SW SB FREE] Campagne Acte O : petit Moff deviendra grand
» Free Angel RFID

Permission de ce forum:Vous ne pouvez pas répondre aux sujets dans ce forum
Forum des Objets Communicants et Solutions pour les Libérer... :: III. Nouveaux Objets Communicants (NOC) :: Sense-
Sauter vers: