The main differences between RS-232, RS-422 and RS-485

The RS-232, RS-422 and RS-485 designations refer to interfaces for digital data transmission. The RS-232 standard is better known as a normal computer COM port or serial port (although Ethernet, FireWire and USB can also be considered as a serial port). The RS-422 and RS-485 interfaces are widely used in the industry for connecting various equipment.

The table shows the main differences between RS-232, RS-422 and RS-485 interfaces.

Port nameRS-232RS-422RS-485
Transfer typeFull duplexFull duplexHalf duplex (2 wires),
full duplex (4 wires)
Maximum distance15 meters at 9600 bps1200 meters at 9600 bps1200 meters at 9600 bps
Contacts in useTxD, RxD, RTS, CTS, DTR, DSR, DCD, GND*TxA, TxB, RxA, RxB, GNDDataA, DataB, GND
TopologyPoint-to-PointPoint-to-PointMulti-point
Max. Number of connected devices11 (10 devices in receive mode)32 (with repeaters larger, usually up to 256)

FT232RL USB TO TTL Converter Pinout

Isolation voltage: 1500VDC voltage isolation, with continuous short circuit protection
Pin Definition: RXD,TXD,GND,VCC,P30(P30 is only for STC MCU)
TTL Level: 3.3V or 5V
USB interface: 2.0
The maximum speed: 3Mbps

About indicator LED:
PWM LED:Power Indicator
RXD LED:The data transmission indicator flashes when there is data from the USB port.
TXD LED:The data receiving indicator flashes when the USB port receives data.

内置特斯拉同类型无钴电芯,4款磷酸铁锂户外电源值得一看

目前大部分电池负极的材料都是石墨,因为其具有结晶度高,导电性好等特点,所以现在关于电池的研究就全部放在了正极上。

目前锂电池的种类主要有
钴酸锂、
锰酸锂、
镍钴锰酸锂、
镍钴铝酸锂、
磷酸铁锂、
钛酸锂等几大种类。
而这几类锂电池命名的方式用的就是正极采用的材料,由于正极采用的材料不同所以电池的价格、储电性能等各方面的因素都不相同,这其中由于能量性能和稀有金属成本的原因,导致锰酸锂、钛酸锂和钴酸锂电池逐渐变为小众选择,

于是磷酸铁锂和三元锂电池脱颖而出。

发票红冲

红冲发票,就是冲减原销项,然后开具正确的发票重新入账,跨月的就需要开红字发票了。

红冲就是以前做了一张错误的凭证,就用红字做一张和蓝字一模一样的红字凭证,就可以把原凭证冲了,然后再重新再做一张正确的凭证就可以了。

红冲发票有二种,一种是按原做账方法作为负数即可;第二种是冲减差额部分。比如借:管理费2000 贷:现金2000, 下月发现金额有误,应为200元,这时再做一张凭证更正,借:管理费用-1800, 贷:现金-1800。两种方法根据需要来使用。

Listen with spatial audio for AirPods Pro and AirPods Max

利用 AirPods Pro 和 AirPods Max 的空间音频功能实现畅快聆听体验

Listen with spatial audio for AirPods Pro and AirPods Max
Spatial audio with dynamic head tracking brings theater-like sound that surrounds you from the movie or video you’re watching, so that it seems as if the sound is coming from all around you. The sound field stays mapped to the device, and the voice stays with the actor or action on screen.

Spatial audio on iOS
What you need
AirPods Pro or AirPods Max
iPhone 7 or later or one of these iPad models:iPad Pro 12.9‑inch (3rd generation) and later
iPad Pro 11‑inch
iPad Air (3rd generation) and later
iPad (6th generation) and later
iPad mini (5th generation)
iOS or iPadOS 14 or later
Audiovisual content from a supported app

Spatial audio in Bluetooth settings on your iOS device
Turn on spatial audio
Go to Settings > Bluetooth.
Find your AirPods Pro or AirPods Max in the list (for example, “John’s AirPods”). 
Tap the Info button  next to your AirPods.
Turn on Spatial Audio.
To listen to a demonstration of spatial audio, tap See & Hear How It Works. You can switch from stereo audio to spatial audio to hear the difference between them.

Control spatial audio and see the status in Control Center
Open and close Control Center on your iPhone or on your iPad.
Touch and hold the volume control to turn spatial audio on or off and see the status icons.
Spatial audio enabled
Spatial audio is enabled, but not active for the audio content that you’re listening to.
 
Spatial audio active
Spatial audio is active.
Spatial audio off
Spatial audio is off.

