Jump to content


  • Content Count

  • Joined

  • Last visited

  • Days Won


Everything posted by p2baron

  1. Marking this as solved. I have raised a new issue at github @@energia https://github.com/energia/Energia/issues/773
  2. I think I've found the culprit with the help of this article: http://www.elevendroids.com/2013/06/code-recipe-reading-msp430-power-supply-voltage-level/ If I add "ADC10CTL0 &= ~ENC;" to wiring_analog.c the problem is solved. i.e. #if defined(__MSP430_HAS_ADC10__) ADC10CTL0 &= ~ADC10ENC; // disable ADC ADC10CTL1 = ADC10SSEL_0 | ADC10DIV_4; // ADC10OSC as ADC10CLK (~5MHz) / 5 ADC10CTL0 = analog_reference | // set analog reference ADC10ON | ADC10SHT_3 | ADC10IE; // turn ADC ON; sample + hold @ 64
  3. It has something to do with the analogRead function. After I've sampled the internal ADC the average power consumption rises even though it goes into LPM4.
  4. @@Fmilburn wakeup is indeed needed @@spirilis I'm using Energytrace to measure power consumption I've tried setting the anologReference back to default. Unfortunately that doesn't help. attached are three screenshots. The first one is the EnergyTrace log without calling reportVcc() and the second one with. The third screenshot shows the debug screens from CCS Cloud. It is always calling the suspend() function. I'm a bit lost. Why is the MCU unable to suspend? Are there other thing I can check?
  5. Thanks for all the suggestions. I tried debugging the code in CCS cloud. Thanks for the tip. I did not even know that CCS Cloud existed! When debugging I see that the code is functioning fine and the the suspend() code is always called/entered. Two questions. Do I always need to clear an interrupt? Is the wakeup call even needed? Verstuurd vanaf mijn SM-G920F met Tapatalk
  6. 1. Yes everything is working fine. Suspend is also working fine execpt once I've called reportVcc() it is unable to suspend again. 2. I don't have much experience with CCS. I'm also having troubles setting up CCS. After I've imported my Energia sketch and do a build I receive the following error: C:/Users/Pieter/Google Drive/03 - Workspace/CSS/lpmsp430g2553_core/Debug\liblpmsp430g2553_core.a(main.o): In function `main': C:/Users/Pieter/Google Drive/02 - Apps/energia-0101E0016/hardware/msp430/cores/msp430/main.cpp:7: undefined reference to `setup' C:/Users/Pieter/Google Drive/02 - Apps/ener
  7. I am currently working on a low power application. Using the MSP-EXP430FR5969 and the energytrace functionality in CSS I'm finally able to monitor the power usage of my sketch. (thanks for the writeup Frank!). I notice that if I call the following function my MSPG2553 is unable to suspend. // returns VCC in millivolts int getVCC() { // start with the 1.5V internal reference analogReference(INTERNAL1V5); int data = analogRead(ANALOG_HALFVCC_INPUT); // if overflow, VCC is > 3V, switch to the 2.5V reference if (data==0x3ff) { analogReference(INTERNAL2V5); data = (int)
  8. Just tried this. I received this error when I tried to start energytrace: A firmware update is required for the MSP430 Debug Interface You can solve this by downloading the MSP430 flasher from the TI website and running the command "MSP430Flasher.exe -s: i.e. C:\TI\MSP430Flasher_1.3.7>MSP430Flasher.exe -s
  9. Solved. See this thread: http://forum.43oh.com/topic/5465-problem-with-capacitive-touch-library/
  10. @@zormino Thanks, that solved the problem for me!! @@energia Robert, sorry for the late reply. Here are my answers: 1: What are you using as the sensing pad? A piece of breadboard wire 2: What are you using as the power supply for the MSP430? Just a plain USB charger (LG, 5v, 800mA) 3: Is this a LaunchPad or is the MSP430 standalone (e.g. soldered onto a breadboard)? I used the launchpad Zormino's solution fixed the problem for me. I am unsure why I am having this problem but you don't.
  11. Robert is the Captouch-master. @@energia do you know a way to debug this?
  12. @@spirilis thanks. I will handle that in the main loop, I basically want to stay in LPM3/4 mode all of the time except when an interrupt occurs. Do I need to have sleepsecond(xxx) in the main loop?
  13. I am currently working on a low power mailbox sensor which notifies me when I recieve (snail) mail and when it is picked up. (I live in an appartment and my mailbox is in the central staircase) I've implement the changes from both Robert and Spirillis to enable low-power interrupts. This is the code: #include <x10rf.h> //https://github.com/p2baron/x10rf #define intpin1 P1_2 // Sensor on the outer lid <- used by mailman to deliver mail #define intpin2 P1_3 // Sensor on the inner lid <- used by me to pickup mail #define txpin P2_7 // Signal pin for 433Mhz module #
  14. I'm having similiar issue. Never managed to resolve this. I suspect this has something to do with the size of the object that is being used as the touchpad. Also the power supply seems to make a difference. With some cheap usb-charger the MCU constantly registered touches that weren't there.
  15. Please note that the precompiled Openwrt binaries contains ACM drivers that contain a bug. When your MSP430 spits out serial messages before you open the serial port (in python or bash) the driver crashes and no communication is possible. Wasted a couple of hours figuring that out. :-( This isn't a problem when the OpenWRT devices initiates communication. You can fix this by modifying the drivers and compiling OpenWRT yourself. Verstuurd vanaf mijn HTC One met Tapatalk
  16. THanks. I've done some testing this weekend. Please note that I am not using the CapTouch boosterpack. Just a wire and a piece of metal. This is the output I am getting when it goes berzerk: State: 1 Base: 18855 Measured: 10110 Delta: 8745State: 1 Base: 18855 Measured: 9983 Delta: 8872State: 1 Base: 18855 Measured: 10052 Delta: 8803
  17. @@energia , how did your test go? Not pushing for a solution but just curious if you've experienced the same behaviour. I will do a test tonight to see if this also affects the Stellaris boards.
  18. Hi Robert, just got home and noticed that the red light is on all of the time. The green light is still blinking so it seems to be something in the CapTouch library. Verstuurd vanaf mijn HTC One met Tapatalk
  19. Thanks. I will give it a go. I've replaced middle_led with red_led. I hope that isn't a problem.
  20. 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 bu
  21. Not yet, it is still in breadboard phase. See my other post I am working on wireless door sensors with temperature and ambience reporting. Next to that I am planning to use this library to send my meter readings (power, gas) to my server. I will post pictures once something is finished.
  22. Thanks, I will try LPM3. Timing isn't critical since I need to send temperature (dallas 1-wire) and brightness (LDR?) every 30-60 minutes. I've used the latest Energia version so that should explain why my sketch is working. Not sure what this means for my code. It has been running for over a week on a coin cell battery. (cr2032)
  23. For the transmission side I use a 433Mhz OOK FSK transmitter: The receiving end is a wireless dimmer sold by http://www.klikaanklikuit.nl. I believe this is sold as "HomeEasy" in other parts of the world. I am still having problems with the code. The MCU freezes(red and green led on) after some time. Is it possible that my sketch is causing a RAM-overflow after some time? Not sure how to debug this
  24. I've used the cheap (3$) ebay module shown in below. With perhaps a little tweaking on the timing this library should also work voor 315Mhz version. Haven't tried this. I still need to update the library. It would be nice to support receiving X10rf messages and the delay functions need to be replaced by non-block code. Currently I am using a RfxCom USB transceiver to receive X10 messages for home automation in Domoticz.
  25. I am currently working on a battery operated wireless doorsensor. A message is sent whenever a magnetic switch causes an interrupt. I have read some topics on this forum and changed some lines in Winterrupts file and created the following sketch: #include <x10rf.h> #define intpin1 P1_5 #define txpin P1_7 #define txvcc P1_0 #define reps 4 x10rf myx10 = x10rf(txpin,0,reps); void setup() { myx10.begin(); pinMode(intpin1,INPUT_PULLUP); pinMode(txvcc,OUTPUT); digitalWrite(intpin1, HIGH); digitalWrite(txvcc, LOW); attachInterrupt(intpin1, Wake, CHAN
  • Create New...