Author Topic: Say a weekend project idea, something nice to build  (Read 2411 times)

0 Members and 3 Guests are viewing this topic.

Offline RoGeorgeTopic starter

  • Super Contributor
  • ***
  • Posts: 6327
  • Country: ro
Say a weekend project idea, something nice to build
« on: May 09, 2024, 07:43:20 am »
What would that be?

Offline Nominal Animal

  • Super Contributor
  • ***
  • Posts: 6339
  • Country: fi
    • My home page and email address
Re: Say a weekend project idea, something nice to build
« Reply #1 on: May 09, 2024, 03:24:47 pm »
A fire.

No, really.  Fry some sausages or marshmallows, look at the fire, and relax.
 
The following users thanked this post: Ed.Kloonk, tom66, Halcyon, RoGeorge, JPortici

Offline MK14

  • Super Contributor
  • ***
  • Posts: 4581
  • Country: gb
Re: Say a weekend project idea, something nice to build
« Reply #2 on: May 09, 2024, 04:06:33 pm »
Connect together a set of suitable LEDs, and your favorite/in-stock microcontroller board, to make a relaxing and pleasant fire simulator, flashing pattern.

For Inspiration:






 
The following users thanked this post: RoGeorge

Offline Zeyneb

  • Regular Contributor
  • *
  • Posts: 239
  • Country: nl
Re: Say a weekend project idea, something nice to build
« Reply #3 on: May 09, 2024, 04:44:51 pm »
Maybe your car needs an oil change, how about DIY?

EDIT: I think MK14s post would be more suitable for the Southern Hemisphere citizens at this time.
« Last Edit: May 09, 2024, 05:06:29 pm by Zeyneb »
goto considered awesome!
 
The following users thanked this post: RoGeorge

Offline Nominal Animal

  • Super Contributor
  • ***
  • Posts: 6339
  • Country: fi
    • My home page and email address
Re: Say a weekend project idea, something nice to build
« Reply #4 on: May 09, 2024, 06:50:48 pm »
If you have WS2812 or similar programmable RGB leds, and a microcontroller with N×M×2+768 bytes of RAM, you can do some really nice fire and plasma effects.

The idea is that you use a good pseudorandom number generator as a seed in suitable cells.  I recommend using the 32 or 40 high bits of Xorshift64*, e.g.
Code: [Select]
#include <stdint.h>

// Any nonzero 64-bit seed will work; randomize it!
uint64_t  prng_state = 1;

// Cache for 8-bit pseudorandom numbers.
uint8_t   prng_cache[4];
uint8_t   prng_cached = 0;

// Obtain a random number between 0 and 255.
uint8_t   prng_u8(void)
{
    if (prng_cached > 0)
        return prng_cache[--prng_cached];

    uint64_t  x = prng_state;
    x ^= x >> 12;
    x ^= x << 25;
    x ^= x >> 27;
    prng_state = x;

    x = (x * UINT64_C(2685821657736338717)) >> 24;

    prng_cache[0] = x;
    prng_cache[1] = x >> 8;
    prng_cache[2] = x >> 16;
    prng_cache[3] = x >> 24;
    prng_cached   = 4;

    return x >> 32;
}
You declare two buffers and an RGB look-up table:
Code: [Select]
#define  N  //rows, vertical
#define  M  //columns, horizontal

typedef struct {
    uint8_t  cell [N][M];
} grid;

grid  g[2];

uint8_t  rgb[256][3];
For each inner cell, you apply a 3×3 kernel, centered on the cell, with the weights summing to 257 (or less if you want dimming).
Code: [Select]
const uint8_t  kernel[3][3] = { ... };

