Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Thunderstorm Support #18

Open
Kaiede opened this issue Jul 26, 2018 · 2 comments
Open

Thunderstorm Support #18

Kaiede opened this issue Jul 26, 2018 · 2 comments
Labels
enhancement New feature or request
Milestone

Comments

@Kaiede
Copy link
Owner

Kaiede commented Jul 26, 2018

It would be nice if the schedule included the ability to insert thunderstorms.

Example:
User decides that starting at 4:30pm every day, there should be a 20% chance of a thunderstorm lasting 30 minutes should occur. This is added as a special event into their schedule JSON.

The easiest way to implement this is to make a Behavior that handles the thunderstorm. It should have a higher priority than the basic ramp. It can fire at fairly short intervals to mimic lightning. It may also be worth making it possible for an active behavior to set the next run time for the behavior job to lessen some of the load on the CPU, letting it idle between lighting strikes. Since it will want to do updates to the PWM at rates on the order of a millisecond during a lightning strike, but go dormant for multiple seconds afterwards.

The trick here I think is to handle the down/up ramp of the lighting to simulate clouds when entering the thunderstorm and leaving it. Ramping down to the thunderstorm is easy, but ramping back up afterwards can be tricky. I'm thinking of situations where the ramp back up crosses an event point in the schedule. We may want to think about leveraging something like the "Behavior Plugin" during the transitions, and a Behavior for the thunderstorm itself.

@Kaiede Kaiede added enhancement New feature or request large feature labels Jul 26, 2018
@Kaiede Kaiede added this to the vNext milestone Jul 26, 2018
@Kaiede Kaiede modified the milestones: Backlog, V0.4 Aug 26, 2018
@Kaiede
Copy link
Owner Author

Kaiede commented Nov 13, 2018

This is technically ready, minus full testing. But I’m closing it out for now. The PR will remain open and can be merged down the road if it is wanted.

@Kaiede Kaiede closed this as completed Nov 13, 2018
@Kaiede Kaiede reopened this Nov 13, 2018
@Kaiede Kaiede modified the milestones: 1.0, Backlog Nov 13, 2018
@Kaiede
Copy link
Owner Author

Kaiede commented Nov 13, 2018

Actually, let’s just track this on the backlog. There’s a few ideas there already that are “nice-to-have”, but aren’t likely to be done anytime soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant