ladislas

ladislas

CTO @leka

Member Since 9 years ago

Leka Inc. - @leka , Paris, France

Experience Points
66
follower
Lessons Completed
262
follow
Lessons Completed
382
stars
Best Reply Awards
58
repos

1386 contributions in the last year

Pinned
⚡ Start your Arduino projects right out of the box
⚡ LekaOS is Leka's firmware based on Mbed OS
⚡ Homebrew AVR Toolchain
⚡ Lean 'n' Clean Neovim Config
⚡ A simple and easy to use event manager
Activity
Jan
26
1 day ago
Activity icon
created branch

ladislas in leka/LekaOS create branch hugo/feature/add-core-led-LADISLAS_REVIEW

createdAt 2 hours ago
pull request

ladislas pull request leka/LekaOS

ladislas
ladislas

hugo/feature/add core led LADISLAS REVIEW

  • FIXUP - remove trailing return type for void functions
  • FIXUP - fix mock::SPI name and namespace
  • FIXUP - unit tests - simplify spimock & CoreLED instantiation
  • FIXUP - move start/reset/end frames to struct for cleaner naming
  • :bug: (drivers): Allow interface::SPI write from const/constexpr containers
  • FIXUP - make frames constexpr
  • FIXUP - unit tests - use ::testing::_ for brightness as we actually don't care about the value
  • FIXUP - default color should be RGB::Black
  • FIXUP - rename & reoganize private variables
  • FIXUP - unit tests - rename, reorganize & clean up
  • :test_tube: (tests): Add failing tests calling turnOn() before set/showColor
  • :test_tube: (tests): Add failing tests calling turnOn() after set/showColor
  • :white_check_mark: (tests): Add turnOff test after set/showColor
open pull request

ladislas wants to merge leka/LekaOS

ladislas
ladislas

hugo/feature/add core led

  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :fire: (drivers): Remove CoreLED directory
  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :sparkles: Add CoreLED
  • ✨ (CoreLED): Add CoreLED
ladislas
ladislas

j'avais pas du être très clair alors. effectivement le template ne doit pas faire partie de cette PR.

par contre avoir le size dans le constructeur pour la stocker n'est pas très difficile et répond au besoin.

je suis pas très fan de merge du code dont on sait qu'il est "faux".

pull request

ladislas merge to leka/LekaOS

ladislas
ladislas

hugo/feature/add core led

  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :fire: (drivers): Remove CoreLED directory
  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :sparkles: Add CoreLED
  • ✨ (CoreLED): Add CoreLED
open pull request

ladislas wants to merge leka/LekaOS

ladislas
ladislas

hugo/feature/add core led

  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :fire: (drivers): Remove CoreLED directory
  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :sparkles: Add CoreLED
  • ✨ (CoreLED): Add CoreLED
ladislas
ladislas

tu peux faire std::to_array<uint8_t>({0x00, 0x00, 0x00, 0x00});

pull request

ladislas merge to leka/LekaOS

ladislas
ladislas

hugo/feature/add core led

  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :fire: (drivers): Remove CoreLED directory
  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :sparkles: Add CoreLED
  • ✨ (CoreLED): Add CoreLED
open pull request

ladislas wants to merge leka/LekaOS

ladislas
ladislas

hugo/feature/add core led

  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :fire: (drivers): Remove CoreLED directory
  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :sparkles: Add CoreLED
  • ✨ (CoreLED): Add CoreLED
ladislas
ladislas

si mais c'est le cas là avec RGB::black, RGB::pure_red, etc.

pull request

ladislas merge to leka/LekaOS

ladislas
ladislas

hugo/feature/add core led

  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :fire: (drivers): Remove CoreLED directory
  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :sparkles: Add CoreLED
  • ✨ (CoreLED): Add CoreLED
pull request

ladislas merge to leka/LekaOS

ladislas
ladislas

hugo/feature/add core led

  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :fire: (drivers): Remove CoreLED directory
  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :sparkles: Add CoreLED
  • ✨ (CoreLED): Add CoreLED
open pull request

ladislas wants to merge leka/LekaOS

ladislas
ladislas

hugo/feature/add core led

  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :fire: (drivers): Remove CoreLED directory
  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :sparkles: Add CoreLED
  • ✨ (CoreLED): Add CoreLED
