Jump to content
43oh

hobron9

Members
  • Content Count

    9
  • Joined

  • Last visited

About hobron9

  • Rank
    Noob Class

Profile Information

  • Location
    Pittsburgh, PA
  • Interests
    amateur radio
  1. Thanks, I'll do that. Update, I just removed two ; and two= and the program runs as expected. I just now need to enhance a couple of things and it is done. Thanks for your help, you pointed me in the right direction, and that tutorial is great, much better than the C programming text book I have. Now,, on to a visual basic program for the PC end of this.
  2. Can anyone explain why the long variable 'frequency' will not change based on pin status? (loop function) I know I must be doing something wrong but I can't seem to figure it out. The program as written works. I type in for example 7000000 and the DDS programs to 7.0 Mhz. If a pin is pulled low I want to add or subtract 1500. But that part does not work. It always sets the DDS to the input frequency. I've added print statements to verify what is happening and I know the program is detecting pin state OK. so something is wrong with my logic for adding or subtracting. file attache
  3. Thanks, that solved the problem. The DDS now programs to the frequency I send it via the serial monitor and then reflects it back. I just now need to have it maintain the frequency as it resets after a couple of seconds. I used the code you suggested above. How do I latch the 'frequency' data till I send new data? It resets 'frequency' to zero and re-sends it to reset the DDS. I need to store that data somewhere or don't resend until new data is received from the serial monitor. Got it to work. Not great coding but added a goto to jump over sendFrequency(frequency). if (frequenc
  4. I've uploaded a picture of my board setup to control the DDS on left. I do think there is something wrong with the serial setup since I loaded and ran the 4. communications example and it did not put out anything when reset to the serial monitor. I also put some print statements into some code and saw no output to the serial monitor. Data is definitely not being input into the program. It's probably something simple I've overlooked and I really appreciate your help. By the way, I set the com port on com1, com2, com3 and com4 with only com4 reflecting back what I typed into the serial monit
  5. I must be missing something. Is there any way to see what has been loaded into 'frequency'? In other compilers I've used you could just put 'debug' on the line and it would display values. I put in the code you suggested and added sendFrequency (frequency); but still nothing. The program does compile and load. Serial monitor does print what I sent. It appears that nothing is being loaded into 'frequency' or it is not what I sent from the serial monitor. I put in a number such as 7222222 to see if it was dropping zeros but still no results. But, if I put in a number directly in the frequ
  6. Thanks, I'll try that. Just a thought, do I need to jumper the RXD and TXD pins (P1_1 AND P1_2) on the board as well as the TX and RX pins in the jumper field? I'm using a ver 1.3 board so the jumpers are different than 1.5.
  7. Thanks for the input; I tried your suggestion but still no results. I used the routine in 4. communications for serial event. The input from the serial monitor does not seem to be assigned to 'frequency'. Number sent from the serial input reflects back and prints of the serial monitor. I must be missing something. It's getting late so I will get back to it tomorrow.
  8. To clarify the above topic, can anyone suggest a way to make the serial data sent via the usb port from the pc using the serial monitor function, available to load into a variable that I can plug into the program and use to set the frequency of the dds? I want to input a number from 1000000 to 30000000. I can't find an example anywhere. Thanks
  9. Hi everyone, I'm new to launchpad and I want to control a DDS ad9850 module using launchpad. I got this program to work so far. It compiles and uploads OK. It will set the frequency I want and I have added serial input via USB and it works in that it answers back whatever I send via the serial monitor (using energia). What I can't figure out, is how to take the data I send via the serial monitor to be put into the field at the bottom of the program ("sendFrequency"). It's now set to 7.255 Mhz If I change the number there, the DDS will change to that frequency, so the link to the serial data
×
×
  • Create New...