Some device settings, including Follow iPhone, Balance, Mono audio, and Headphone Accommodations, can affect how spatial audio works.
Published Date: February 08, 2021
利用 AirPods Pro 和 AirPods Max 的空间音频功能实现畅快聆听体验
空间音频支持动态头部跟踪技术,可在您观看影片或视频时带来影院级的环绕声聆听体验,就如同声音环绕在您周围一样。声场会一直映射到设备,让您始终感觉声音来自屏幕上的演员或动作。

iOS 上的“空间音频”
所需条件
AirPods Pro 或 AirPods Max
iPhone 7 或更新机型,或者以下任一 iPad 机型:12.9 英寸 iPad Pro(第 3 代)及更新机型
11 英寸 iPad Pro
iPad Air(第 3 代)及更新机型
iPad(第 6 代)及更新机型
iPad mini(第 5 代)
iOS/iPadOS 14 或更高版本
受支持 App 中提供的视听内容

iOS 设备上“蓝牙”设置中的“空间音频”
打开空间音频
前往“设置”>“蓝牙”。
在列表中查找您的 AirPods Pro 或 AirPods Max(例如“John 的 AirPods”)。 
轻点 AirPods 旁边的“信息”按钮 
打开“空间音频”。
要聆听空间音频的演示效果,请轻点“查看并聆听其效果”。您可以在立体声音频和空间音频之间切换,以聆听两者的区别。

在“控制中心”中控制空间音频和查看状态
在 iPhone 或 iPad 上打开和关闭“控制中心”。
按住音量控制项可以打开或关闭空间音频,同时可以查看相关状态图标。
空间音频已启用
空间音频已启用,但对于您正在聆听的音频内容未激活。
 
空间音频已激活
空间音频已激活。
空间音频已关闭
空间音频已关闭。

某些设备设置(包括“跟随 iPhone”、“平衡”、“单声道音频”和“耳机调节”可能会影响空间音频的效果。
发布日期: 2021 年 02 月 16 日

install nginx onto Mac

brew install nginx

After install run:

sudo nginx

Testing

Open Navigator it by going to URL:

http://localhost:8080

Configuration

The default place of nginx.conf on Mac after installing with brew is:

/usr/local/etc/nginx/nginx.conf

Changing the default port (8080)

We shall change it to 80. First stop the nginx server if it is running by:

sudo nginx -s stop

Update thanks @zue666, @pixel67 if apache is running must also stop sudo apachectl stop

Then open nginx.conf with (example vim):

vim /usr/local/etc/nginx/nginx.conf

and change the:

server {
listen       8080;
server_name  localhost;

#access_log  logs/host.access.log  main;

location / {
    root   html;
    index  index.html index.htm;
}

to:

server {
listen       80;
server_name  localhost;

#access_log  logs/host.access.log  main;

location / {
    root   html;
    index  index.html index.htm;
}

Save configuration and relaunch nginx

sudo nginx

Testing

Open Navigator it by going to URL:

http://localhost

Update: thanks @pablohenrique * ERROR 403 Forbidden – * dont worry, some other application is already using port 80. probably be skype.

1 Solution 1: Change Skype port in Skype > Preferences > advanced 2 Solution 2: No change server { listen to 80.

That means that nginx will use port 8080 instead of 80. To access it I would use this url http://localhost:8080.


Changing the path of defualt web location

he nginx html folder (brew install only) is by the defult in:

/usr/local/Cellar/nginx/1.2.3/html

Note: change ** 1.2.3 ** to your nginx version.

The defualt path configuration:

server {
listen       80;
server_name  localhost;

#access_log  logs/host.access.log  main;

location / {
    root   html;
    index  index.html index.htm;
}

To let say Users/to/www:

server {
listen       80;
server_name  localhost;

#access_log  logs/host.access.log  main;

location / {
    root   /Users/to/www;
    index  index.html index.htm;
}

After change relaunch nginix server and nginx is now serving pages from your custom folder!

enjoy!

 

ttysXXX in who command

I am just playing with my OS-X terminal.
When I use the command: who
It result with the following output:

raj   console  Sep  3 09:37
raj   ttys000  Sep 11 16:58
raj   ttys002  Sep 11 17:53
raj   ttys004  Sep 11 17:53

I’m confused with what is meant by ttys000, ttys002 & ttys004?

=======

Everytime you open up a new terminal window it’s allocated a “pseudo teletype” aka ptty. When the os needs to send some info to one windows, it just specifies the ptty it’s going to get sent to.

You’ll notice that as you open and close terminal windows, the number of lines listed there will grow and shrink.

每次您打开新的终端窗口时,都会分配一个“伪电传打字机”(又名ptty)。 当操作系统需要将一些信息发送到一个窗口时,它仅指定要发送到的ptty。

您会注意到,在打开和关闭终端窗口时,其中列出的行数会增加和减少。