Jump to content

Search the Community

Showing results for tags 'timing'.



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 3 results

  1. I'm attempting to add support for a pseudo digital protocol to a project of mine. I'm attempting to implement the dShot protocol for controlling ESCs on my thrust stand, and having some issues. The TivaC doesn't appear to have very robust output control. You can see what I'm trying to do here: https://github.com/VirtualEnder/TestStandv2/blob/dev/MQTB_Thrust_Stand/hardwareTimers.ino Basically the protocol uses a modified PWM signal with each bit being 1.67us period with 1250ns representing a 1 and 635ns representing 0, basically encoding a 2048 bit throttle signal with some CRC data and a telemetry call bit crammed on the ends. After a couple days I've gotten to the point of using a PWM timer synced with a GP timer to attempt to modify the duty cycle for each bit, however I'm not having much luck. Is there a more precise way of accomplishing this? I'd like to not have to switch MCUs, but I know the ESP32 can do this easily with their RMT methodology and the STM chips can do with with a DMA transfer. I looked at the uDMA implementation in the TivaC and it doesn't appear to operate in a way that would work to toggle pins like this. This is the output signal I'm getting on my relatively limited DSO Nano from the TivaC: And this is the output signal as seen from an STM32F405 that is working properly: Any help would be very much appreciated.
  2. Still new to embedded programming and I am trying to use the MMA8452 accelerometer (datasheet) on SparkFun's breakout board (link). I programmed SparkFun's example program (link) into the MSP430G2553 via Energia with no issues and plotted the serial data in Excel. However this data, for lack of a better word, was "noisy." There would be huge spikes in the data even though the device was sitting still. Sometimes the WHO_AM_I value would be reported incorrectly as well. I found out the board shipped with 10k pull ups so I dropped them to the recommended 4.7k? resistors and the problem persisted. When I tried to investigate the SCL and SDA lines with my oscilloscope, the problem would disappear and the data would be a pristine flat line (as expected). That told me the scope probe capacitance was actually helping the circuit and rather than decrease resistance I should increase resistance. That seemed very counter intuitive to me, but I followed the data and changed pull ups to 15k. The problem disappeared and the data was clean. I was using short leads with and without a breadboard. The jumper to the Green LED was also removed from the SCL line. Being required to have 15k pull ups on the I2C bus seems wrong to me especially since the datasheet recommends 4.7k. Am I missing something? I am not well versed in I2C and Freescale's tech support has been less than helpful. I did order a MMA8451 sample and swapped it on SparkFun's breakout board and had the same problem. So I know the problem was not specific to that MMA8452. Other I2C devices (like the BQ32000) work fine.
  3. Hey all, I'm having some trouble with a project that checks a pin every hour and should trip a relay if a certain pin is HIGH. Some notes: - this is with the MSP430G2553 chip - it seems to run fine if duration is low (ex: 5000ms) - it worked at least once (triggered buzzer after an hour) when I replaced the relay circuit with a simple buzzer I'm using this relay circuit: And this code using TwoMsTimer library: #include <TwoMsTimer.h> unsigned long duration = 3600000; int relayPin = 14; int moistPin = 15; int state = 0; void setup() { pinMode(relayPin, OUTPUT); pinMode(moistPin, INPUT); digitalWrite(relayPin, LOW); // necessary bc energia sets green led HIGH by default? TwoMsTimer::set(duration, checkMoisture); TwoMsTimer::start(); } void loop() { if (state == 1) { state = 0; // set state back to zero digitalWrite(relayPin, HIGH); delay(500); digitalWrite(relayPin, LOW); } } void checkMoisture() { if(digitalRead(moistPin) == HIGH) { // set state to 1 to trip relay next time loop runs state = 1; } } Any help is much appreciated. Thanks, Matt
×
×
  • Create New...