-
Notifications
You must be signed in to change notification settings - Fork 125
Typical_T1n
Tonino Fazio edited this page Apr 27, 2017
·
2 revisions
A detailed description of the T1n class is included below
Handle one digital output based on hardware and software commands,
output can be timed out.
This logic can be used for lights, wall socket and all the devices
that has an ON/OFF behaviour.
Hardware Command:
If using a monostable wall switch (press and spring return),
each press will toggle the output status.
#define Souliss_T1n_ToggleCmd 0x01
If using a bistable wall switch (press without return), the two
switch position can be associated with the ON and OFF commands
#define Souliss_T1n_OnCmd 0x02
#define Souliss_T1n_OffCmd 0x04
Software Commands:
From any available software interface, these commands will turn
the light ON and OFF.
#define Souliss_T1n_OnCmd 0x02
#define Souliss_T1n_OffCmd 0x04
Timed Output Command:
This logic can be used with a timer to active the output state for
a predefined amount of time, timer is activated if the input command
is greater than
#define Souliss_T1n_Timed 0x30
A timed out command can be sent via software or hardware commands,
in case of hardware commands is usually associated to a long press
of a monostable wall switch.
If INPUTVAL is the input value the output will be timed for nCYCLES
of the associated timer.
nCYCLES = INPUTVAL - Souliss_T1n_Timed
Command recap, using:
- 1(hex) as command, toggle the output
- 2(hex) as command, the output move to ON
- 4(hex) as command, the output move to OFF
- >30(hex) as command, time the output to ON
- 0(hex) as command, no action
Output status,
- 0(hex) for output OFF,
- 1(hex) for output ON.
Handle one digital output based on hardware and software commands,
output can be set in AUTO mode.
This logic can be used for lights, wall socket and all the devices
that has an ON/OFF behaviour, output can be driven by external event
like a PIR sensor.
Hardware Command:
If using a monostable wall switch (press and spring return),
each press will toggle the output status.
#define Souliss_T1n_ToggleCmd 0x01
If using a bistable wall switch (press without return), the two
switch position can be associated with the ON and OFF commands
#define Souliss_T1n_OnCmd 0x02
#define Souliss_T1n_OffCmd 0x04
Every time that an ON, OFF or TOOGLE command is received the AUTO
mode is automatically removed.
Software Commands:
From any available software interface, these commands will turn
the light ON and OFF.
#define Souliss_T1n_OnCmd 0x02
#define Souliss_T1n_OffCmd 0x04
Every time that an ON, OFF or TOOGLE command is received the AUTO
mode is automatically removed.
AUTO Mode:
If in AUTO the output is driven by external event, such events has
no effect if the AUTO mode is not active.
This logic MUST be used with a timer to active the output state for
a predefined amount of time, once the external event is recognized.
Once the external event occur, the input of the logic shall be
greater than
#define Souliss_T1n_AutoCmd 0x08
If INPUTVAL is the input value associated to the external event the
output will be timed for nCYCLES of the associated timer.
nCYCLES = INPUTVAL - Souliss_T1n_AutoCmd
Command recap, using:
- 1(hex) as command, toggle the output
- 2(hex) as command, the output move to ON the mode is reset
- 4(hex) as command, the output move to OFF the mode is reset
- 8(hex) as command, the mode is set to AUTO
- >8(hex) as command, time the output to ON if in AUTO
- 0(hex) as command, no action
Output status,
- 0(hex) for output OFF and mode not in AUTO,
- 1(hex) for output ON and mode not in AUTO,
- F0(hex) for output OFF and mode in AUTO,
- F1(hex) for output ON and mode in AUTO.
It read read data from input are of the memory map and place the
values in the output, this logic shall be used to monitor a digital
value into an user interface.
Hardware Command:
Using a bistable input switch (press without return) the two switch
position can be associated with the ON and OFF commands
#define Souliss_T1n_OnCmd 0x02
#define Souliss_T1n_OffCmd 0x04
Command recap, using:
- 2(hex) as command, the output move to ON
- 4(hex) as command, the output move to OFF
- 0(hex) as command, no action
Output status,
- 0(hex) for output OFF,
- 1(hex) for output ON.
It control a digital output with a pulse of the duration of one
execution cycle.
Hardware and/or Software Command:
Using a monostable input switch (press with return) or a software
command from the user interface to have a pulse on the output
#define Souliss_T1n_OnCmd 0x02
Command recap, using:
- 2(hex) as command, the output move to ON for a cycle
- 0(hex) as command, no action
Output status,
- 0(hex) for output OFF,
- 1(hex) for output ON pulse.
It map output over inputs matching the user interface commands,
act as a remote control for the conditioner and require a mapping of
the typical commands and the expected commands on the conditioner.
Software Commands:
A command is long one byte and indicate one operating mode of the
RBG light. In the definitions are available the commands that shall
be mapped versus the RGB light command map.
It use two memory slots
Handle one RGB LED strip based on software commands, with automatic
fade effects and "Good Night" feature. It use four (4) SLOT.
Hardware Command:
If using a monostable wall switch (press and spring return),
each press will toggle the output status.
#define Souliss_T1n_ToggleCmd 0x01
#define Souliss_T1n_BrightUp 0x10
#define Souliss_T1n_BrightDown 0x20
If using a bistable wall switch (press without return), the two
switch position can be associated with the ON and OFF commands
#define Souliss_T1n_OnCmd 0x02
#define Souliss_T1n_OffCmd 0x03
Software Commands:
From any available software interface, these commands will turn
the light ON and OFF.
#define Souliss_T1n_OnCmd 0x02
#define Souliss_T1n_OffCmd 0x03
#define Souliss_T1n_BrightUp 0x10
#define Souliss_T1n_BrightDown 0x20
#define Souliss_T1n_Flash 0x21
Color can be set using the following command in the first slot,
and giving the R, B and G values into the next three slots
#define Souliss_T1n_Set 0x22
Good Night:
The light goes off with a long time fade effect, this feature needs the
external timer. Good Night mode is activated using if the input command
is greater than
#define Souliss_T1n_Timed 0x30
A Good Night command can be sent via software or hardware commands,
in case of hardware commands is usually associated to a long press
of a monostable wall switch.
If INPUTVAL is the input value the output will be timed for nCYCLES
of the associated timer.
nCYCLES = INPUTVAL - Souliss_T1n_Timed
Command recap, using:
- 1(hex) as command, toggle the output
- 2(hex) as command, the output move to ON
- 4(hex) as command, the output move to OFF
- 10(hex) as command, the light bright is increased
- 20(hex) as command, the light bright is decreased
- 21(hex) as command, the light flash on and off at each cycle
- 22(hex) as command, set the color (needs R, G and B values)
- >30(hex) as command, time the output to ON
- 0(hex) as command, no action
Output status,
- 0(hex) for output OFF,
- 1(hex) for output ON.
The next three slots contains the R, G and B values applied to the
light.
Handle one digital output based on hardware and software commands,
output can be timed out.
This logic can be used for lights, wall socket and all the devices
that has an ON/OFF behaviour. It has a pulsed output, and can be
used with bistable relay or similar devices.
The actual state shall be reported with an external digital input
such as an auxiliary contact or a current measure.
Hardware Command:
If using a monostable wall switch (press and spring return),
each press will toggle the output status.
#define Souliss_T1n_ToggleCmd 0x01
If using a bistable wall switch (press without return), the two
switch position can be associated with the ON and OFF commands
#define Souliss_T1n_OnCmd 0x02
#define Souliss_T1n_OffCmd 0x04
The actual state shall be reported using these two feedbacks in
relevant INPUT slot.
#define Souliss_T1n_OnFeedback 0x23
#define Souliss_T1n_OffFeedback 0x24
Software Commands:
From any available software interface, these commands will turn
the light ON and OFF.
#define Souliss_T1n_OnCmd 0x02
#define Souliss_T1n_OffCmd 0x04
Command recap, using:
- 1(hex) as command, toggle the output
- 2(hex) as command, the output move to ON
- 4(hex) as command, the output move to OFF
- 0(hex) as command, no action
Output status,
- 0(hex) for state OFF,
- 1(hex) for state ON,
- A1(hex) for pulsed output.
Handle one single color LED strip based on software commands, with automatic
fade effects and "Good Night" feature. It use two (2) SLOT.
Hardware Command:
If using a monostable wall switch (press and spring return),
each press will toggle the output status.
#define Souliss_T1n_ToggleCmd 0x01
#define Souliss_T1n_BrightUp 0x10
#define Souliss_T1n_BrightDown 0x20
If using a bistable wall switch (press without return), the two
switch position can be associated with the ON and OFF commands
#define Souliss_T1n_OnCmd 0x02
#define Souliss_T1n_OffCmd 0x03
Software Commands:
From any available software interface, these commands will turn
the light ON and OFF.
#define Souliss_T1n_OnCmd 0x02
#define Souliss_T1n_OffCmd 0x03
#define Souliss_T1n_BrightUp 0x10
#define Souliss_T1n_BrightDown 0x20
#define Souliss_T1n_Flash 0x21
Intensity can be set using the following command, followed by the
value to be forced
#define Souliss_T1n_Set 0x22
Good Night:
The light goes off with a long time fade effect, this feature needs the
external timer. Good Night mode is activated using if the input command
is greater than
#define Souliss_T1n_Timed 0x30
A Good Night command can be sent via software or hardware commands,
in case of hardware commands is usually associated to a long press
of a monostable wall switch.
If INPUTVAL is the input value the output will be timed for nCYCLES
of the associated timer.
nCYCLES = INPUTVAL - Souliss_T1n_Timed
Command recap, using:
- 1(hex) as command, toggle the output
- 2(hex) as command, the output move to ON
- 4(hex) as command, the output move to OFF
- 10(hex) as command, the light bright is increased
- 20(hex) as command, the light bright is decreased
- 21(hex) as command, the light flash on and off at each cycle
- 22(hex) as command, set the intensity
- >30(hex) as command, time the output to ON
- 0(hex) as command, no action
Output status,
- 0(hex) for output OFF,
- 1(hex) for output ON.
It read read data from input and pass them through to the output.
There aren't command, but every value is copied in output
Command recap, using:
- Any value
Output status,
- Any value
Handle one digital output based on position of the mobile user
interface, that is requested to push continuously data in order
to keep the output in the ON condition.
The output goes to OFF once the user interface stop to push data.
Is expected that the user interface push data only via WiFi, this
give a position constrained behaviour.
Software Commands:
From any available software interface, these commands will turn
the light ON and OFF.
#define Souliss_T1n_OnCmd 0x02
#define Souliss_T1n_OffCmd 0x04
#define Souliss_T1n_PositionOnCmd 0x31
The Souliss_T1n_PositionOnCmd force the output to Souliss_T1n_OnCoil
and start a count-down timer. The timer got a reset every time that
the user interface send a the command Souliss_T1n_PositionOnCmd.
If the user interface send periodically the Souliss_T1n_PositionOnCmd the
output stays in Souliss_T1n_OnCoil, and goes back to Souliss_T1n_OffCoil
only when the user interface is out of WiFi range and is no longer able
to send data.
Output status,
- 0(hex) for output OFF,
- 1(hex) for output ON.
- Introduction
- Getting started
- User Interfaces
- Build your Souliss
- Examples
- Boards
- Interfaces
- Hacks
- Advanced
- Source Code
- Downloads
- Community