- ginbeeではクライアント・サーバ間の通信にJSON形式を使用している。
- 画面のウィジェットの各項目の値をJSONにしているが、各項目が空白文字列であることが多い。
- 空白文字列や0などの値をデフォルト値として省略するとJSONのサイズを大幅に小さくできる。
- 通信量が減るので高速化できる。
- まだ実装してないので予想でしかありませんが100ms前後の高速化が期待できそう。
- 空白文字列や0などの値をデフォルト値として省略するとJSONのサイズを大幅に小さくできる。
- クライアント側で省略項目を認識してデフォルト値に展開しないといけない。
- 今月中くらいはかかりそう。
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # encoding:utf-8 | |
| require 'serialport' | |
| $serial_port = '/dev/ttyUSB0' | |
| $serial_baudrate = 9600 | |
| $serial_databit = 8 | |
| $serial_stopbit = 1 | |
| $serial_paritycheck = 0 | |
| sp = SerialPort.new($serial_port, $serial_baudrate, $serial_databit, $serial_stopbit, $serial_paritycheck) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| mihara@trusty48:~/samples/gtk3$ LANG=C ./checkfcitx.c | |
| ./checkfcitx.c: In function 'main': | |
| ./checkfcitx.c:25:3: warning: 'gtk_vbox_new' is deprecated (declared at /usr/include/gtk-3.0/gtk/deprecated/gtkvbox.h:61): Use 'gtk_box_new' instead [-Wdeprecated-declarations] | |
| vbox = gtk_vbox_new(FALSE,1); | |
| ^ | |
| process 8356: D-Bus library appears to be incorrectly set up; failed to read machine uuid: Failed to open "/etc/machine-id": Too many open files | |
| See the manual page for dbus-uuidgen to correct this issue. | |
| process 8356: D-Bus library appears to be incorrectly set up; failed to read machine uuid: Failed to open "/etc/machine-id": Too many open files | |
| See the manual page for dbus-uuidgen to correct this issue. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # coding:utf-8 | |
| require 'json' | |
| require 'pp' | |
| require 'tempfile' | |
| def cpanda(command,opt,json=nil) | |
| out = nil | |
| arr = [ | |
| opt[:cpanda], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| IDENTIFICATION DIVISION. | |
| PROGRAM-ID. TEST1. | |
| ENVIRONMENT DIVISION. | |
| CONFIGURATION SECTION. | |
| INPUT-OUTPUT SECTION. | |
| FILE-CONTROL. | |
| * | |
| DATA DIVISION. | |
| FILE SECTION. | |
| * |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| --- u14.log 2019-10-29 11:24:19.253258539 +0900 | |
| +++ u18.log 2019-10-29 11:24:19.253258539 +0900 | |
| @@ -2,2 +2,2 @@ | |
| - -falign-functions 1 | |
| - -falign-jumps 1 | |
| + -falign-functions 0 | |
| + -falign-jumps 0 | |
| @@ -5 +5,2 @@ | |
| - -falign-loops 1 | |
| + -falign-loops 0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # 概要 | |
| 簡単なCOBOLプログラムを作成してscan-build、およびvalgrindでInitialize漏れがチェックできるか確認した。 | |
| 結論としては両ツールではチェックできなかった。 | |
| # TEST1.CBLのビルドおよびscan-build実行 | |
| `% ./build.sh` | |
| 結果をbuild.sh.outに記載 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #if 0 | |
| #!/bin/bash | |
| src=$0 | |
| obj=${src%.*} | |
| gcc -g -Wl,--no-as-needed `pkg-config --cflags --libs json-c` -o $obj $src | |
| $obj | |
| exit | |
| #endif | |
| /************************************************** |
Slack apiで特定のチャンネルのエクスポートを行うスクリプト
- Slack api Tokenの取得
- expoort_slack_channel.rbへのTokenの設定 L:9 TOKEN=''の部分を変更