User Tools

Site Tools


elektor-spl-en

Differences

This shows you the differences between two versions of the page.


elektor-spl-en [2021/07/01 00:48] (current) – created - external edit 127.0.0.1
Line 1: Line 1:
 +====== Serial Programmable LEDs (SPL) ======
 +[[:english#command_stations|{{  :interface.png}}]][[:english|{{  :rocrail-logo-35.png}}]]
 +[[english|Content]] -> [[english#command_stations|Command Stations]] ->   **SPL**
 + \\
 + \\
 +{{:spl:spl.jpg}}[[:gca_lm2-en|{{:gca:gca_lm2_pict03.jpeg?0x100}}]]\\
 + \\
 +=====Introduction=====
 +This library supports the Elektor **Serial Programmable LEDs**, SPL, project which was published in december 2013.\\
 +Its a very economically priced DIY 'Bus' for controlling LEDs in buildings and so on.\\
  
 + \\
 +
 +=====Setup=====
 +{{:spl:spl-setup-en.png}}\\
 +Only the serial port must be selected the line settings are fixed:
 +  * 9600-n-1
 + \\
 +
 +=====Addressing=====
 +Switch, Signal and Output objects are supported.
 +| Address | Home number | 1...255 |
 +| Port | LED number | 1...8 |
 + \\
 +
 +====Signal Aspects====
 +The Signal support is for __**[[:signal-int-en#aspect_numbers|Control type Aspect number]]**__ only.\\
 +The __**[[:signal-props-en#number|Aspect number]]**__ must be set accordingly to which LED(s) must be set.\\
 +^ Aspect # ^ L1 ^ L2 ^ L3 ^ L4 ^ L5 ^
 +|  0  | | | | | |
 +|  1  |  X  | | | | |
 +|  2  |  |  X  | | | |
 +|  3  |  X  |  X  | | | |
 +|  4  | | |  X  | | |
 +|  5  |  X  | |  X  | | |
 +|  6  | |  X  |  X  | | |
 +|  7  |  X  |  X  |  X  | | |
 +|  8  | | | |  X  | |
 +|  9  |  X  | | |  X  | |
 +|  10  | |  X  | |  X  | |
 +|  11  |  X  |  X  | |  X  | |
 +|  12  | | |  X  |  X  | |
 +|  13  |  X  | |  X  |  X  | |
 +|  14  | |  X  |  X  |  X  | |
 +|  15  |  X  |  X  |  X  |  X  | |
 +|  16  | | | | |  X  |
 +|  17  |  X  | | | |  X  |
 +|  ...  | | | | | |
 +
 +
 + \\
 +
 +=====Programming a module address=====
 +{{:spl:spl-programming-en.png}}\\
 +With the SPL dialog the address can be programmed of a module.\\
 +  * Set the IID field to the SPL library as configured in the Rocrail Controllers.
 +  * Set address to 255 if the module did not became an address before and set the new address as desired.
 +  * Set address to the actual module address to program the new address.
 +With the **Set** button the address will be programmed.\\ 
 +
 +> Note: The module shows its address at startup with the connected LEDs at startup until the first PC command is received.\\
 +
 + \\
 +
 +=====Random LED Control=====
 +{{:spl:spl-control-en.png}}\\
 +To generate random LED activity can be programmed on the Control tab of the SPL dialog.\\
 +Check the **8 LEDs** option if the modules are supporting 8 instead of 5 LEDs. (GCA)\\
 +Set the module range and program it by the **Set** button.\\
 +
 +  * To disable this Random LED Control both addresses should be set to zero.
 +  * The random pause between the random actions is between 500ms and 3500ms.
 +  * The random action will flip the actual LED status.
 +
 + \\
 +
 +=====Hardware=====
 +GCA has SPL compatible hardware:
 +  * __**[[:gca_lm2-en|GCA-LM2]]**__
 +
 + \\
 +=====Protocol=====
 +<code>
 +    Adressering van de module
 +    Voer de volgende tekenreeks in om een adres in het interne EEPROM-geheugen van de PIC- te zetten:
 +
 +    ‘H’ : Huis
 +    ‘F’ : Hoogste byte van het hexadecimale adres: F voor niet-geprogrammeerde modules
 +    ‘F’ : Laagste byte van het hexadecimale adres: F voor niet-geprogrammeerde modules
 +    ‘P’ : Commando P voor programmeren
 +    ‘a’
 +    ‘a’
 +    ‘5’: Beveiligingscode tegen per ongeluk programmeren
 +    ‘5’: Beveiligingscode tegen per ongeluk programmeren
 +    ‘x’: Hoogste byte van het te programmeren hex-adres: x = 0-9, A-F
 +    ‘y’: Laagste byte van het te programmeren hex-adres: y = 0-9, A-F
 +    ‘CR’: Carriage Return als afsluiting
 +
 +    Voer in het terminalprogramma ‘HFFPaa55’ in. De module reageert door alle LED’s in te schakelen.
 +    Voer dan het gewenste adres in (xy) en stuur een CR (druk op de Enter-toets). De LED’s doven dan.
 +    Als nu de voeding wordt uit- en weer inge- schakeld, is het adres geprogrammeerd.
 +    Gebruik dezelfde procedure om het adres van de module later te veranderen als dat nodig is.
 +    Voorbeeld: Om een nog niet geprogrammeerde module in te stellen op adres 23h, voeren we ‘HFFPaa5523’ in en drukken op ‘ENTER’.
 +
 +    LED-patronen instellen
 +    Aansturen van een module:
 +    ‘H’ : Huis
 +    ‘x’: Hoogste byte van het adres van het aan te sturen huis, x = 0-9, A-F
 +    ‘y’: Laagste byte van het adres van het aan te sturen huis, y = 0-9, A-F
 +    ‘S’: Commando S voor Set
 +    ‘a’: In te schakelen LED’s: hoogste byte, 0-1
 +    ‘b’: In te schakelen LED’s: laagste byte, 0-9, A-F
 +    ‘CR’: Carriage Return als afsluiting
 +
 +    De invoer is dus HxySab ENTER, waarbij xy het adres van de module aangeeft en na
 +    de S de hexadecimale waarde van de in te schakelen LED’s volgt. Met het bereik van
 +    00h tot 1Fh zijn alle 32 mogelijke combinaties van de vijf LED’s afgedekt.
 +
 +    Voorbeeld: Om LED 3 en 5 van module 12 te activeren, voeren we H12S14 ENTER in op de terminal.
 +
 +</code>
 +
 +====Output Type LED====
 +//Rocrail revision 14.386+//\\
 +| This is a protocol extension for controlling individual LEDs on Arduino and compatible boards. This is __not__ part of the official Elektor protocol. |
 +If the **[[:output-int-en#type|Output Type]]** is set to type LED, the following command will be send over the serial connection:
 +<code>
 +HxxExxVxx\r
 +</code>
 +^ Char ^ Value ^ Rocrail |
 +| H | Module number (Home) | Output address |
 +| E | LED number | Output port |
 +| V | Value | **[[:output-int-en#value|Output value]]** |
 + \\
 +**xx** is a hexadecimal representation in the range of 00 to FF. (0...255)\\
 +
 + \\
 +
 +=====Links=====
 +  * http://www.elektor-magazine.nl
 +  * [[https://www.elektor-magazine.com/nl/inhoudsopgave/vorige-uitgaven.html?tx_elektorarticle_listissues%5Barticle%5D=24103&tx_elektorarticle_listissues%5Baction%5D=show&cHash=4ae05bfb5899a388a46dc4c68d254f17|Elektor December 2013]]