Shop OBEX P1 Docs P2 Docs Learn Events
Trouble communicating with MLX90614 IR Thermometer Module — Parallax Forums

Trouble communicating with MLX90614 IR Thermometer Module

GTEE09GTEE09 Posts: 4
edited 2012-02-07 10:54 in Accessories
Hello everyone.

For a project I'm working on, we're hooking up an MLX90614 module to a BS2p24 Stamp. The Stamp is working properly and is correctly connected to the IR module (RST, Alarm, and SIG pins connected to three IO pins on the Stamp, +5 and GND connected to VDD and VSS respectively), but when we run either of the two sample programs given on the module's product page, one which writes some info to the module's EEPROM and one which just constantly reads and outputs the temperature in a Debug window, we can't seem to get the module to respond to the serial signal from the Stamp. We used an oscilloscope to make sure that the signal was actually being sent properly, and we could see that the SIG pin of the module holds at +5 volts and then shows a burst of activity when the Stamp runs the SEROUT statement to send commands to the module. So it looks as if the Stamp is sending commands and the IR module is just not responding to them.

We tried using different IO pins, tried changing the slave address that the SEROUT command is sending to (tried the default of $5A, $00, and $35, which is what the EEPROM-writing program is supposed to change the module to), and we can never seem to get any response at all from the module. Even a simple program that sends an !ID command to the module gets no response. If anyone could provide any help or insight at all, it would be very much appreciated.

Thank you!

Comments

  • kelvin jameskelvin james Posts: 531
    edited 2009-03-05 02:44
    The sample code is for a bs2, since the bsp is a faster stamp, the serial timing has to be adjusted. Try 240 for the baud rate. Check out the help section for serin and serout commands.

    **
  • GTEE09GTEE09 Posts: 4
    edited 2009-03-05 18:03
    That did the trick. Thank you for the help!
  • leolib2004leolib2004 Posts: 5
    edited 2012-02-07 10:54
    How did you do to get it work?
    I can not communicate to it. I have read the datasheet and have seen the examples.
    I am using a microchip pic (16F628A). According to the datasheet, first i do a reset to the module (a 0 in reset pin for 5 ms and then a 1 forever)
    Then i send in hexa this sequence

    (0x00) - Delay_ms(10) - (0x21); - (0x54); - (0x45); - (0x4D); - (0x63); - (0x5A); - (0x07);
    This is for doing a continuous reading.

    And then,

    (0x00) - Delay_ms(10) - (0x21); - (0x54); - (0x45); - (0x4D); - (0x52); - (0x5A); - (0x07);
    for reading temperature...

    After that I wait for 3 bytes sent by the module.


    I use UART's library to do this (2400 bps).

    I can not see any response with my oscilloscope. What could be the problem?
    Maybe 0x5A is not the address or i am thinking something wrong...

    Thanks for your response! Regards!
Sign In or Register to comment.