Page 1 of 2

Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Thursday 27 April 2017 10:06
by BakSeeDaa
Hi there!

As the title says, I'm looking for fellow developers/collaborators for a Google Calendar/Domoticz project named GCal

I've recently developed a project in Python that enables the integration of Google Calendar into Domoticz. Have a look at the wiki at https://github.com/BakSeeDaa/GCal/wiki

While GCal currently is working at my installation I believe that many improvements still can be made. Both in the code itself and in the documentation. I'm not a native English speaker as You probably already realized so all written text needs an overhaul as well.

As a Collaborator You will get an appropriate permission level: Write, Read, or Admin.

(My old project viewtopic.php?f=38&t=8333 has been deprecated since it by its design had potential to create delays in the Domoticz event queue)

EDIT
We need:
  • Coders
  • Testers
  • Native English speakers (to proofread the wiki and maybe adding some structure to it)
  • And last but not least: Demanders

Re: Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Thursday 27 April 2017 11:21
by four2six
what exactly are you looking for?
a pro in coding? a native speaker? a nagging demander? an avid tester?
edit:
all of the above? ;-)

Re: Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Thursday 27 April 2017 11:37
by BakSeeDaa
four2six wrote:what exactly are you looking for?
a pro in coding? a native speaker? a nagging demander? an avid tester?
edit:
all of the above? ;-)
yes, all of the above. :D

Someone who is willing to contribute to the project (for any reason) and share it with our fellows here. More people involved will hopefully lead to a better project and more structure. Well, at least that's what I hope. :lol:

Re: Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Thursday 27 April 2017 11:55
by emme
Can I be considered as a tester? :oops:

Re: Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Thursday 27 April 2017 12:12
by BakSeeDaa
emme wrote:Can I be considered as a tester? :oops:
That would be very nice of You.

Just follow the Installation Instructions and please if You find something that is not clear, something that needs clarification, something wrong, please create a new issue in the tracker so we can correct it. If You want to contribute and alter the Installation Instructions by yourself please let me know so I can assign permissions for you.

Thanks! looking forward to hear the results! :D

Edit: Fixed the link to installation instructions

Re: Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Thursday 27 April 2017 20:58
by deennoo
As i'm a user of your Great LUA works, let's try it on Python !

Re: Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Friday 28 April 2017 7:55
by BakSeeDaa
deennoo wrote:As i'm a user of your Great LUA works, let's try it on Python !
Thanks @deenoo

Please report any difficulties that you may encounter so that we can improve the Wiki.
four2six wrote:... ;-)
Thank You (you) @four2six for your great work with the Wiki and for testing. Things are getting better and better! :D

Re: Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Friday 28 April 2017 12:33
by four2six
Don't you dare You me ;)
emme wrote:Can I be considered as a tester? :oops:
@emme did you find the time trying it yet?

Re: Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Friday 28 April 2017 12:35
by emme
not yet... (a 2yo daughter stole al my time once back at home from office and I'm quite happy - she will have the rest of her life to blame against me :lol: :lol: )
I think to be able to make a try tomorrow or on Monday :P :P

Re: Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Friday 28 April 2017 12:38
by four2six
make your daughter do the setup, if she can do it, it'll be perfect ;)

Re: RE: Re: Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Friday 28 April 2017 18:13
by BakSeeDaa
four2six wrote:Don't you dare You me ;)
emme wrote:Can I be considered as a tester? :oops:
@emme did you find the time trying it yet?
Thank you again. I think you have been doing a great job in a short time. Github works great for collaborating I think.

I wish you all a happy weekend.

Re: Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Tuesday 02 May 2017 20:22
by emme
four2six wrote:make your daughter do the setup, if she can do it, it'll be perfect ;)
LOL!!! she is!!! believe me... she is!!!
2yo and she's cmpletely able to make a coffee (with moka... not espresso ;) ) and heat her milk with the microwave oven all by herself!!! :D
I will have she start coding next year!! :D

...ok.. I finish the installation...
Installation went good....
by my opinion it works GREAT! a test event is pulled down... now I have to create a sort of syntax and create a command parser (I presume...)

Just a personal visual opinion... date format shoul be personalizable (not yyyy-mm-dd, but dd-mm-yyyy :P :P)


My idea would be something like...
1st row: deviceID :sValue, deviceID:sValue etc etc....
2nd row: timer (but you could check the switch value)

but in this way I have a question on this:
I can setup commands and act them when the switch is on... but what about the end of the event?!
if I want to toggle states of the devices... do I have to create a second event that switch them off?

ciao
M

P.S.
what about events duration of 0 seconds? :P :P

Re: Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Tuesday 02 May 2017 21:15
by four2six
ciao M
thx for helping! you and your daughter. send the mokka over, please.

and about your question:
the switch turns off after the event has passed. if you didn't leave a gap between two events, it will be kept turned on. did you notice you can use keywords to select certain events from one calendar?

and: how do you enter 0 second events in google calendar? ;)

edit: damn, you're right. you can set "zero second" events in google calendar. i added that to the issues. thank you!

Re: Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Wednesday 10 May 2017 9:54
by BakSeeDaa
emme wrote: Just a personal visual opinion... date format shoul be personalizable (not yyyy-mm-dd, but dd-mm-yyyy :P :P)
Your request for enhancement has been implemented and documented. For more information see https://github.com/BakSeeDaa/GCal/wiki/ ... stallation.

Re: Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Wednesday 10 May 2017 10:07
by emme
THANK YOU!!! :D :D