void apply(grid *const dst, grid *const src, const uint8_t flicker, const uint8_t bias)
{
    const uint_fast16_t  cmin =  (uint_fast16_t)flicker * (uint_fast16_t)bias;
    const uint_fast16_t  cmax = (uint16_t)( -(uint_fast16_t)flicker * (uint_fast16_t)(255 - bias) );

    for (uint_fast8_t n = 1; n < N-1; n++) {
        for (uint_fast8_t m = 1; m < M-1; m++) {
            uint16_t c = (uint_fast16_t)(kernel[ 0 ][ 0 ]) * (uint_fast16_t)(src->cell[ n-1 ][ m-1 ])
                       + (uint_fast16_t)(kernel[ 0 ][ 1 ]) * (uint_fast16_t)(src->cell[ n-1 ][ m   ])
                       + (uint_fast16_t)(kernel[ 0 ][ 2 ]) * (uint_fast16_t)(src->cell[ n-1 ][ m+1 ])
                       + (uint_fast16_t)(kernel[ 1 ][ 0 ]) * (uint_fast16_t)(src->cell[ n   ][ m-1 ])
                       + (uint_fast16_t)(kernel[ 1 ][ 1 ]) * (uint_fast16_t)(src->cell[ n   ][ m   ])
                       + (uint_fast16_t)(kernel[ 1 ][ 2 ]) * (uint_fast16_t)(src->cell[ n   ][ m+1 ])
                       + (uint_fast16_t)(kernel[ 2 ][ 0 ]) * (uint_fast16_t)(src->cell[ n+1 ][ m-1 ])
                       + (uint_fast16_t)(kernel[ 2 ][ 1 ]) * (uint_fast16_t)(src->cell[ n+1 ][ m   ])
                       + (uint_fast16_t)(kernel[ 2 ][ 2 ]) * (uint_fast16_t)(src->cell[ n+1 ][ m+1 ])
                       ;
            if (c >= cmin && c <= cmax) {
                c = c - cmin + prng_u8() * uint_fast16_t)flicker;
            }
            dst->cell[n][m] = c >> 8;
        }
    }
}
You need two grids,
    grid g, gtemp;
Initialize the main one to all zeros, set the seed cell values using the prng_u8() function, and apply the kernel twice,
    apply(gtemp, g, 0, 128);
    apply(g, gtemp, 0, 128);
The flicker term is how much randomness is added to each cell, and bias is whether it tends to increase (<128) or decrease (>128) the cell value.

Now you have the updated state in the main grid, and you can sample specific cells for your RGB LEDs, using the RGB look-up table rgb[g.cell[row][column]][0..2] for red, green, and blue components for that LED, respectively.  You can also do a number of apply() rounds before updating the LEDs.

My favourite is using a regular triangular grid for the LEDs, with relatively large grids.

If you use a RAM-based kernel, you can adjust it in real time, skewing it to a side, creating changing "draft".  Bias it completely towards one side to get drifting plasma/fire.

The possibilities are very nearly limitless, and it is easy to get going and some nice results, while genuine-looking fire takes careful tuning and experimentation.  :-+
« Last Edit: May 09, 2024, 06:59:34 pm by Nominal Animal »
 
The following users thanked this post: tom66, RoGeorge, MK14

Offline Halcyon

  • Global Moderator
  • *****
  • Posts: 5707
  • Country: au
Re: Say a weekend project idea, something nice to build
« Reply #5 on: May 10, 2024, 07:41:05 am »
A visual system to identify the presence of cats and spray them with a water jet, so they stop peeing in my front yard.
 
The following users thanked this post: RoGeorge, MK14

Offline RoGeorgeTopic starter

  • Super Contributor
  • ***
  • Posts: 6327
  • Country: ro
Re: Say a weekend project idea, something nice to build
« Reply #6 on: May 10, 2024, 09:04:18 am »
A visual system to identify the presence of cats and spray them with a water jet, so they stop peeing in my front yard.

Try cucumbers in your front yard.  ;D


Offline JPortici

  • Super Contributor
  • ***
  • Posts: 3472
  • Country: it
Re: Say a weekend project idea, something nice to build
« Reply #7 on: May 10, 2024, 09:09:38 am »
A visual system to identify the presence of cats and spray them with a water jet, so they stop peeing in my front yard.

That's usually called a dog
 

Offline Zoli

  • Frequent Contributor
  • **
  • Posts: 506
  • Country: ca
  • Grumpy old men
Re: Say a weekend project idea, something nice to build
« Reply #8 on: May 11, 2024, 06:28:11 am »
A visual system to identify the presence of cats and spray them with a water jet, so they stop peeing in my front yard.
I remember reading something like this in an nvidia engineer blog a few years ago(ML, RPi, cameras & automation involved, IIRC).
 

