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.

MSP430I2041: HID Bridge (MSP-EXP430F5529LP) is not communicating with Energy Measurement Design Center(GUI) and Energy Meter

Part Number: MSP430I2041
Other Parts Discussed in Thread: UNIFLASH, MSP-EXP430F5529LP, MSP-ISO, MSP-FET, EVM430-I2040S

Hello Sir/Madam,

I am using Single phase energy meter based on MSP430I2041 . 

Project created from Energy Measurement Design Center(GUI) is imported in CCS and Flashd to MSP430I2041 Device.

After this,I have flashed the MSP-EXP430F5529LP device with the HID firmware using UniFlash.  It is showing flashed successfully. For this i am following the user guide for Energy Measurement Design Center(GUI). On the launchpad LED 2 is blinking slowly after this.

Connections are also made as per the user guide

But after this once i goes back to  Energy Measurement Design Center(GUI) and selected the connect HID bridge device  as follows 

After this i am able to see the HID connected message in bottom left of GUI 

But here the name of meter is not showing as explained by the document  

I am not able to see the readings in results window and not able to calibrate meter as well. 

One more thing if i tried to connect HID in shunt resistor window , it is throwing error...detected but could not connect .

I have calibrated meter previously in this way but couple of times i have received the same issue but after one more trial it worked for me.

1. I have tried with the example Project from the Energy Measurement Design Center(GUI) 

2. Also I have changed the MSP430I2041 IC from the meter.  Same issue is coming with that also.

3. I tried by swapping the RXD - TXD  lines also at the end 

But i am getting this issue again. And not able to move forward .

As per my understanding HID device is not communicating with meter .

Is there any mistake in my understanding ...? Please clarify.

Thanks , 

