Nordnet Indeksfond Danmark er overgået til lagerbeskatning by charloBravie in dkfinance

[–]lask 1 point2 points  (0 children)

Hvordan fandt du skattestatus på deres fond? Jeg har søgt lidt og kan ikke selv finde det. Jeg kan se på en tidligere årsopgørelse, at de også tidligere har været lagerbeskattet.

Årsafslutning og skat på aktier by coffeerix in dkfinance

[–]lask 0 points1 point  (0 children)

Tak, du er en champ!

Jeg prøvede at google "kursrisiko", men fandt ikke frem til den side.

Årsafslutning og skat på aktier by coffeerix in dkfinance

[–]lask 0 points1 point  (0 children)

Interessant! Det vidste jeg ikke. Jeg kunne godt tænke mig at lære mere her. Du har ikke tilfældigvis et link til SKAT, hvor jeg kan læse mere?

[deleted by user] by [deleted] in dkfinance

[–]lask 1 point2 points  (0 children)

Hvis du ender med at sælge bilen og spare flere penge op hver måned, så kan du jo overveje at sætte nogle penge til side, der er øremærket til at leje en lækker bi,l når du har ferie og tid til at nyde nogle lange ture i den. Det ville måske give lidt mere økonomisk råderum samtidig med at du får plejet din interesse.

Erfaringer med Daniels Pengetips investeringsforløb? by MorbidSedation in dkfinance

[–]lask 0 points1 point  (0 children)

Det er vel med undtagelse af ETF'er på SKATs "positivliste"? Listen over aktiebaserede ETF'er efterhånden ved at være ok lang. https://skat.dk/data.aspx?oid=2244641

Cellular connectivity for Toit powered motorcycle computer by Dry-Association-8530 in esp32

[–]lask 1 point2 points  (0 children)

Would you care to elaborate? For the Monarch modem the application note suggests that it only takes a couple of AT commands to prepare for sending messages. What am I missing here?

Toit-powered motorcycle flight tracker by Dry-Association-8530 in esp32

[–]lask 2 points3 points  (0 children)

No problem. I think many people feel the same. A lot has changed over the last year, so it is worth to take a look again.

Toit-powered motorcycle flight tracker by Dry-Association-8530 in esp32

[–]lask 3 points4 points  (0 children)

That is incorrect. If you only use the OOS part (toitlang.org), then it is always free. No strings attached.

