This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

  • Resolved

EVM430-F6779: Viewing EMDC results in a serial terminal

Intellectual 710 points

Replies: 10

Views: 445

Part Number: EVM430-F6779

Hi,

I have tested EVM with the EMDC GUI and am getting the desired results. Now I want to interface EVM430-F6779 electric meter to serial COM PORT terminal. How do I connect to serial com port? Shall I use same hid bridge or on board RS232 or have to connect externally ?

Plz send me very first command to communicate? I didn't  change anything on EMDC generated code.

I just want to view results on com port terminal . Pls reply me as soon as possible.

  • Hi James,
    I can able to communicate with EMDC GUI.
    Now im trying to read the values over a COM port.
    when i try to use On board EVM RS232 cant get any values on COM port.
    So How do i connect EVM to PC terminal ? shall i use ON BOARD RS232 or MSP-EXP430F5529LP or have to connect RS232 externally?
  • In this thread which is you referred to me ,MSP430i2040: Interfacing EMDC with another MCU over UART.
    you said "To help get you started with the communication between your host MCU and your MSP430i2041-based system, I spent some time communicating with my MSP430i2041 device (programmed with EMDC-generated code) over a TTL-to-serial adapter using a terminal called Serial Port Utility".

    This is what now im trying to do with EVM430F6779 board, but i cant get any response on com port terminal.
    I placed jumpers on TX_EN & RX-EN, so that TTL uart linked with ON board RS232.
    Then i opened Serial Port Utility and i send this command first 0x55, 0XAA, 0X07, 0x04, 0X02, 0X00, 0X05, 0X00, 0X0B, 0X00 one by one and sequentially but im not getting any response

  • In reply to applied automation:

    Hello,

    applied automation
    I have tested EVM with the EMDC GUI and am getting the desired results. Now I want to interface EVM430-F6779 electric meter to serial COM PORT terminal. How do I connect to serial com port? Shall I use same hid bridge or on board RS232 or have to connect externally ?

    You're making great progress! To use a terminal program, you can definitely use the on-board RS-232 connector which provides isolation between the board and your PC. Just make sure the USB-to-RS232 adapter can support the desired baud rate. For me, I have one that can support baud rates higher than 1 Mbaud to use it with the default EMDC baud rate of 250kbaud.

    applied automation
    In this thread which is you referred to me ,MSP430i2040: Interfacing EMDC with another MCU over UART.
    you said "To help get you started with the communication between your host MCU and your MSP430i2041-based system, I spent some time communicating with my MSP430i2041 device (programmed with EMDC-generated code) over a TTL-to-serial adapter using a terminal called Serial Port Utility".

    I've used either a USB-to-RS232 adapter or a TTL-to-serial adapter. I do want to point out that the TTL-to-serial adapter wouldn't be isolated so if you use one, be sure the EVM isn't connected to any high voltage. As I mentioned above, the RS232 connector is isolated.

    applied automation
    This is what now im trying to do with EVM430F6779 board, but i cant get any response on com port terminal.
    I placed jumpers on TX_EN & RX-EN, so that TTL uart linked with ON board RS232.

    Nice work populating the jumpers. This should work assuming the board has been powered on and is not stuck in some part of the communication state machine due to incorrect commands. Power cycling is a quick way of making sure that's not the case. Make sure your terminal is configured for the correct baud rate. Also, I use 8 data bits, no parity, 1 stop bit and no flow type.

    applied automation
    This is what now im trying to do with EVM430F6779 board, but i cant get any response on com port terminal.
    I placed jumpers on TX_EN & RX-EN, so that TTL uart linked with ON board RS232.
    Then i opened Serial Port Utility and i send this command first 0x55, 0XAA, 0X07, 0x04, 0X02, 0X00, 0X05, 0X00, 0X0B, 0X00 one by one and sequentially but im not getting any response

    Again, nice work and thanks for sharing the detailed command. It helps me provide better guidance. Try the following command to start the reports coming from the EVM to the terminal. Try this command sequentially: 0x55, 0xAA, 0x06, 0x04, 0x01, 0x01, 0x01, 0x07, 0x00

    From To Sync Byte Blank Byte Length Byte ID Byte Command Byte Read/Write Payload (Application Mode) Checksum LSB Checksum MSB
    EMDC Target 0x55 0xAA 0x06 0x04 0x01 0x01 0x01 0x07 0x00

    I confirmed this works on my side, so you should start getting data back from the EVM! There is a typo in the EMDC Technology Guide. For decoding the results, the commands from the target to EMDC (listed here) are 0x8x, not 0xBx. We'll fix this in the next release. Let me know if you run into any other issues.

    Regards,

    James

  • In reply to James Evans:

    My EVM is not connected to high voltage, so most results will be noise or zero. Here's what my terminal looks like after sending the command above.

    Regards,

    James

  • In reply to James Evans:

    Can we use same MSP-EXP430F5529LP to connect to COM port terminal? or
    Shall we Connect the lines which goes to hid bridge to our UART to USB converter connected to the PC ?

    EVM(TTL UART) --> MSP ISO --> UART to USB converter (So that it would be isolated too)
  • In reply to applied automation:

    Hi James,

    Thank you so much for your Timely Help.

    Result output window - After sending this 0x55,0xAA,0x06,0x04,0x01,0x01,0x01,0x07,0x00 command on terminal.

    But why EVM is sending first Phase C result,then Phase B and Phase A ? why is it in reverse order ?

  • In reply to James Evans:

    Hi James,

    My EVM is connected to high voltage, Here's what my terminal looks like after sending the command above.

    EVM continuously sending all phase results but it is reverse order (Phase C , Phase B, Phase A and then total phase) and sometimes alternate.Will you plz tell me resulting order format?

    Now its sending all phase results continuously, how do i request individual Phase results ?

    Ex: if we request Phase A results then corresponding phase A result only

    then after if we request Phase B results then corresponding phase B result only like wise Phase C.

    Is there any individual request command option for getting Phase A results only then Phase B & Phase C.

  • In reply to applied automation:

    Hello,

    applied automation
    My EVM is connected to high voltage, Here's what my terminal looks like after sending the command above.

    Thanks for sharing the terminal results. It's helpful for debugging.

    applied automation
    EVM continuously sending all phase results but it is reverse order (Phase C , Phase B, Phase A and then total phase) and sometimes alternate.Will you plz tell me resulting order format?

    Looking through the data in the terminal, it looks very consistent: Phase C (0x04), Phase B (0x02), Phase A (0x01), and Total (0x80) results. I couldn't see any alternating order unless I just overlooked it. If you configured the phase names in the EMDC GUI, did you select A, B and C or was the order C, B or A? If I remember correctly, the reporting order depends on which phase is finished first. Since the sampling frequency is periodic, it would make sense that the first phase reported would continue to be the first reported.

    applied automation

    Now its sending all phase results continuously, how do i request individual Phase results ?

    Ex: if we request Phase A results then corresponding phase A result only

    then after if we request Phase B results then corresponding phase B result only like wise Phase C.

    Is there any individual request command option for getting Phase A results only then Phase B & Phase C.

    Unfortunately, there's not a command to just query a single phase. If your EMDC project just had a single phase, then the report would contain results for a single phase (obviously). For the EMDC protocol, we implemented a communication state machine for these set of commands. Our goal was to send all the data to the GUI and the GUI would parse the packets and update those results in the GUI. You could definitely change this in the EMDC-generated code or you could have the host MCU or processor receive the packet and parse which phase to update. I hope this helps!

    Regards,

    James

  • In reply to James Evans:

    Hi James,

    Thanks for your quick reply.

    This way We configured the phase names in the EMDC GUI.

  • In reply to applied automation:

    Hello,

    Thanks for sharing this screenshot. Digging into the code, the reporting order seems to depend on which phase results are ready first. Again, on the host side, this order shouldn't matter since it will still need to parse the message to determine the results for each phase. You could always change the EMDC-generated application code to add custom commands/messages for sending each phase result independently.

    Regards,

    James

This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.