Offline RoGeorgeTopic starter

  • Super Contributor
  • ***
  • Posts: 6327
  • Country: ro
Re: Say a weekend project idea, something nice to build
« Reply #9 on: May 11, 2024, 07:43:21 am »
A visual system to identify the presence of cats and spray them with a water jet, so they stop peeing in my front yard.

That's usually called a dog

An electronic dog would be a nice build.  Might take longer than a weekend.  Anybody has the schematics for this one?



Maybe the schematic is shown somewhere in the movie, will watch this for now:  https://youtu.be/0S-sBIOZWMQ  :D
« Last Edit: May 11, 2024, 07:52:38 am by RoGeorge »
 

Offline nali

  • Frequent Contributor
  • **
  • Posts: 662
  • Country: gb
Re: Say a weekend project idea, something nice to build
« Reply #10 on: May 11, 2024, 08:09:54 am »
A visual system to identify the presence of cats and spray them with a water jet, so they stop peeing in my front yard.

I thought this was the Aussie approach..?

 
The following users thanked this post: RoGeorge

Offline Nominal Animal

  • Super Contributor
  • ***
  • Posts: 6339
  • Country: fi
    • My home page and email address
Re: Say a weekend project idea, something nice to build
« Reply #11 on: May 11, 2024, 02:39:45 pm »
A visual system to identify the presence of cats and spray them with a water jet, so they stop peeing in my front yard.
Citrus mister?

In truth, I think it is like trying to get back at divebombing seagulls by spiking snacks with high-Scoville chili sauce: birds' capsaicin pain receptors are very weak, so they just don't mind.  Trying to convince the local cat colony that your front yard is a no-peemail zone is as futile, unless you're some kind of cat whisperer.  Making it their fresh water drinking spot might have better chances of success than cat repellent plants, I reckon, exploiting their tendency to keep their food and water sources clean.  Dunno; sounds like a frustrating weekend to me.  I prefer the evening fire and toasting snacks.
« Last Edit: May 11, 2024, 02:41:27 pm by Nominal Animal »
 

Offline RAPo

  • Frequent Contributor
  • **
  • Posts: 642
  • Country: nl
Re: Say a weekend project idea, something nice to build
« Reply #12 on: May 11, 2024, 03:05:27 pm »
I've built a germanium transistor tester this weekend; see this .
 
The following users thanked this post: RoGeorge, ledtester

Offline RoGeorgeTopic starter

  • Super Contributor
  • ***
  • Posts: 6327
  • Country: ro
Re: Say a weekend project idea, something nice to build
« Reply #13 on: May 17, 2024, 08:08:23 am »
New weekend ahead!  :D
What project for this weekend?

Offline Messtechniker

  • Frequent Contributor
  • **
  • Posts: 786
  • Country: de
  • Old analog audio hand - No voodoo.
Re: Say a weekend project idea, something nice to build
« Reply #14 on: May 17, 2024, 08:34:59 am »
How about a 12 V DC distribution unit to get rid of
some larger wall warts blocking adjacent mains sockets.
Agilent 34465A, Siglent SDG 2042X, Hameg HMO1022, R&S HMC 8043, Peaktech 2025A, Voltcraft VC 940, M-Audio Audiophile 192, R&S Psophometer UPGR, 3 Transistor Testers, DL4JAL Transistor Curve Tracer, UT622E LCR meter
 
The following users thanked this post: RoGeorge

Offline RAPo

  • Frequent Contributor
  • **
  • Posts: 642
  • Country: nl
Re: Say a weekend project idea, something nice to build
« Reply #15 on: May 17, 2024, 10:08:50 am »
I've very little time, but hopefully there is enough time for a .
 
The following users thanked this post: RoGeorge

Offline RoGeorgeTopic starter

  • Super Contributor
  • ***
  • Posts: 6327
  • Country: ro
Re: Say a weekend project idea, something nice to build
« Reply #16 on: May 17, 2024, 10:22:45 am »
Gyrators are always fun and interesting to play with, indeed, that reminds me of a nice 101 article I've read last year from the Elektor Magazine #2/1975:

