Board index » delphi » Dallas DS1820

Dallas DS1820

Hi...
Does anybody know how to program the
Dallas DS1820 thermometer?.
The code I get is all in C/C++ and all DOS.
How do I send a hex value directly to a port?(equiv. outportb)
Thanks

--
         ________
___/\/                \/\___
M. Stevens

 

Re:Dallas DS1820


M.Stevens <steve...@mail.pentech.ac.za> schreef in berichtnieuws
9hhhgg$i...@news.adamastor.ac.za...

Quote
> Hi...
> Does anybody know how to program the
> Dallas DS1820 thermometer?.
> The code I get is all in C/C++ and all DOS.
> How do I send a hex value directly to a port?(equiv. outportb)

There is no such thing as a "hexvalue". Hex is just a convenient _notation_
to visualize numbers, so that individual bits can be seen easily. A comport
can only receive/send bytes. What these bytes _represent_ is purely a matter
of agreement.
If you send a byte with decimal value 65 to the comport, then it is up to
the receiving party to interpret this value as just the number 65, or as the
ascii-code of the character 'A'.

If you need a Delphi serial component, go to http://www.claessens16.yucom.be

--
Regards,

Dirk Claessens -  Agfa Belgium
---------------------------------------------------------------------------
ATTENTION : All spamshields  raised -- direct emails will bounce!
---------------------------------------------------------------------------

Re:Dallas DS1820


You'll need to be a bit specific here. The DS1820 runs on the OneWire LAN,
and I don't see you driving that straight from a hardware port with critical
timings of the order of a few tens of microseconds.

Have you looked a the Maxim-Dallas website? There are specialised devices
for connection to the serial port of a PC which in turn link into the
OneWire bus. Even better they have evaluation kits which presumably come
with drivers.

Although they have chips for connection to the serial port of the PC, I'm
not clear whether you will be able to run under Windows. A preemptive
multitasking OS that  walks of the job when the mood takes it is not what's
needed. However, it may be they have implemented sufficient command caching
or somesuch in the interface chip to isolate the OneWire timing from the PC.

After reading your way through the mass of tech notes, writing to a hardware
port will be a doddle :-)

Dave

Quote
M.Stevens <steve...@mail.pentech.ac.za> wrote in message

news:9hhhgg$iq$1@news.adamastor.ac.za...
Quote
> Hi...
> Does anybody know how to program the
> Dallas DS1820 thermometer?.
> The code I get is all in C/C++ and all DOS.
> How do I send a hex value directly to a port?(equiv. outportb)
> Thanks

> --
>          ________
> ___/\/                \/\___
> M. Stevens

Other Threads