Cov txheej txheem:
- Kauj Ruam 1: Daim Duab Circuit Court thiab Kev Tiv Thaiv Circuit
- Kauj Ruam 2: Kev tsim kho
- Kauj Ruam 3: Kev teeb tsa WiFi Shield
- Kauj Ruam 4: Ntxiv Qhov Taw Qhia Leds (Tsis teb los tau)
- Kauj Ruam 5: Teeb tsa Kev teeb tsa los ntawm Ua Hauv Webpage
- Kauj Ruam 6: Pab - Tsis Muaj Cov Ntaub Ntawv
Video: Pheej Yig NMEA/AIS Hub - RS232 rau Wifi Choj rau Onboard Siv: 6 Kauj Ruam
2024 Tus sau: John Day | [email protected]. Kawg hloov kho: 2024-01-30 09:24
Hloov Kho Lub Ib Hlis 9, 2021 - Ntxiv TCP txuas ntxiv thiab rov siv qhov kev sib txuas zaum kawg yog tias muaj cov neeg siv txuas ntau dua Hloov kho zaum 13 Lub Kaum Ob Hlis 2020 - Ntxiv tsis muaj teeb tsa tus qauv ntawm cov cai rau nkoj nrog cov routers uas twb muaj lawm.
Taw qhia
Qhov NMEA / AIS RS232 rau WiFi choj yog ua raws li ESP8266-01 WiFi Shield. AIS yog lub tshuab ntsuas tus kheej tsis siv neeg los qhia txoj haujlwm ntawm cov nkoj nyob ze. NMEA 0183 yog National Marine Electronics Association tus qauv siv rau GPS cov lus.
RS232 rau WiFi choj tau hloov pauv los ntawm ESP8266-01 WiFi Shield kom siv tau los ntawm roj teeb 12V thiab lees txais RS232 cov tswv yim (+/- 15V) thiab tsim lub network hauv zos uas tshaj tawm cov ntaub ntawv ntawm TCP thiab UDP. Nws tau tsim kho ua ke nrog Jo uas xav ua kom pheej yig thiab yooj yim tus kheej muaj lub network hauv zej zog kom nkag tau nws AIS cov ntaub ntawv los ntawm txhua qhov chaw ntawm nws lub nkoj. Qhov kev ua tiav no tsim ib qho Access Point (Router) thiab teeb tsa TCP server rau txog 4 kev sib txuas thiab tseem tshaj tawm cov ntaub ntawv ntawm pab pawg tshaj tawm UDP. Lub vev xaib teeb tsa tau muab los teeb tsa tus lej TCP thiab UDP, WiFi Txawj siv zog thiab nkag mus RS232 baud tus nqi. Tsis zoo li WiFi Shield, tsis muaj lub pob teeb tsa, yog li ib zaug tsim cov qauv tuaj yeem ua tiav kaw cov dej nruj. Kev tiv thaiv kab hluav taws xob suav nrog txhawm rau ua kom lub cuab yeej no muaj zog tiv thaiv kev xaim hluav taws xob. Thaum tsim nrog NMEA (GPS) thiab AIS hauv siab, tus qauv yuav ua haujlwm ib qho RS232 cov ntaub ntawv nrog tus nqi baud ntawm 4800 thiab 38400 (thiab lwm tus los ntawm kev kho cov duab Arduino).
Nta
- Siv qhov pheej yig thiab npaj tau ESP8266-01 tus qauv:- Lwm yam ESP8266 cov qauv kuj tseem tuaj yeem siv tau
- Muaj zog:- Lub Circuit Court muaj tus lej tiv thaiv tsim los tiv thaiv kev ua yuam kev thaum txuas xov.
- Kev Siv Hluav Taws Xob:- DC-DC hloov pauv lub zog siv hluav taws xob ua haujlwm tau zoo los ntawm lub roj teeb 12V thiab WiFi Tx hwj chim tuaj yeem txo kom txuag hluav taws xob ntau dua.
- Yooj yim rau siv:- Tsuas yog txuas 5.5V rau 12V cov khoom siv thiab kab RS232 TX thiab tom qab ntawd koom nrog koj qhov kev lees paub rau lub network thiab txuas rau TCP lossis UDP kev pabcuam kom tau txais cov ntaub ntawv. Yuav tuaj yeem hloov pauv sai rau ib qho khoom seem yog tias chav tsev tsis ua haujlwm
- Yooj yim rau teeb tsa:- Tsis muaj qhov rov tsim kho qhov tsim nyog, tsis muaj hom kev teeb tsa tshwj xeeb. Ib nplooj ntawv teeb tsa tau muab uas tso cai rau koj teeb tsa RS232 baud tus nqi thiab WiFi xa lub zog thiab tus lej chaw nres nkoj rau TCP thiab UDP servers
-
Yeem Tsis muaj teeb tsa version:- Tseem muaj lwm qhov kos duab qhov twg txhua qhov teeb tsa tau npaj ua ntej. Qhov no yog rau cov xwm txheej uas twb muaj lub network hauv zos khiav nrog nws tus kheej router (Access Point)
Khoom siv:
Qhov ESP8266-01 RS232 rau WiFi Choj xav tau cov hauv qab no, lossis zoo sib xws. Tus nqi qhia ntawm no yog thaum Lub Yim Hli 2020 thiab tsis suav cov nqi thauj khoom thiab qee yam ntawm cov ntaub yas:
WiFi Module ESP8266-01-~ US $ 1.50 online (coj koj txoj hauv kev) LOS YOG kom ntseeg tau cov khoom lag luam SparkFun ESP8266-01-US $ 6.95
MPM3610 3.3V Buck Converter Adafruit-US $ 5.95 5V rau 21V cov tswv yim, lossis DC-DC 3A Buck Nqes-nqis Hwj chim Mov Module online Aliexpress ~ US2.00
10-pin header Element14-US $ 0.40 (lossis 28 Pin Header Terminal Sawb los ntawm Jaycar AU $ 0.95)
1 tawm 1N5711 Schottky Diode Digikey US $ 1.15 (lossis Jaycar AU $ 1.60)
2 tawm 1N4001 Diodes SparkFun US $ 0.30 (lossis 1N4004 Jaycar AU $ 1.00) Txhua 1A 50V lossis siab dua diode yuav ua, piv txwv li 1N4001, 1N4002, 1N4003, 1N4004
1 tawm 2N3904 NPN transistor SparkFun US $ 0.50 (lossis Jaycar AU $ 0.75 txhua lub hom phiaj NPN nrog Vce> 40V, Hfe> 50 ntawm 1mA, Ic> 50mA xws li BC546, BC547, BC548, BC549, BC550, 2N2222
6 x 3K3 resistors xws li 3K3 resistors - Digikey - US $ 0.60 (lossis 3K3ohm 1/2 Watt 1% Hlau Zaj Duab Xis Resistors - Pk.8 los ntawm Jaycar AU $ 0.85)
3 tawm 330R resistor Element14 US $ 0.10 (lossis 330ohm 1/2 Watt 1% Hlau Zaj Duab Xis Resistors - Pk.8 los ntawm Jaycar AU $ 0.85)
1 tawm 10K resistor Element14 US $ 0.05 (lossis 10k Ohm 0.5 Watt Hlau Zaj Duab Xis Resistors - Pob ntawm 8 los ntawm Jaycar AU $ 0.85)
Vero board (txuas thiab tsheb npav) Jaycar HP9556 LOS YOG (tooj liab tooj liab) (kab tooj liab) piv txwv li Jaycar HP9540 ~ AU $ 5.50
thiab ib rooj plaub yas thiab xaim txuas.
Tus Nqi Tag Nrho ~ US $ 9.90 + kev xa khoom thiab cov ntaub yas (raws li lub Yim Hli 2020) siv Aliexpress ESP8266-01 thiab DC-DC module LOSSIS ~ US $ 19.30 siv Sparkfun ESP8266-01 module thiab Adafruit DC-DC buck converter. Pheej yig txaus los ua ob peb yam khoom ntxiv.
Txhawm rau ua haujlwm RS232 rau WiFi Choj, koj kuj xav tau USB rau Serial cable. Nov yog SparkFun's USB rau TTL Serial Cable (US $ 10.95) tau siv vim tias nws tau sau npe zoo kawg thiab muaj kev txhawb nqa tsav tsheb rau ntau yam ntawm OS suav nrog cov phiaj xwm kab, tus nqi tsuas yog ib qho RS232 rau WiFi Choj yog ~ US $ 20 txog US $ 24 (ntxiv rau kev xa khoom thiab rooj plaub).
Kauj Ruam 1: Daim Duab Circuit Court thiab Kev Tiv Thaiv Circuit
Saum toj no yog daim duab qhia chaw rau RS232 rau WiFi Choj (pdf version). Qhov no tau hloov pauv los ntawm ESP8266-01 Wifi Shield thiab hloov kho kom tau txais RS232 thiab 5V txog 12V (roj teeb) khoom siv. DC rau DC hloov pauv muab lub zog ua haujlwm tau zoo los ntawm 12V roj teeb rau hmo ntuj siv thaum tsis muaj lub hnub ci thiab lub zog siv tau zoo.
Muaj ntau qhov kev tiv thaiv hluav taws xob tau tsim rau hauv Circuit Court. Cov kev sib txuas ntawm sab laug ntawm lub Circuit Court tsuas yog siv thaum tsim kho los kho qhov program/debug lub tsev. 330R resistors R6 thiab R7 tiv thaiv luv luv TX tso tawm rau TX tso tawm thaum ua haujlwm/debugging. Thaum lub cajmeem koj txuas TX rau RX thiab RX rau TX. Qhov debug TX tso tawm yuav tsum txuas nrog RX UART 3v3 cov tswv yim kom pom qhov debug tso zis (saib cov lus hauv ESP8266_NMEA_BRIDGE.ino kos duab).
Cov kev sib txuas ntawm sab xis ntawm lub Circuit Court tau siv los txuas chav ua tiav rau lub zog siv thiab NMEA/AIS RS232 qhov chaw. Cov no yog cov kev sib txuas nkaus xwb uas xav tau kom nkag mus tau thaum lub tsev tau tsim. Khaws cov kev sib txuas ua khub.
2N3904 muab kev hloov pauv thiab qib hloov pauv los ntawm RS232 +/- 15V teeb liab mus rau TTL UART cov tswv yim rau ESP2866. Qhov rov qab hluav taws xob nruab nrab ntawm Emitter thiab Base ntawm 2N3904 tau hais kom tiv taus yam tsawg kawg 6V. D4 txwv qhov rov qab Emitter Base qhov hluav taws xob kom tsawg dua 1V thaum RS232 cov tswv yim yog -15V.
Thaum kawg, "RS-232 tus tsav tsheb thiab tus txais yuav tsum tuaj yeem tiv taus qhov luv luv luv luv mus rau hauv av" (RS232 wikipedia) yog li yog koj yuam kev txuas RS232 kab mus rau Lub Hwj Huam Muab Khoom Siv, nws yuav tsum tsis txhob puas NMEA/AIS ntaus ntawv.
Hwj chim Mov
Lub diode D1 tiv thaiv kev thim rov qab tau siv rau DC-DC hloov pauv yog tias koj tshwm sim los pauv qhov +V thiab GND kev sib txuas thaum txuas xov. D1 muaj qhov xau me me tam sim no. D2 muab txoj hauv kev qis qis rau qhov xau tam sim no kom ua rau qhov rov qab hloov pauv ntawm DC -DC hloov pauv hauv qab -0.3V. 330R resistor (R10) hauv kab RS232 GND muab kev tiv thaiv tiv thaiv kom luv lub roj teeb mus rau hauv av yog tias lub roj teeb +cov hlau lead txuas nrog lub Rooj Tswjhwm Saib Cov Khoom Siv Hluav Taws Xob GND xaim thaum RS232 GND txuas nrog.
DC-DC hloov pauv tau ntsuas txog li 21V kev siv ua haujlwm yog li nws haum rau lub roj teeb 12V thaum nws raug hloov pauv. Lub roj teeb uas them tag nrho tuaj yeem nce txog ~ 14.8V thiab lub roj teeb them tuaj yeem siab dua, 16V lossis ntau dua. Qhov ntsuas 21V ntawm DC-DC hloov pauv tau ntsuas los daws qhov no. Qhov xwm txheej rov qab sib txuas sib cuam tshuam (nruab nrab hmo ntuj hauv huab cua ntxhib) tau tiv thaiv. Qhov siab tshaj plaws qhov siab tshaj plaws rau qhov hloov pauv tswv yim yog 28V yog li tuaj yeem tswj tau muaj lub teeb liab RS232 txuas nrog nws. RS232 qhov hluav taws xob tau teev tseg kom tsawg dua +/- 25V.
Yog tias koj yuam kev txuas cov hlau lead los ntawm koj lub zog xa mus rau RS232 TX/GND kev sib txuas (ib qho pauv lossis tsis yog), 10K thiab 330R cov neeg tiv thaiv yuav tiv thaiv tsis pub luv zog.
Hauv cov ntsiab lus, kev tiv thaiv hluav taws xob tiv thaiv kev sib pauv lub zog thiab RS232 ua thiab txuas cov xov hlau los ntawm cov khub hauv ob qho tib si. Kev sib xyaw cov xov hlau, ib qho los ntawm txhua khub, tsis muaj kev tiv thaiv hauv txhua qhov kev sib txuas yog li ua kom RS232 thiab lub hwj chim ua khub thiab txuas lawv ua khub.
Qhov nruab nrab tam sim no siv los ntawm pawg thawj coj yog kwv yees li 100mA (nyob ntawm WiFi xa lub zog thiab cov ntaub ntawv). Yog hais tias ib qho yooj yim linear regulator tau siv los txhawb lub rooj tsavxwm los ntawm 12V roj teeb lub zog siv yuav yog 12V x 100mA = 1.2W lossis 1.2Ahrs dhau 12 hmo. Siv DC rau DC hloov pauv, uas ~ 70% ua tau zoo, txo qhov kev thauj khoom no mus rau 0.47W lossis 0.47Ahrs dhau 12 teev hmo ntuj.
Kauj Ruam 2: Kev tsim kho
Kuv tsim lub tsev no siv ib qho me me ntawm vero board nrog txuas thiab lub npav loj zog (pdf version). Nov yog cov lus pom saum toj thiab hauv qab ntawm pawg thawj coj ua tiav. Xyuas kom koj ua tib zoo xyuas cov thaiv thaum koj ua tiav. Nws yooj yim rau xaim mus rau tus lej tsis raug thaum koj tig thiab xaim los ntawm hauv qab.
Kauj Ruam 3: Kev teeb tsa WiFi Shield
Txhua RS232 rau WiFi choj yuav tsum tau ua haujlwm ib zaug, tsuas yog, thiab tsis muaj dua. Lub vev xaib built-in muab kev nkag mus rau cov kev teeb tsa muaj.
Txhim kho ESP8266 kev txhawb nqa
Txhawm rau txhawm rau txhim kho daim ntawv pov thawj ua raws cov lus qhia tau muab rau ntawm https://github.com/esp8266/Arduino nyob rau hauv Kev Txhim Kho Nrog Cov Thawj Tswj. Thaum qhib Tus Thawj Saib Xyuas Haujlwm los ntawm Cov Cuab Yeej → Pawg ntawv qhia zaub mov thiab xaiv Hom Pabcuam thiab teeb tsa lub esp8266 platform. Txoj haujlwm no tau suav sau siv ESP8266 version 2.6.3. Cov ntawv tom qab yuav zoo dua tab sis tej zaum yuav muaj lawv tus kheej kab vim lub platform tab tom hloov pauv sai.
Kaw thiab rov qhib Arduino IDE thiab tam sim no koj tuaj yeem xaiv "Generic ESP8266 Module" los ntawm Tools → Board menu.
Txhim kho cov tsev qiv ntawv txhawb nqa
Koj kuj yuav tsum tau teeb tsa, los ntawm https://www.forward.com.au/pfod/pfodParserLibraries/index.html, hloov tshiab kawg ntawm pfodESP8266BufferedClient library (rau pfodESP8266Utils.h thiab pfodESP8266BufferedClient.h) thiab millisDelay library (rau millisDelay. h).
Rub tawm cov ntawv zip no rau koj lub khoos phis tawj, txav nws mus rau koj lub khoos phis tawj lossis qee lwm daim nplaub tshev uas koj tuaj yeem nrhiav tau yooj yim thiab tom qab ntawd siv Arduino IDE cov ntawv qhia zaub mov xaiv Sketch → Import Library → Ntxiv Library rau nruab lawv. Koj kuj yuav tsum teeb tsa lub tsev qiv ntawv SafeString. Lub tsev qiv ntawv SafeString muaj los ntawm Arduino tus thawj tswj hwm lub tsev qiv ntawv lossis koj tuaj yeem rub tawm SafeString.zip cov ntaub ntawv ncaj qha rau kev teeb tsa kev teeb tsa los ntawm Sketch → Ntshuam Lub Tsev Qub → Ntxiv Lub Tsev Qiv Ntawv
Nres thiab rov pib dua Arduino IDE thiab hauv File-> Piv txwv tam sim no koj yuav tsum pom pfodESP8266BufferedClient thiab SafeString.
Programming Pawg Thawj Coj
Txhawm rau teeb tsa pawg thawj coj, teeb tsa lub rooj tsavxwm rau hauv hom phiaj ua haujlwm los ntawm kev txuas luv (hauv qab sab laug). Tom qab ntawd txuas lub USB rau TTL UART serial cable
Nco tseg ua tib zoo txuas tsuas yog 3V3 TX/RX ua rau sab laug sab txuas nrog siv 3V3 TX/RX los ntawm Sparkfun USB rau TTL Serial Cable Cov kab txuas sib txuas yog RX (Daj), TX (Txiv kab ntxwv), VCC (5V) (Liab), thiab GND (Dub). Nco tseg lub daj (RX) cable txuas nrog TX tus pin ntawm lub rooj tsavxwm thiab Txiv kab ntxwv (TX) cable txuas nrog RX tus pin ntawm lub rooj tsavxwm. Cov Dub (GND) cable txuas nrog GND rau TX/RX tus pin
Nco tseg: Zoo li muaj ob lub qauv ntawm cov kab no. Cov ntawv qub muaj 5V Vcc thiab RX (Brown), TX (Tan-like/Peach), VCC (Liab), thiab GND (Dub), hauv txhua qhov xwm txheej VCC cov hlau lead tsis siv ntawm no. Kuj tseem muaj cov lus hais tias TX thiab RX xaim tau thim rov qab hauv qee kis. Yog tias Arduino IDE tsis tuaj yeem teeb tsa lub rooj tsavxwm, sim hloov pauv TX/RX cables. 330R tiv thaiv TX-TX luv.
Hwj chim lub rooj tsavxwm los ntawm 6V txog 12V 500mA lossis cov khoom loj lossis roj teeb. Txuas Cov Khoom Siv Hluav Taws Xob -Ve (GND) ua ntej kom lub zog hluav taws xob tam sim no tsis sim ntws rov qab los ntawm USB txuas. Ua ntej tshaj yog siv cais (ntab) 6V rau 12V muab lossis roj teeb. Nco tseg Aliexpress Aliexpress DC-DC cov qauv xav tau tsawg kawg yog 6.5V muab khoom.
Tom qab ntawd ntsaws rau hauv USB cable rau koj lub computer. Xaiv nws qhov chaw nres nkoj COM hauv Cov Cuab Yeej → Chaw nres nkoj ntawv qhia zaub mov. Tawm ntawm CPU Zaus, Flash Loj thiab Tshaj Tawm ntawm lawv qhov kev teeb tsa ua ntej.
Txheeb daim duab thiab koj cov xov hlau. Kuj pom ESP8266 Cov Lus Qhia Ua Haujlwm (espcomm tsis ua tiav) Sau ESP8266_NMEA_BRIDGE.ino kos duab. Tom qab ntawd xaiv Cov Ntaub Ntawv → Upload lossis siv khawm xub xub los ua ke thiab rub tawm cov program. Ob daim ntawv tau muab tso tawm. Yog tias koj tau txais cov lus yuam kev xa mus xyuas koj lub xov tooj sib txuas tau txuas rau hauv tus pin raug thiab sim dua.
Thaum cov phiaj xwm ua tiav, tshem tawm txoj haujlwm ua haujlwm luv qhov txuas thiab cov phiaj xwm TX/RX kev sib txuas thiab tom qab ntawd tig lub zog tso tawm thiab rov pib dua lub rooj tsavxwm hauv nws qhov qub.
Txuas lub NMEA/AIS ntaus ntawv.
Tsis muaj Configuration Version
Muaj lwm qhov qauv ntawm daim duab no, ESP8266_NMEA_BRIDGE_noCfg.ino, uas txhua qhov kev teeb tsa tau npaj ua ntej hauv kab kos. Hauv qhov no NMEA hub txuas rau lub router uas twb muaj lawm (nkag mus rau qhov chaw) txhawm rau ua cov ntaub ntawv muaj rau hauv lub network.
Kev teeb tsa yog txhua yam nyob rau sab saum toj ntawm ESP8266_NMEA_BRIDGE_noCfg.ino cov ntaub ntawv.
// ================= HARD CODED CONFIG ==================
const char ssid = "yourRouterSSID"; // teeb tsa koj lub network SSID ntawm no yog tus lej cim tus lej = "yourRouterPassword"; // teeb tsa koj lub network tus password ntawm no IPAddress zoo li qub IP (10, 1, 1, 190); // teeb tsa NMEA hub zoo li qub IP ntawm no. NCO TSEG, ntawm tus lej // xyuas kom tsis muaj lwm lub cuab yeej ua haujlwm nrog tib tus IP no thiab tus IP nyob hauv koj tus router IP ntau // ntau tus router IP ntau yog 10.1.1.2 txog 10.1.1.254 // 192.168.1.2 txog 192.168.254.254 thiab // 172.16.1.2 txog 172.31.254.254 // lub router feem ntau yog 10.1.1.1 lossis 192.168.1.1 lossis 172.16.1.1 nyob ntawm nws qhov IPAddress udpBroadcaseIP (230, 1, 1, 1); // teeb tsa UDP tshaj tawm IP ntawm no. NCO TSEG, ntawm cov lej. Tus IP no ywj siab ntawm tus router ntau yam tsis hloov pauv uint16_t tcpPortNo = 10110; // teeb tsa NMEA tcp server chaw nres nkoj Tsis nyob ntawm no const uint16_t udpPortNo = 10110; // set NMEA UDP broadcast port No No const const unsigned int txPower = 10; // TX lub zog hauv thaj tsam 0 txog 82; const unsigned int GPS_BAUD_RATE = 4800; // Serial baud tus nqi ntawm koj GPS module // ================= Kawg ntawm qhov nyuaj CODED CONFIG ==============
Kauj Ruam 4: Ntxiv Qhov Taw Qhia Leds (Tsis teb los tau)
Kuv tus kws pab tswv yim caij nkoj ntawm txoj haujlwm no, Jo, hais kom nce lub Liab Lub Hwj Chim coj thiab Cov Ntaub Ntawv Ntsuab coj los ntawm rooj plaub los qhia tias txhua yam tau ua tiav. Nov yog qhov hloov pauv Circuit nrog ob lub leds ntxiv. (pdf verison) Cov
R9 thiab R11 teeb tsa Led tam sim no thiab yog li qhov ci ci. Siv qhov loj tshaj plaws tiv thaiv uas ua rau cov leds tseem pom. Lawv yuav nyuaj rau pom hauv lub hnub ci ncaj qha lossis hauv lub tsev ci ci, yog li txhim kho chav nyob rau hauv qhov tsaus ntuj kom pom kev siab tshaj. Jaycar muaj qhov tsim nyog bezel coj Liab thiab Ntsuab (~ AU $ 2.75) thiab Sparkfun muaj qee qhov ci ntsa iab Liab thiab Ntsuab (US $ 1.70) tab sis yuav luag txhua qhov liab thiab ntsuab coj yuav ua.
Kauj Ruam 5: Teeb tsa Kev teeb tsa los ntawm Ua Hauv Webpage
Thaum koj txhawb lub rooj tsavxwm tom qab ua haujlwm, nws yuav cia li tsim lub network hauv zos. Ntawd yog nws yuav dhau los ua Lub Chaw Nkag Mus Hauv Ib Cheeb Tsam (router). Lub npe network yuav pib nrog NMEA_ ua raws 12 tus lej hex tus lej tshwj xeeb rau txhua lub rooj tsavxwm, piv txwv li. NMEA_18FE34A00239 Tus password rau lub network hauv ib txwm yog NMEA_WiFi_Bridge. Yog tias koj xav tau kev sib pauv chav nyob hauv hiav txwv, siv lub zog qub, teeb tsa qhov seem thiab tom qab ntawd nrhiav NMEA_ tshiab….. network thiab siv tus password NMEA_WiFi_Bridge koom nrog nws.
Yog tias koj tsis tuaj yeem pom lub network, txav mus ze rau ntawm pawg thawj coj saib xyuas thiab xyuas tias koj muaj lub xov tooj hluav taws xob txuas nrog kom raug. Yuav tsum muaj lub teeb xiav yog ESP8266-01 pawg thawj coj.
Thaum koj tau koom nrog lub network nrog koj lub khoos phis tawj, lossis xov tooj ntawm tes, koj tuaj yeem qhib lub vev xaib teeb tsa ntawm https://10.1.1.1 (Nco tseg: ntaus hauv https://10.1.1.1, yog tias koj tsuas yog ntaus hauv 10.1.1.1 koj tej zaum yuav tau txais Google sim tshawb rau nws thiab ua tsis tiav vim tias koj tsis txuas nrog internet)
Nplooj ntawv teeb tsa cia koj teeb tsa WiFi xa hluav taws xob. Cov lej qis dua rau lub zog tsawg thiab ntau yam thiab kev siv tam sim no. Koj tseem tuaj yeem hloov tus lej chaw nres nkoj rau kev sib txuas TCP thiab UDP. Lub neej 10110 yog qhov chaw nres nkoj xaiv rau NMEA kev sib txuas, tab sis koj tuaj yeem xaiv koj tus kheej yog tias koj xav tau. Tus lej IP tau tsau. Thaum kawg koj tuaj yeem teev tus nqi baud kom phim koj li NMEA/AIS qhov chaw. 4800 baud yog tus qauv baud tus nqi rau NMEA. Thaum 34800 baud yog tus qauv baud tus nqi rau AIS.
Thaum koj tau xaiv qhov koj xaiv, nyem Xa thiab nplooj ntawv ntsiab lus ntawm cov kev hloov pauv uas tau khaws cia tau tshwm.
Yog tias cov no tsis raug yog siv lub browser rov qab khawm rov qab thiab kho lawv. Txhawm rau thov hloov pauv lub rooj tsav xwm yuav tsum tau rov pib dua. Nyem rau Apply qhov hloov pauv khawm no yuav ua li ntawd.
Thaum lub rooj tsavxwm rov pib dua nws yuav cia li pom nplooj ntawv teeb tsa dua nrog rau kev teeb tsa tam sim no.
Txuas koj lub khoos phis tawj lossis lub xov tooj ntawm tes mus rau TCP lossis UDP kev txuas thiab xyuas koj tau txais cov ntaub ntawv.
Qhov ntawd tiav lawm !! Muab txhua yam tso rau hauv lub thawv yas ntim dej tawm tsuas yog ob lub zog coj thiab ob lub RS232 coj dawb.
Kauj Ruam 6: Pab - Tsis Muaj Cov Ntaub Ntawv
Thaum koj tau txuas nrog lub network thiab teeb tsa koj lub xov tooj ntawm tes txuas mus rau TCP 10.1.1.1 thiab chaw nres nkoj koj tau teeb tsa (lossis koom nrog UDP multicast pab pawg 230.1.1.1 nrog qhov chaw nres nkoj koj tau teeb tsa), yog tias koj tseem tsis tau txais ib cov ntaub ntawv sim cov theem hauv qab no.
1) Txheeb xyuas NMEA / AIS cov cuab yeej tau qhib
2) Txheeb xyuas RS232 cov xov hlau txuas nrog txoj hauv kev ib puag ncig.
3) Txheeb xyuas qhov 'ntws tswj' teeb tsa ntawm koj cov khoom NMEA / AIS. Teem nws rau 'TSIS MUAJ' yog tias yog qhov kev xaiv. Yog tias tsis yog li xaiv 'kho vajtse' LOSSIS RTS / CTS kev tswj ntws thiab luv tawm RTS rau CTS thiab DSR tus pin ntawm NMEA / AIS cable. Ntawd yog rau DB-25 txuas, txuas tus pin 4 thiab 5 thiab 6 ua ke. Rau DB-9 txuas, txuas tus pin 6 thiab 7 thiab 8 ua ke. Nrog 'kho vajtse' tswj NMEA / AIS cov cuab yeej (DTE) lees paub RTS (ReadyToSend) thaum nws xav xa cov ntaub ntawv. Nrog cov kev sib txuas no RTS tus pin tsav lub ClearToSend (CTS) thiab DataSetReady (DSR) tus pin uas tau rov qab nkag mus rau NMEA / AIS cov cuab yeej los qhia nws tias lwm sab tau npaj thiab tuaj yeem tau txais cov ntaub ntawv.
Debugging
Txhawm rau qhib qhov Debugging TX tso tawm, tsis txaus siab, piv txwv li hloov kho rau #define DEBUGnear saum ESP8266_NMEA_BRIDGE.ino kos duab.
Tshem tawm TX/RX USB cable thiab tsuas yog txuas lub RX daj cable rau Debug TX tso tawm. Tawm ntawm Black GND cable txuas nrog GND rau TX/RX. Arduino IDE Serial Monitor yuav tam sim no qhia cov lus debug.
Los ntawm lub neej ntawd pab pawg UDP multicast tau pib, tab sis koj tuaj yeem xiam nws los ntawm kev tawm tswv yim, piv txwv li hloov mus rau // #define UDP_BROADCAST ze rau saum ESP8266_NMEA_BRIDGE.ino kos duab.
Xaus
NMEA/AIS RS232 rau WiFi choj no muaj zog thiab siv tau yooj yim. Nws ua haujlwm tau zoo los ntawm 12 lub hauv paus roj teeb thiab pheej yig txaus nqa cov khoom seem nrog koj uas koj tuaj yeem sib pauv hauv nruab nrab lub nkoj yog tias tsim nyog.
Pom zoo:
Pheej Yig Qhov Chaw Nkag Nkag Pheej Yig Pheej Yig: 6 Kauj Ruam (nrog Duab)
Pheej Yig Qhov Chaw Nkaum Nkag Pheej Yig: CreditI zoo nkauj heev theej Savjee qhov kev siv tab sis tsis txhob siv Shelly Kuv siv Sonoff Basic. Txheeb xyuas nws lub vev xaib thiab YouTube Channel
Cov Khoom Siv Hluav Taws Xob Hloov Kho Siv Cov Pheej Yig EBay Pheej Yig: 8 Kauj Ruam
Kev Hloov Kho Lub Hwj Huam Siv Pheej Yig EBay Qhov Chaw: Hauv phau ntawv qhia no peb tab tom tsim kho lub zog hloov kho kom pheej yig los pab peb ua haujlwm rau peb cov phiaj xwm arduino, qhov ntau tshaj ntawm cov khoom siv hluav taws xob raws li cov tuam txhab tsim khoom uas peb siv yuav tsum nyob ib puag ncig 60W. Tus nqi ntawm qhov haujlwm yuav tsum yog
Multi-Touch Interface ntawm Pheej Yig (Yeej Pheej Yig): 3 Cov Kauj Ruam
Multi-Touch Interface ntawm Pheej Yig (Pheej Yig Heev): Nov yog kuv thawj Kev Qhia yog li thov ua zoo. Nov yog yuav ua li cas thiaj kov tau ntau tus neeg tawm ntawm koj lub rooj rau nyiaj tsawg heev. Thaum kawg tau txais daim vis dis aus tso tawm, thov txim txog qhov tsis zoo-tus nqi kuv lub laptop tsis zoo txhua
Txuag lub Ntiaj Teb thiab Koj Lub Hnab. $$ Hloov Koj P & S Pheej Yig Pheej Yig Lub Koob Yees Duab kom rov them rov qab: 4 Cov Kauj Ruam (nrog Duab)
Txuag lub Ntiaj Teb thiab Koj Lub Hnab. $$ Hloov Koj Li P & S Pheej Yig Tshaj Lub Koob Yees Duab kom rov tau txais txiaj ntsig: Ntau xyoo dhau los, Kuv yuav Dolphin Jazz 2.0 Megapixel Digital Camera Nws muaj cov yam ntxwv zoo thiab tus nqi. Nws kuj tseem muaj qhov qab los noj mov rau AAA Bateries. Tsis yog ib tus neeg taug kev deb ntawm qhov kev sib tw, kuv xav tias kuv yuav hloov kho nws kom siv lub roj teeb rov tau los kom tsis txhob nkim sijhawm ntxiv
Txoj Kev Pheej Yig Pheej Yig: 8 Kauj Ruam
Txoj Kev Pheej Yig Pheej Yig: Kuv xav tau txoj hauv kev los thauj kuv lub amp tsis muaj nws tau tsoo tag nrho. Kuv tab tom yuav ua tus amp amp tawm ntawm ntoo, muab qee cov ntaub pua plag rau nws thiab lub log … tab sis qhov no tsis yog qhov kuv xav tau tiag tiag. Kuv xav tau ib qho ntawm cov roto-molded txias uas raug nqi $ 100+. Yog li