PDA

View Full Version : My first (larger) Propeller Project



Reinhard
10-24-2011, 10:35 PM
Hello,
my goal is to learn, programming the Propeller in C (at the best Catalina).
For this way i search a real project, better than a theoretical exercise.

Based on the original idea
http://www.exp-astro.phys.ethz.ch/astro1/Users/cmonstei/instrument/callisto/ecallisto/applidocs.htm
i build a prototype on breadboard and prog a PROPSTICK/USB with following tasks:

communication with a host (PC)
control a DVBT tuner modul via I2C Bus
read analog value from an 12Bit ADC (MAX127)

The tuner works from 50MHz to 900MHz in 62.500 KHz steps.
The start/stop frequency and the step comes from host (PC) to the Propeller.
The Propeller set the Tunermodul to the requested frequency.
The IF output from tuner feed an logarithmic amplifier, which outputs 25mV/dB.
This output is simple low pass filtered with RC element.
This filtered signal goes into an ADC, which is readed via 4wire bus from the Propeller.
finally the Propeller send this Value to the host(PC).

If anybody is interest, here are the first results:
http://home.mnet-online.de/reimay/Projects/Radiometer/

There are several sub directories:

Firmware: the propeller chip , programmed in C.
Software: a quick&dirty hack for the host.
Hardware: datasheets for used electronic components and several photos from the breadboard (bad quality, the photo not the board ;-)
Logs: a scan from 50MHz to 900MHz in 62.500 KHz steps, x axis = frequenty y-axis is value from ADC.
note the DVBT carriers between 600MHz and 800Mhz, which received with a simple bar antenna here in munich.

best regards,
Reinhard

jazzed
10-24-2011, 10:59 PM
Congrats. Nice project.

Rayman
10-25-2011, 12:28 AM
Looks like a great project, very professional.

Out of curiousity (marketing question here), why did you choose Catalina and C over SPIN?
Was it so you could copy over code from a PC?

graffix
10-25-2011, 12:42 AM
Welcome to the forums Reinhard!!!

Reinhard
10-25-2011, 07:55 AM
Looks like a great project, very professional.

Out of curiousity (marketing question here), why did you choose Catalina and C over SPIN?
Was it so you could copy over code from a PC?

Thank you Rayman,
the simple answer is, SPIN is quite an excellence Programming Language,
but my favorits, over years, are C,C++ and Java (in this order).

Further i can test some hardware independ algos on PC.

The Propeller is a great(!) chip and since is it possible programm FPGAs with C, why not the Propeller.

best regards,
Reinhard

Rayman
10-25-2011, 02:25 PM
Thanks Reinhard. I see you are upgrading from ATMega to Propeller.
So, I guess the original program was in C also, right?

Did you have trouble getting the I2C and that 4-wire bus communications working in Catalina?

Reinhard
10-25-2011, 02:58 PM
Thanks Reinhard. I see you are upgrading from ATMega to Propeller.
So, I guess the original program was in C also, right?

Did you have trouble getting the I2C and that 4-wire bus communications working in Catalina?

Hi Rayman,
you are right , I adapt the I2C Routines from the origin ATMega Sourcecode, so I have no problem with this issue.

the 4wire bus protocol is developed by myself in very short time.
I read the datasheet and implement step by step the protocol.

I am not a newbie in C - programming ( experience > 10 years) and the real challenge is to combine my background knowledge with this S U P E R chip.

By the way, just now I found in this forum a link to the propgcc project. W O W !
I can not await to try this ;-)

best regards,
Reinhard