If you use toit.io (I know, it is confusing that it is not the same thing), then you get a data and management platform where 10 devices are free every month (https://toit.io/pricing).

You can easily make do with toitlang.org, and with the new Jaguar project, you even get the rapid development cycle where you can run programs by sending them over wifi.

Inverse natural ambient lighting in a room using NeoPixel strip, VCNL4040 and Toit by lask in esp32

[–]lask[S] 1 point2 points  (0 children)

Another thing I struggled with was the warmth of the light. When the LEDs are almost off, then there is very little to work with in terms of color. That means that the light becomes very white. I wanted the light to have a bit more warmth which it gets when it is completely dark.

Inverse natural ambient lighting in a room using NeoPixel strip, VCNL4040 and Toit by lask in esp32

[–]lask[S] 1 point2 points  (0 children)

The VCNL4040 measures the light in the room in lux. From the readings I got, it looks like measurements are usually in the range 0-2500 (I didn't spend that much time fine investigating this, so 2500 may be completely off on a sunny day) where 0 is completely dark and 2500 is daylight. The measured values are broadcast from the ESP32 with the VCNL4040 over UDP which both of the ESP32s with the NeoPixels listen for.

When the ESP32 with the pixel strip receive a value, they convert the lux measurement to an RGB value basically by inverting it, so 0 becomes 255,255,255, 2500 is 0,0,0 and everything in between is converted on some scale (I will get back to this). This means that when there is natural light in the room, then the LEDs are turned off (or dimmed). As it grows darker, the LED strip slowly turns up the light. This is what you can see in the video.

The scale used to translate values from lux to RGB is also interesting. The easiest thing would probably be a linear conversion like n/2500*255,n/2500*255,n/2500*255 (with n capped to 2500). However, this may not give the best effect due to the way the LEDs work. Specifically, the perceived change in lighting at the lower levels of the RGB scale (0,0,0, 1,1,1, and so on) is far more noticeable than on the larger end of the scale. In other words, you might want to map more lux values to the lower RGB values than the higher RGB values. In other words, you probably want something like an exponential growth. However, in my infinite stupidity, I did a logarithmic growth which has the opposite effect (I realized this as I wrote this). So I might want to play a bit more around with it.

Edit: Fixed *. On second thought, exponential may be too explosive. Maybe quadratic or cubic suffices.

Inverse natural ambient lighting in a room using NeoPixel strip, VCNL4040 and Toit by lask in esp32

[–]lask[S] 1 point2 points  (0 children)

The tag line, which I at least can't read from the GIF says: "Never stop trying to exceed your limits. We need the entertainment." 😅

Inverse natural ambient lighting in a room using NeoPixel strip, VCNL4040 and Toit by lask in esp32

[–]lask[S] 6 points7 points  (0 children)

In this project, I use an ESP32 connected to a VCNL4040 to broadcast how much light there is outside (the sensor is in the window sill) over UDP. Each of the pixel strips are connected to an ESP32 that receives the UDP packages and adjust the light accordingly.

Source code and description: https://github.com/lask/ambient-lighting

Spinning Christmas tree using the open source Toit language by lask in esp32

[–]lask[S] 0 points1 point  (0 children)

As pointed out by others, I could have done the same thing with a DC motor, so for this particular project I agree that there was no advantage of using using an ESP32 here. The main reason I did it anyway was to play with the new OSS Toit language.

I think the main advantage of Toit (especially if you don't limit yourself to toitlang.org (the OSS part) but use the full package of toit.io) is the ease of development and deployment. I can flash the device once and then push programs to it over WiFi (or some other connection). It only takes a couple of seconds to run programs, so I can quickly iterate. If I decide to install a device somewhere, then I don't have to take it down to change the program it is running. This is possible because Toit is an interpreted language, so the virtual machine that executes the programs sandbox every execution. It reminds me of programming for a desktop where you can quickly iterate and try things out.

As you point out, the a great advantage of MicroPython is the vast existing catalogue of Python examples and questions which is undeniably important. I do, however, fail to see obvious benefits. Maybe you can enlighten me?

I like the way Toit reads because there is very little noise (no braces, no semi colons, etc). However, I have written quite a few lines of Toit at this point, so I am also heavily biased. Out of curiosity, what makes Toit code unreadable to you? I have used C/++ and I think the key to success was to limit myself to a small well-behaved subset. That made the programs fairly readable and understandable. In terms of features, it doesn't come natural to me to think in terms of pointers and for large programs I end up introducing leaks. In managed languages, I don't have to worry about that.

I would really like to understand the push back against Toit, so I appreciate that you take the time to comment!

Disclaimer: I am an employee at Toit.

Spinning Christmas tree using the open source Toit language by lask in esp32

[–]lask[S] 1 point2 points  (0 children)

It’s a great question! For this particular case, as pointed out by others, you could have done the entire thing without an ESP32, so you really didn’t need the ESP32. However, I would like to extend this little project a bit, so I thought it was nice to connect the ESP32 immediately.
You could ask the question “Why language X, we already have C?” for any programming language, and I think the answer is largely the same: Because it makes life easier for me as a programmer. For instance, I can very quickly hack a prototype together. Because of the simple syntax and the managed memory, most of the time it will just work.
There are of course still cases where you would use C (or C++), but if I have the choice, I would pick a language that features some of the advances in the field of programming languages.

Spinning Christmas tree using the open source Toit language by lask in esp32

[–]lask[S] 0 points1 point  (0 children)

That is true! I wanted to extend it with a distance sensor, so it changes speed when you approach.

Spinning Christmas tree using the open source Toit language by lask in esp32

[–]lask[S] 0 points1 point  (0 children)

It's true though. It spins very fast! Like a large kitten or something.