teleren/devto huggingface dataset:
CSSBattle | #31 Equals
Tags: css, challenge, cssbattle, equals
Published: 2022-10-16 16:24:10

Welcome to CSSBattle Challenges!

In this short article, I go through my solution for [CSSBattle - #31 Equals](https://cssbattle.dev/play/31) challenge. Please refer to the code snippet below to get a better insight into my thought processes and the implementation detail.

---

> #### Challenge:


![Equals Challenge](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/afflatgfpque7juqkal4.png)

---

> #### Solution:

```html
<div class="container">
  <div class="semi-circle left"></div>
  <div class="semi-circle right"></div>
</div>
<style>
  * {
    padding: 0;
    margin: 0;
    box-sizing: border-box;
  }
  .container {
    width: 100vw;
    height: 100vh;
    background: #aa445f;
  }
  .semi-circle {
    width: 200px;
    height: 100px;
    border-top-right-radius: 100px;
    border-top-left-radius: 100px;
    position: absolute;
    top: 50%;
    left: 50%;
  }
  .right {
    background: #e38f66;
    transform: translate(calc(-50% + 75px), -50%) rotate(90deg);
  }
  .left {
    background: #f7ec7d;
    transform: translate(calc(-50% - 75px), -50%) rotate(-90deg);
  }
</style>
```

---

> #### Key Takeaway(s):
- create semi-circles with height half the size of the width along with border radius properties
- use multiple transform properties to shift or rotate an element in multiple ways

As always, I welcome any feedback or questions regarding the implementation detail of the challenge. Otherwise, I hope this was useful!
Some links to pimp your gitHub profile
Published: 2022-10-16 18:12:18

https://dev.to/dailydevtips1/pimp-your-github-profile-hoc

https://docs.github.com/en/account-and-profile/setting-up-and-managing-your-github-profile/customizing-your-profile/about-your-profile

https://medium.com/nerd-for-tech/stand-out-by-personalizing-your-github-profile-f0a5d73f2b4d
5 Preferences Tweaks For A New Mac
Tags: productivity, customize, tooling, ios
Published: 2022-10-22 11:02:33

## 1. Screenshot Shortcut

The default when taking a screenshot is to save it, but most often we want to just send it to someone right away so to make things easier, change the shortcut to:
<kbd>⌘ Cmd</kbd> + <kbd>⇧ Shift</kbd> + <kbd>4</kbd>

![Screenshot Shortcut - preferences](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jjlhfvw7z21vo5ewksnn.png)

> Go to `System Preferences` -> `Keyboard` -> `Shortcuts` tab

--- 

## 2. Speed of Mouse Cursor

The default speed is too slow in my opinion, change it to your liking, he is mine 🙂

![Speed of Mouse Cursor - preferences](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/i1yus38t4owlslvgw53e.png)

> Go to `System Preferences` -> `Mouse`

--- 

## 3. Speed of keyboard Cursor

The default here is also slower than what I prefer.

![keyboard Cursor - preferences](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/7osf85kbw1sf7y11lchf.png)

> Go to `System Preferences` -> `Keyboard`

--- 

## 4. Untick the `fn` Option

This option will remove the need for pressing the `fn` key with one of the `F1, F2, F3....` keys.

Most often I use the <kbd>F2</kbd> key to [change variable names in `VsCode`](https://dev.to/danielbellmas/productivity-boost-with-cmd-ctrl-1nh8#bonus-productivity-tip-%EF%B8%8F).

> Unfortunately, this only works for an apple keyboard, not external ones.


![fn key - preferences](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/qkkaf1fnbgfpwj6v24vw.png)

> Go to `System Preferences` -> `Keyboard`

--- 

## 5. Text Replacements

Save time by putting your most frequently used phrases here.
My favorite is the email one :)

![Text Replacements - preferences](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/t4q1jbtupqjav0hnapda.png)

> Go to `System Preferences` -> `Keyboard` -> `Text`
The testing pyramid is outdated! E2E tests are now easy to write
Tags: testing, webdev, programming, frontend
Published: 2022-10-19 15:39:13

No doubt having a well-tested code base allows us to cover regression errors during releases.

### Unit test

Often we just test the business logic with unit tests, because they have a smaller scope and a very high execution speed.
These tests are a fair compromise between the effort spent and the benefits we get with a well-tested code base.

### End-to-end

There are also other types of tests such as End-to-End ones, they are more demanding and time-consuming to write and require more execution time.

Until recently, I was also on the same line of thinking until I tried to use ... Cypress.
It is an automatic tool and allows us to write and execute E2E tests quickly and easily.

Wow, this is awesome, but there is more...

Now with Cypress Studio, you can record tests quickly and easily instead of writing them.

### But how can I register for my test
Once [Cypress has been installed](https://docs.cypress.io/guides/end-to-end-testing/writing-your-first-end-to-end-test) a "trigger" test and the _experimentalStudio_ property in the cypress configuration will be sufficient to start recording your first test.

#### Cypress configuration

![CypressConfig](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/gi6gu5crmvpi32i8wm92.png)

#### Trigger test

![ExampleTest](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/1b8ub5yzjfrdxauc8sks.png)

Now you can start Cypress Studio and record new tests like this example:

<img width="100%" style="width:100%" src="https://s4.gifyu.com/images/ezgif-4-fc4ecc7cfd.gif">

✅ In the [docs](https://docs.cypress.io/guides/references/cypress-studio) you can the official example and all the steps to use it.

### Final thought

Recently I introduced this functionality in a project that we wanted to cover with the E2E test.
Together with the users of the platform we recorded the core flows of the application.
The results are excellent, with a little effort we were able to strengthen our tests and now we can sleep more peacefully.

You can [follow me on Twitter](https://twitter.com/giorgio_boa), where I'm posting or retweeting interesting articles.

I hope you enjoyed this article, don't forget to give ❤️.
Bye 👋

{% embed https://dev.to/gioboa %}
AWS Cognito ( Facebook log ). Why token doesn't have an email?
Tags: aws, javascript, webdev, react
Published: 2022-10-17 17:02:49

I tried google and Facebook login using `AWS Cognito & Amplify`.

Google login works fine.

But when I log in to Facebook, if I decode the token that comes, I don't get the email only.

But I think I did everything right.

Please help me if you have an answer to my question!

Thanks

## Code:

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/rlld03kx5df94ea83ug5.png)

## Cognito:

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/dy7fuwbie916rib0mfpz.png)



## response:

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/4m73iww639s3ku0fkj20.png)
Demonstration Sample Project "Practice1" (Movie)
Published: 2022-10-17 17:32:45

## Shirates (shirates-core)
Shirates is an integration testing framework that makes it easy and fun to write test code for mobile apps.
[shirates-core](https://github.com/ldi-github/shirates-core) is core library.

---

## Demonstraion
This is a demonstration movie for the article [Introducing Shirates, a Mobile Testing Automation Tool](https://dev.to/wave1008/introducing-shirates-a-mobile-testing-automation-tool-3nmc).

{% embed https://youtu.be/kwCL11BU2SQ %}
Setup local k8s cluster using kind
Tags: kubernetes
Published: 2022-10-18 00:36:09

In k8s world, there is a need for testing before going production. One among them is using `kind` to build local cluster. 
There are many ways in [official document](https://kind.sigs.k8s.io/docs/user/quick-start/), here is my prefer way using yaml to define my expectation. 

Creating a yaml file named `kind.yaml` as below to configure 1 master and 2 workers:
```
apiVersion: kind.x-k8s.io/v1alpha4
kind: Cluster
nodes:
- role: control-plane
  image: kindest/node:v1.22.0@sha256:b8bda84bb3a190e6e028b1760d277454a72267a5454b57db34437c34a588d047
  extraPortMappings:
  - containerPort: 30778
    hostPort: 30778
    listenAddress: "0.0.0.0"
    protocol: tcp
- role: worker
  image: kindest/node:v1.22.0@sha256:b8bda84bb3a190e6e028b1760d277454a72267a5454b57db34437c34a588d047
- role: worker
  image: kindest/node:v1.22.0@sha256:b8bda84bb3a190e6e028b1760d277454a72267a5454b57db34437c34a588d047 
```

Install kind if not have. If you're using MacOS, run: `brew install kind` for package manager using brewk

Run command to setup cluster: `kind create cluster --name local --config kind.yaml` 

Here is my result, tested in Mac M1 chip:

```
kind create cluster --name local --config kind.yaml
Creating cluster "local" ...
 ✓ Ensuring node image (kindest/node:v1.22.0) 🖼 
 ✓ Preparing nodes 📦 📦 📦  
 ✓ Writing configuration 📜 
 ✓ Starting control-plane 🕹️ 
 ✓ Installing CNI 🔌 
 ✓ Installing StorageClass 💾 
 ✓ Joining worker nodes 🚜 
Set kubectl context to "kind-local"
You can now use your cluster with:

kubectl cluster-info --context kind-local

Have a nice day! 👋
```

With k8s contents as below:
```
kubectl config set-context local-kind                                           Context "local-kind" created.

kubectl get node                                                                  
NAME                  STATUS   ROLES                  AGE     VERSION
local-control-plane   Ready    control-plane,master   7m58s   v1.22.0
local-worker          Ready    <none>                 7m26s   v1.22.0
local-worker2         Ready    <none>                 7m26s   v1.22.0
```
What is react ?And How to learn react in one week
Tags: javascript, react, webdev, beginners
Published: 2022-10-24 16:47:30

  **So before moving to react you should know how the web works from giving a request to getting a response from the server.__**
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/rz9minf6wh1fz784jw1p.png)

_First of all React is not a framework like angular and vue ,it is a javascript librabry.React APP is basically a collection of components .What is component ' Component are a simple function that you can call with some input and they render some output.
As they are reusable and interactable, so you can merge many components in order to make a entire React app.
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/cbck6absrmybx2irh6h5.jpeg)..

Best resources and yt channels for learning react :

1. freecodecamp
2. code evolution
3. 6 pack programmer
4. perdotech

HOW TO LEARN REACT IN ONE WEEK?
   FIRST I WILL SHARE HOW I LEARNED REACT IN ONE WEEK .
**DAY 1**
   I LEARNT ABOUT WHY DO WE ACTUALLY USE REACT RATHER THAN PURE VANILLA JS.THEN I REFRESHED ES6 JS CONCEPTS AND GET FAMILIER ABOUT THE FILE STRUCTURE OF REACT.
**DAY 2** 
 I LEARNT ABOUT JSX ,PROPS AND STYLING IN REACT .

 **DAY 3**
       ON THIRD DAY I LEARNT ABOUT FORMS IN REACT AND ALSO  USESTATE AND USEEFFECT HOOKS .

 **DAY 4**
 CREATED A SIMPLE TO DO LIST APP TO KNOW HOW WE PERFORM CRUD OPERATIONS AND MAMNAGE THE COMPONENTS RENDERING 

**DAY5**
I LEARNT ABOUT THE ROUTING IN REACT USING REACT-ROUTER-DOM.YOU SHOULD MUST LEARN IT WELL .THE OFFICIAL DOCS ARE PRETTY WELL FOR THAT .


**DAY 6**
THEN I LEARNT ABOUT THE REACT LIFECYCLE AND CLASS BASED COMPONENTS .ON THE SAME DAY I SOLVDED ALL THE REACT CHALLENGES ON FREECODECAMP.COM.IT WAS GREAT TO PRACTISE ALL THAT I HAVE LEARNT .

**DAY 7**
THEN I FINALLY MADE A CLONE OF MI STORE SITE .ALSO USED REACT BOOSTRAP .IT IS PRETTY GOOD FOR FAST DEVELOPEMENT OF INTERFACES.


**ADVICE FOR THE BEGINNERS :**
`_
1.DON'T TRY TO LEARN EVERYTHING ON ONE DAY AND RUSH TOWARDS THE ADVANCED TOPICS .TAKE YOUR OWN TIME.
2.AFTER WATCHING A TUTORIAL FIRST PRACTISE IT THEN SWITCH TO ANOTHER TOPIC.REMEMBER YOU GET GOOD AT ANYTHING  BY CREATING NOT JUST ONLY  BY CONSUMING .
3.DO PEER PROGRAMMING .MEANS FIND SOMEONE WHO ALSO WANTS TO LEARN REACT AND PASSIONATE ABOUT THE FRONT END .BELEIVE ME IT'S GREAT WAY TO LEARN .
4.CREATE AS MANY PROJECTS AS YOU CAN .YOU DON'T NEED TO LEARN THE SYNTAX DOCS AND GOOGLE IS ALWAYS THERE JUST BUILD THE LOGIC ABOUT WHERE YOU NEED TO USE WHICH CONCEPT 
5.GO THROUGH THE CODE OF OTHERS ON GITHUB .OBSERVE HOW THEY MAINATAIN COMPONENTS FOLDER ,EXTENSIONS OF VS CODE FOR REACT,AND MANY STUFFS FIGURE OUT ALONG THE JOURNEY .
6.THERE IS NO SHORTCUT YOU JUST HAVE TO START .
_`
REMOTE Data Science Job that pays up to $165K - Santhoscheeku77
Tags: career, job, productivity
Published: 2022-11-05 13:45:34

####   Original Tweet From  [@Santhoscheeku77](https://twitter.com/Santhoscheeku77)
{% embed https://twitter.com/Santhoscheeku77/status/1588546664918405122 %}


### 1  Decentral, US 

▪ Role              - Machine Learning Engineer 

▪ Salary         - $70k – $120k • 0.3% – 1.5% ( equity )

 [https://angel.co/company/decentralinc/jobs/576333-machine-learning-engineer](https://angel.co/company/decentralinc/jobs/576333-machine-learning-engineer) 

### 2  Weights &amp; Biases, US

▪ Role               - Machine Learning Engineer

▪ Salary          - $100k – $160k

 [https://angel.co/company/wandb/jobs/1193123-machine-learning-engineer-customer-success-remote](https://angel.co/company/wandb/jobs/1193123-machine-learning-engineer-customer-success-remote) 

AdSpace Here!!

### 3  Neo Cybernetica

▪ Role               - AI Research Engineer

▪ Salary          - $60k – $140k

 [https://angel.co/company/neo-cybernetica-1/jobs/2432007-ai-research-engineer-reasoning](https://angel.co/company/neo-cybernetica-1/jobs/2432007-ai-research-engineer-reasoning) 

### 4  Generally Intelligent

▪ Role               - Machine Learning Engineer

▪ Salary          - $140k

 [https://angel.co/company/generally-intelligent/jobs/1490456-machine-learning-engineer-remote](https://angel.co/company/generally-intelligent/jobs/1490456-machine-learning-engineer-remote) 

AdSpace Here!!

### 5 Light, Europe

▪ Role               - AI developer 

▪ Salary          - €65k – €100k • 0.1% – 0.5% ( equity )

 [https://angel.co/company/light-15/jobs/2458863-ai-developer](https://angel.co/company/light-15/jobs/2458863-ai-developer) 

### 6 Paleo

▪ Role               - Data Scientist

▪ Salary          - $85k – $165k • 1.0% – 15.0%  ( equity )

 [https://angel.co/company/paleo-3/jobs/2466427-data-scientist](https://angel.co/company/paleo-3/jobs/2466427-data-scientist) 

AdSpace Here!!

###7 Growthday, US

▪ Role               - Data Analyst

▪ Salary          - $70k – $90k

 [https://angel.co/company/growthday/jobs/2462744-data-analyst](https://angel.co/company/growthday/jobs/2462744-data-analyst) 

That's a wrap! &amp; Thank you for Reading ❤

AdSpace Here!!

If you enjoyed this thread:

1.  I plan to share such resources in Future

2. Follow me [@Santhoscheeku77](https://twitter.com/Santhoscheeku77) for more of this Data Science content 

3. Like &amp; RT the tweet below to share this thread with your audience  [https://twitter.com/Santhoscheeku77/status/1588546664918405122](https://twitter.com/Santhoscheeku77/status/1588546664918405122) 



Click [Here](https://www.knowledge-twitter.com/?utm_source=dev.to)  For More Posts Like This [https://www.knowledge-twitter.com](https://www.knowledge-twitter.com/?utm_source=dev.to)
FTDI Bitbanging GCC
Tags: robots, ftdi, gcc
Published: 2014-05-18 10:00:00

---
title: FTDI Bitbanging GCC
tags: robots, ftdi, gcc
published_at: 20140518T10:00Z
canonical_url: https://ladvien.com/ftdi-bitbanging
main_image: https://ladvien.com/images/FTDI.jpg
published: true
---

This is a short note on how to setup a C programming environment for the FTDI chip in bit banging mode, since that's what I had difficulty doing.

There may be easier ways to go about this, but I wanted to use GCC to compile a small C program to control the 8 IOs.  The purpose was to write a small command-line program that would reset my LPC1114 before and after programming.

To setup the environment:

1. I downloaded and setup [MinGW32](http://www.mingw.org/wiki/HOWTO_Install_the_MinGW_GCC_Compiler_Suite).

2. I then downloaded [FTD2XX libraries](http://www.ftdichip.com/Drivers/D2XX.htm).  **This included the ftd2xx.h file and ftd2xx.lib**.

3. I then stole the test code from Hack-a-Day's article on [bitbanging with the FTDI](http://hackaday.com/2009/09/22/introduction-to-ftdi-bitbang-mode/).

4. I modified the code as they suggested by including, in this order, the Windows compatibility files:

```cpp
#include <stdio.h>
#include <stdarg.h>
#include <windows.h>
#include <windef.h>
#include <winnt.h>
#include <winbase.h>
#include <string.h>
#include <math.h>
#include "ftd2xx.h"
```
5. I then used the rest of their code as a base: [Hack-a-Day's FTDI PWM Code](https://github.com/Ladvien/FTDI_Bitbangin_GCC/blob/master/ftdi_Test.c)

I used this line to build it:

```bash
gcc -o ftdi_PWM ftdi_Test.c -L./ -lftd2xx
```

You must have both the ftd2xx.h and ftd2xx.lib in the same directory as you attempt to build.

6. I then wrote two programs, one to send DTR and CTS high and low in order to reset the LPC1114 into **programming mode. ** Second, to send DTR and CTS high and low in order to send the LPC1114 into **run program mode.**  The idea being, I could use the typical [Sparkfun FTDI programmer](https://www.sparkfun.com/search/results?term=ftdi) to program my [LPC1114](http://letsmakerobots.com/content/lpc1114-setup-bare-metal-arm).

1. [LPC1114_reset_to_program](https://github.com/Ladvien/FTDI_Bitbangin_GCC/blob/master/LPC1114_reset_to_program.c)
2. [LPC1114_reset_to_bootloader](https://github.com/Ladvien/FTDI_Bitbangin_GCC/blob/master/LPC1114_reset_to_bootloader.c)

That's it.  Just wanted to make sure this was out in the universe for the next guy's sake.
.NET MAUI for production code?
Tags: programming, maui, discuss
Published: 2022-11-07 21:22:57

I've been working on a new mobile app for some time now. I wanted to implement it in .NET MAUI. This has been in General Availability status since the end of May and has been positioned as the successor to Xamarin.
During the development of the app, disillusionment quickly set in because I was affected by one of the more than 1200 issues that are open in Github which are flagged as bugs. I haven't checked Github beforehand, so I was really astonished how many bugs are reported and still not solved. Some of them are already flagged with .NET8. 
Besides these bugs there are several hundred other issues. 
These numbers are of course across all supported platforms.
 
On some controls like the CollectionView properties or methods are still marked as "To be added".

Using third party tools does not make one’s life easier, because many .NET MAUI controls are still in preview mode.

To use unit tests on Windows you have make manual modifications in the project files of the app to be tested. Also something which is not really well done.
 
All in all, .NET MAUI doesn't look like a system I want to use productively. Love to read your opinion about .NET MAUI in the comments.
Here are the top 20 code contributors to the ethereum ecosystem
Tags: ethereum, opensource, github, webdev
Published: 2022-11-07 22:37:46

Vitalik is the face of ethereum but here are 19 others that have contributed significantly to the ethereum ecosystem code base. #notallheroeswearcapes

Disclaimer: All data from open source github repos

Let me know in the comments if you'd like to see more interesting ethereum facts.

![Top 20 Ethereum Ecosystem Contributors](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/p9viskw3dkbig7z7n5ll.png)
Device-Based Ads And App Binary
Tags: webdev, javascript, news, tutorial
Published: 2022-11-08 03:52:40

Device-Based Ads And App Binary
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/zgwe8ph7c8eloa1jpfbh.PNG)


Suggest Native App Binary based on their IP and also Tailor/Target Ads for user OS or Browser.

Let's look at a more clearer example of this, for instance you want to download Visual Studio Tools from Microsoft website https://visualstudio.microsoft.com/downloads/, the website will automatically detect your operating system and will suggest the type of build to download. If you are using a windows machine, you will be asked to download the windows build for Visual Studio Tools.

Sometimes they are some website you may want to download a software from. they will automatically detect your operating system and trigger a download build for your operating system.

With IpForensics, you can detect users operating system or device and implement your logic.

See code documentation here
 https://ipforensics.gitbook.io/ipforensics/code-implantation/device-based-ads-and-app-binnary[](https://ipforensics.gitbook.io/ipforensics/code-implantation/device-based-ads-and-app-binnary)


Follow us on LinkedIn
https://www.linkedin.com/company/ipforensics/

Visit our website for more
https://ipforensics.net
7 Websites That Will Help You Spend Your Time Wisely!
Published: 2022-11-08 04:49:42

The internet is a great treasure for someone who knows how to use it. Instead of killing off time on platforms like Twitter and Instagram, you can use the hundreds of websites out there. Almost every day, an interactive website is created by people for the needs of other people.



#1 - Earth Nullschool



Earth Nullschool is a website that provides an interactive map with detailed information about all the winds worldwide. The information and details on the website are updated every three hours based on NASA's supercomputer.



#2 - The Collected Papers of Albert Einstein



After Einstein died, tens of thousands of documents were left behind. The Princeton University Press has made all of Einstein's legacy available. The Collected Papers of Einstein project has collected around 30,000 documents from Einstein.



#3 - Brilliant



Brilliant.org is a tool developed by two Silicon Valley engineers who've gone bonkers over fundamental fields such as math and science. Instead of explanatory videos, they have a method where self-motivated individuals can learn by reading up on the topics.



#4 - River Runner



A raindrop that fell on Arizona's Tonto National Forest travels 724 km and arrives in Golfo, located in California. Sam Learner created the River Runner website that interactively shows us where a raindrop goes after it falls on the earth.



#5 - The Fry Universe



Chris Williams created a website that discusses the 3D models of various french fries and the designs and physics behind them. Obtaining interesting information about one's likes also increases the taste behind it.



#6 - Why Time Flies?



As a person nearing age 40, I have no idea how time has passed in my past. Why Time Flies is a fantastic website showing how time flies as we age.



#7 - Neal.Fun



Fun may be the best website in the world. It's a website type that makes you laugh and think simultaneously. There are a lot of things worth discovering with your child.