just a noob question:
Domoticz text device Start Time format [%Y-%m-%d. From %H:%M to ]: Here you have the option to specify how the Domoticz text device Start Time shall be displayed. For Advanced users, generally accept the default value. Formatting must be valid according to Python's strftime reference. In case you specify invalid syntax here, the default formatting will apply.

Domoticz text device End Time format [%H:%M]: Domoticz text device End Time formatting, see the explanation above.
this is related to a new calendar config.... but in case I wish to change the format in an already existing calendart I suppose to manual change the .data/config.json

unfortunately I do not see the time format parameter (because it was firstly configured when the option was uncovered)... how can I add it? :P :P
thanks
ciao
M

Re: Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Wednesday 10 May 2017 17:48
by emme
ok...
here's my very first, complex, almost useless command interpreter for gCal...
actully I can drive Devices, Groups, Scenes, Variables (as soon as I finish the string split portion :P :P)

Syntax for gCal Event:
chr 1: Device Type
actyally can handle:
N - Normal device with ON(01)/OFF(00) capabilities
D - Device with LEVEL capability (Dimmer, Blind, selector switch)
G - Group ON(01)/OFF(00)
S - Scenary (can be only ON)
V - Variable (not yet implemented)
and more to come
P - Set Point
M - Notification (quite useless to setup a notification under domoticz while gCal can notify either)
C - Camera Snapshot to mail


chr 2-3: New Value
chr 4-: device Name

examples:
D30Dinner light --> means Dinner Light LEVEL 30
G00ALL --> means Group ALL OFF
N01BedRoom --> means Bedroom ON

Code: Select all

-- Event Device: Google Calendare Decoder

local pfx = '<font color="Bisque">'
local sfx = '</font>'

local gcalDevName = 'Google_Calendar_Event'    -- Your gCal switch
local gcalcmdStr = 'Calendario'                -- Yeour gCal String Device

commandArray = {}
    if devicechanged[gcalDevName] == 'On' then
        cmdString = otherdevices[gcalcmdStr]:sub(1, otherdevices[gcalcmdStr]:find(' !#'))
        devType = cmdString:sub(1,1)
        devVal = cmdString:sub(2,3)
        devName = cmdString:sub(4)
        
        if devType == 'N' or devType == 'n' then         -- Device is a Normal switch with On(01)/Off(00) values 
            if devVal == '01' then
                devVal = 'On'
            else
                devVal = 'Off'
            end 
            commandArray[devName] = devVal
        
        elseif devType == 'D' or devType == 'd' then     -- Device is a Dimmer/Blind with position/Generic Level Device 
            commandArray[devName] = 'Set Level '..devVal
        
        elseif devType == 'V' or devType == 'v' then     -- Device is a Variable (value is ; separated)
            print(pfx..'VARIABLE PARSING NOT YET IMPLEMENTED'..sfx)
            
        elseif devType == 'G' or devType == 'g' then     -- Device is a Group with On(01)/Off(00) values
            if devVal == '01' then
                devVal = 'On'
            else
                devVal = 'Off'
            end 
            commandArray['Group:'..devName] = devVal
            
        elseif devType == 'S' or devType == 's' then     -- Device is a Scenary and value is not needed since it cam be only activated
            commandArray['Scene:'..devName] = 'On'
        
        else 
            print(pfx..'Google command string UNRECOGNIZED... please check...'..sfx)
        end
    end 
return commandArray
not really really tested.. but in my mind it would work :P :P
what you think about? :P :P

Re: Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Wednesday 31 May 2017 16:10
by BakSeeDaa
four2six wrote:... ;-)
Hi there @four2six ...

Have you installed the latest version yet on your new SD card? GCal 0.9.0 has been running here for quite some time now and I feel we would need a few more testers before releasing it.

Cheers!

Re: Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Wednesday 31 May 2017 17:36
by four2six
hi, bakseeda, i have been running it for some time, but not really 'using' it extensively.... the summer is taking its toll. thx for reminding me, i'll scrape some time off to do a bit of testing the coming days.

Re: Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Friday 09 June 2017 2:54
by deennoo
BakSeeDaa wrote:
deennoo wrote:As i'm a user of your Great LUA works, let's try it on Python !
Thanks @deenoo

Please report any difficulties that you may encounter so that we can improve the Wiki.
four2six wrote:... ;-)
Thank You (you) @four2six for your great work with the Wiki and for testing. Things are getting better and better! :D
First version without detailled wiki wasn't easy for me, and i stop it, just retry now and all are ok, exepted :

['domoticz']['textDevAllDayEventFmt'] is missing or faulty. Using the default value. how to solve this please ?


And i just need to find how to show date and hour as your previous GCal3

Maybe this can be more easier by providing a full installation script using bash and domoticz Python Plugin ?

Re: Invitation to become a Collaborator for a Google Calendar/Domoticz project (python)

Posted: Monday 12 June 2017 14:12
by BakSeeDaa
deennoo wrote: ['domoticz']['textDevAllDayEventFmt'] is missing or faulty. Using the default value. how to solve this please ?
Thanks for reporting that issue. I have been able to reproduce it and I have now fixed it in the latest version 0.9.1.

Please update GCal to latest version.

Then reconfigure GCal. (reconfigure the common GCal settings) An additional question will appear:

Code: Select all

Domoticz text device All Day Event format [%Y-%m-%d. (All day event)]:
That would solve the problem.