Jump to content

bcarroll

Members
  • Content Count

    10
  • Joined

  • Last visited

  1. bcarroll

    15 channel PWM with async serial control

    The code doesn't work.. There is HTML in 2 of the for loops. for(;<img src='http://forum.43oh.com/public/style_emoticons/<#EMO_DIR#>/icon_e_wink.gif' class='bbc_emoticon' alt=';)' /> {
  2. bcarroll

    Launchpad Rev 1.4 RXD TXD jumpers ?

    I too have a rev 1.4 Launchpad upgraded with an m430g2553 and have created an X jumper for the RXD TXD. I have tried several of the example sketches in Energia but I am not getting any data back from the Launchpad in the serial console. Any help would be greatly appreciated.
  3. bcarroll

    Error with Liquid Crystal library...

    Here is the working example: #include LiquidCrystal lcd(P2_0,P2_1,P2_2,P2_3,P2_4,P2_5); uint8_t smiley[8] = { B00000, B10001, B00000, B00000, B10001, B01110, B00000, }; void setup() { lcd.createChar(1, smiley); lcd.begin(16, 2); lcd.write(1); } void loop() {}
  4. bcarroll

    Error with Liquid Crystal library...

    Apparently the problem is with the numbering in the createChar() function of the Liquid Crystal library The Liquid Crystal library documentation states: I was able to resolve this issue by changing lcd.createChar(0,smiley); lcd.write(0); to lcd.createChar(1,smiley); lcd.write(1); I also confirmed that using 1-8 works for createChar(). Maybe the doc should be changed for the Liquid Crystal library that is included with Energia?
  5. I am attempting to run the example sketch in the Liquid Crystal library that comes with Energia and am getting a compile error: sketch_sep19a.cpp: In function 'void setup()': sketch_sep19a.cpp:18:14: error: call of overloaded 'write(int)' is ambiguous sketch_sep19a.cpp:18:14: note: candidates are: C:\energia-0101E0008\hardware\msp430\libraries\LiquidCrystal/LiquidCrystal.h:82:18: note: virtual size_t LiquidCrystal::write(uint8_t) C:\energia-0101E0008\hardware\msp430\cores\msp430/Print.h:56:12: note: size_t Print::write(const char*) Here's the code: #include LiquidCrystal lcd(P2_0,P2_1,P2_2,P2_3,P2_4,P2_5); byte smiley[8] = { B00000, B10001, B00000, B00000, B10001, B01110, B00000, }; void setup() { lcd.createChar(0, smiley); lcd.begin(16, 2); lcd.write(0); } void loop() {}
  6. bcarroll

    webbotlib speech synthesizer on launchpad

    I ran the conversion script and tried compiling with Energia. There were a couple of items that needed to be defined #define TRUE 1 #define FALSE 0 I had to move uint8_t _speech_timeFactor; to the top of the header file, and changed the pause function (due to compiler errors) static void pause(uint8_t delay){ uint8_t r; for(r=_speech_timeFactor; r>0; r--){ //__delay_cycles(delay); delay(sleep); } } though I'm not sure what issues this will introduce... I was able to get webbotlib to compile for the g2553, but all I have is a g2452 and the code is 78 bytes too big... Is there anything that can be removed/reworked to reduce the size? c:/energi~1/hardware/tools/msp430/bin/../lib/gcc/msp430/4.6.3/../../../../msp430/bin/ld.exe: Webbotlib.cpp.elf section `.bss' will not fit in region `ram' c:/energi~1/hardware/tools/msp430/bin/../lib/gcc/msp430/4.6.3/../../../../msp430/bin/ld.exe: region `ram' overflowed by 78 bytes collect2: ld returned 1 exit status
  7. bcarroll

    How Do I Add Libraries To Energia?

    I found an example that uses a servo and serial with the g2211, however the code doesn't compile in Energia. Here is the error I get: sketch_aug29a.cpp: In function 'void Timer_A1()': sketch_aug29a.cpp:265:14: error: 'TAIV_TACCR1' was not declared in this scope ...was getting an error about main needing to return an int, so I changed the code to int main(void) instead of void main(void) which fixed that issue... Here is the example: http://buildsmartrobots.ning.com/profiles/blogs/build-a-4-30-programmable-servo-controller
  8. bcarroll

    How Do I Add Libraries To Energia?

    I am using the g2452. Any way to work around this limitation?
  9. bcarroll

    How Do I Add Libraries To Energia?

    I am trying to use the Servo library but am getting a compile error: core.a(TimerSerial.cpp.o): In function `TimerSerial__TxIsr': C:\energia-0101E0008\hardware\msp430\cores\msp430/TimerSerial.cpp:202: multiple definition of `__isr_9' Servo\Servo.cpp.o:C:\energia-0101E0008\hardware\msp430\libraries\Servo/Servo.cpp:87: first defined here collect2: ld returned 1 exit status Am I doing something wrong? Here is my code: //get a number from Serial and move a servo to that position (no error/limit checking implemented yet) #include #define baudrate 9600 #define servoPin P1_4 int inByte = 0; // incoming serial byte char inData[3]; // serial input array (buffer) int index = 0; Servo myservo; // create servo object to control a servo void setup(){ Serial.begin(baudrate); myservo.attach(servoPin); } void loop(){ if (Serial.available() > 0) { inByte = Serial.read(); inData[index] = inByte; index++; if (index > 2 || inByte == 10 || inByte == 13){ //buffer is full or we got a charage return or linefeed inData[index] = '\0'; //Null terminate the string Serial.println(inData); myservo.write(atoi(inData)); // sets the servo position according to the scaled value delay(15); // waits for the servo to get there index = 0; } } }
  10. bcarroll

    Do you want a linux binary distribution?

    A debian package for the Raspberry Pi would be awesome!
×