Categories
Ask Electrical Engineering Engineering

How does forward biasing of both junctions in BJT leads to saturation?

As far as I know, for an NPN-BJT, when both (base-emitter and base-collector) are forward biased; we consider the operation to be in saturation mode. Here, the transistor functions as a short circuit between emitter and collector. [SEE IMAGE BELOW] However, I expect quite different. With the electric field directions as shown above; I expect […]

Categories
Cryptocurrency Ethereum Mastering Development

How to understand the last argument of the solidity assembly call(g,a,v,in,insize,out,outsize) outsize

openzeppelin-labs proxy contract assembly { let ptr := mload(0x40) calldatacopy(ptr, 0, calldatasize) let result := delegatecall(gas, _impl, ptr, calldatasize, 0, 0) let size := returndatasize returndatacopy(ptr, 0, size) switch result case 0 { revert(ptr, size) } default { return(ptr, size) } } In the official documentation, I got this description. call(g, a, v, in, insize, […]

Categories
Linux Mastering Development

Hide “Terminated/Killed” message after killing a group of processes

So i am trying to hide the Killed message after executing the following command: while :;do echo 1;done 2>/dev/null|./scr.sh 2>/dev/null with the scr.sh containing: kill -9 — -$(ps -o pgid= $$ | grep -o [0-9]*) But it doesn’t work. The scr.sh is supposed to kill all the processes in the current pipe which i try […]

Categories
Linux Mastering Development

gawk/awk cross referencing partial string

So currently I have this script gawk -F: ‘ FNR==NR{a[$1][$2]=1;next} $2 in a{for(i in a[$2]) print $1 FS i} ‘ a.txt b.txt Example of a.txt contents: Email@gmail.com:example123 Email@gmail.com:example Example of b.txt: Charles:Email@gmail.com Erica:Email@gmail.com which will output Charles:example123 Charles:example Erica:example123 Erica:example as you can see it currently examines 2 files and matches a.txt first column against […]

Categories
Linux Mastering Development

Grub is not booting Ubuntu with LUKS/LVM

I have installed Ubuntu 20.04 on LUKS/LVM but unfortunately on booting I am only getting a grub> prompt. # lsblk NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT sda 8:0 0 465.8G 0 disk ├─sda1 8:1 0 731M 0 part /boot └─sda5 8:5 0 465G 0 part └─sda5_crypt 253:0 0 465G 0 crypt ├─ubuntu–vg-home 253:1 0 […]

Categories
Linux Mastering Development

Ubuntu: User ‘uname’ is not allowed to use [tool]

I found this cool tool called "incron." I think it will be a great productivity booster, but I am having issues getting it to run. sudo apt-get install incron … Adding group `incron’ … sudo usermod -a -G incron myname # no luck incrontab -e # user ‘myname’ is not allowed to use incron This […]

Categories
Linux Mastering Development

How do mount tools, helpers, and calls relate?

man 8 mount says mount uses helpers in /sbin/ (such as mount.exfat, mount.fuse, and mount.ntfs). man 2 mount doesn’t mention helpers. The corresponding umount pages showed the same thing. My ls /sbin | grep mount shows: mount.cifs mount.ecryptfs mount.ecryptfs_private mount.exfat mount.exfat-fuse mount.fuse mount.lowntfs-3g mount.ntfs mount.ntfs-3g umount.ecryptfs umount.ecryptfs_private umount.udisks2 Why doesn’t man 2 mount mention the […]

Categories
Linux Mastering Development

How can I add a Windows partition to a Linux device?

There are any number of articles online describing how to turn your Windows box into a dual-boot Windows/Linux, but I can’t find anything about how to go the other direction. My laptop is running Manjaro Linux, and I’d like to make it dual-boot Manjaro and Windows. I’ve downloaded a Windows 10 ISO from here, and […]

Categories
Linux Mastering Development

Setting TCP MSS on a bridge port

I have a VXLAN tunnel between two Linux hosts. This tunnel is carried over an Ethernet link with an MTU of 1500 bytes. At each end, the VXLAN interface is slaved to a bridge, along with another Ethernet interface. It looks something like this: | Host A | Host B | Client Device <–> eth0 […]

Categories
Mastering Development

Connection reset from WCF service when sending file from Android

I am battling a connection reset issue and I am hoping someone can help me diagnose it. We have a WCF Service that has a function that receives a file (a SQLite database) and saves it to the server. Periodically, a client will get a connection reset exception when uploading the file. We have never […]