Energia: Errors when compiling Wire Master Reader code (Reads data from an I2C

I would greatly appreciate help resolving the error messages below created when verifying the Wire Master Reader code included in this posting.

IDE: Energia 1.8.11E23 running on Windows 7 64 bit

Master device: Launch Pad MSP-EXP30g2ET with a MCU part type MSP-EXP430G2553

Error messages:
Energia: 1.8.11E23 (Windows 10), Board: "MSP-EXP430G2 w/ MSP430G2553"

C:\energia-1.8.10E23-windows\energia-1.8.10E23\hardware\energia\msp430\libraries\Wire\utility\twi.c: In function 'twi_disable':

C:\energia-1.8.10E23-windows\energia-1.8.10E23\hardware\energia\msp430\libraries\Wire\utility\twi.c:443:5: error: 'UCBzCTLW0' undeclared (first use in this function)

C:\energia-1.8.10E23-windows\energia-1.8.10E23\hardware\energia\msp430\libraries\Wire\utility\twi.c:443:5: note: each undeclared identifier is reported only once for each function it appears in

Multiple libraries were found for "Wire.h"
Used: C:\energia-1.8.10E23-windows\energia-1.8.10E23\hardware\energia\msp430\libraries\Wire
exit status 1
Error compiling for board MSP-EXP430G2 w/ MSP430G2553.

Note: I have deleted all but one instance of wire.h

// Wire Master Reader

// by Nicholas Zambetti http://www.zambetti.com

// Demonstrates use of the Wire library

// Reads data from an I2C/TWI slave device

// Refer to the "Wire Slave Sender" example for use with this

// Created 29 March 2006

// This example code is in the public domain.

#include <Wire.h>

void setup()

{

Wire.begin(0x5A); // slave address (Address not required if master)

Serial.begin(9600); // start serial for output

}

void loop()

{

Wire.requestFrom(2, 6); // request 6 bytes from slave device #2

while(Wire.available()) // slave may send less than requested

{

char c = Wire.read(); // receive a byte as character

Serial.print(c); // print the character

}

delay(500);

}

We don't use Energia and we don't use the MSP430. Is there a forum for those ? The STM32 seems to work with Arduino.
Can you cross over to our side and use a SAMD21G ? For example a Arduino MKR board.

Energia: https://energia.nu/

It seems that the library uses a register that does not exist. Something could be wrong with your build environment, but it could also be a bug.

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.