Developer's dream! All Entitlements, permits, and plans, ready to go! Just start building! 11,974 total Sq. Ft. Lot with approved city variance! Permit Set ready Construction Plans are for 5 units, each on their own parcel with own assessor ID. Each unit includes 2 Master Bedrooms both each own full master bathrooms plus an additional 1/2 bathroom on 1st floor. approx. 1,350 Sq Ft each with attached 2 car garage, patio, and balcony. Construction Plans have gone through plan check and are approved and ready for new owner to pull the permit. Transaction also includes completion of properties HOA budget, as well as origination of HOA and CC&R's. Both the HOA budget and HOA origination and CC&R's are currently in progress and seller will allow new buyer final input of both before finalizing during escrow. Existing Utilities on site for water, power, data connections. Construction plans and Entitlement are finalized and ready for new owner to pull permit and begin this fantastic project! Existing structures have already been demoed to grade level. Storage containers on site will be removed prior to close of escrow. SQL 觸發器-蔡海濤 1.)取水表取水毫升 ??? SELECT field INTO var ............ 不可加@ CREATE DEFINER = root@localhost TRIGGER fetch_updae_userWM AFTER UPDATE ON wr_fetch begin DECLARE Discount FLOAT(3,2); DECLARE UnitPrice FLOAT(4,2); DECLARE Summoney FLOAT(9,1); DECLARE OwnWater BIGINT(10); DECLARE ActOpenId VARCHAR(32); if NEW.paytype=1 and NEW.FlowMl<>0 then SELECT Water INTO OwnWater FROM wr_user WHERE openid = NEW.openid; if OwnWater>0 then set ActOpenId = NEW.openid; else SELECT openid INTO ActOpenId FROM wr_userbind WHERE BindOpenid = NEW.openid; end if; UPDATE wr_user SET Water=Water-NEW.FlowMl WHERE openid=ActOpenId; end if; if NEW.paytype=2 and NEW.FlowMl<>0 then SELECT Discount INTO @Discount FROM wr_user WHERE openid = NEW.openid; SELECT UnitPrice INTO @UnitPrice FROM wr_mach WHERE MachId = NEW.MachId; set Summoney = NEW.FlowMl/1000*@Discount*@UnitPrice; UPDATE wr_user SET Money=Money-Summoney WHERE openid=NEW.openid; end if; end ------------------------------------------------------------------------- old-backup begin DECLARE Discount float(3,2); DECLARE UnitPrice float(4,2); DECLARE Summoney float(9,1); if NEW.paytype=1 and NEW.FlowMl<>0 then UPDATE wr_user SET Water=Water-NEW.FlowMl WHERE openid=NEW.openid; end if; if NEW.paytype=2 and NEW.FlowMl<>0 then SELECT Discount INTO @Discount FROM wr_user WHERE openid = NEW.openid; SELECT UnitPrice INTO @UnitPrice FROM wr_mach WHERE MachId = NEW.MachId; set Summoney = NEW.FlowMl/1000*@Discount*@UnitPrice; UPDATE wr_user SET Money=Money-Summoney WHERE openid=NEW.openid; end if; end ------------------------------------------------------------------------- 2.)個人水庫錢包小於0校正歸0 CREATE DEFINER = root@localhost TRIGGER bank_wallet_zero_correct BEFORE UPDATE ON wr_user begin if NEW.Water<0 then set NEW.Water=0; end if; if NEW.Money<0 then set NEW.Money=0; end if; end DV-SQL 觸發器 1.)水箱空/滿 CREATE DEFINER = root@localhost TRIGGER mq_bank_empty_full AFTER INSERT ON mq_bank begin if NEW.BankStat='E' then UPDATE water_cht.wr_mach SET BankStock=0 WHERE MachNum=NEW.GateId; elseif NEW.BankStat='F' then UPDATE water_cht.wr_mach SET BankStock=6500 WHERE MachNum=NEW.GateId; end if; end 2.)水箱出水 1000/(7.5*60) ml/cnt CREATE DEFINER = root@localhost TRIGGER mq_bank_out AFTER UPDATE ON mq_flow begin if NEW.EndTmk<>'' then UPDATE water_cht.wr_mach SET BankStock=BankStock-round((NEW.Cnt*1000/(7.5*60)),0) WHERE MachNum=NEW.GateId; UPDATE water_cht.wr_fetch SET MqFlowId=NEW.MqFlowId,FlowMl=round((NEW.Cnt*1000/(7.5*60)),0) WHERE MachNum=NEW.GateId ORDER BY addtime DESC LIMIT 1; end if; end 3.)水箱進水 1000/(24*60) ml/cnt CREATE DEFINER = root@localhost TRIGGER mq_bank_in AFTER INSERT ON mq_flow_in begin if NEW.RepTmk<>'' then UPDATE water_cht.wr_mach SET BankStock=BankStock+round((NEW.Cnt*1000/(24*60)),0) WHERE MachNum=NEW.GateId; end if; end 4.)閥開關 CREATE DEFINER = root@localhost TRIGGER mq_valve_state AFTER INSERT ON mq_valve begin if NEW.ValveTmkStamp<>'' then UPDATE water_cht.wr_mach SET ValveStat=NEW.ValveStat,ValveTime=NEW.ValveTmkStamp WHERE MachNum=NEW.GateId; end if; if NEW.ValveStat='i' then UPDATE mq_flow SET EndTmk=NOW(),Cnt='0' WHERE GateId=NEW.GateId AND EndTmk IS NULL ; UPDATE water_cht.wr_fetch SET MqFlowId=0,FlowMl=0 WHERE MachNum=NEW.GateId AND MqFlowId IS NULL AND FlowMl IS NULL ; end if; end 5.)TDS CREATE DEFINER = root@localhost TRIGGER mq_tds_update AFTER INSERT ON mq_tds begin if NEW.TdsTmkStamp<>'' then UPDATE water_cht.wr_mach SET TdsIn=round((NEW.Tds0/30),0),TdsOut=round((NEW.Tds1/40),0),TdsTime=NEW.TdsTmkStamp WHERE MachNum=NEW.GateId; end if; end 6.)超時未取水 CREATE DEFINER = root@localhost TRIGGER mq_wait_timeout AFTER INSERT ON mq_flow begin if NEW.EndTmk<>'' AND NEW.Cnt=0 then UPDATE water_cht.wr_fetch SET MqFlowId=NEW.MqFlowId,FlowMl=0 WHERE MachNum=NEW.GateId ORDER BY addtime DESC LIMIT 1; end if; end FTP連98常中斷: 改FlashFXP 選項->參數選擇->連結->FTP->數據連結模式->主動模式(PORT) String.toInt()-> Long integers can be as large as 2147483647 and as low as -2147483648 Ko Command: Ko Pub -> Device topic R769000001 (R + area call + (10)gate id) 'c': // pipe N limit counter to stop: "c" + (10)gate id + (1)pipe id + (8)counter xxxxxxxx mosquitto_pub -h 119.29.34.98 -u user1 -P u1234 -t R769000001 -m cR769000001012345678 't': // require report 2 tds meter2: "t" + (10)gate id mosquitto_pub -h 119.29.34.98 -u user1 -P u1234 -t R769000001 -m tR769000001 's': // setup WaitFlowGap + NextUserGap + RepCnti: "s" + (10)gate id + (3)wait flow sec + (3)next user sec + (6)report income pure water counter mosquitto_pub -h 119.29.34.98 -u user1 -P u1234 -t R769000001 -m sR769000001020005002880 'v': // close valve pipe N : "v" + (10)gate id + (1)pipe id mosquitto_pub -h 119.29.34.98 -u user1 -P u1234 -t R769000001 -m vR7690000010 Device Report: Device Pub -> Ko topic R769 "i") # report start up "i" + (10)gate id mosquitto_pub -h 119.29.34.98 -t R769 -m iR769000001 "t") # report tds 0,1 "t" + (10)gate id + (5)tds 0 value + (5)tds 1 value mosquitto_pub -h 119.29.34.98 -t R769 -m tR7690000015555599999 "v") # report valve turn on/off "v" + (10)gate id + (1)pipe id + (1)"o"n / of"f" mosquitto_pub -h 119.29.34.98 -t R769 -m vR7690000010f "b") # report start flow "b" + (10)gate id + (1)pipe id mosquitto_pub -h 119.29.34.98 -t R769 -m bR7690000010 "e") # report stop flow "e" + (10)gate id + (1)pipe id + (8)counter xxxxxxxx mosquitto_pub -h 119.29.34.98 -t R769 -m eR769000001012345678 "z") # report zero flow wait flow expired "z" + (10)gate id + (1)pipe id mosquitto_pub -h 119.29.34.98 -t R769 -m zR7690000010 "I") # report income tap water counter "I" + (10)gate id + (8)counter xxxxxxxx mosquitto_pub -h 119.29.34.98 -t R769 -m IR76900000112345678 "E") # report water bank empty "E" + (10)gate id mosquitto_pub -h 119.29.34.98 -t R769 -m ER769000001 "F") # report water bank full "F" + (10)gate id mosquitto_pub -h 119.29.34.98 -t R769 -m FR769000001 Protel 99 SE E:\Program Files\Design Explorer 99 SE\Library\Sch 下先COPY要的ddb並rename 再到browse Sch->find->find now->找到新lib->Add to library list->ok DV電路板 JP3-D7-TDS0 JP4-D5-TDS1 JP5-24V JP6-D6-Valve0 JP7-D1-Meter0 JP8-D2-Meter income DV板SSID:R769000001 + 1353879297300 聯通卡托 192.168.100.1 admin+aa223344 AP PSW 1234567890 -> 1353879297 SSID 3G uFI_XXX -> Gate0001禁用廣播 新QQ云 119.29.34.98 SSH要先用個人帳號 ubuntu ; frevres0907 登入, 再打 su -l 切換成 root ; frevres0907 ps aux|grep -i 'bish-bosh' (查出執行 kill -9 第二排的id數字) /www/web/default/bish-bosh/bish-bosh --verbose 2 -- /www/web/default/bish-bosh/r01 & (背景執行後按 enter r01中不可以有output echo否則ssh斷線就退出停止) subscriber -> mosquitto_sub -h 119.29.34.98 -t R769000001 -u user1 -P u1234 KO command set valve counter -> mosquitto_pub -h 119.29.34.98 -t R769000001 -m cR769000001099999999 -u user1 -P u1234 KO command stop valve -> mosquitto_pub -h 119.29.34.98 -t R769000001 -m cR769000001000000000 -u user1 -P u1234 KO command get TDS -> mosquitto_pub -h 119.29.34.98 -t R769000001 -m tR769000001 -u user1 -P u1234 ID+PSW /etc/mosquitto/mosquitto.conf user1:u1234 user2:u2234 user3:u3234 看MQTT-log cat /var/log/mosquitto/mosquitto.log|perl -nwe's/^(\d+)/localtime($1)/e; print' run mosquitto /usr/local/sbin/mosquitto -c /etc/mosquitto/mosquitto.conf -d wcmp http://119.29.34.98:8080 -> http://119.29.34.98:33888 admin ; frevres0907, mysql root ; revres88 phpmyadmin http://119.29.34.98/pma_e07f4b62/ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ =============== TAPPURE-170917 ================================================================================================================================= D0 GPIO16 T1 純水TDS (外波形3P黑)-(下公XH2.54 白) D1 GPIO5 , SCL M1 熱水流量計(公SM-4P 藍)-(母SM-4P 藍)-(上公XH2.54 白) D2 GPIO4 , SDA M2 冰水流量計(公SM-4P 黑)-(母SM-4P 黑)-(上公XH2.54 黃) D3 GPIO0 , 10k Pull-up S1 熱水開關 (公SM-4P 紅)-(母SM-4P 紅)-(上公XH2.54 橙) (因為用3.3V-GPIO電位不穩,必須用 pin0 GPIO(high)-ground) D4 GPIO2 , 10k Pull-up, BUILTIN_LED S2 冰水開關 (公SM-4P 綠)-(母SM-4P 綠)-(上公XH2.54 綠) (因為用3.3V-GPIO電位不穩,必須用 pin2 GPIO(high)-ground) D5 GPIO14, SCK T2 進水TDS (內波形3P黑)-(下公XH2.54 藍)-(下公XH2.54 黃) D6 GPIO12, MISO V1 進水電磁閥(內繼電3P紅)-(下公XH2.54 橙) D7 GPIO13, MOSI V2 冰水電磁閥(外繼電3P紅)-(下公XH2.54 綠) D8 GPIO15, 10k Pull-down, SS H1 電熱繼電器(母SM-2P 紅)-(公SM-2P 紅)(因為pulldown,必須用大負載否則wemos開不了機) X X X 5V GN D4 D3 D2 D1 RX TX 紫 藍 綠 橙 黃 白 紅 黑 WEMOS 3V D8 D7 D6 D5 D0 A0 RS 紫 藍 綠 橙 黃 白 紅 黑 X X Wemos D1 mini D1 (上公XH2.54 白)-(母SM-4P 藍) D2 (上公XH2.54 黃)-(母SM-4P 黑) D3 (上公XH2.54 橙)-(母SM-4P 紅) D4 (上公XH2.54 綠)-(母SM-4P 綠) GN (上公XH2.54 藍)-(母SM-2P 黑) -(公SM-2P 黑) D0 (下公XH2.54 白)-(外波形3P黑) D5 (下公XH2.54 黃)-(內波形3P黑) D6 (下公XH2.54 橙)-(內繼電3P紅) D7 (下公XH2.54 綠)-(外繼電3P紅) D8 (下公XH2.54 藍)-(公SM-2P 紅) 3V (下公XH2.54 紫)-(母SM-2P 紅) 外波形模塊 GN (外波形3P黃)-(上公XH2.54 藍) D0 (外波形3P黑)-(下公XH2.54 白) 3V (外波形3P紅)-(下公XH2.54 紫) 內波形模塊 GN (內波形3P黃)-(上公XH2.54 藍) D5 (內波形3P黑)-(下公XH2.54 黃) 3V (內波形3P紅)-(下公XH2.54 紫) 內繼電模塊 GN (內繼電3P黃)-(上公XH2.54 藍) 3V (內繼電3P黑)-(下公XH2.54 紫) D6 (內繼電3P紅)-(下公XH2.54 橙) 外繼電模塊 GN (外繼電3P黃)-(上公XH2.54 藍) 3V (外繼電3P黑)-(下公XH2.54 紫) D7 (外繼電3P紅)-(下公XH2.54 綠) 61.220.188.84 -> 119.29.228.213 mosquitto -d (背景啟動 MQTT server ) subscriber -> mosquitto_sub -h 119.29.228.213 -t Ko001 publisher -> mosquitto_pub -h 119.29.228.213 -t Ko001 -m 12 ps aux|grep -i 'bish-bosh' (查出執行 kill -9 第二排的id數字) /www/web/default/bish-bosh/bish-bosh --verbose 2 -- /www/web/default/bish-bosh/q01 & (背景執行後按 enter q01中不可以有output echo否則ssh斷線就退出停止) Ko Command: Ko Pub -> Gate topic Ko001 1.) 8x limit counter to stop: "C" + gate id xxxxxxxx + counter 0~7 xxxxxxxx (8x8) mosquitto_pub -h 119.29.228.213 -t Ko001 -m CGate00010000000011111111222222223333333344444444555555556666666677777777 2.) 8x limit minisec to stop: "T" + gate id xxxxxxxx + timer 0~7 xxxxxxxxxxxx (12x8) mosquitto_pub -h 119.29.228.213 -t Ko001 -m TGate0001000000000000111111111111222222222222333333333333444444444444555555555555666666666666777777777777 3.) pipe N limit counter to stop: "c" + gate id xxxxxxxx + pipe id x + counter xxxxxxxx mosquitto_pub -h 119.29.228.213 -t Ko001 -m cGate0001712345678 4.) pipe N limit minisec to stop: "t" + gate id xxxxxxxx + pipe id x + timer xxxxxxxxxxxx mosquitto_pub -h 119.29.228.213 -t Ko001 -m tGate00017123456789012 Gate Report: Gate Pub -> Ko topic Dv001 2.) Gate Start Up: "i" + gate id xxxxxxxx + 9 digit 000000000 mosquitto_pub -h 119.29.228.213 -t Dv001 -m iGate0001000000000 2.) pipe N start flow counters: "b" + gate id xxxxxxxx + pipe id x + counter xxxxxxxx mosquitto_pub -h 119.29.228.213 -t Dv001 -m bGate0001712345678 3.) pipe N stop flow counters: "e" + gate id begin + pipe id x + counter xxxxxxxx mosquitto_pub -h 119.29.228.213 -t Dv001 -m eGate0001712345678 4.) pipe N now flow counters: "c" + gate id xxxxxxxx + pipe id x + counter xxxxxxxx mosquitto_pub -h 119.29.228.213 -t Dv001 -m cGate0001712345678 ======================= qq cloud MQTT ========================================= ps aux|grep -i 'bish-bosh' (查出執行 kill -9 第二排的id數字) /home/httpd/www/html/bish-bosh/bish-bosh --verbose 2 -- /home/httpd/www/html/bish-bosh/q01 & (背景執行後按 enter q01中不可以有output echo否則ssh斷線就退出停止) Ko Command: Ko Pub -> Gate topic Ko001 1.) 8x limit counter to stop: "C" + gate id xxxxxxxx + counter 0~7 xxxxxxxx (8x8) mosquitto_pub -h 61.220.188.84 -t Ko001 -m CGate00010000000011111111222222223333333344444444555555556666666677777777 2.) 8x limit minisec to stop: "T" + gate id xxxxxxxx + timer 0~7 xxxxxxxxxxxx (12x8) mosquitto_pub -h 61.220.188.84 -t Ko001 -m TGate0001000000000000111111111111222222222222333333333333444444444444555555555555666666666666777777777777 3.) pipe N limit counter to stop: "c" + gate id xxxxxxxx + pipe id x + counter xxxxxxxx mosquitto_pub -h 61.220.188.84 -t Ko001 -m cGate0001712345678 4.) pipe N limit minisec to stop: "t" + gate id xxxxxxxx + pipe id x + timer xxxxxxxxxxxx mosquitto_pub -h 61.220.188.84 -t Ko001 -m tGate00017123456789012 5.) pipe N limit counter + minisec to stop: "p" + gate id xxxxxxxx + pipe id x + counter xxxxxxxx + timer xxxxxxxxxxxx mosquitto_pub -h 61.220.188.84 -t Ko001 -m pGate0001712345678123456789012 Gate Report: Gate Pub -> Ko topic Dv001 2.) Gate Start Up: "i" + gate id xxxxxxxx + 9 digit 000000000 mosquitto_pub -h 61.220.188.84 -t Dv001 -m iGate0001000000000 2.) pipe N start flow counters: "b" + gate id xxxxxxxx + pipe id x + counter xxxxxxxx mosquitto_pub -h 61.220.188.84 -t Dv001 -m bGate0001712345678 3.) pipe N stop flow counters: "e" + gate id begin + pipe id x + counter xxxxxxxx mosquitto_pub -h 61.220.188.84 -t Dv001 -m eGate0001712345678 4.) pipe N now flow counters: "c" + gate id xxxxxxxx + pipe id x + counter xxxxxxxx mosquitto_pub -h 61.220.188.84 -t Dv001 -m cGate0001712345678 振荡电路参考这个,其中R2就是探针之间的水电阻 1、求出探针之间的水电阻 2、根据探针的间距、横截面面积获得L/S 3、根据上面两个值获得探针之间的电导率 4、根据电导率获得TDS TDS= (0.55~0.7)电导率 两根针间距是5.2mm,针长度是5.5mm,针个直径是1mm /home/httpd/www/html/bish-bosh/bish-bosh --verbose 2 -- /home/httpd/www/html/bish-bosh/q01 & (背景執行 不可以有output echo否則ssh中斷就退出) ps aux|grep -i 'bish-bosh' (查出執行 kill -9 第二排的id數字) cd /home/httpd/www/html/bish-bosh ./bish-bosh --verbose 2 -- q01 mosquitto_pub -h 61.220.188.84 -t Dv001 -m Gate0001700000001 (gate id xxxxxxxx + pipe 0-7 + counter xxxxxxxx -> 00000001/begin 00000000/end else/counter) change valve publisher(84) -> mosquitto_pub -h 61.220.188.84 -t Ko001 -m Gate000100000010 (GateId + 8 valve on/off) 604,523,637 1,2,3 760 600,527,617 1,2,3 800 607,457,651 1,2,3 800,710,820 520,500,513 2,3,1 740 708,682,692 3,1,2 1050 1766 1544 1234 1,2,3 700 1514-870 1532-860 joe /usr/bin/dv01 chmod 777 /usr/bin/dv01 #!/bin/bash mxi=60*5 for (( i = 0; i < $mxi; i++ )); do dat=$(date "+%Y%m%d%H%M%S") echo $dat mosquitto_pub -h 61.220.188.84 -t Gate0001 -m $dat $(php '/home/httpd/www/html/mq.php') sleep 1 done exit 0 方 主板 rm /home/httpd/www/html/dv02 subscriber(84) -> mosquitto_sub -h 61.220.188.84 -t Gate0001 > /home/httpd/www/html/dv02 change valve publisher(84) -> mosquitto_pub -h 61.220.188.84 -t Master -m Gate00010000111 (GateId + 8 valve on/off) timer(84) -> /usr/bin/dv01 -> (mosquitto_pub -h 61.220.188.84 -t Gate0001 -m 20170720202311 + php '/home/httpd/www/html/mq.php') 電磁閥7 流量計7(電源旁) x-publisher(84) -> mosquitto_pub -h 61.220.188.84 -t Master -m 11118 (valve 3 ON 11117 OFF) systemctl restart mosquitto.service RSSI Wifi 訊號 0 - (-55)dbm 满格(4格)信号 (-55) - (-70)dbm 3格信号 (-70) - (-85)dbm 2格信号 (-85) - (-100)dbm 1格信号 =========== C language ===================== char *xxx = ""; -> 一定要先給值後才可以用array去改值 C++ string xxx.length() 字符串長度 char *xxx 沒有預留空間, char xxx[100] 才有 char[x+1] 至少要比字串多1,才不會影嚮下一個未串 ""->string ''->char ============================================ http://61.220.188.84/dv-m/mq-1.php -->從KO送DATA去wemos http://61.220.188.84/dv-m/mq-2.php -->查KO的SQL最後10筆 wemos傳給KO的DATA david@NB3 MINGW64 /f/WX-Water/Arduino/hardware $ cd esp8266com david@NB3 MINGW64 /f/WX-Water/Arduino/hardware/esp8266com $ git clone https://github.com/wemos/Arduino_D1.git esp8266 Cloning into 'esp8266'... remote: Counting objects: 13742, done. Receiving objects: 18% (2606/13742), 1.71 MiB | 8.00 KiB/s s david@NB3 MINGW64 /f/WX-Water/Arduino/hardware/esp8266com $ cd esp8266/tools david@NB3 MINGW64 /f/WX-Water/Arduino/hardware/esp8266com/esp8266/tools (master) $ python get.py Platform: i686-mingw32 Downloading esptool-0.4.9-win32.zip Done Extracting dist/esptool-0.4.9-win32.zip Renaming esptool-0.4.9-win32/ to esptool Downloading win32-xtensa-lx106-elf-gb404fb9-2.tar.gz Done Extracting dist/win32-xtensa-lx106-elf-gb404fb9-2.tar.gz Downloading mkspiffs-0.1.2-windows.zip Done Extracting dist/mkspiffs-0.1.2-windows.zip Renaming mkspiffs-0.1.2-windows/ to mkspiffs david@NB3 MINGW64 /f/WX-Water/Arduino/hardware/esp8266com/esp8266/tools (master) $ wemos MQTT broker(84) -> mosquitto -v subscriber(103-esp) -> 固定send outTopic + 收到callback inTopic publisher(84) -> mosquitto_pub -h 61.220.188.84 -t inTopic -m 111111111111 upload speed 115200 COM5 wemos D1 & mini AVRISP mkII D1接GND + RST接GND Wemos Installing Hardware package cd /f/WX-Water/Arduino/hardware/esp8266com git clone https://github.com/wemos/Arduino_D1.git esp8266 cd esp8266/tools python get.py MQTT broker(84) -> mosquitto -v subscriber(104-pi) -> mosquitto_sub -h 61.220.188.84 -t dv01 publisher(84) -> mosquitto_pub -h 61.220.188.84 -t dv01 -m 12 --------------------- raspberry pi ------------------------------------------- 控制gpio18亮燈 (104-pi) -> sudo python simple.py (84) -> mosquitto_pub -h 61.220.188.84 -t dv01 -m "{\"pin\":18,\"value\":1}" apache-php 加權限才可執行shell sudo visudo 加一行 www-data ALL=(ALL:ALL) NOPASSWD:ALL php 必須用 sudo 去執行shell bash 安裝 PHP + APACHE apt-get install apache2 php5 libapache2-mod-php5 安裝 vsftpd apt-get install vsftpd ftp 修改匿名設定才能上傳檔案 joe /etc/vsftpd.conf write_enable=YES anonymous_enable=YES anon_upload_enable=YES anon_mkdir_write_enable=YES ftp 修改上傳檔案欋限自動變為666 (777?) local_umask=000 讀取 TDS 模塊 minicom -H -S /usr/local/bin/dv02 -C /usr/local/bin/dv03 dv02----------------- #!/bin/sh print "\n" send \0374\0374\0374 dv03----------------- fd 5e 00 fd fd fe 24 01 fe fe raspberry pi 接 USB-串口 接 TDS 產生Hex的 FD FD FD 檔案 > dv01 echo -e "\0375\0375\0375" > dv01 進入minicom -H 顯示十六進位 ctrl-A -> S -> ascii -> /usr/local/bin/dv01 上傳檔案 dv01 當作發送 FD FD FD TDS 雙路 9600 8N1 停止位 1 TX-RX,RX-TX 交換接 TDS 二直突條正面4P孔向上,左->右,接wemos GRN-RX-TX-5V 发送FC FC FC 返回 FD TDSL1 TDSH1 FD FD FE TDSL2 TDSH2 FE FE IC盒探針線向上 右1左2 TDS 單路 9600 8N1 停止位 1 TX-TX,RX-RX 對接 發送 FD FD FD 返回 FD 低位 高位 FD FD ssh -NfR 8080:192.168.100.104:22 root@61.220.188.84 先 apt-get update 再 apt-get install minicom 工作文件區 /usr/local/bin/ ...... gpio18 設定方式 echo 18 > /sys/class/gpio/export echo out > /sys/class/gpio/gpio18/direction echo 1 > /sys/class/gpio/gpio18/value 取消設定 echo 18 > /sys/class/gpio/unexport apt-get install joe apt-get remove xxx pi + raspberry (已改) -> frevres0907 -> su + frevres0907 ====================================== 20170531 New WX Water ===================================================== https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential&appid=wx7fe291f76cf93354&secret=d8fd277920bba0cfddc1fd8f5eacf937 {"access_token":"y-RkXsDVDdxRaMTBybYL8hj5YREkUJmG6hLkGM4E_JkcNmq1pClejE5gF9mTJrmI5qc4Jf2elQf2aD7OBmgx22sWoaZrtArDxAa3A6RWQa8","expires_in":7200} 微信公眾平台 lee@dacomputing.com aa2233zz AppID(应用ID) wx7fe291f76cf93354 AppSecret(应用密钥) d8fd277920bba0cfddc1fd8f5eacf937 weixin.qq.com 101.227.131.102, 101.226.76.175 BIOS 中的南橋USB->8 ports, USB2.0->disable 才不會常常抓不到USB0 BIOS設少8小時->如果linux多8小時 為了確定 wifi AP 是否存在用 ping wifi AP 192.168.188.253 開機增加/etc/sysconfig/network-scripts/ifcfg-eth0:4 --> 192.168.188.100 date -s 2015-01-15 date -s 09:41:30 hwclock -w 把date 寫入 BIOS 點煙器的黃線在中間藍靠主板咖啡靠面板 如果timer_3g卡死,flag-3g-busy將一直存在 ps -ef 列出defunct 僵屍 kill -9 xxxx 進程號 /usr/bin/autossh -M 5678 -NfR 8080:192.168.100.99:22 root@61.220.188.84 ipad-saferi