pulseaudio

黒したことシリーズ

 

mattintosh.hatenablog.com

 

 

再起動時にdefault-sinkの変更

qastack.jp

 

 

How do the PulseAudio libraries decide where to connect to?

The following rule applies: (see Server Strings for an explanation of the format of server specifications)

  • If the the application using the library specifies a server to connect to it is used. If the connection fails, the library fails too.
  • If the environment variable $PULSE_SERVER is defined the library connects to that server. If the connection fails, the library fails too.
  • If $DISPLAY is set, the library tries to connect to that server and looks for the root window property PULSE_SERVER for the host to connect to. If PULSE_COOKIE is set it is used as the path to the authentication cookie.
  • If the client configuration file (~/.pulse/client.conf or /etc/pulse/client.conf) sets the server address, the library connects to that server. If the connection fails, the library fails too.
  • The library tries to connect to the default local UNIX socket for PulseAudio servers. If the connection fails, it proceeds with the next item.
  • The library tries to connect to the default local TCP socket for PulseAudio servers. If the connection fails, it proceeds with the next item.
  • If $DISPLAY is set, the library tries to connect to the default TCP port of that host. If the connection fails, it proceeds with the next item.
  • The connection fails.

ccs811

http://blog.akanumahiroaki.com/entry/2018/06/12/080000

 

 

我が家

#include <SparkFunCCS811.h>

#define CCS811_ADDR 0x5A

CCS811 mySensor(CCS811_ADDR);

void setup() {
Serial.begin(115200);
Serial.println("CCS811 Basic Example");

CCS811Core::status returnCode = mySensor.begin();
if (returnCode != CCS811Core::SENSOR_SUCCESS)
{
Serial.println(".begin() returned with an error.");
while (1);
}
}

void loop() {
if (mySensor.dataAvailable())
{
mySensor.readAlgorithmResults();

Serial.print("CO2[");
Serial.print(mySensor.getCO2());
Serial.print("] tVOC[");
Serial.print(mySensor.getTVOC());
Serial.print("] millis[");
Serial.print(millis());
Serial.print("]");
Serial.println();
}

delay(10);
}

xrandr 2枚の設定

--portで場所決める必要あり。

 

最終的には、wqhdを1.5倍にscalingして、dpiを1.5倍にすることでちょうど。

xrandr --output DisplayPort-0 --panning 3840x2160+3840+0 --scale 1.5x1.5 --fb 7680x2160 --pos 3840x0

 

https://www.ncaq.net/2018/12/12/23/31/21/

 

Screen 0: minimum 320 x 200, current 7680 x 2160, maximum 16384 x 16384
DisplayPort-0 connected 3840x2160+3840+0 (normal left inverted right x axis y axis) 597mm x 336mm panning 3840x2160+3840+0

 

Screen 0: minimum 320 x 200, current 7680 x 2160, maximum 16384 x 16384
DisplayPort-0 connected 3840x2160+3840+0 (normal left inverted right x axis y axis) 597mm x 336mm panning 3840x2160+3840+0

 

モンテカルロ計算

https://www.amazon.co.jp/%E3%83%A2%E3%83%B3%E3%83%86%E3%82%AB%E3%83%AB%E3%83%AD%E7%B5%B1%E8%A8%88%E8%A8%88%E7%AE%97-%E3%83%87%E3%83%BC%E3%82%BF%E3%82%B5%E3%82%A4%E3%82%A8%E3%83%B3%E3%82%B9%E5%85%A5%E9%96%80%E3%82%B7%E3%83%AA%E3%83%BC%E3%82%BA-%E9%8E%8C%E8%B0%B7-%E7%A0%94%E5%90%BE/dp/4065191831