How to gyrate - and why
https://archive.org/details/ElektorMagazine/Elektor%5Bnonlinear.ir%5D%201975-02/page/n49/mode/2up
 
The following users thanked this post: RAPo

Online joeqsmith

  • Super Contributor
  • ***
  • Posts: 11796
  • Country: us
Re: Say a weekend project idea, something nice to build
« Reply #17 on: May 17, 2024, 01:00:07 pm »
What would that be?

I wonder what the average time frame is.  Most of my home projects seem to take about a week.  Some are years in the making.  Because I tend to work on things that I have no background in, they often require learning several areas.  For me, the construction and seeing it work (if it does) isn't as much fun as learning new things.   
 
The following users thanked this post: Sensorcat

Offline RoGeorgeTopic starter

  • Super Contributor
  • ***
  • Posts: 6327
  • Country: ro
Re: Say a weekend project idea, something nice to build
« Reply #18 on: May 17, 2024, 01:52:08 pm »
I wonder what the average time frame is.

Doesn't matter much, anything would do.  Ideal time frame would be a weekend (something between 2-20 hours total?), or at least to have some standalone partial result that can be enjoyed the same weekend.

Offline Zeyneb

  • Regular Contributor
  • *
  • Posts: 239
  • Country: nl
Re: Say a weekend project idea, something nice to build
« Reply #19 on: May 17, 2024, 03:14:57 pm »
Isn't this a wholesome DIY repair situation?

https://www.youtube.com/shorts/7Fw7bZoPyVU
« Last Edit: May 17, 2024, 03:18:42 pm by Zeyneb »
goto considered awesome!
 
The following users thanked this post: RAPo

Offline linux-works

  • Super Contributor
  • ***
  • Posts: 2000
  • Country: us
    • netstuff
Re: Say a weekend project idea, something nice to build
« Reply #20 on: May 17, 2024, 03:17:22 pm »
if in doubt, build a clock.

(arduino makes it easy)
 
The following users thanked this post: RoGeorge

Offline RoGeorgeTopic starter

  • Super Contributor
  • ***
  • Posts: 6327
  • Country: ro
Re: Say a weekend project idea, something nice to build
« Reply #21 on: May 18, 2024, 02:52:06 pm »
The clock I would like to build would be one that randomly advances, I mean it "ticks" driven by the movement of a double articulated pendulum, something like this:



Of course, the double pendulum arm will have to be pushed a little, here and there, to replenish the energy lost by friction in the pendulum articulations.  Then, some electronic that senses the movement and count the minutes and hours.

I'm not sure if a clock based on randomness would be able to keep the time at all, or if it will behave like a random walk, and the longer it runs the bigger the error it accumulates.  I suspect it should be able to keep track of time in the long run.  ::)

Offline RAPo

  • Frequent Contributor
  • **
  • Posts: 642
  • Country: nl
Re: Say a weekend project idea, something nice to build
« Reply #22 on: May 18, 2024, 03:46:43 pm »
Beware of the equilibrium points, for a triple articulated pendulum see this .



The clock I would like to build would be one that randomly advances, I mean it "ticks" driven by the movement of a double articulated pendulum, something like this:



Of course, the double pendulum arm will have to be pushed a little, here and there, to replenish the energy lost by friction in the pendulum articulations.  Then, some electronic that senses the movement and count the minutes and hours.

I'm not sure if a clock based on randomness would be able to keep the time at all, or if it will behave like a random walk, and the longer it runs the bigger the error it accumulates.  I suspect it should be able to keep track of time in the long run.  ::)
 

Offline RoGeorgeTopic starter

  • Super Contributor
  • ***
  • Posts: 6327
  • Country: ro
Re: Say a weekend project idea, something nice to build
« Reply #23 on: May 18, 2024, 05:39:57 pm »
Cool!  :-+
There is also a way to do about the same with a jig-saw.  ;D

Self-correcting Inverted Pendulum Defies Gravity
The Action Lab

 
The following users thanked this post: RAPo

Online joeqsmith

  • Super Contributor
  • ***
  • Posts: 11796
  • Country: us
Re: Say a weekend project idea, something nice to build
« Reply #24 on: May 18, 2024, 06:19:49 pm »
Day1 is done.  Lets see your progress.


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf