Cov txheej txheem:

Kev kho tus kheej PulseSensor Visualizer mus rau qhov tshwm sim (Anti-Productivity Monitor): 8 Cov Kauj Ruam
Kev kho tus kheej PulseSensor Visualizer mus rau qhov tshwm sim (Anti-Productivity Monitor): 8 Cov Kauj Ruam

Video: Kev kho tus kheej PulseSensor Visualizer mus rau qhov tshwm sim (Anti-Productivity Monitor): 8 Cov Kauj Ruam

Video: Kev kho tus kheej PulseSensor Visualizer mus rau qhov tshwm sim (Anti-Productivity Monitor): 8 Cov Kauj Ruam
Video: koj lub neej | Nkauj Tshiab 2020 - Official MV - [ Wen.Original ] 2024, Hlis ntuj nqeg
Anonim
Customizing PulseSensor Visualizer rau Kev Ua Yeeb Yam (Kev Tiv Thaiv Kev Tsim Khoom)
Customizing PulseSensor Visualizer rau Kev Ua Yeeb Yam (Kev Tiv Thaiv Kev Tsim Khoom)

Hauv cov lus qhia no koj yuav kawm paub yuav hloov kho PulseSensor Visualizer Program kom ua rau muaj kev tshwm sim hauv lub vev xaib li cas. Kuv tab tom hu txoj haujlwm no los tiv thaiv Kev Tsim Khoom Tsim Nyog vim tias thaum peb muaj ntau yam cuab yeej uas pab peb saib xyuas peb qhov tseem ceeb, peb cov sijhawm teem tseg, thiab peb cov zaub mov noj, tsis muaj ntau qhov tawm uas ceeb toom rau peb siv ob peb feeb tawm ntawm peb cov hnub tsis khoom. kom qeeb thiab ua pa.

Kauj ruam 1: Yam Koj Yuav Tsum Tau

- PulseSensor lub ntsuas ntsuas lub plawv ntsuas, uas suav nrog:

  • Mos braided-hlau ribbon cable
  • Pob ntseg pob ntseg (qhov loj me rau lub sensor)
  • Velcro Finger Pluaj

- Arduino Ib

- Arduino IDE, rau kev xa cov cai rau koj Arduino

- Ua App, rau BPM pom kev

- PulseSensor Chaw Ua Si Chaw Ua Si (Rau Arduino)

- PulseSensor Amped Ua Visualizer (Rau Kev Ua)

Kauj Ruam 2: Npaj Plugging PulseSensor rau Arduino

Npaj Lub Plugging PulseSensor rau Arduino
Npaj Lub Plugging PulseSensor rau Arduino

Vim tias lub ntsuas cua yog lub rooj sib tham nthuav tawm, koj yuav tsum nrhiav txoj hauv kev kom tsis muaj roj lossis hws los ntawm kev sib cuag nrog cov khoom ntawd. Koj tuaj yeem siv cov kua nplaum kub los txhuam cov ntsia hlau. TSIS TXHOB npog sab dawb lossis lub ntsuas pa nrog ib yam khoom tsis zoo, qhov no ua rau koj lub cuab yeej siv tsis tau.

Txuas cov xov hlau mus rau cov chaw nres nkoj sib xws:

5v - RED CABLE

Hauv av - CABLE BLACK

Analog 0 (A0) - Ntshav Cable

Kauj Ruam 3: Arduino Code Install and Upload

Arduino Code Install thiab Upload
Arduino Code Install thiab Upload
Arduino Code Install thiab Upload
Arduino Code Install thiab Upload

Thaum Arduino THIAB Ua software tau rub tawm thiab teeb tsa, Thauj Chaw Qiv Chaw Ua Si rau hauv Arduino lub tsev qiv ntawv. Hauv Arduino app, mus rau Sketch> suav nrog Tsev Kawm Ntawv> Tswj Tsev Qiv Ntawv. Tshawb nrhiav PulseSensor thiab teeb tsa lub tsev qiv ntawv.

Tom ntej no qhib tus piv txwv los ntawm kev mus rau> Piv txwv> PulseSensor Chaw Ua Si. Rau peb lub hom phiaj, peb yuav siv PulseSensor_BPM. Qhov piv txwv tus lej kawg yog tsim los xa cov ntaub ntawv txuas mus rau Kev Ua Haujlwm. Ua ntej peb tuaj yeem xa cov duab kos rau peb Arduino, peb yuav tsum hloov kab ntawm kab ntawv kom cov ntaub ntawv arduino raug xa mus rau kev ua haujlwm. Qhov txawv txav output_type los ntawm lub neej ntawd tau teeb tsa rau SERIAL_PLOTTER. Qhov no yuav tsum hloov mus rau PROCESSING_VISUALIZER.