ladislas
ladislas

faut tester mais on est obligé de forward declare la struct.

l'intérêt c'est qu'une autre implémentation de CoreLED peut implémenter la même interface tout en définissant une autre struct RGB.

open pull request

ladislas wants to merge leka/LekaOS

ladislas
ladislas

hugo/feature/add core led

  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :fire: (drivers): Remove CoreLED directory
  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :sparkles: Add CoreLED
  • ✨ (CoreLED): Add CoreLED
ladislas
ladislas

euh par contre ça turn pas off ça.

open pull request

ladislas wants to merge leka/LekaOS

ladislas
ladislas

hugo/feature/add core led

  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :fire: (drivers): Remove CoreLED directory
  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :sparkles: Add CoreLED
  • ✨ (CoreLED): Add CoreLED
ladislas
ladislas
	constexpr auto end_frame = std::to_array({byte_zero, byte_zero});

je sortirai les start/reset et end frame pour les mettre en static constexpr en variable membre. pas besoin de les créer à chaque fois et ça rendra la lecture plus simple

open pull request

ladislas wants to merge leka/LekaOS

ladislas
ladislas

hugo/feature/add core led

  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :fire: (drivers): Remove CoreLED directory
  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :sparkles: Add CoreLED
  • ✨ (CoreLED): Add CoreLED
ladislas
ladislas
	constexpr auto start_frame   = std::to_array({byte_zero, byte_zero, byte_zero, byte_zero});
open pull request

ladislas wants to merge leka/LekaOS

ladislas
ladislas

hugo/feature/add core led

  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :fire: (drivers): Remove CoreLED directory
  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :sparkles: Add CoreLED
  • ✨ (CoreLED): Add CoreLED
ladislas
ladislas

cette struct pourrait même être dans son propre header.

open pull request

ladislas wants to merge leka/LekaOS

ladislas
ladislas

hugo/feature/add core led

  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :fire: (drivers): Remove CoreLED directory
  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :sparkles: Add CoreLED
  • ✨ (CoreLED): Add CoreLED
ladislas
ladislas

really?! 😂

macros == ☠️

constexpr == 🎉

mais dans le cas présent tu forces 20 leds. si je veux écrire un spike avec CoreLED pour les oreilles, je fais comment?

il te faut donc un moyen de passer le nombre de LEDs à l'objet et de l'utiliser après.

Quelles sont les différentes options?

open pull request

ladislas wants to merge leka/LekaOS

ladislas
ladislas

hugo/feature/add core led

  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :fire: (drivers): Remove CoreLED directory
  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :sparkles: Add CoreLED
  • ✨ (CoreLED): Add CoreLED
ladislas
ladislas

petite réorganisation pour mettre les choses en rapport proches les unes des autres.

	auto setColor(RGB color) -> void override;
	auto showColor() -> void override;

	auto turnOn() -> void override;
	auto turnOff() -> void override;

	[[nodiscard]] auto isOn() const -> bool;
open pull request

ladislas wants to merge leka/LekaOS

ladislas
ladislas

hugo/feature/add core led

  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :fire: (drivers): Remove CoreLED directory
  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :sparkles: Add CoreLED
  • ✨ (CoreLED): Add CoreLED
ladislas
ladislas
open pull request

ladislas wants to merge leka/LekaOS

ladislas
ladislas

hugo/feature/add core led

  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :fire: (drivers): Remove CoreLED directory
  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :sparkles: Add CoreLED
  • ✨ (CoreLED): Add CoreLED
ladislas
ladislas
	constexpr uint8_t byte_zero  = 0x00;
	constexpr uint8_t brightness = 0x32;

pourquoi 32 pour la brightness?

pourquoi byte_zero? 0x00 c'est pas assez clair?

open pull request

ladislas wants to merge leka/LekaOS

ladislas
ladislas

hugo/feature/add core led

  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :fire: (drivers): Remove CoreLED directory
  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :sparkles: Add CoreLED
  • ✨ (CoreLED): Add CoreLED
ladislas
ladislas
	constexpr auto reset_frame = std::to_array({byte_zero, byte_zero, byte_zero, byte_zero});
pull request