Fakruddin.

  • Hi Fakruddin,

    Thanks for your very detailed post. It's extremely helpful when trying to help diagnose these types of issues. I'm happy to see that you've been able to use EMDC for your project and for calibration, but I'm sorry you're having this issue. I'll do my best to help you resolve it.

    The first thing I'd check is that your custom board is powering the MSP430i2041. I've seen this behavior before when I've mistakenly connected to a power-off MCU. Another thing you could try to do is disconnect the communication in the GUI, unplug the HID bridge, save the EMDC project, close EMDC, reopen the EMDC project, and then plug the HID bridge into your PC with it connected to your powered-up MCU also connected to the HID Bridge.

    Are you using the MSP-ISO? If so, you could try removing that from the communication chain to rule out an issue there. Be mindful not to connect your board to high voltage and instead power the board from a bench supply.

    Do you have both the MSP-FET AND HID Bridge connected when you try to connect? If so, I would recommend removing the MSP-FET and see if there was a conflict with the HID Bridge somehow.

    You're definitely doing the right things to narrow down this issue. Using the example EMDC project and switching the RX/TX connections are great things to rule out mistakes. Do you have an EVM430-i2040S board that you could use as a baseline? You could try connecting to that and once you have verified the communication works, then it should work on your custom board.

    Please keep us posted on your progress.

    Regards,

    James

  • Hello James,

    Thanks for your kind attention.

    As suggested by you -

    1. Yes, My custom board is powering the MSP430i2041 . I checked the power lines and I am getting 3.3 V there. 

    2.With power OFF and ON cycle you suggested ,I got two things -

    First one is Meter gets connected to HID bridge the same way mentioned in previous case but if click continuously on Start Tab in calibration window sometimes i am able to see readings in the window but Apply tab becomes inactive . But you can see the same HID connected message in bottom left.

    Second thing I repeated the cycle again and meter got connected as explained by the EMDC GUI help document .

    and with this i can see the readings in results window as-

    and I am also able to calibrate the meter here.With the same cycle repeated,I am able to connect meter to GUI through HID Bridge and calibrate .

    But this process is taking too long if meter doesn't get connected to HID bridge  properly.

    I followed the same process for both cycles but had different results. Reasons unknown.

     

    For MSP-ISO - I am not using MSP-ISO.

    I am using two Isolators on board and this is working fine since this has been tested for long time on the same board.

    I have tried by connecting RXD ,TXD and DGND lines from  MSP 430i2041 side (skipped the ISO7221) but the same two cases observed here also. 

    I am using only MSP-EXP430F5529LP launchpad as HID bridge and Not the MSP-FET.

    Can you suggest me a way to resolve the issue. 

    Regards,

    Fakruddin.

  • Hi Fakruddin,

    Thanks for the detailed reply. Do you happen to have an EVM430-i2040S or an i20xx target socket board that you could run the same test on? I'm wondering if your consecutive clicks to connect are causing the communication state machine on the target i20xx device to get stuck somewhere causing the communication issue.

    One thing that could be causing the issue would be if the project configuration differs from the code running on the target. The protocol contents can change depending on what parameters you have selected and the number of phases. Please make sure these match.

    Can you provide a very detailed step-by-step process that I can try to duplicate on my side? Thanks.

    Regards,

    James

  • Hi Fakruddin,

    Were you able to resolve the issue? Please let me know if you haven't so we can resolve it. Thanks.

    Regards,

    James

  • Hello Sir,

    I don't have  EVM430-i2040S or an i20xx target socket board , so i cant do the same test on it.

    If I do consecutive clicks to connect to the target and it might be having issue,then After first click it should connect to the target if i wait for some time (means if i provide sufficient time to HID bridge and GUI to communicate to target).  In this case also it is having the same issue ( If target doesn't get connected properly).

    Project configuration is same which is running on the target.

    I am providing detailed screenshots of my process below. Please let me know any mistake in  this.(Please note that ,In this screenshots  HID is communicating properly , I am raising this issue if meter doesn't get connected to GUI through HID as mentioned in above post.)

    1.Create Project-

    2.Check for errors-


     

    3.Generate Code- 

     


    4. Import the same project in CCS-

    5. Flash the target- 

     

    6.FLASH HID image - 

     


    7. Connect HID to Target and GUI-

    8.Calibrate and see the results (Note - this one is not calibrated)

    9. Disconnect- 

    These are the steps, Which i am following . 

    Please let me know any mistake in this.

    Moreover, I want to ask one more question here.

    If meter is calibrated and after that I made some changes in code in CCS and reflashed to same target , Will it retain its calibration values or do I need to calibrate meter once again...?

     

    Thanks and Regards,

    Fakruddin

  • Hello Fakruddin,

    Thanks for the additional details. I will duplicate these steps on my side with the MSP430i2041 target board.

    Fakruddin Mulla9 said:
    I am providing detailed screenshots of my process below. Please let me know any mistake in  this.(Please note that ,In this screenshots  HID is communicating properly , I am raising this issue if meter doesn't get connected to GUI through HID as mentioned in above post.)

    In the meantime, could you clarify your comments in the parenthesis above? After you do the steps mentioned in your last post above (the steps that I will duplicate), when exactly do you see the issue? Or is the issue intermittent? I will go through your steps and then disconnect the board and attempt to reconnect to see if I see anything.

    Regards,

    James

  • Hello Fakruddin,

    I went through your steps using EMDC and the i2041 target board, and I was able to connect successfully.

    • In EMDC
      • Configured a project like yours with two voltage sensors, one current sensor
      • Same hardware connections
      • Kept default sampling rate and selected all parameters
      • Used P2 pins for active energy pulses, P1 pins for reactive energy pulses
      • Kept advanced parameters the same
      • For shunt, chose 0.5mOhm and max RMS current of 15A
      • For voltage sensors, chose max RMS voltage of 230V, R1 = 990kOhms, R2 = 1.5kOhms (matches our EVM430-i2040S components, yours may be different)
      • Checked for errors
      • Saved the project
      • Generated the code

    • In CCS
      • Imported, built, and programmed the target
      • Started debugging, then stopped
      • Power cycled the i20xx target
    • In EMDC
      • Opened MCU, went to Results tab, clicked "Connected"
      • Device started sending results and showed up correctly on the status bar at the bottom
      • Clicked "Connected" to disconnect, then clicked it again after a few seconds to re-connect > communication started again just fine
      • Clicked "Connected" to disconnect, then unplugged the HID bridge and power cycled the i20xx target, then clicked "Connected" again > communication started again just fine
      • All these steps were done without closing EMDC GUI after generating the code, but even after closing and re-opening EMDC, the communication worked fine

    Let me know if you're doing anything differently. We want to help resolve this issue so you can continue your development.

    Regards,

    James

  • James Evans said:

    Hello Fakruddin,

    Thanks for the additional details. I will duplicate these steps on my side with the MSP430i2041 target board.

    Fakruddin Mulla9
    I am providing detailed screenshots of my process below. Please let me know any mistake in  this.(Please note that ,In this screenshots  HID is communicating properly , I am raising this issue if meter doesn't get connected to GUI through HID as mentioned in above post.)

    In the meantime, could you clarify your comments in the parenthesis above? After you do the steps mentioned in your last post above (the steps that I will duplicate), when exactly do you see the issue? Or is the issue intermittent? I will go through your steps and then disconnect the board and attempt to reconnect to see if I see anything.

    Regards,

    James

    Hello James ,

    The issue is observed intermittently.

    Thanks,

    Fakruddin

  • James Evans said:

    Hello Fakruddin,

    I went through your steps using EMDC and the i2041 target board, and I was able to connect successfully.

    • In EMDC
      • Configured a project like yours with two voltage sensors, one current sensor
      • Same hardware connections
      • Kept default sampling rate and selected all parameters
      • Used P2 pins for active energy pulses, P1 pins for reactive energy pulses
      • Kept advanced parameters the same
      • For shunt, chose 0.5mOhm and max RMS current of 15A
      • For voltage sensors, chose max RMS voltage of 230V, R1 = 990kOhms, R2 = 1.5kOhms (matches our EVM430-i2040S components, yours may be different)
      • Checked for errors
      • Saved the project
      • Generated the code

    • In CCS
      • Imported, built, and programmed the target
      • Started debugging, then stopped
      • Power cycled the i20xx target
    • In EMDC
      • Opened MCU, went to Results tab, clicked "Connected"
      • Device started sending results and showed up correctly on the status bar at the bottom
      • Clicked "Connected" to disconnect, then clicked it again after a few seconds to re-connect > communication started again just fine
      • Clicked "Connected" to disconnect, then unplugged the HID bridge and power cycled the i20xx target, then clicked "Connected" again > communication started again just fine
      • All these steps were done without closing EMDC GUI after generating the code, but even after closing and re-opening EMDC, the communication worked fine

    Let me know if you're doing anything differently. We want to help resolve this issue so you can continue your development.

    Regards,

    James

    Hi James,

    I am following the same steps and its working fine for me at times.

    Thanks and Regards,

    Fakruddin

  • Hi Fakruddin,

    Thanks for the reply. I'm not sure how to help if it's intermittent. Can you please try to identify anything that contributes to the intermittent behavior? I'm thinking about things like power supply issues on the i20xx, checking/unchecking "Connected" too quickly, etc. I would also suggest that you power cycle the i20xx target each time you'd like to reconnect. Perhaps there are corner cases where you were connected in a certain mode (e.g. calibration) and you physically disconnect the board or closed the GUI, and the i20xx target code was at a certain level in the communication state machine. Then, if you reconnect, it may not be able to recognize the initialization command from the EMDC GUI.

    Hope this helps.

    Regards,

    James

**Attention** This is a public forum