Jump to content

Search the Community

Showing results for tags '#energia'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • News
    • Announcements
    • Suggestions
    • New users say Hi!
  • Spotlight!
    • Sponsor Spotlight
    • Sponsor Giveaways
  • Energia
    • Energia - MSP
    • Energia - TivaC/CC3XXX
    • Energia - C2000
    • Energia Libraries
  • MSP Technical Forums
    • General
    • Compilers and IDEs
    • Development Kits
    • Programmers and Debuggers
    • Code vault
    • Projects
    • Booster Packs
    • Energia
  • Tiva-C, Hercules, CCXXXX ARM Technical Forums
    • General
    • SensorTag
    • Tiva-C, Hercules, CC3XXX Launchpad Booster Packs
    • Code Vault
    • Projects
    • Compilers and IDEs
    • Development Kits and Custom Boards
  • Beagle ARM Cortex A8 Technical Forums
    • General
    • Code Snippets and Scripts
    • Cases, Capes and Plugin Boards
    • Projects
  • General Electronics Forum
    • General Electronics
    • Other Microcontrollers
  • Connect
    • Embedded Systems/Test Equipment Deals
    • Buy, Trade and Sell
    • The 43oh Store
    • Community Projects
    • Fireside Chat
  • C2000 Technical Forums
    • General
    • Development Kits
    • Code Vault
    • Projects
    • BoosterPacks

Calendars

There are no results to display.


Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Website URL


Location


Interests


Sparkfun


Github

Found 4 results

  1. Hi all, I'm relatively new to microcontroller programming and I'm having a few problems with a current project that I would appreciate help with. I'm using MSP430G2553 and Energia to control the speed of two vibromotors. To this I use three pushbuttons, one to change from one motor to another and two more(up and down) to increase/decrease the speed. I have 3 interrupts to do all this and I copied the code below. The program works mostly but sometimes it acts randomly, for example, increasing the speed when I press the decrease button, or not responding at all. My questions are these, they are quite simple but I am struggling quite a lot and I want to understand the basics good: 1). Am I using the interrupts correctly? Do I need to put all of them in the setup routine? Also, I have too much code in the interrupt functions, but not sure how to fix this. Should I just poll the flags in the functions and do the motor speed updating in the loop routine? Basically, and help and comments regarding the interrupts would be very helpful. 2). How do I use switch debouncing for more then one switch? I used the Energia example previously to debounce one switch but it seems complicated using that for 3 switches. int reading = digitalRead(buttonPin); if (reading != lastButtonState) { lastDebounceTime = millis(); } if ((millis( ) - lastDebounceTime) > debounceDelay) { buttonState = reading; } My current code: up_down_test.ino Thank you a lot in advance!
  2. Thank you so much we really need help! Here are the errors we got: project3-1.ino:50:10: error: expected constructor, destructor, or type conversion before '(' token project3-1.ino:51:10: error: expected constructor, destructor, or type conversion before '(' token project3-1.ino:52:10: error: expected constructor, destructor, or type conversion before '(' token project3-1.ino:53:10: error: expected constructor, destructor, or type conversion before '(' token project3-1.ino:54:10: error: expected constructor, destructor, or type conversion before '(' token project3-1.ino:55:10: error: expected constructor, destructor, or type conversion before '(' token project3-1.ino:56:10: error: expected constructor, destructor, or type conversion before '(' token project3-1.ino:57:10: error: expected constructor, destructor, or type conversion before '(' token project3-1.ino:58:10: error: expected constructor, destructor, or type conversion before '(' token project3-1.ino:59:10: error: expected constructor, destructor, or type conversion before '(' token project3-1.ino:60:10: error: expected constructor, destructor, or type conversion before '(' token project3-1.ino:61:10: error: expected constructor, destructor, or type conversion before '(' token project3-1.ino:77:24: error: storage size of 'inputed_array' isn't known project3-1.ino:83:10: error: expected constructor, destructor, or type conversion before '(' token project3-1.ino: In function 'double calculatePPM(int)': project3-1.ino:135:2: error: expected ';' before '}' token project3-1.ino:140:5: error: expected ';' before 'Rs' project3-1.ino:150:5: error: expected ';' before 'Rs' project3-1.ino:160:5: error: expected ';' before 'Rs' project3-1.ino: In function 'void float2Bytes(float, byte*)': project3-1.ino:178:10: error: 'flt_array' was not declared in this scope project3-1.ino: In function 'void LCD_INITIALIZE()': project3-1.ino:195:65: error: assigning to an array from an initializer list project3-1.ino:197:65: error: assigning to an array from an initializer list project3-1.ino:199:65: error: assigning to an array from an initializer list project3-1.ino:202:66: error: assigning to an array from an initializer list project3-1.ino:203:64: error: assigning to an array from an initializer list project3-1.ino:204:64: error: assigning to an array from an initializer list project3-1.ino:205:67: error: assigning to an array from an initializer list project3-1.ino:206:65: error: assigning to an array from an initializer list project3-1.ino: In function 'int array_to_lcd_converter(double*, int)': project3-1.ino:230:3: error: 'm' was not declared in this scope project3-1.ino:231:3: error: 'num' was not declared in this scope project3-1.ino:236:68: error: assigning to an array from an initializer list project3-1.ino:237:70: error: assigning to an array from an initializer list project3-1.ino:241:67: error: assigning to an array from an initializer list project3-1.ino:245:69: error: assigning to an array from an initializer list project3-1.ino:249:69: error: assigning to an array from an initializer list project3-1.ino:252:10: error: 'pos' was not declared in this scope project3-1.ino:254:8: error: expected '(' before 'inputed_array' project3-1.ino:381:1: error: expected '}' at end of input project3-1.ino:381:1: error: expected '}' at end of input Project.ino
  3. how do i add math.h (the arduino library) to energia? or is there an equivalent library i can use that includes math functions. And where could i find either of those. thank you
  4. Guys, I am having some problems with the CapTouch library and need some help from the experts to resolve this. I modified (stripped) the CapTouch button example an uploaded that code to a G2553: #include <CapTouch.h> #define LEFT_BUTTON 10 #define MIDDLE_LED P1_6 uint8_t state = false; CapTouch left = CapTouch(LEFT_BUTTON, TOUCH_BUTTON); void setup() { /* Use the middle LED to indicate touch */ pinMode(MIDDLE_LED, OUTPUT); } void loop() { /* State will be 1 if any of the buttons was touched, otherwise 0 */ state = left.isTouched(); /* Turn on the LED if any of the buttons was touched */ digitalWrite(MIDDLE_LED, state); } This code runs fine for over 20 hours but then stalls. The the green led (as defined in the code) is constantly on and the board no longer responses. Any clues to what might cause this behaviour?
×
×
  • Create New...