ladislas merge to leka/LekaOS

ladislas
ladislas

hugo/feature/add core led

  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :fire: (drivers): Remove CoreLED directory
  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :sparkles: Add CoreLED
  • ✨ (CoreLED): Add CoreLED
pull request

ladislas merge to leka/LekaOS

ladislas
ladislas

hugo/feature/add core led

  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :fire: (drivers): Remove CoreLED directory
  • :heavy_plus_sign: (Add SPI lines to several CMakeLists): Add SPI lines to several CMakeLists
  • :sparkles: Add CoreLED
  • ✨ (CoreLED): Add CoreLED
push

ladislas push leka/LekaOS

ladislas
ladislas

:memo: (badges): Fix CI badge

ladislas
ladislas

:twisted_rightwards_arrows: Merge branch 'ladislas/bugfix/fix-readme-build-badge' into develop

  • ladislas/bugfix/fix-readme-build-badge: :memo: (badges): Fix CI badge

commit sha: 0ec4443ed574f67b5ff02abd46e41b65210ebf28

push time in 10 hours ago
Activity icon
delete

ladislas in leka/LekaOS delete branch yann/feature/timeout/add

deleted time in 11 hours ago
pull request

ladislas pull request leka/LekaOS

ladislas
ladislas

✨ (timeout): Add CoreTicker and CoreTimeout

CoreTimeout will help to switch into Sleep state in the StateMachine

push

ladislas push leka/LekaOS

ladislas
ladislas

:wrench: (time): Add CoreTicker and CoreTimeout to coverage exclusion

ladislas
ladislas

:sparkles: (time): Add CoreTicker, wrap of mbed::LowPowerTicker

ladislas
ladislas

:clown_face: (time): Mock of Ticker

ladislas
ladislas

:sparkles: (time): Add CoreTimeout, wrap of mbed::LowPowerTimeout

ladislas
ladislas

:clown_face: (time): Mock of Timeout

ladislas
ladislas

:sparkles: (spike): Add CoreTicker and CoreTimeout spike

ladislas
ladislas

:twisted_rightwards_arrows: Merge branch 'yann/feature/timeout/add' into develop

  • yann/feature/timeout/add: :sparkles: (spike): Add CoreTicker and CoreTimeout spike :clown_face: (time): Mock of Timeout :sparkles: (time): Add CoreTimeout, wrap of mbed::LowPowerTimeout :clown_face: (time): Mock of Ticker :sparkles: (time): Add CoreTicker, wrap of mbed::LowPowerTicker :wrench: (time): Add CoreTicker and CoreTimeout to coverage exclusion

commit sha: 3c97dad97fae22c9555a3d8a303ae8846763c58c

push time in 11 hours ago
pull request

ladislas merge to leka/LekaOS

ladislas
ladislas

✨ (timeout): Add CoreTicker and CoreTimeout

CoreTimeout will help to switch into Sleep state in the StateMachine

ladislas
ladislas

super clean! trop cool 👍

Activity icon
delete

ladislas in leka/LekaOS delete branch ladislas/bugfix/unit-test-template

deleted time in 14 hours ago
push

ladislas push leka/LekaOS

ladislas
ladislas

:white_check_mark: (unit): Replace all mentions of LEKA_V1_0_DEV with LEKA_Vx_x_UNIT_TEST

fixes #461

ladislas
ladislas

:memo: (tools): Update code snippets to run ruby scripts

ladislas
ladislas

:twisted_rightwards_arrows: Merge branch 'ladislas/bugfix/unit-test-template' into develop

  • ladislas/bugfix/unit-test-template: :memo: (tools): Update code snippets to run ruby scripts :white_check_mark: (unit): Replace all mentions of LEKA_V1_0_DEV with LEKA_Vx_x_UNIT_TEST

commit sha: 136010f0eec9401a539569fd6e205ff69b2a4f7b

push time in 14 hours ago
pull request

ladislas pull request leka/LekaOS

ladislas
ladislas

ladislas/bugfix/unit test template

  • :white_check_mark: (unit): Replace all mentions of LEKA_V1_0_DEV with LEKA_Vx_x_UNIT_TEST
  • :memo: (tools): Update code snippets to run ruby scripts
Previous