Komunikasi Serial Mikrokontroler Beograd

2020. 2. 18. 12:20카테고리 없음

I can add a fourth one:4. The device is picky about serial timings.In this case don't use the SoftwareSerial it's not exact enough in timings to communicate with picky devices. I had similar problems with a RN-XV from Roving Networks, they went away as soon as I switched to the hardware serial interface.SoftwareSerial does work with some devices but try connecting a scope and see the timing differences you get. They are not exceptionally high but as I wrote: a picky device gets confused and reacts unpredictably. Yeah, I was trying to follow the previous advice to try using the hardware serial to talk to the pH meter rather than software, but I didn't know of a way to monitor what was happening if the hardware serial was being used to talk to the meter.

Komunikasi serial mikrokontroler beograd 2017Komunikasi

I've since started using a leonardo. The hardware serial goes to monitor and serial1 goes to the meter. I'm not sure if serial1 is a hardware or software serial, though nor am I sure if it makes a difference. Either way, I'm not getting anything from the meter through serial1.I've done some more careful monitoring of the COM1 port when the PC controls the pH meter and I've found a whole slew of commands being used that I didn't find before (the PC successfully controls the meter). They look like this:IRPMJDEVICECONTROL (IOCTLSERIALWAITONMASK)IRPMJDEVICECONTROL (IOCTLSERIALGETCOMMSTATUS)IRPMJDEVICECONTROL (IOCTLSERIALGETHANDFLOW)IRPMJDEVICECONTROL (IOCTLSERIALGETTIMEOUTS)None of these commands appear when I monitor what comes out of the arduino using the PC.

Komunikasi

Komunikasi Serial Mikrokontroler Beograd 2

I've even tried sending the ASCII characters transmitted during these commands, but that didn't work.