Commit Graph

18 Commits

Author SHA1 Message Date
redPanther 5aac2be702 Leddevice refactoring the next next part (#263)
* switch rs232 provider to completly async transfer

* start of implementing a seperate init function for leddevices

* rename setconfig to init

* more fixes

* implement missing code

* fix code style

* remove debug  code

* remove  debug stuff

* set loglevel to original state
2016-10-08 08:14:36 +02:00
redPanther d6a34edfb2 Leddevice refactoring the next part (#253)
* add general switchOff

* refactoring of leddevices regarding ledcount and switchoff

* remove obsolete includes
2016-09-23 08:49:22 +02:00
penfold42 cc8185691a Renamed the lowlevel providers from LedXXXDevice to ProviderXXX (#206)
%s/LedUdpDevice/ProviderUdp/g
git mv LedUdpDevice.cpp ProviderUdp.cpp
git mv LedUdpDevice.h ProviderUdp.h

vi `grep -l LedHID *`
%s/LedHIDDevice/ProviderHID/g
git mv LedHIDDevice.cpp ProviderHID.cpp
git mv LedHIDDevice.h ProviderHID.h

vi `grep -l LedRs *`
%s/LedRs232Device/ProviderRs232/g
git mv LedRs232Device.cpp ProviderRs232.cpp
git mv LedRs232Device.h ProviderRs232.h

vi `grep -l LedSpi *`
%s/LedSpiDevice/ProviderSpi/g
git mv LedSpiDevice.cpp ProviderSpi.cpp
git mv LedSpiDevice.h ProviderSpi.h
2016-08-28 07:12:47 +02:00
redPanther d679affeb4 Leddevice rework2 (#193)
* commit debug code to save it due to merge

* migrate first devices to new device registry and configure on runtime

* fadecandy and rs232 resets device if config is set

* try to hunt crash on osx

* test commit if this works with osx

* refactor spi devices

* cleanup

* refactor leddevices file, tinkerforge and ws2812b

* refactor raw usb devices

* refactor udp devices

* - add tpm2net driver
- remove old udp driver from build (files left in place for reference for new udp driver)
- json serverinfo shows available leddevices

* finish rework part 2 of leddevices

* add schemas for leddevices.
currently only compiled in, but not usedx
2016-08-23 20:07:12 +02:00
redPanther 97181fa83c leddevice refactoring. code style and extension of baseclass to avoid dups (#174) 2016-08-14 10:46:44 +02:00
redPanther 36b4d072c5 common ledbuffer for color transform (#77)
* common ledbuffer for color transform

hyperion class uses a common buffer for all operations on ledColors got from muxer
all color transforms uses new ledBuffer instead of making copies of ledbuffer

other fixes:
fix compile bug in profiler
update doxygen config

* migrate logging for color transform classes

* prepare new logger in hyperion class

* implement hwledcount

* Update Hyperion.cpp

Fix off color

* remove ledscount equivalent from apa102
migrate logging in hyperion.cpp
remove unused and duuplicate colorcorrection - but same is available through tempertature

* remove colorcorrection completly
fix compile

* set colororder back to static

* in remote: using correction is the same as using temperature - correction is obsolete, command not delete atm for compat reasons
2016-07-01 23:20:41 +02:00
penfold42 33f1ef457b More logging cleanup on led devices (#47) 2016-06-25 14:44:52 +02:00
penfold42 c17e4894d9 Apa102 fix if the led strip has more physical LEDs than you want to configure with hyperion (#626)
* Removed -HUP so the default -TERM signal is sent instead.
- hyperiond only listens for TERM and INT. HUP is often used to get an exe to reread its config

Changed pgrep to add '-x' so it wont partial match on the exe name.
- I have multiple instances with multiple hyperiond-instance1 names
- this ensures the service script only kills the right process

* reversing errant change to hyperion.systemd.sh

* started bug fixes for APA strips with more physical leds than configured

* 1st cut of changes to APA102.

now looks at config for "leds" which is the # of hardware leds in the strip.
This enables us to write the correct trailer length in the packet.

Also fixed a bug where switchoff was writing the wrong # of leds

* removed commented out old code

removed debug printf

* included prebuild test binary for Pi2

* Second attempt at the fix.
BEFORE:
If you have more physcial LEDs than defined in the "leds" "index" section of the config there is random junk added to the end of the strip.

WITH THIS FIX:
In the "device" section specify the number of physical leds with:
 "leds" : 212,
If this is greater than the number of led indexes, additional LEDs are set to black
If this is smaller than the number of led indexes, it is ignored

* included test binary

* Clean exit if the device config is missing or a non-supported device type is specified

Former-commit-id: 8ae96188fa74d91b13a921e7d5faf6d6ac1c42ee
2016-05-10 12:16:19 +02:00
wisc17 d6b5dc7ae6 Revert "Update LedDeviceAPA102.cpp by pcaffardi"
Former-commit-id: 493b32c03f922cc26d9fb4fce4778636f6a96e84
2016-02-09 20:21:49 +01:00
wisc 79dda5e840 Update LedDeviceAPA102.cpp by pcaffardi
Former-commit-id: e7efe8917fc10ceb860e44bbb37442cffa3512db
2016-02-07 17:40:24 +01:00
wisc 543042b870 pcaffardi/patch-1
Former-commit-id: 4a6737d50727518ae44f494be46a7c9c2fb54513
2016-02-07 14:52:44 +01:00
AEtHeLsYn 1c41919c08 Update LedDeviceAPA102.cpp
Former-commit-id: f0b04ded96a9c9b99c2329e7889917645065382d
2015-11-04 14:08:33 +01:00
AEtHeLsYn 958aa428a3 Update LedDeviceAPA102.cpp
Former-commit-id: 164b396f7d779d01e2fc1df80438ad817a0ac712
2015-11-04 14:05:09 +01:00
AEtHeLsYn acc1a1b397 Update LedDeviceAPA102.cpp
Problem with endFrame was not only endFrameSize, but ledValue index too

Former-commit-id: cc14e9d440a1d27f6a51c18f92aeba1f438c9c01
2015-10-30 20:07:21 +01:00
pcaffardi 2eea311dce Update LedDeviceAPA102.cpp
This fix the previous limit of 64 APA102 leds, because of too short end frame. Now the end frame is computed accordling to this documentation: https://cpldcpu.wordpress.com/2014/11/30/understanding-the-apa102-superled/. Tested on my 98 leds, it works fine.

I suggest to modify hyperion to allow LED drivers to apply the brightness parameter because APA102 has a parameter for that, without the need to elaborate RGB color to simulate it (result is wrong colors!). Is it possible to introduce such parameter in LED drivers and let the driver apply that?

Former-commit-id: 2d714e6eb075ec57e0973839fe96d2d7a051c57f
2015-08-09 16:15:25 +02:00
AEtHeLsYn c9636aaa6b Update LedDeviceAPA102.cpp
End frame fixed

Former-commit-id: 44107997d92d729f84adee368d12e35f1b5be6f1
2015-08-05 10:07:31 +02:00
wayland 63d0f6652e Rewrote the class to make it work with apa102 led strips
Former-commit-id: 9f63b95fb635b15e550d9368c7c8dbc632572bc5
2014-12-11 13:48:14 +01:00
wayland 4b716a9e2f Added the apa102 engine class
Former-commit-id: 03e11a19aed2ae782c5d134e1f4fcf9faea1969e
2014-12-03 09:35:10 +01:00