Kauj Ruam 4: Ua Txoj Cai Txhim Kho thiab Upload

Tom qab rub tawm PulseSensor Amped Visualizer file thiab unzip nws. Nrhiav cov ntawv hu ua "PulseSensor_Amped_Processing_150" thiab muab tso rau hauv koj Cov Ntawv> Ua cov ntawv tais ceev tseg.

Tam sim no qhib Ua thiab mus rau cov ntawv> kos duab thiab nyem rau ntawm PulseSensorAmped_Processing_Visualizer.

Kauj Ruam 5: Xeem

Xeem
Xeem
Xeem
Xeem
Xeem
Xeem

Thaum koj nyem khiav hauv Kev Ua Haujlwm, lub qhov rai yuav qhib nug seb koj xav siv qhov chaw nres nkoj twg. Feem ntau Arduino chaw nres nkoj yog nyob rau sab saum toj ntawm cov npe. Xaiv qhov chaw nres nkoj, thiab tso lub ntsuas cua nyob txhua qhov chaw ntawm koj lub cev koj ib txwm tuaj yeem hnov koj lub plawv dhia. Koj yuav tsum pom kev nyeem ntawv tas li ntawm koj li BPM!

Kauj Ruam 6: Kho qhov Visualizer Program

Thaum koj muaj qhov haujlwm tau ua tiav, muaj ntau qhov kev hloov pauv uas koj tuaj yeem ua los kho qhov kev paub dhau los. Txawm li cas los xij, ceev faj txog cov cai koj ntxiv lossis siv. Nws tuaj yeem ua txhaum txoj haujlwm!

Ib qhov kev hloov pauv me me uas koj tuaj yeem ua tau yog hloov cov ntawv () ua haujlwm hauv kab 87 kom nyeem txhua yam koj xav tau. Nws xub hais tias PulseSensor Amped Visualizer. Kuv hloov kuv li hais Anti Productivity Monitor.

Ib qho kev hloov pauv loj uas kuv tau ua kuv tau tso rau hauv qhov tsis muaj dabtsis drawheart () muaj nuj nqi thiab ua ntej qhov tsis muaj npe listAvailablePorts () muaj nuj nqi. Nov yog cov cai:

Tshaj tawm qhov sib txawv openWindow ua ntej qhov kawg ntawm lub voj kos zoo li:

openWindow ();

} // kawg ntawm kos voj

Kev ua haujlwm tau muab tso rau hauv qhov tsis muaj dabtsis drawheart () muaj nuj nqi thiab ua ntej qhov tsis muaj npe listAvailablePorts () muaj nuj nqi.

tsis muaj dab tsi openWindow () {

thaum (BMP> = 120) {

txuas ("txuas ntawm koj xaiv");

}

Txoj cai no tas li tshuaj xyuas qhov nyeem los ntawm arduino, thiab ib qho kev nyeem siab dua 120 BPM ua rau cov vis dis aus youtube qhib rau hauv lub browser qub.

CEEB TOOM: Tsis txhob khiav qhov pom kev kom txog thaum tom qab nyeem cov teeb meem hauv qab no thiab daws tau.

Kauj Ruam 7: Teeb meem

Teeb meem
Teeb meem

Vim hais tias openWindow hais kom ua zoo rau BPM qhov tseem ceeb tshaj 120 HUNDREDS ntawm lub sijhawm thib ob, nws tuaj yeem ua rau txuas txuas kom qhib txhua lub sijhawm nws sau npe dhau los ntawm qhov pib. Koj yuav pom qhov no hauv qhov screen txhaj tshuaj saum toj no. Kuv qhib HUNDREDS ntawm cov tab tshiab hauv vib nas this. Qhov no khov tag nrho kuv lub computer - Kuv yuav tsum rov pib dua nws! Txhawm rau zam qhov teeb meem no, ntxig ncua () hais kom ua tom qab txuas kab lus hais li no.

void openWindow () {thaum (BMP> = 120) {

txuas ("txuas ntawm koj xaiv");

ncua (60000);

}

Lub sijhawm ntsuas hauv millis hauv kev ua, thiab 60, 000 millis sib npaug ib feeb.

Kauj Ruam 8: Cov Khoom Kawg

Ua tau zoo! Thaum cov neeg siv BMP mus txog 120 BPM yav dhau los, qhov txuas tau qhib hauv koj tus browser. Lub voj yuav ncua rau ib feeb.

Pom zoo: